/* ========================================
   penclos.com — Blobitecture Chrome Metallic
   ======================================== */

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background-color: #1A1D23;
    color: #D1D5DB;
    font-family: 'Nunito', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.65;
    overflow-x: hidden;
    position: relative;
}

/* --- Crosshatch Background Pattern --- */
.crosshatch-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    pointer-events: none;
    background-image:
        repeating-linear-gradient(0deg, transparent, transparent 19px, rgba(200,205,213,0.06) 19px, rgba(200,205,213,0.06) 20px),
        repeating-linear-gradient(90deg, transparent, transparent 19px, rgba(200,205,213,0.06) 19px, rgba(200,205,213,0.06) 20px);
}

/* --- Ambient Chrome Spheres --- */
.ambient-sphere {
    position: fixed;
    z-index: -1;
    border-radius: 50%;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 35%, #6B7280 70%, #4A4E58 100%);
    pointer-events: none;
    opacity: 0.15;
    will-change: transform;
}

.sphere-1 {
    width: 260px;
    height: 260px;
    top: 8vh;
    left: -80px;
    animation: sphereFloat 20s ease-in-out infinite;
}

.sphere-2 {
    width: 140px;
    height: 140px;
    top: 30vh;
    right: 5vw;
    animation: sphereFloat 22s ease-in-out infinite 3s;
}

.sphere-3 {
    width: 200px;
    height: 200px;
    bottom: 20vh;
    left: 10vw;
    animation: sphereFloat 18s ease-in-out infinite 6s;
}

.sphere-4 {
    width: 100px;
    height: 100px;
    top: 55vh;
    right: 20vw;
    animation: sphereFloat 24s ease-in-out infinite 2s;
}

.sphere-5 {
    width: 300px;
    height: 300px;
    bottom: 5vh;
    right: -100px;
    animation: sphereFloat 20s ease-in-out infinite 8s;
}

@keyframes sphereFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

/* --- Hero Section --- */
#hero {
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.hero-blob {
    width: 70vw;
    height: 50vh;
    min-width: 300px;
    min-height: 260px;
    max-width: 1000px;
    max-height: 600px;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 35%, #6B7280 70%, #4A4E58 100%);
    border-radius: 42% 58% 45% 55% / 48% 52% 56% 44%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: transform 0.8s cubic-bezier(0.22, 0.61, 0.36, 1), opacity 0.8s ease;
    will-change: transform, opacity;
    padding: 2rem;
}

.hero-blob-highlight {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: radial-gradient(ellipse at 30% 30%, rgba(244,246,248,0.4) 0%, transparent 70%);
    pointer-events: none;
}

.hero-title {
    font-family: 'Bungee', cursive;
    font-size: clamp(3rem, 7vw, 8rem);
    text-transform: uppercase;
    letter-spacing: -0.02em;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 35%, #6B7280 70%, #4A4E58 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: chromeShimmer 2s ease forwards;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.3));
}

@keyframes chromeShimmer {
    0% { background-position: -100% 0; }
    100% { background-position: 0% 0; }
}

.hero-subtitle {
    font-family: 'Righteous', cursive;
    font-size: clamp(1rem, 2vw, 1.4rem);
    color: #2D2D3A;
    text-align: center;
    margin-top: 0.5rem;
    position: relative;
    z-index: 1;
    max-width: 480px;
    opacity: 0.85;
}

/* Hero recede on scroll */
.hero-blob.receded {
    transform: scale(0.92);
    opacity: 0.7;
}

/* --- Sticky Navigation --- */
.sticky-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.8rem 2rem;
    background: rgba(26, 29, 35, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(200, 205, 213, 0.08);
    transform: translateY(-100%);
    transition: transform 0.4s cubic-bezier(0.22, 0.61, 0.36, 1);
    pointer-events: none;
}

.sticky-nav.visible {
    transform: translateY(0);
    pointer-events: all;
}

