好看的首页展示

news2024/9/27 10:46:41

代码

<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* RESET STYLES
–––––––––––––––––––––––––––––––––––––––––––––––––– */
        @import url("https://fonts.googleapis.com/css2?family=Bitter:ital,wght@0,100..900;1,100..900&display=swap");

        :root {
            --height: 80vh;
            --half-height: calc(var(--height) / 2);
            --transition: all 1s;
        }

        * {
            box-sizing: border-box;
        }

        body {
            font-family: "Bitter", serif;
            margin: 20px 0;
            padding: 0 15px;
            background: #cae9ff;
        }

        a {
            color: inherit;
        }

        .notification {
            display: none;
            position: absolute;
            top: 0;
            right: 0;
            padding: 10px;
            font-size: 0.85em;
            background: #e9c46a;
        }

        /* MAIN STYLES
–––––––––––––––––––––––––––––––––––––––––––––––––– */
        .grid,
        .sub-grid,
        .grid .card {
            transition: var(--transition);
        }

        .grid {
            max-width: 1600px;
            margin: 0 auto;
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.35);
        }

        .card {
            cursor: pointer;

            figure,
            img {
                width: 100%;
                height: 100%;
            }

            figure {
                position: relative;
                margin: 0;
                overflow: hidden;
            }

            img {
                object-fit: cover;
                background: #333;
            }

            figcaption {
                position: absolute;
                top: 0;
                left: 0;
                width: 100%;
                height: 100%;
                display: grid;
                place-items: center;
                font-size: 1.5em;
                line-height: 1.3;
                text-align: center;
                padding: 10px;
                color: white;
                background: rgba(0, 0, 0, 0.5);

                span {
                    display: block;
                    font-size: 0.75em;
                }
            }
        }

        @media (max-width: 899px) {
            .card {
                height: var(--half-height);
            }
        }

        @media (min-width: 900px) {

            .grid,
            .sub-grid {
                display: grid;
            }

            .grid {
                grid-template-columns: 2fr 1fr 1fr;
            }

            .sub-grid {
                grid-template-rows: var(--half-height) var(--half-height);
            }

            .sub-grid-1 {
                grid-template-columns: 1fr 1fr auto;
            }

            .sub-grid-1 .card:last-child {
                grid-column: 1/-1;
            }

            /*.sub-grid-2 {
    grid-template-columns: 1fr;
  }*/

            .grid>.card {
                height: var(--height);
            }
        }

        @media (hover: hover) and (min-width: 900px) {
            .notification {
                display: block;
            }

            .grid:has(.sub-grid-1 .card:first-of-type:hover) .sub-grid-1 {
                grid-template-columns: 1fr 0fr auto;
            }

            .grid:has(.sub-grid-1 .card:nth-of-type(2):hover) .sub-grid-1 {
                grid-template-columns: 0fr 1fr auto;
            }

            .grid:has(.sub-grid-1 .card:last-of-type:hover) .sub-grid-1 {
                grid-template-rows: 0 var(--height);
            }

            .grid:has(> .card:hover) {
                grid-template-columns: 0fr 1fr 0fr;
            }

            .grid:has(.sub-grid-2 .card:first-of-type:hover) .sub-grid-2 {
                grid-template-rows: var(--height) 0;
            }

            .grid:has(.sub-grid-2 .card:last-of-type:hover) .sub-grid-2 {
                grid-template-rows: 0 var(--height);
            }

            .card {
                filter: grayscale(1);

                figcaption {
                    opacity: 0;
                }

                &:hover {
                    filter: grayscale(0);

                    figcaption {
                        opacity: 1;
                        transition: opacity 0.5s 0.5s;
                    }
                }
            }
        }

        /* FOOTER STYLES–––––––––––––––––––––––––––––––––––––––––––––––––– */
        .page-footer {
            position: fixed;
            right: 0;
            bottom: 50px;
            display: flex;
            align-items: center;
            padding: 5px;
            font-size: 0.9em;
            background: white;
        }

        .page-footer a {
            display: flex;
            margin-left: 4px;
        }
    </style>
