/* =========================================
   1. RESET & BASICS
   ========================================= */
:root {
    --bg-dark: #050505;
    --text-main: #ffffff;
    --text-muted: #9ca3af;
    --accent-gold: #d4af37;
    --card-ratio: 1.586;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body { background: var(--bg-dark); color: var(--text-main); font-family: 'Outfit', sans-serif; overflow-x: hidden; }

/* =========================================
   2. HEADER & LAYOUT (UPDATED)
   ========================================= */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 15px; }

.glass-header {
    position: fixed; top: 0; width: 100%; z-index: 1000;
    background: rgba(5,5,5,0.9); backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.08); padding: 15px 0;
}

.glass-header .container { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    /* Gap taaki desktop par bhi elements chipke nahi */
    gap: 20px; 
}

.logo { 
    font-size: 1.1rem; 
    font-weight: 800; 
    display: flex; 
    align-items: center; 
    gap: 8px; 
    letter-spacing: 1px;
    /* White-space nowrap taaki text kabhi tute nahi */
    white-space: nowrap; 
}

.cta-small { 
    font-size: 0.8rem; 
    padding: 10px 20px; 
    border: 1px solid rgba(255,255,255,0.2); 
    border-radius: 4px; 
    color: #fff; 
    text-decoration: none; 
    transition: 0.3s; 
    white-space: nowrap; /* Button text ek line me rahega */
}
.cta-small:hover { background: #fff; color: #000; }

/* =========================================
   3. HERO SECTION
   ========================================= */
.hero { min-height: 60vh; display: flex; align-items: center; justify-content: center; text-align: center; padding-top: 100px; }
.hero h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); font-weight: 800; margin-bottom: 15px; line-height: 1.1; }
.hero p { color: var(--text-muted); font-size: 1rem; max-width: 500px; margin: 0 auto; }
.badge { color: var(--accent-gold); font-size: 0.75rem; letter-spacing: 3px; display: block; margin-bottom: 15px; }

/* =========================================
   4. CARD GRID
   ========================================= */
.showcase-section { padding: 40px 0 80px; }
.cards-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 50px; }

/* =========================================
   5. REALISTIC CARD ENGINE
   ========================================= */
.card-scene {
    width: 100%; max-width: 340px; aspect-ratio: var(--card-ratio);
    perspective: 1200px; margin: 0 auto; position: relative;
}
.card-object {
    width: 100%; height: 100%; position: relative;
    transform-style: preserve-3d; transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.6); border-radius: 16px;
}

/* --- MOBILE FIX: Only rotate on HOVER supported devices --- */
@media (hover: hover) { 
    .card-scene:hover .card-object { transform: rotateY(180deg); } 
}
/* Click/Tap Logic (Works everywhere) */
.card-object.flipped { transform: rotateY(180deg); }

/* =========================================
   6. CARD FACES & BACKS
   ========================================= */
.face {
    position: absolute; inset: 0; border-radius: 16px;
    padding: 30px;
    backface-visibility: hidden; -webkit-backface-visibility: hidden;
    display: flex; flex-direction: column; justify-content: space-between;
}
.front { z-index: 2; transform: rotateY(0deg); }
.back { 
    transform: rotateY(180deg); 
    display: flex; flex-direction: column; align-items: center; justify-content: center;
}

/* --- CHIP --- */
.chip {
    width: 50px; height: 38px;
    background: linear-gradient(135deg, #e6cfa3 0%, #d4af37 50%, #b8860b 100%);
    border-radius: 6px; position: absolute; top: 60px; left: 30px;
    box-shadow: inset 0 1px 2px rgba(255,255,255,0.2), 0 2px 4px rgba(0,0,0,0.3);
    overflow: hidden;
}
.chip::before { content: ''; position: absolute; top: 50%; left: 0; width: 100%; height: 1px; background: rgba(0,0,0,0.4); }
.chip::after { content: ''; position: absolute; left: 33%; top: 0; width: 1px; height: 100%; background: rgba(0,0,0,0.4); box-shadow: 16px 0 0 rgba(0,0,0,0.4); }

/* --- CARD STYLES --- */
.face-gold, .card-scene:nth-child(1) .back {
    background: linear-gradient(135deg, #8a6e2f 0%, #d4af37 25%, #f9e58b 50%, #b8860b 75%, #5e4b20 100%);
    border: 1px solid #f9e58b; color: #3b2806;
}
.face-gold::after, .card-scene:nth-child(1) .back::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.4) 50%, transparent 60%);
    pointer-events: none; opacity: 0.6;
}

