/* simulai.xyz - McBling Aesthetic */
/* Colors: Hot Pink #FF2D9B, Electric Lavender #B24BF3, Candy Yellow #FFE234,
   Chrome Silver #C0C0C8, Deep Plum #1A0A2E, Bubblegum White #FFF0F8,
   Neon Mint #3DFFC0, Glossy Black #0D0818 */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Nunito', sans-serif;
    font-weight: 400;
    font-size: clamp(1rem, 1.8vw, 1.25rem);
    line-height: 1.7;
    color: #0D0818;
    background: #0D0818;
    overflow-x: hidden;
    position: relative;
}

/* Gradient Mesh Background */
#gradient-mesh {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    background:
        radial-gradient(ellipse 80% 60% at 20% 30%, rgba(255, 45, 155, 0.15) 0%, transparent 70%),
        radial-gradient(ellipse 70% 80% at 80% 70%, rgba(178, 75, 243, 0.15) 0%, transparent 70%),
        radial-gradient(ellipse 60% 50% at 50% 50%, rgba(61, 255, 192, 0.12) 0%, transparent 70%);
    background-size: 200% 200%, 200% 200%, 200% 200%;
    animation: meshShift 20s ease-in-out infinite;
}

@keyframes meshShift {
    0% { background-position: 0% 0%, 100% 100%, 50% 50%; }
    25% { background-position: 50% 30%, 30% 70%, 80% 20%; }
    50% { background-position: 100% 100%, 0% 0%, 30% 80%; }
    75% { background-position: 30% 70%, 70% 30%, 60% 40%; }
    100% { background-position: 0% 0%, 100% 100%, 50% 50%; }
}

/* Sparkle Overlay */
#sparkle-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1000;
    pointer-events: none;
}

.sparkle-particle {
    position: fixed;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ffffff, #C0C0C8);
    box-shadow: 0 0 6px rgba(255, 45, 155, 0.6), 0 0 12px rgba(192, 192, 200, 0.3);
    pointer-events: none;
    z-index: 1000;
}

/* Progress Bar */
#progress-bar {
    position: fixed;
    right: 0;
    top: 0;
    width: 3px;
    height: 100vh;
    z-index: 999;
    background: linear-gradient(to bottom, #FF2D9B, #B24BF3, #3DFFC0);
    transform-origin: top;
    transform: scaleY(0);
}

/* Card Stack */
#card-stack {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4vh 0;
    gap: 8vh;
}

/* Base Card Styles */
.sim-card {
    width: 88vw;
    max-width: 1200px;
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    transition: box-shadow 0.4s ease, transform 0.2s ease;
    box-shadow: 0 8px 40px rgba(255, 45, 155, 0.15), 0 2px 10px rgba(0, 0, 0, 0.3);
    transform-style: preserve-3d;
    perspective: 1000px;
}

.sim-card:hover {
    box-shadow: 0 0 40px rgba(255, 45, 155, 0.4), 0 0 80px rgba(178, 75, 243, 0.2);
}

/* Crown Card */
.crown-card {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1A0A2E 0%, #0D0818 50%, #1A0A2E 100%);
    border: 1px solid rgba(192, 192, 200, 0.15);
}

.crown-content {
    position: relative;
    z-index: 5;
    text-align: center;
}

.frosted-panel {
    background: rgba(255, 240, 248, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 45, 155, 0.2);
    border-radius: 20px;
    padding: clamp(2rem, 6vw, 5rem) clamp(3rem, 8vw, 8rem);
}

.logotype {
    font-family: 'Quicksand', sans-serif;
    font-weight: 700;
    font-size: clamp(3rem, 8vw, 7rem);
    letter-spacing: 0.02em;
    color: #FFF0F8;
    text-shadow: 0 0 40px rgba(255, 45, 155, 0.5), 0 0 80px rgba(178, 75, 243, 0.3);
    margin-bottom: 0.3em;
}

.logotype span {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px) scale(0.8);
}

.tagline {
    font-family: 'Nunito', sans-serif;
    font-weight: 600;
    font-size: clamp(1.2rem, 2.5vw, 2rem);
    letter-spacing: 0.03em;
    color: #C0C0C8;
    text-transform: uppercase;
}

/* Theatre Card */
.theatre-card {
    min-height: 600px;
    background: #1A0A2E;
    padding: clamp(2rem, 4vw, 3rem);
    border: 1px solid rgba(178, 75, 243, 0.2);
}

.card-title {
    font-family: 'Quicksand', sans-serif;
    font-weight: 700;
    font-size: clamp(1.8rem, 4vw, 3rem);
    letter-spacing: 0.02em;
    margin-bottom: 0.5em;
    position: relative;
    z-index: 5;
}

