/* AI Advanced Summit — base + older-browser fallbacks (no build step) */

:root {
    --bg-deep: #050814;
    --bg-mid: #0a0f22;
    --surface: rgba(255, 255, 255, 0.055);
    --surface-border: rgba(255, 255, 255, 0.1);
    --text-primary: #f4f6fb;
    --text-muted: rgba(244, 246, 251, 0.68);
    --accent-cyan: #22d3ee;
    --accent-violet: #a855f7;
    --focus-ring: rgba(34, 211, 238, 0.35);
    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
    --shadow-elevated: 0 32px 64px rgba(0, 0, 0, 0.55);
    --radius-lg: 1.25rem;
    --radius-md: 0.75rem;
    --space-section-x: max(1.25rem, env(safe-area-inset-left, 0px));
    --space-section-y: max(2rem, env(safe-area-inset-top, 0px));
}

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

html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    min-height: 100vh;
    min-height: 100dvh;
    background-color: var(--bg-deep);
    background-image:
        radial-gradient(ellipse 120% 80% at 50% -20%, rgba(34, 211, 238, 0.12), transparent 55%),
        radial-gradient(ellipse 80% 50% at 100% 50%, rgba(168, 85, 247, 0.08), transparent 50%),
        radial-gradient(ellipse 60% 40% at 0% 80%, rgba(0, 114, 255, 0.06), transparent 45%),
        linear-gradient(180deg, var(--bg-deep) 0%, var(--bg-mid) 45%, var(--bg-deep) 100%);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.hero {
    position: relative;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    min-height: min(100vh, 56rem);
    min-height: min(100dvh, 56rem);
    padding: clamp(2.5rem, 6vw, 4rem) var(--space-section-x) clamp(3rem, 7vw, 5rem);
    padding-top: max(clamp(2.5rem, 6vw, 4rem), var(--space-section-y));
    overflow: hidden;
}

.hero-content {
    position: relative;
    max-width: 32.5rem;
    width: 100%;
    text-align: center;
}

.badge {
    display: inline-block;
    background: linear-gradient(135deg, #0891b2 0%, #2563eb 50%, #6366f1 100%);
    color: #fff;
    font-weight: 600;
    font-size: 0.6875rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    padding: 0.5rem 1.35rem;
    border-radius: 999px;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 2px 12px rgba(37, 99, 235, 0.35);
}

h1 {
    font-size: 2.2rem;
    font-weight: 900;
    line-height: 1.08;
    letter-spacing: -0.03em;
    margin-bottom: 0.65rem;
    text-wrap: balance;
}

@supports (font-size: clamp(1px, 1vw, 2px)) {
    h1 {
        font-size: clamp(2rem, 5.5vw, 3.25rem);
    }
}

h1 span {
    color: var(--accent-cyan);
    background: linear-gradient(135deg, #22d3ee 0%, #38bdf8 35%, #a855f7 100%);
    -webkit-background-clip: text;
    background-clip: text;
}

@supports (-webkit-background-clip: text) {
    h1 span {
        color: transparent;
        -webkit-text-fill-color: transparent;
    }
}

@supports (background-clip: text) {
    h1 span {
        color: transparent;
    }
}

.subtitle {
    font-size: clamp(1rem, 2.2vw, 1.125rem);
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-weight: 400;
    letter-spacing: 0.01em;
    max-width: 28rem;
    margin-left: auto;
    margin-right: auto;
}

.card {
    background: var(--surface);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--surface-border);
    border-radius: var(--radius-lg);
    padding: clamp(1.75rem, 4vw, 2.35rem) clamp(1.5rem, 4vw, 2rem);
    box-shadow: var(--shadow-card);
}

.form-group {
    margin-bottom: 1rem;
}

.form-group:last-of-type {
    margin-bottom: 0;
}

.form-group input {
    width: 100%;
    min-height: 3rem;
    padding: 0.875rem 1.125rem;
    font-size: 1rem;
    font-family: inherit;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    outline: none;
    -webkit-transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.form-group input::-webkit-input-placeholder {
    color: rgba(255, 255, 255, 0.38);
}

.form-group input::-moz-placeholder {
    color: rgba(255, 255, 255, 0.38);
    opacity: 1;
}

.form-group input:-ms-input-placeholder {
    color: rgba(255, 255, 255, 0.38);
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.38);
}

.form-group input:hover {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.08);
}

.form-group input:focus {
    border-color: rgba(34, 211, 238, 0.55);
    box-shadow: 0 0 0 3px var(--focus-ring);
    background: rgba(255, 255, 255, 0.07);
}