.face-white, .card-scene:nth-child(2) .back {
    background: #fdfdfd; color: #111; border: 1px solid #ccc;
    background-image: radial-gradient(#ddd 1px, transparent 1px); background-size: 10px 10px;
}
.dark-text { color: #111 !important; }

.face-black, .card-scene:nth-child(3) .back {
    background: #111; color: #fff; border: 1px solid #333;
    background: linear-gradient(135deg, #1a1a1a 0%, #050505 100%);
}

.logo-top { font-size: 0.8rem; letter-spacing: 2px; text-transform: uppercase; align-self: flex-end; opacity: 0.8; font-weight: 700; }
.card-details h3 { font-size: 1.2rem; font-weight: 700; letter-spacing: 2px; margin-bottom: 4px; text-shadow: 0 1px 0 rgba(255,255,255,0.2); }
.face-black h3, .face-gold h3, .card-scene:nth-child(1) .back, .card-scene:nth-child(3) .back { text-shadow: none; }
.card-details p { font-size: 0.7rem; text-transform: uppercase; opacity: 0.7; letter-spacing: 1px; }
.nfc-icon { position: absolute; bottom: 30px; right: 30px; font-size: 1.8rem; opacity: 0.5; }
.center-icon { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 4rem; opacity: 0.1; }

/* =========================================
   7. POPUP ANIMATION (MOBILE BUG FIXED)
   ========================================= */
.pop-up-element {
    position: absolute; top: 50%; left: 50%; 
    transform: translate(-50%, -50%) scale(0.8);
    background: white; padding: 12px 18px; border-radius: 12px;
    display: flex; align-items: center; gap: 12px; width: max-content;
    opacity: 0; pointer-events: none; z-index: 100;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
}

/* DESKTOP: Hover triggers popup & corrects rotation */
@media (hover: hover) {
    .card-scene:hover .pop-up-element {
        opacity: 1;
        transform: translate(-50%, -180%) scale(1) rotateY(180deg);
    }
}

/* MOBILE/ALL: 'flipped' class triggers popup & corrects rotation */
.card-object.flipped .pop-up-element {
    opacity: 1;
    transform: translate(-50%, -180%) scale(1) rotateY(180deg);
}

.icon-circle { width: 32px; height: 32px; background: #000; color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.icon-circle.green { background: #00e676; }
.icon-circle.blue { background: #2979ff; }
.pop-text span { display: block; color: #000; font-weight: 700; font-size: 0.8rem; text-align: left; }
.pop-text small { display: block; color: #666; font-size: 0.7rem; text-align: left; }

/* =========================================
   8. PDF DOWNLOAD SECTION (GLOWING)
   ========================================= */
.pdf-container { text-align: center; margin-top: 60px; padding: 0 20px; }
.pdf-container p { color: var(--text-muted); margin-bottom: 20px; font-size: 0.9rem; }

/* GLOW ANIMATION */
@keyframes glow-pulse {
    0% { box-shadow: 0 0 5px rgba(255,255,255,0.1); }
    50% { box-shadow: 0 0 20px rgba(255,255,255,0.4), 0 0 10px var(--accent-gold); }
    100% { box-shadow: 0 0 5px rgba(255,255,255,0.1); }
}

.pdf-link {
    display: inline-flex; align-items: center; gap: 10px;
    color: #fff; text-decoration: none; font-size: 1rem; font-weight: 600;
    border: 1px solid rgba(255,255,255,0.3); padding: 14px 30px;
    border-radius: 50px; transition: 0.3s;
    background: rgba(255,255,255,0.05);
    animation: glow-pulse 3s infinite ease-in-out;
}

.pdf-link:hover { 
    background: #fff; color: #000; border-color: #fff; 
    box-shadow: 0 0 30px rgba(255,255,255,0.6);
    transform: translateY(-2px);
}

/* =========================================
   9. MOBILE RESPONSIVE (HEADER FIXED)
   ========================================= */
@media (max-width: 768px) {
    /* Container par gap lagaya taaki items takraye nahi */
    .glass-header .container {
        gap: 15px; 
    }

    /* Logo Styling Override for Mobile */
    .logo {
        /* Text size chhota kiya */
        font-size: 0.8rem !important; 
    }
    
    /* Inline Padding ko force-override karne ke liye !important */
    /* Isse tumhara white box chhota ho jayega mobile par */
    .logo[style] {
        padding: 6px 12px !important;
    }
    
    .logo img {
        height: 22px !important; /* Image bhi chhoti */
    }
    
    .logo span {
        font-size: 0.85rem !important; /* Text bhi chhota */
        letter-spacing: 0.5px !important;
    }

    /* Button Styling for Mobile */
    .cta-small {
        font-size: 0.75rem; /* Font chhota */
        padding: 8px 12px;  /* Padding kam */
        margin-left: 5px;   /* Thoda extra gap left side se */
    }

    /* Layout Fixes */
    .container { padding: 0 15px; }
    .hero { padding-top: 120px; }
    .card-scene { max-width: 100%; }
    .face { padding: 25px; }
    
    .card-object.flipped .pop-up-element {
        transform: translate(-50%, -150%) scale(0.9) rotateY(180deg);
    }
}