.nav-logo {
    font-family: 'Bungee', cursive;
    font-size: 1rem;
    text-transform: uppercase;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 50%, #6B7280 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-link {
    font-family: 'Righteous', cursive;
    font-size: 0.9rem;
    color: #B8C0CC;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #D4A574;
}

.nav-link:visited {
    color: #7B8FA8;
}

/* --- Pod Clusters --- */
.pod-cluster {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: center;
    gap: 2rem;
    padding: 6vh 4vw;
    margin-bottom: 12vh;
}

.cluster-1 { padding-top: 8vh; }
.cluster-2 { justify-content: flex-end; padding-right: 8vw; }
.cluster-3 { justify-content: flex-start; padding-left: 8vw; }
.cluster-4 { justify-content: center; }
.cluster-5 { justify-content: center; margin-bottom: 6vh; }

/* --- Mercury Drip Connectors --- */
.mercury-connector {
    position: absolute;
    top: -150px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 200px;
    opacity: 0.3;
    pointer-events: none;
}

.connector-1 { left: 40%; }
.connector-2 { left: 55%; }
.connector-3 { left: 45%; }
.connector-4 { left: 50%; }
.connector-5 { left: 48%; }

/* --- Pods --- */
.pod {
    position: relative;
    background: #2D2D3A;
    border-radius: var(--br-tl) var(--br-tr) var(--br-br) var(--br-bl) / var(--br-tl2) var(--br-tr2) var(--br-br2) var(--br-bl2);
    padding: clamp(1.5rem, 3vw, 2.5rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    transition:
        transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
        box-shadow 0.3s ease,
        filter 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform, filter;
}

.pod-large {
    width: clamp(320px, 55vw, 720px);
    aspect-ratio: 4 / 3;
}

.pod-medium {
    width: clamp(240px, 38vw, 520px);
    aspect-ratio: 5 / 4;
}

.pod-small {
    width: clamp(180px, 25vw, 340px);
    aspect-ratio: 1 / 1;
}

/* Reflection arc highlight */
.pod-highlight {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: radial-gradient(ellipse at 30% 30%, rgba(244,246,248,0.12) 0%, transparent 70%);
    pointer-events: none;
    transition: background 0.3s ease;
    z-index: 2;
}

/* Zoom-focus initial state */
.zoom-target {
    transform: scale(0.88);
    filter: blur(3px);
    opacity: 0.6;
}

.zoom-target.in-view {
    transform: scale(1);
    filter: blur(0);
    opacity: 1;
}

/* Pod hover */
.pod:hover {
    transform: scale(1.03);
    box-shadow: 0 0 40px rgba(212, 165, 116, 0.15);
}

.pod:hover .pod-highlight {
    background: radial-gradient(ellipse at 30% 30%, rgba(244,246,248,0.25) 0%, transparent 70%);
}

/* Chrome gradient shift on hover */
.pod::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(215deg, rgba(244,246,248,0.05) 0%, rgba(200,205,213,0.03) 35%, rgba(107,114,128,0.02) 70%, rgba(74,78,88,0.04) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    z-index: 1;
}

.pod:hover::before {
    opacity: 1;
}

/* --- Pod Typography --- */
.pod-title {
    font-family: 'Bungee', cursive;
    font-size: clamp(1.4rem, 3vw, 2.2rem);
    text-transform: uppercase;
    letter-spacing: -0.02em;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 35%, #6B7280 70%, #4A4E58 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 3;
}

.pod-body {
    font-family: 'Nunito', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.65;
    color: #D1D5DB;
    position: relative;
    z-index: 3;
}

.pod-body-small {
    font-family: 'Nunito', sans-serif;
    font-weight: 400;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #D1D5DB;
    position: relative;
    z-index: 3;
}

.pod-label {
    font-family: 'Righteous', cursive;
    font-size: clamp(1.2rem, 2.5vw, 2rem);
    color: #B8C0CC;
    margin-bottom: 0.5rem;
    display: block;
    position: relative;
    z-index: 3;
}

.pod-meta {
    font-family: 'Overpass Mono', monospace;
    font-weight: 400;
    font-size: 0.8rem;
    color: rgba(232, 236, 241, 0.6);
    margin-top: 0.75rem;
    display: block;
    position: relative;
    z-index: 3;
}

/* --- Concentric Rings --- */
.concentric-rings {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.concentric-rings svg {
    width: 100%;
    height: 100%;
}

.rings-offset {
    top: 40%;
    left: 60%;
}

/* --- Pod Image Wrapper --- */
.pod-image-wrapper {
    position: relative;
    width: 100%;
    height: 60%;
    border-radius: 35% 45% 40% 38% / 42% 38% 45% 40%;
    overflow: hidden;
    margin-bottom: 0.75rem;
    z-index: 3;
}

.pod-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    filter: grayscale(0.7) contrast(1.15) brightness(0.9) sepia(0.15);
}

.chrome-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 35%, #6B7280 70%, #4A4E58 100%);
    mix-blend-mode: overlay;
    opacity: 0.5;
    pointer-events: none;
}