.btn-submit {
    width: 100%;
    min-height: 3.25rem;
    padding: 0.95rem 1.25rem;
    font-size: 1.0625rem;
    font-family: inherit;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 40%, #0891b2 100%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md);
    cursor: pointer;
    margin-top: 1rem;
    -webkit-transition: transform 0.18s ease, box-shadow 0.25s ease, filter 0.2s ease;
    transition: transform 0.18s ease, box-shadow 0.25s ease, filter 0.2s ease;
    letter-spacing: 0.02em;
    box-shadow: 0 4px 20px rgba(37, 99, 235, 0.35);
}

.btn-submit:hover {
    -webkit-transform: translateY(-2px);
    -ms-transform: translateY(-2px);
    transform: translateY(-2px);
    box-shadow: 0 12px 36px rgba(37, 99, 235, 0.45);
    filter: brightness(1.05);
}

.btn-submit:active {
    -webkit-transform: translateY(0);
    -ms-transform: translateY(0);
    transform: translateY(0);
    filter: brightness(0.98);
}

.btn-submit:focus-visible {
    outline: 2px solid #22d3ee;
    outline-offset: 3px;
}

.btn-submit:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    -webkit-transform: none;
    -ms-transform: none;
    transform: none;
    box-shadow: none;
    filter: none;
}

.toast {
    position: fixed;
    top: max(1.25rem, env(safe-area-inset-top, 0px));
    left: 50%;
    -webkit-transform: translateX(-50%) translateY(-120%);
    -ms-transform: translateX(-50%) translateY(-120%);
    transform: translateX(-50%) translateY(-120%);
    padding: 1rem 1.75rem;
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    font-weight: 600;
    -webkit-transition: -webkit-transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    backdrop-filter: blur(16px) saturate(150%);
    -webkit-backdrop-filter: blur(16px) saturate(150%);
    max-width: min(90vw, 24rem);
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow-elevated);
}

.toast.show {
    -webkit-transform: translateX(-50%) translateY(0);
    -ms-transform: translateX(-50%) translateY(0);
    transform: translateX(-50%) translateY(0);
}

.toast.success {
    background: rgba(5, 150, 105, 0.92);
    color: #fff;
}

.toast.error {
    background: rgba(220, 38, 38, 0.92);
    color: #fff;
}

.collage-wrap {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    overflow: hidden;
}

/* Flex fallback when CSS Grid is unavailable */
.collage {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-flex-wrap: wrap;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    width: calc(100% + 6px);
    height: 100%;
    margin: -3px;
}

.collage img {
    -webkit-box-flex: 1;
    -ms-flex: 1 1 25%;
    flex: 1 1 25%;
    box-sizing: border-box;
    width: 25%;
    max-width: 25%;
    height: 33.333%;
    min-height: 80px;
    padding: 3px;
    -o-object-fit: cover;
    object-fit: cover;
    display: block;
}

@supports (display: grid) {
    .collage {
        display: grid;
        width: 100%;
        margin: 0;
        grid-template-columns: repeat(4, 1fr);
        grid-template-rows: repeat(3, 1fr);
        gap: 5px;
        -webkit-flex-wrap: nowrap;
        -ms-flex-wrap: nowrap;
        flex-wrap: nowrap;
    }

    .collage img {
        -webkit-box-flex: initial;
        -ms-flex: initial;
        flex: initial;
        width: 100%;
        max-width: none;
        height: 100%;
        min-height: 0;
        padding: 0;
    }

    .collage img:nth-child(1) {
        grid-column: 1 / 3;
        grid-row: 1 / 2;
    }

    .collage img:nth-child(2) {
        grid-column: 3 / 4;
        grid-row: 1 / 2;
    }

    .collage img:nth-child(3) {
        grid-column: 4 / 5;
        grid-row: 1 / 2;
    }

    .collage img:nth-child(4) {
        grid-column: 1 / 2;
        grid-row: 2 / 3;
    }

    .collage img:nth-child(5) {
        grid-column: 2 / 4;
        grid-row: 2 / 4;
    }

    .collage img:nth-child(6) {
        grid-column: 4 / 5;
        grid-row: 2 / 3;
    }

    .collage img:nth-child(7) {
        grid-column: 1 / 2;
        grid-row: 3 / 4;
    }
}

.collage-overlay {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background:
        linear-gradient(180deg, rgba(5, 8, 20, 0.55) 0%, rgba(5, 8, 20, 0.78) 45%, rgba(5, 8, 20, 0.88) 100%),
        radial-gradient(ellipse 100% 60% at 50% 0%, rgba(34, 211, 238, 0.06), transparent 70%);
}