.theatre-title {
    color: #FF2D9B;
    text-shadow: 0 0 20px rgba(255, 45, 155, 0.3);
}

.card-subtitle {
    font-family: 'Nunito', sans-serif;
    font-weight: 400;
    color: #C0C0C8;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 5;
}

.theatre-container {
    position: relative;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(13, 8, 24, 0.8);
    border: 1px solid rgba(61, 255, 192, 0.15);
}

#sim-canvas {
    width: 100%;
    height: 400px;
    display: block;
    cursor: crosshair;
}

.sim-stats {
    position: absolute;
    bottom: 12px;
    right: 16px;
    display: flex;
    gap: 12px;
    align-items: center;
    z-index: 5;
}

.stat-label {
    font-family: 'Inconsolata', monospace;
    font-weight: 400;
    font-size: 0.85rem;
    color: #C0C0C8;
    letter-spacing: 0.05em;
}

.stat-value {
    font-family: 'Inconsolata', monospace;
    font-weight: 500;
    font-size: 1rem;
    color: #3DFFC0;
}

.binary-watermark {
    font-family: 'Inconsolata', monospace;
    font-size: 0.75rem;
    color: rgba(192, 192, 200, 0.15);
    position: absolute;
    bottom: 8px;
    left: 16px;
    letter-spacing: 0.1em;
    z-index: 2;
}

/* Concept Cards */
.concept-card {
    min-height: 350px;
    padding: clamp(2rem, 5vw, 4rem);
    border: 1px solid rgba(192, 192, 200, 0.1);
}

.concept-content {
    position: relative;
    z-index: 5;
}