/* --- Footer Blob --- */
.footer-blob-section {
    display: flex;
    justify-content: center;
    padding: 4vh 4vw 8vh;
    position: relative;
}

.footer-blob {
    width: clamp(320px, 60vw, 800px);
    aspect-ratio: 3 / 2;
    background: linear-gradient(145deg, #F4F6F8 0%, #C8CDD5 35%, #6B7280 70%, #4A4E58 100%);
    border-radius: var(--br-tl) var(--br-tr) var(--br-br) var(--br-bl) / var(--br-tl2) var(--br-tr2) var(--br-br2) var(--br-bl2);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    transition:
        transform 0.6s cubic-bezier(0.22, 0.61, 0.36, 1),
        filter 0.6s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform, filter;
}

.footer-content {
    text-align: center;
    position: relative;
    z-index: 3;
}

.footer-logo {
    font-family: 'Bungee', cursive;
    font-size: clamp(1.5rem, 4vw, 3rem);
    text-transform: uppercase;
    letter-spacing: -0.02em;
    color: #1A1D23;
    display: block;
    margin-bottom: 1rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.footer-link {
    font-family: 'Righteous', cursive;
    font-size: 0.95rem;
    color: #2D2D3A;
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-block;
}

.footer-link:hover {
    color: #D4A574;
}

.footer-copy {
    font-family: 'Overpass Mono', monospace;
    font-size: 0.75rem;
    color: rgba(45, 45, 58, 0.7);
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .pod-cluster {
        flex-direction: column;
        align-items: center;
        padding: 4vh 5vw;
        margin-bottom: 8vh;
    }

    .cluster-2,
    .cluster-3 {
        justify-content: center;
        padding-left: 5vw;
        padding-right: 5vw;
    }

    .pod-large {
        width: clamp(280px, 85vw, 600px);
    }

    .pod-medium {
        width: clamp(240px, 80vw, 500px);
    }

    .pod-small {
        width: clamp(180px, 70vw, 320px);
    }

    .hero-blob {
        width: 85vw;
        height: 55vh;
    }

    .nav-links {
        gap: 1rem;
    }

    .nav-link {
        font-size: 0.8rem;
    }

    .footer-blob {
        width: clamp(280px, 85vw, 600px);
    }

    .footer-links {
        gap: 1rem;
    }

    .mercury-connector {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero-blob {
        width: 92vw;
        height: 50vh;
    }

    .nav-links {
        gap: 0.6rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* --- Selection Color --- */
::selection {
    background: rgba(212, 165, 116, 0.3);
    color: #E8ECF1;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #1A1D23;
}

::-webkit-scrollbar-thumb {
    background: #4A4E58;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #6B7280;
}