.pitch {
    position: relative;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    max-width: 71.25rem;
    margin: 0 auto;
    padding: clamp(3.5rem, 8vw, 6rem) max(1.5rem, env(safe-area-inset-right, 0px)) clamp(3.5rem, 8vw, 6rem) var(--space-section-x);
    background: transparent;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* Margin-based spacing (no flex gap) for broad browser support */
.pitch-text {
    margin-right: clamp(1.5rem, 4vw, 3.5rem);
    -webkit-box-flex: 1;
    -ms-flex: 1 1 55%;
    flex: 1 1 55%;
    min-width: 0;
}

.pitch-text .pitch-h1 {
    font-size: 2.2rem;
    font-weight: 900;
    line-height: 1.12;
    margin-bottom: 1.25rem;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

@supports (font-size: clamp(1px, 1vw, 2px)) {
    .pitch-text .pitch-h1 {
        font-size: clamp(1.85rem, 4vw, 2.85rem);
    }
}

.pitch-text h2 {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.28;
    margin-bottom: 1.15rem;
    letter-spacing: -0.015em;
    text-wrap: balance;
}

.pitch-text h2:last-child {
    margin-bottom: 0;
}

@supports (font-size: clamp(1px, 1vw, 2px)) {
    .pitch-text h2 {
        font-size: clamp(1.35rem, 2.8vw, 2rem);
    }
}

.pitch-text h2 em {
    font-style: normal;
    color: #c4b5fd;
    background: linear-gradient(135deg, #22d3ee, #818cf8 45%, #a855f7);
    -webkit-background-clip: text;
    background-clip: text;
}

@supports (-webkit-background-clip: text) {
    .pitch-text h2 em {
        color: transparent;
        -webkit-text-fill-color: transparent;
    }
}

@supports (background-clip: text) {
    .pitch-text h2 em {
        color: transparent;
    }
}

.pitch-text p {
    font-size: 1.1rem;
    line-height: 1.75;
    color: var(--text-muted);
    margin-bottom: 1.2rem;
}

.pitch-text p:last-child {
    margin-bottom: 0;
}

.pitch-image {
    margin-left: 0;
    -webkit-box-flex: 0;
    -ms-flex: 0 1 400px;
    flex: 0 1 400px;
    max-width: 400px;
    min-width: 0;
}

.pitch-image img {
    width: 100%;
    border-radius: var(--radius-lg);
    display: block;
    box-shadow: var(--shadow-elevated);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

@media (max-width: 960px) {
    .pitch-text {
        margin-right: 2rem;
    }

    .pitch-image {
        -ms-flex: 0 1 min(360px, 42vw);
        flex: 0 1 min(360px, 42vw);
        max-width: min(360px, 42vw);
    }
}

@media (max-width: 768px) {
    .hero {
        min-height: min(100vh, 52rem);
        min-height: min(100dvh, 52rem);
    }

    .pitch {
        -webkit-box-orient: vertical;
        -webkit-box-direction: reverse;
        -ms-flex-direction: column-reverse;
        flex-direction: column-reverse;
        padding: clamp(2.5rem, 6vw, 3.5rem) max(1.15rem, env(safe-area-inset-right, 0px)) clamp(3rem, 10vw, 4rem) max(1.15rem, var(--space-section-x));
    }

    .pitch-text {
        margin-right: 0;
        margin-top: clamp(2rem, 5vw, 2.75rem);
        flex-basis: auto;
        text-align: center;
    }

    .pitch-image {
        margin-left: 0;
        max-width: min(100%, 28rem);
        -ms-flex: 0 1 auto;
        flex: 0 1 auto;
        width: 100%;
    }
}

@media (max-width: 600px) {
    .card {
        padding: 1.5rem 1.2rem;
    }

    .badge {
        font-size: 0.625rem;
        padding: 0.45rem 1.1rem;
    }

    @supports (display: grid) {
        .collage {
            grid-template-columns: repeat(3, 1fr);
            grid-template-rows: repeat(3, 1fr);
        }

        .collage img:nth-child(1) {
            grid-column: 1 / 3;
            grid-row: 1 / 2;
        }

        .collage img:nth-child(2) {
            grid-column: 3 / 4;
            grid-row: 1 / 2;
        }

        .collage img:nth-child(3) {
            grid-column: 1 / 2;
            grid-row: 2 / 3;
        }

        .collage img:nth-child(4) {
            grid-column: 2 / 4;
            grid-row: 2 / 3;
        }

        .collage img:nth-child(5) {
            grid-column: 1 / 3;
            grid-row: 3 / 4;
        }

        .collage img:nth-child(6) {
            grid-column: 3 / 4;
            grid-row: 3 / 4;
        }

        .collage img:nth-child(7) {
            display: none;
        }
    }

    @supports not (display: grid) {
        .collage img {
            width: 33.333%;
            max-width: 33.333%;
        }
    }
}

@media (max-width: 380px) {
    .hero {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .form-group input,
    .btn-submit {
        font-size: 1rem;
    }
}