</head>

<body>
    <div class="grid">
        <div class="sub-grid sub-grid-1">
            <article class="card">
                <figure>
                    <img width="1600" height="900" src="https://assets.codepen.io/162656/beach2.jpg" alt="">
                    <figcaption>
                        <div>
                            Santorini, Greece
                            <span>by <a href="https://unsplash.com/photos/white-sun-lounger-lot-KrGbdPfIYD4"
                                    target="_blank">Khamkéo</a>
                            </span>
                        </div>
                    </figcaption>
                </figure>
            </article>
            <article class="card">
                <figure>
                    <img width="1600" height="1067" src="https://assets.codepen.io/162656/beach6.jpg" alt="">
                    <figcaption>
                        <div>
                            Kvalvika Beach, Moskenes, Norway
                            <span>by <a href="https://unsplash.com/photos/beach-near-mountain-range-wnRvXXzZK7w"
                                    target="_blank"></a>Martine Jacobsen
                            </span>
                        </div>
                    </figcaption>
                </figure>
            </article>
            <article class="card">
                <figure>
                    <img width="1600" height="1036" src="https://assets.codepen.io/162656/beach3.jpg" alt="">
                    <figcaption>
                        <div>
                            San Lorenzo, Italy
                            <span>by <a href="https://unsplash.com/photos/photo-of-seashore-d7M5Xramf8g"
                                    target="_blank">Camille Minouflet</a>
                            </span>
                        </div>
                    </figcaption>
                </figure>
            </article>
        </div>
        <article class="card">
            <figure>
                <img width="1600" height="900" src="https://assets.codepen.io/162656/beach4.jpg" alt="">
                <figcaption>
                    <div>
                        McWay Falls, California, USA
                        <span>by <a
                                href="https://unsplash.com/photos/aerial-photography-of-boulders-on-body-of-water-07mSKrzKiRw"
                                target="_blank">Chor Tsang</a>
                        </span>
                    </div>
                </figcaption>
            </figure>
        </article>
        <div class="sub-grid sub-grid-2">
            <article class="card">
                <figure>
                    <img width="1600" height="1064" src="https://assets.codepen.io/162656/beach5.jpg" alt="">
                    <figcaption>
                        <div>
                            Inisheer, County Galway, Ireland
                            <span>by <a
                                    href="https://unsplash.com/photos/a-beach-with-a-boat-on-it-and-people-walking-on-it-Il4WLGeMsUk"
                                    target="_blank">Ulrike R. Donohue</a>
                            </span>
                        </div>
                    </figcaption>
                </figure>
            </article>
            <article class="card">
                <figure>
                    <img width="1600" height="898" src="https://assets.codepen.io/162656/beach1.jpg" alt="">
                    <figcaption>
                        <div>
                            Beaches, Jacksonville Beach, Florida, United States
                            <span>by <a href="https://unsplash.com/photos/man-surfing-on-waves-L5aI2jU0i50"
                                    target="_blank">Lance Asper</a>
                            </span>
                        </div>
                    </figcaption>
                </figure>
            </article>
        </div>
    </div>
    <p class="notification">Hover over a card</p>
    <footer class="page-footer">
        <span>made by </span>
        <a href="https://georgemartsoukos.com/" target="_blank">
            <img width="24" height="24" src="https://assets.codepen.io/162656/george-martsoukos-small-logo.svg"
                alt="George Martsoukos logo">
        </a>
    </footer>
</body>

</html>

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2169730.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

气膜游泳馆:舒适恒温,寒冷季节中的理想游泳场所—轻空间

随着天气逐渐转凉&#xff0c;许多人在秋冬季节减少了户外活动&#xff0c;尤其是游泳。然而&#xff0c;气膜游泳馆为您提供了一种全新的选择&#xff0c;让您即使在寒冷的季节&#xff0c;也能享受畅游的乐趣。凭借其独特的恒温设计和舒适的环境&#xff0c;气膜游泳馆成为了…

