/* ============================================
   WOBBLEBERRY GAMES — Cybernetic Deep Space
   Ultra-dark background #030305
   Aurora gradients, neon accents, glow effects
   ============================================ */

:root {
    --bg: #030305;
    --surface: #0a0a12;
    --surface-light: #12121e;
    --text: #e4e4ef;
    --text-muted: #6b6b8a;
    --neon-purple: #8b5cf6;
    --neon-cyan: #22d3ee;
    --neon-pink: #f472b6;
    --glow-purple: rgba(139, 92, 246, 0.15);
    --glow-cyan: rgba(34, 211, 238, 0.1);
    --border: rgba(139, 92, 246, 0.12);
    --radius: 10px;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    text-align: center;
    margin-bottom: 12px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    max-width: 480px;
    margin: 0 auto 48px;
    font-size: 1.02rem;
}

.section-label {
    font-family: var(--font-heading);
    font-size: clamp(1rem, 2.5vw, 1.25rem);
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 20px;
    color: var(--neon-cyan);
}

/* --- Button --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 14px 28px;
    border: 1px solid var(--neon-purple);
    border-radius: var(--radius);
    background: transparent;
    color: var(--text);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: background 0.25s, box-shadow 0.25s, transform 0.2s;
    will-change: transform;
}

.btn--glow:hover {
    background: rgba(139, 92, 246, 0.12);
    box-shadow: 0 0 24px rgba(139, 92, 246, 0.2), inset 0 0 24px rgba(139, 92, 246, 0.05);
    transform: translateY(-1px);
}

.btn--glow:active { transform: translateY(0); }

.btn--full { width: 100%; justify-content: center; }

/* --- Navigation --- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: background 0.3s, padding 0.3s;
}

.nav--scrolled {
    background: rgba(3, 3, 5, 0.88);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.nav__inner {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text);
}

.nav__logo svg { flex-shrink: 0; }

.nav__links { display: flex; gap: 28px; }

.nav__links a {
    font-family: var(--font-heading);
    font-weight: 500;
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-muted);
    transition: color 0.2s;
}

.nav__links a:hover { color: var(--neon-cyan); }

.nav__toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav__toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    transition: transform 0.3s, opacity 0.3s;
}

/* --- Hero --- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 0 80px;
    overflow: hidden;
}

/* Aurora background — no filter:blur(), using radial-gradient soft edges */
.hero__aurora {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.aurora {
    position: absolute;
    border-radius: 50%;
    will-change: transform;
}

.aurora--1 {
    width: 600px;
    height: 600px;
    top: -15%;
    left: -10%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.12) 0%, transparent 70%);
    animation: aurora-drift-1 18s ease-in-out infinite alternate;
}

.aurora--2 {
    width: 500px;
    height: 500px;
    bottom: -10%;
    right: -8%;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.08) 0%, transparent 70%);
    animation: aurora-drift-2 22s ease-in-out infinite alternate;
}

.aurora--3 {
    width: 400px;
    height: 400px;
    top: 40%;
    left: 50%;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(244, 114, 182, 0.06) 0%, transparent 70%);
    animation: aurora-drift-3 16s ease-in-out infinite alternate;
}

@keyframes aurora-drift-1 {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(80px, 40px) scale(1.15); }
}

@keyframes aurora-drift-2 {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(-60px, -30px) scale(1.1); }
}

@keyframes aurora-drift-3 {
    from { transform: translate(-50%, 0) scale(1); }
    to { transform: translate(-45%, 30px) scale(1.2); }
}

.hero__inner {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 700px;
    padding: 0 24px;
}

.hero__title {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 7vw, 4.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.04em;
    margin-bottom: 28px;
    position: relative;
}

/* Glitch effect via ::before and ::after */
.hero__title[data-glitch]::before,
.hero__title[data-glitch]::after {
    content: attr(data-glitch);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.hero__title[data-glitch]::before {
    color: var(--neon-cyan);
    animation: glitch-1 4s infinite linear alternate-reverse;
    clip-path: inset(0 0 70% 0);
    opacity: 0.6;
}

.hero__title[data-glitch]::after {
    color: var(--neon-pink);
    animation: glitch-2 3.5s infinite linear alternate-reverse;
    clip-path: inset(70% 0 0 0);
    opacity: 0.6;
}

/* Use text content for glitch layers */
.hero__title[data-glitch]::before { content: 'YOUR GAME.\AOUR PLAYGROUND.'; white-space: pre; }
.hero__title[data-glitch]::after { content: 'YOUR GAME.\AOUR PLAYGROUND.'; white-space: pre; }

@keyframes glitch-1 {
    0%, 92%, 100% { transform: translate(0); }
    93% { transform: translate(-3px, 1px); }
    95% { transform: translate(2px, -1px); }
    97% { transform: translate(-1px, 2px); }
}

@keyframes glitch-2 {
    0%, 90%, 100% { transform: translate(0); }
    91% { transform: translate(3px, -1px); }
    94% { transform: translate(-2px, 1px); }
    96% { transform: translate(1px, -2px); }
}

.hero__sub {
    font-size: clamp(1rem, 2vw, 1.12rem);
    color: var(--text-muted);
    max-width: 520px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

/* --- About --- */
.about {
    padding: 80px 0;
    border-top: 1px solid var(--border);
}

.about__inner {
    max-width: 640px;
}

.about__inner p {
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.75;
}

/* --- Services --- */
.services {
    padding: 80px 0;
    border-top: 1px solid var(--border);
}

.services__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.card {
    padding: 32px 28px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--surface);
    transition: border-color 0.3s, box-shadow 0.3s;
    will-change: auto;
}

.card:hover {
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: 0 0 32px rgba(139, 92, 246, 0.06);
}

.card__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: rgba(139, 92, 246, 0.1);
    color: var(--neon-purple);
    margin-bottom: 18px;
}

