@import url('https://fonts.googleapis.com/css2?family=Outfit&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Sumana&display=swap');
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@500&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* 通用隐藏滚动条 */
    overflow: auto;
    /* 保留滚动功能 */
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE 10+ */
}

/* Chrome / Safari / Edge */
html::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

body {
    background: url("https://Geekstrange.github.io/images/background.jpg") no-repeat center center fixed;
    background-size: cover;
    min-height: 100vh;
    font-family: "Outfit", sans-serif;
    overflow-x: hidden;
}

.bg-glass {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;

    background: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.4));
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    /* Safari 兼容 */
    pointer-events: none;
    /* 不阻挡页面交互 */
}

header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 30px 100px;
    color: #112434;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;

    opacity: 0;
    /* 1️初始透明 */
    transform: translateY(-50px);
    /* 2️初始向上偏移 */
    animation: slideDown 0.8s ease-out forwards;
    animation-delay: 1s;
    /* 可根据打字动画时间调整 */
}

.logo-bg {
    fill: #000;
    clip-path: url(#clipFolded);
    transition: clip-path 0.4s ease-in-out;
}

.fold-corner {
    fill: #fff;
    transition: opacity 0.4s ease;
}

.logo:hover .logo-bg {
    clip-path: url(#clipFull);
}

.logo:hover .fold-corner {
    opacity: 0;
}

@keyframes slideDown {
    0% {
        opacity: 0;
        transform: translateY(-50px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.navigation {
    display: flex;
    gap: 20px;
    list-style: none;
}

.navigation a {
    text-decoration: none;
    padding: 6px 15px;
    border-radius: 20px;
    color: #112434;
    font-size: 1rem;
}

.navigation a:hover,
.navigation a.active {
    background-color: #112434;
    color: white;
}

.parallax {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
}

.scroll-indicator {
    text-decoration: none;
    border: none;
}

#title {
    font-size: 8rem;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 7rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    position: relative;
    color: #0d0d0d;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
}

#title::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 8rem;
    background: #0d0d0d;
    right: -30px;
    border-radius: 2px;
    animation: blink 1.1s steps(2, jump-none) 5 forwards;
}

@keyframes blink {

    0%,
    49% {
        opacity: 1;
    }

    50%,
    100% {
        opacity: 0;
    }
}

#title span {
    --delay: 10s;
    display: inline-block;
    overflow: hidden;
    width: 0ch;
    animation: text-in 0.1s ease-in-out forwards;
    animation-delay: var(--delay);
}

@keyframes text-in {
    from {
        width: 0ch;
    }

    to {
        width: 1ch;
    }
}

.scroll-indicator {
    opacity: 0;
    transition: opacity 0.6s ease;
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2rem;
    color: #D8E3E7;
    z-index: 10;
    pointer-events: none;
}

.scroll-indicator.show {
    opacity: 0.7;
    pointer-events: auto;
    animation: pulse 2s infinite ease-in-out,
        floatUpDown 2s infinite ease-in-out;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.4;
    }

    50% {
        opacity: 1;
    }
}

@keyframes floatUpDown {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@keyframes fadeZoomIn {
    0% {
        opacity: 0;
        transform: scale(0.9);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.h2two {
    font-size: 23px;
    color: #222;
    text-transform: uppercase;
    letter-spacing: 5px;
    cursor: pointer;
    position: relative;
    z-index: 6;
    text-align: center;
    opacity: 0;
    transform: scale(0.9);
    transition: all 0.6s ease;
}

.h2two span {
    transition: 0.8s;
}

.h2two:hover span:nth-child(1) {
    margin-right: 10px;
}

.h2two:hover span:nth-child(1)::after {
    content: "IF";
    margin-left: 5px;
}

.h2two:hover span:nth-child(2) {
    margin-left: 25px;
}

.h2two:hover span {
    color: #fff;
    text-shadow:
        0 0 10px #fff,
        0 0 20px #fff,
        0 0 40px #fff,
        0 0 80px #fff,
        0 0 120px #fff,
        0 0 160px #fff;
}

.cards {
    display: grid;
    gap: 60px;
    padding: 60px 5%;
    grid-template-columns: 1fr;
}

.card {
    position: relative;
    width: min(100%, 1200px);
    margin: 0 auto;
}

.card-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 30px;
    position: relative;
    align-items: center;
    z-index: 2;
}

.black-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
    border-radius: 10px;
}

.card-image {
    width: 100%;
    max-width: 380px;
    height: 280px;
    object-fit: contain;
    margin: auto;
    z-index: 2;
}

.card-text {
    padding: 0 30px;
    font-family: "Sumana", serif;
    z-index: 2;
}

.card:nth-child(odd) .card-image {
    order: 1;
}

.card:nth-child(odd) .card-text {
    order: 2;
}

.card:nth-child(even) .card-image {
    order: 2;
}

.card:nth-child(even) .card-text {
    order: 1;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    color: white;
    opacity: 0;
    transition: 0.4s ease;
    z-index: 3;
    border-radius: 10px;
}

.overlay-content span {
    display: inline-block;
    transition: all 0.4s ease;
    cursor: pointer;
}

.overlay-content span:hover {
    color: #fff;
    text-shadow:
        0 0 5px #fff,
        0 0 10px #fff,
        0 0 20px #fff,
        0 0 40px #fff;
}

.overlay-content {
    width: 80%;
    text-align: center;
    padding: 30px;
}

.overlay-content p {
    font-size: 0.9em;
    line-height: 1.6;
}

.copy {
    text-align: center;
    font-family: "Sumana", serif;
    padding-bottom: 40px;
}

@media (max-width: 900px) {
    .card-content {
        grid-template-columns: 1fr;
    }

    .card-image {
        height: 240px;
        margin-bottom: 20px;
    }

    .card-text {
        text-align: left !important;
        padding: 0 10% !important;
    }
}

@media (min-width: 901px) {
    .card:nth-child(odd) .card-text {
        text-align: right;
        padding-left: 15%;
        padding-right: 5%;
    }

    .card:nth-child(even) .card-text {
        text-align: left;
        padding-right: 15%;
        padding-left: 5%;
    }
}