计算机毕业设计宠物领养网站我的发布领养领养用户信息/springboot/javaWEB/J2EE/MYSQL数据库/vue前后分离小程序

目录 1.课题背景 2.课题意义 ‌ 3.技术介绍 4.技术性需求 4.1后端服务‌&#xff1a; 4.2 前端展示‌ 5.数据库设计‌&#xff1a; 6.系统性能‌&#xff1a; 7.安全性‌&#xff1a; 8. 功能介绍&#xff1a; 9. 部分代码 1.课题背景 近年来&#xff0c;随着宠物饲养数量…

TDEngine在煤矿综采管控平台中的应用

一、行业背景 智能综采管控平台&#xff0c;是将煤矿综采工作面传感器数据采集&#xff0c;通过可视化界面展示。实现综采工作面的透明化展示&#xff0c;并基于历史的传感器数据进行机器学习的训练&#xff0c;了解工作面周期来压&#xff0c;设备故障检测等数据应用。因此针…

AIGC引领数智未来:企业架构演进的深度解析与实践路径,The Open Group 2024生态系统架构·可持续发展年度大会专题报道

随着人工智能技术的迅猛发展&#xff0c;特别是以ChatGPT、Sora等为代表的AIGC&#xff08;人工智能生成内容&#xff09;技术的爆发&#xff0c;我们正处于通用人工智能&#xff08;AGI&#xff09;时代的前夜。AIGC技术在多个领域展现出近乎甚至超越人类的能力&#xff0c;已…

【LeetCode】动态规划—最小路径和(附完整Python/C++代码)

动态规划—64. 最小路径和 前言题目描述基本思路1. 问题定义:2. 理解问题和递推关系:3. 解决方法:3.1. 初始化:3.2. 边界条件:3.3. 填充 dp 数组:3.4. 返回结果: 4. 进一步优化:5. 小总结: 代码实现Python3代码实现Python 代码解释C代码实现C 代码解释 总结: 前言 给定一个包含…

liunx系统虚拟机

https://mirrors.aliyun.com/centos/7.9.2009/isos/x86_64/ 下载地址 DVD版本 安装vm软件12通过vm软件来创建一个虚拟机空间通过vm软件在创建好的虚拟机空间上&#xff0c;安装我们的centos操作系统使用centos你得需要将鼠标点击进入界面中&#xff0c;但是鼠标会消失&#xf…

杨辉三角-C语言

1.问题&#xff1a; 输出杨辉三角。 2.解答&#xff1a; 对有特点的数&#xff08;每行开头和结束的数都是1&#xff09;进行赋值&#xff0c;给中间的数进行赋值&#xff0c;把上面赋值后的二维数组&#xff0c;遍历输出。 3.代码&#xff1a; #include<stdio.h>//头…

基于SSM商铺租赁系统JAVA|VUE|SSM计算机毕业设计源代码+数据库+LW文档+开题报告+答辩稿+部署教+代码讲解

源代码数据库LW文档&#xff08;1万字以上&#xff09;开题报告答辩稿 部署教程代码讲解代码时间修改教程 一、开发工具、运行环境、开发技术 开发工具 1、操作系统&#xff1a;Window操作系统 2、开发工具&#xff1a;IntelliJ IDEA或者Eclipse 3、数据库存储&#xff1a…

使用session来实现验证码发送功能

一、什么是session&#xff1f; Session由服务器创建&#xff0c;并为每一次会话分配一个Session对象。同一个浏览器发起的多次请求&#xff0c;同属于一次会话&#xff08;Session&#xff09;。首次使用到Session时&#xff0c;服务器会自动创建Session&#xff0c;并创建Co…

大觅网之自动化部署(Automated Deployment of Da Mi Network)

&#x1f49d;&#x1f49d;&#x1f49d;欢迎来到我的博客&#xff0c;很高兴能够在这里和您见面&#xff01;希望您在这里可以感受到一份轻松愉快的氛围&#xff0c;不仅可以获得有趣的内容和知识&#xff0c;也可以畅所欲言、分享您的想法和见解。 本人主要分享计算机核心技…