.card__title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text);
}

.card__desc {
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.6;
}

/* --- Testimonials --- */
.reviews {
    padding: 80px 0;
    border-top: 1px solid var(--border);
}

.reviews__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.review {
    padding: 24px 20px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--surface);
    display: flex;
    flex-direction: column;
    transition: border-color 0.3s;
}

.review:hover { border-color: rgba(34, 211, 238, 0.2); }

.review__text {
    font-size: 0.92rem;
    line-height: 1.6;
    flex: 1;
    margin-bottom: 14px;
    color: var(--text);
}

.review__text::before {
    content: '\201C';
    font-family: var(--font-heading);
    font-size: 1.8rem;
    line-height: 1;
    color: var(--neon-purple);
    display: block;
    margin-bottom: 8px;
}

.review__author {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--neon-cyan);
}

/* --- Contact --- */
.contact {
    padding: 80px 0;
    border-top: 1px solid var(--border);
}

.form {
    max-width: 560px;
    margin: 0 auto;
}

.form__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.form__group { margin-bottom: 14px; }

.form__group label {
    display: block;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 6px;
    color: var(--text-muted);
}

.form__group input,
.form__group select,
.form__group textarea {
    width: 100%;
    padding: 12px 14px;
    font-family: var(--font-body);
    font-size: 0.92rem;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form__group input:focus,
.form__group select:focus,
.form__group textarea:focus {
    border-color: var(--neon-purple);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.form__group input::placeholder,
.form__group textarea::placeholder {
    color: #444466;
}

.form__group select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%236b6b8a' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
    cursor: pointer;
}

.form__group textarea {
    resize: vertical;
    min-height: 110px;
}

.form__group input:user-invalid,
.form__group select:user-invalid,
.form__group textarea:user-invalid,
.form__group input.error,
.form__group select.error,
.form__group textarea.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form__success {
    display: none;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 14px 18px;
    background: rgba(34, 211, 238, 0.08);
    border: 1px solid rgba(34, 211, 238, 0.2);
    border-radius: 8px;
    color: var(--neon-cyan);
    font-weight: 500;
    font-size: 0.9rem;
}

.form__success.visible { display: flex; }
.form__success svg { flex-shrink: 0; }

/* --- Footer --- */
.footer {
    padding: 28px 0;
    border-top: 1px solid var(--border);
}

.footer__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer__logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.footer__copy {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* --- Scroll Reveal --- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform, opacity;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.services__grid .reveal:nth-child(2) { transition-delay: 0.07s; }
.services__grid .reveal:nth-child(3) { transition-delay: 0.14s; }
.services__grid .reveal:nth-child(4) { transition-delay: 0.21s; }

.reviews__grid .reveal:nth-child(2) { transition-delay: 0.05s; }
.reviews__grid .reveal:nth-child(3) { transition-delay: 0.10s; }
.reviews__grid .reveal:nth-child(4) { transition-delay: 0.15s; }
.reviews__grid .reveal:nth-child(5) { transition-delay: 0.20s; }
.reviews__grid .reveal:nth-child(6) { transition-delay: 0.25s; }

/* --- Responsive --- */
@media (max-width: 900px) {
    .reviews__grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .nav__links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 260px;
        height: 100vh;
        background: var(--surface);
        flex-direction: column;
        padding: 80px 28px 28px;
        gap: 20px;
        border-left: 1px solid var(--border);
        transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1);
        z-index: 999;
    }

    .nav__links.open { right: 0; }
    .nav__links a { font-size: 1rem; }

    .nav__toggle { display: flex; z-index: 1001; }
    .nav__toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .nav__toggle.active span:nth-child(2) { opacity: 0; }
    .nav__toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    .services__grid { grid-template-columns: 1fr; }
    .reviews__grid { grid-template-columns: 1fr; }
    .form__row { grid-template-columns: 1fr; }

    .hero { min-height: auto; padding: 140px 0 60px; }

    .aurora--1 { width: 300px; height: 300px; }
    .aurora--2 { width: 250px; height: 250px; }
    .aurora--3 { display: none; }

    .footer__inner {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}