.concept-pink {
    background: linear-gradient(145deg, #1A0A2E 0%, rgba(255, 45, 155, 0.08) 100%);
    border-color: rgba(255, 45, 155, 0.2);
}

.concept-pink .concept-title { color: #FF2D9B; }

.concept-lavender {
    background: linear-gradient(145deg, #1A0A2E 0%, rgba(178, 75, 243, 0.08) 100%);
    border-color: rgba(178, 75, 243, 0.2);
}

.concept-lavender .concept-title { color: #B24BF3; }

.concept-mint {
    background: linear-gradient(145deg, #1A0A2E 0%, rgba(61, 255, 192, 0.08) 100%);
    border-color: rgba(61, 255, 192, 0.2);
}

.concept-mint .concept-title { color: #3DFFC0; }

.concept-title {
    text-shadow: 0 0 20px currentColor;
}

.concept-text {
    font-family: 'Nunito', sans-serif;
    font-weight: 400;
    font-size: clamp(1rem, 1.8vw, 1.25rem);
    line-height: 1.7;
    color: #FFF0F8;
    max-width: 700px;
}

/* Collage Card */
.collage-card {
    min-height: 500px;
    background: #1A0A2E;
    border: 1px solid rgba(255, 45, 155, 0.15);
    overflow: hidden;
}

.collage-container {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
}

/* Holographic Stickers */
.holo-sticker {
    position: absolute;
    padding: 10px 28px;
    font-family: 'Quicksand', sans-serif;
    font-weight: 700;
    font-size: clamp(0.9rem, 1.5vw, 1.1rem);
    letter-spacing: 0.08em;
    color: #0D0818;
    border-radius: 8px;
    background: conic-gradient(from 0deg, #FF2D9B, #FFE234, #3DFFC0, #B24BF3, #FF2D9B);
    background-size: 100% 100%;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(255, 45, 155, 0.3);
}

.holo-sticker.in-view {
    animation: holoShimmer 4s linear infinite;
}

@keyframes holoShimmer {
    0% { filter: hue-rotate(0deg) brightness(1); }
    50% { filter: hue-rotate(30deg) brightness(1.15); }
    100% { filter: hue-rotate(0deg) brightness(1); }
}

.sticker-1 { top: 10%; left: 8%; transform: rotate(-12deg); }
.sticker-2 { top: 20%; right: 10%; transform: rotate(8deg); }
.sticker-3 { bottom: 30%; left: 15%; transform: rotate(-5deg); }
.sticker-4 { bottom: 15%; right: 8%; transform: rotate(14deg); }

/* Connection Lines SVG */
.connection-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
}

.conn-line {
    fill: none;
    stroke: #3DFFC0;
    stroke-width: 1.5;
    stroke-dasharray: 8 6;
    stroke-dashoffset: 0;
    opacity: 0.5;
    animation: dashFlow 3s linear infinite;
}

@keyframes dashFlow {
    to { stroke-dashoffset: -28; }
}

/* Circuit Traces */
.circuit-trace {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, transparent, #C0C0C8, transparent);
    opacity: 0.2;
    z-index: 2;
}

.trace-1 { width: 60%; top: 35%; left: 20%; }
.trace-2 { width: 40%; top: 55%; left: 5%; transform: rotate(25deg); }
.trace-3 { width: 50%; top: 75%; left: 30%; transform: rotate(-15deg); }

/* Pixel Grid */
.pixel-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(192, 192, 200, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(192, 192, 200, 0.03) 1px, transparent 1px);
    background-size: 8px 8px;
    z-index: 1;
    pointer-events: none;
}

.collage-binary {
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.8rem;
}

/* Signature Card */
.signature-card {
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1A0A2E 0%, #0D0818 100%);
    border: 1px solid rgba(255, 45, 155, 0.15);
}

.signature-text {
    font-family: 'Quicksand', sans-serif;
    font-weight: 700;
    font-size: clamp(2.5rem, 7vw, 6rem);
    letter-spacing: 0.02em;
    color: #FFF0F8;
    text-align: center;
    position: relative;
    z-index: 5;
    text-shadow: 0 0 40px rgba(255, 45, 155, 0.4);
}

.signature-text .sig-char {
    display: inline-block;
}

.sig-char.sparkle {
    animation: sigSparkle 3s ease-in-out infinite;
}

@keyframes sigSparkle {
    0%, 100% { text-shadow: 0 0 40px rgba(255, 45, 155, 0.4); color: #FFF0F8; }
    50% { text-shadow: 0 0 60px rgba(255, 45, 155, 0.8), 0 0 100px rgba(178, 75, 243, 0.4); color: #ffffff; }
}

/* Chrome Spheres */
.chrome-sphere {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ffffff, #C0C0C8 40%, #606068 80%, #303038);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3), inset 0 -2px 6px rgba(0, 0, 0, 0.2);
    z-index: 4;
    pointer-events: none;
}

.sphere-1 { width: 60px; height: 60px; top: 15%; left: 10%; animation: sphereFloat 4s ease-in-out infinite; }
.sphere-2 { width: 35px; height: 35px; top: 25%; right: 15%; animation: sphereFloat 5s ease-in-out infinite 0.5s; }
.sphere-3 { width: 80px; height: 80px; bottom: 20%; right: 10%; animation: sphereFloat 6s ease-in-out infinite 1s; }
.sphere-4 { width: 25px; height: 25px; top: 10%; right: 8%; animation: sphereFloat 3.5s ease-in-out infinite 0.3s; }
.sphere-5 { width: 30px; height: 30px; top: -5px; right: 30px; animation: sphereFloat 4.5s ease-in-out infinite 0.7s; }
.sphere-6 { width: 40px; height: 40px; top: 10px; right: 20px; animation: sphereFloat 5.5s ease-in-out infinite 0.2s; }
.sphere-7 { width: 25px; height: 25px; bottom: 20px; right: 40px; animation: sphereFloat 3.8s ease-in-out infinite 1.2s; }
.sphere-8 { width: 50px; height: 50px; top: 8%; left: 5%; animation: sphereFloat 4.2s ease-in-out infinite; }
.sphere-9 { width: 20px; height: 20px; top: 40%; left: 45%; animation: sphereFloat 3.3s ease-in-out infinite 0.4s; }
.sphere-10 { width: 65px; height: 65px; top: 15%; right: 20%; animation: sphereFloat 5.8s ease-in-out infinite 0.8s; }
.sphere-11 { width: 15px; height: 15px; bottom: 25%; left: 35%; animation: sphereFloat 4.7s ease-in-out infinite 1.5s; }
.sphere-12 { width: 45px; height: 45px; bottom: 10%; right: 30%; animation: sphereFloat 5.2s ease-in-out infinite 0.6s; }
.sphere-13 { width: 12px; height: 12px; top: 60%; left: 70%; animation: sphereFloat 3s ease-in-out infinite 1.1s; }
.sphere-14 { width: 40px; height: 40px; top: 20%; left: 8%; animation: sphereFloat 4.8s ease-in-out infinite; }
.sphere-15 { width: 30px; height: 30px; bottom: 15%; right: 12%; animation: sphereFloat 5.3s ease-in-out infinite 0.9s; }

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

/* Star Bursts */
.star-burst {
    position: absolute;
    z-index: 4;
    pointer-events: none;
}

.star-burst::before {
    content: '';
    display: block;
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
}

.star-1 { top: 10%; left: 25%; }
.star-1::before { width: 20px; height: 20px; background: linear-gradient(135deg, #FF2D9B, #FFE234); animation: starPulse 1.5s ease-in-out infinite 0.2s; }

.star-2 { top: 8%; right: 30%; }
.star-2::before { width: 15px; height: 15px; background: linear-gradient(135deg, #FFE234, #FF2D9B); animation: starPulse 1.5s ease-in-out infinite 0.8s; }

.star-3 { bottom: 15%; left: 20%; }
.star-3::before { width: 25px; height: 25px; background: linear-gradient(135deg, #FF2D9B, #B24BF3); animation: starPulse 1.5s ease-in-out infinite 1.3s; }

.star-4 { top: 40%; right: 5%; }
.star-4::before { width: 12px; height: 12px; background: #FFE234; animation: starPulse 1.5s ease-in-out infinite 0.5s; }

.star-5 { bottom: 30%; right: 25%; }
.star-5::before { width: 18px; height: 18px; background: linear-gradient(135deg, #B24BF3, #FF2D9B); animation: starPulse 1.5s ease-in-out infinite 1.8s; }

.star-6 { bottom: 10%; left: 40%; }
.star-6::before { width: 10px; height: 10px; background: #FFE234; animation: starPulse 1.5s ease-in-out infinite 0.1s; }

.star-7 { bottom: 10px; right: 10px; }
.star-7::before { width: 22px; height: 22px; background: linear-gradient(135deg, #FF2D9B, #FFE234); animation: starPulse 1.5s ease-in-out infinite 0.6s; }

.star-8 { bottom: 15px; right: 15px; }
.star-8::before { width: 18px; height: 18px; background: linear-gradient(135deg, #B24BF3, #FFE234); animation: starPulse 1.5s ease-in-out infinite 1.1s; }

.star-9 { top: 15px; left: 15px; }
.star-9::before { width: 16px; height: 16px; background: linear-gradient(135deg, #3DFFC0, #FFE234); animation: starPulse 1.5s ease-in-out infinite 0.4s; }

.star-10 { top: 5%; left: 50%; }
.star-10::before { width: 20px; height: 20px; background: linear-gradient(135deg, #FF2D9B, #FFE234); animation: starPulse 1.5s ease-in-out infinite 0.3s; }

.star-11 { top: 30%; right: 5%; }
.star-11::before { width: 14px; height: 14px; background: #FFE234; animation: starPulse 1.5s ease-in-out infinite 1.4s; }

.star-12 { bottom: 40%; left: 8%; }
.star-12::before { width: 24px; height: 24px; background: linear-gradient(135deg, #B24BF3, #FF2D9B); animation: starPulse 1.5s ease-in-out infinite 0.7s; }

.star-13 { top: 50%; left: 55%; }
.star-13::before { width: 10px; height: 10px; background: #3DFFC0; animation: starPulse 1.5s ease-in-out infinite 1.9s; }

.star-14 { bottom: 20%; right: 15%; }
.star-14::before { width: 16px; height: 16px; background: linear-gradient(135deg, #FFE234, #3DFFC0); animation: starPulse 1.5s ease-in-out infinite 0.9s; }

.star-15 { top: 70%; left: 25%; }
.star-15::before { width: 12px; height: 12px; background: #FF2D9B; animation: starPulse 1.5s ease-in-out infinite 1.6s; }

.star-16 { top: 15%; left: 15%; }
.star-16::before { width: 30px; height: 30px; background: linear-gradient(135deg, #FF2D9B, #FFE234); animation: starPulse 1.5s ease-in-out infinite 0.3s; }

.star-17 { bottom: 20%; right: 20%; }
.star-17::before { width: 22px; height: 22px; background: linear-gradient(135deg, #B24BF3, #3DFFC0); animation: starPulse 1.5s ease-in-out infinite 1.2s; }

@keyframes starPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

/* Rhinestone Grid */
.rhinestone-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.rhinestone-dot {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #C0C0C8;
    box-shadow: 0 0 2px rgba(192, 192, 200, 0.5);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.rhinestone-dot.lit {
    background: #FFE234;
    box-shadow: 0 0 6px rgba(255, 226, 52, 0.8), 0 0 12px rgba(255, 226, 52, 0.4);
}

/* Title Character Animation */
.char-reveal {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px) scale(0.8);
    transition: opacity 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.char-reveal.revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Responsive */
@media (max-width: 768px) {
    .sim-card {
        width: 94vw;
    }
    
    #sim-canvas {
        height: 280px;
    }
    
    .collage-container {
        height: 400px;
    }
    
    .holo-sticker {
        padding: 6px 16px;
        font-size: 0.75rem;
    }
    
    .chrome-sphere {
        transform: scale(0.7);
    }
}