前端大模型入门:Transformer.js 和 Xenova-引领浏览器端的机器学习变革

除了调用别人的api接口使用transformer技术&#xff0c;你是否想过将大模型在浏览器中运行呢&#xff1f;尤其是WebGPU的出现&#xff0c;性能比WebGL高不少&#xff0c;很多小任务真的不再需要在一个中心运行了。 不少同学买课学python了&#xff0c;但我还是在坚持用js尝试&a…

【Linux实践】实验九:Shell流程控制语句

【Linux实践】实验九&#xff1a;Shell流程控制语句 实验目的实验内容实验步骤及结果1. 变量的定义和使用2. 条件3. 运算4. if 语句5. case 语句6. for 语句7. while 语句8. until 语句9. 遍历复制10. 计算平方 实验目的 1、掌握条件判断语句&#xff0c;如if语句、case语句。…

tomcat的安装,管理与配置

目录 Tomcat 服务部署 1.关闭防火墙&#xff0c;将安装 Tomcat 所需软件包上传到虚拟机 2.安装JDK 3.设置JDK环境变量 4.安装启动Tomcat 5.启动tomcat 6.优化tomcat启动速度 Tomcat 服务管理 systemd 管理控制 supervisor 管理控制 Tomcat 虚拟主机配置 1.创建 sun…

EE trade:黄金 999 和黄金 9999 的区别

黄金&#xff0c; 作为一种珍贵的金属&#xff0c; 一直是人们投资和收藏的对象。 在购买黄金时&#xff0c; 您可能会遇到两种纯度的黄金 —— 黄金 999 和黄金 9999。 这两种黄金有什么区别? 消费者应该如何选择呢? 一、 黄金 999 和黄金 9999 的区别 含金量&#xff1a;…

OCR 行驶证识别 离线识别

目录 正页识别 副页识别 全部识别 OCR 行驶证识别 离线识别 正页识别 副页识别 全部识别

C语言实现归并排序(Merge Sort)

目录 一、递归实现归并排序 1. 归并排序的基本步骤 2.动图演示 3.基本思路 4.代码 二、非递归实现 1.部分代码 2.代码分析 修正后代码&#xff1a; 归并过程打印 性能分析 复杂度分析 归并排序是一种高效的排序算法&#xff0c;采用分治法&#xff08;Divide and Con…

中电金信:“源启”金融级数字底座

01方案简介 金融级数字底座是中电金信依托中国电子自主安全计算产业链&#xff0c;采用新一代技术架构&#xff0c;为金融及重点行业打造的数字化新型基础设施。 “源启”面向金融等重点行业场景&#xff0c;依照系统工程方法论&#xff0c;进行全栈技术产品的验证、适配和调…

word2vector训练数据集整理(代码实现)

import math import os import random import torch import dltools from matplotlib import pyplot as plt #读取数据集 def read_ptb():"""将PTB数据集加载到文本行的列表中"""with open(./ptb/ptb.train.txt) as f:raw_text f.read()return…

【深度学习基础模型】双向循环神经网络(Bidirectional Recurrent Neural Networks, BiRNN)详细理解并附实现代码。

【深度学习基础模型】双向循环神经网络&#xff08;Bidirectional Recurrent Neural Networks, BiRNN&#xff09; 【深度学习基础模型】双向循环神经网络&#xff08;Bidirectional Recurrent Neural Networks, BiRNN&#xff09;详细理解并附实现代码。 文章目录 【深度学习…

使用 Llama 3.1 和 Qdrant 构建多语言医疗保健聊天机器人的步骤

长话短说&#xff1a; 准备好深入研究&#xff1a; 矢量存储的复杂性以及如何利用 Qdrant 进行高效数据摄取。掌握 Qdrant 中的集合管理以获得最佳性能。释放上下文感知响应的相似性搜索的潜力。精心设计复杂的 LangChain 工作流程以增强聊天机器人的功能。将革命性的 Llama …