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

:root {
    --bg: #080b0b;
    --bg-soft: #0d1212;
    --panel: #111818;
    --panel-2: #162020;
    --line: rgba(255, 255, 255, 0.1);
    --line-strong: rgba(123, 245, 223, 0.28);
    --text: #f7fbf9;
    --muted: #a7b4b2;
    --soft: #d7e0de;
    --teal: #2bc6b8;
    --teal-bright: #62f0dc;
    --green: #7fe7ac;
    --red: #ff6b71;
    --amber: #e8bc71;
    --shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
    --radius: 8px;
    --max: 1180px;
}

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

body {
    margin: 0;
    background:
        linear-gradient(150deg, rgba(43, 198, 184, 0.14), transparent 32rem),
        radial-gradient(circle at 80% 4rem, rgba(232, 188, 113, 0.12), transparent 30rem),
        var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
    line-height: 1.5;
    min-height: 100vh;
    overflow-x: hidden;
}

body.simple-page {
    background: var(--bg);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

p,
h1,
h2,
h3 {
    margin: 0;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    border-bottom: 1px solid var(--line);
    background: rgba(8, 11, 11, 0.76);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
}

.nav-shell {
    max-width: var(--max);
    margin: 0 auto;
    padding: 14px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0;
}

.brand img {
    width: 34px;
    height: 34px;
    border-radius: 9px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 22px;
    color: var(--muted);
    font-size: 0.94rem;
}

.nav-links a:hover {
    color: var(--text);
}

.button,
.app-store-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 999px;
    border: 1px solid var(--line);
    padding: 0 18px;
    font-weight: 750;
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.button:hover,
.app-store-link:hover {
    transform: translateY(-2px);
    border-color: var(--line-strong);
    background: rgba(43, 198, 184, 0.12);
}

.button.primary {
    background: var(--teal);
    color: #001817;
    border-color: transparent;
}

.app-store-badge {
    height: 50px;
}

.hero {
    min-height: calc(100svh - 64px);
    display: grid;
    align-items: center;
    padding: clamp(44px, 7vw, 86px) 22px;
    overflow: hidden;
}

.hero-grid {
    width: min(var(--max), 100%);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 0.94fr) minmax(320px, 1.06fr);
    gap: clamp(38px, 7vw, 92px);
    align-items: center;
}

.eyebrow {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    color: var(--teal-bright);
    font-weight: 760;
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    margin-bottom: 18px;
}

.hero h1,
.page-hero h1 {
    max-width: 780px;
    font-size: clamp(3rem, 7vw, 6.6rem);
    line-height: 0.95;
    letter-spacing: 0;
}

.hero-copy {
    max-width: 620px;
    margin-top: 24px;
    color: var(--soft);
    font-size: clamp(1.08rem, 1.8vw, 1.32rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    margin-top: 34px;
}

.hero-proof {
    margin-top: 28px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    max-width: 560px;
}

.proof-item {
    border-top: 1px solid var(--line);
    padding-top: 14px;
}

.proof-item strong {
    display: block;
    font-size: 1.05rem;
}

.proof-item span {
    color: var(--muted);
    font-size: 0.92rem;
}

.device-stage {
    position: relative;
    min-height: 720px;
}

.device-stage::before {
    content: "";
    position: absolute;
    inset: 12% 6% 8% 6%;
    background:
        radial-gradient(circle at 72% 18%, rgba(43, 198, 184, 0.18), transparent 24rem),
        radial-gradient(circle at 25% 78%, rgba(232, 188, 113, 0.12), transparent 22rem);
    filter: blur(12px);
    opacity: 0.85;
}

.phone-shot {
    position: absolute;
    width: min(42vw, 354px);
    border-radius: 42px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: #000;
}

.phone-main {
    right: 8%;
    top: 0;
    z-index: 2;
}

.phone-secondary {
    left: 0;
    bottom: 0;
    width: min(36vw, 306px);
    opacity: 0.9;
}

.section {
    padding: clamp(70px, 10vw, 130px) 22px;
}

.section.alt {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.inner {
    max-width: var(--max);
    margin: 0 auto;
}

.section-head {
    max-width: 760px;
    margin-bottom: 44px;
}

.section-head h2,
.page-section h2 {
    font-size: clamp(2.1rem, 4vw, 4.4rem);
    line-height: 1;
    letter-spacing: 0;
}

.section-head p,
.page-section > p {
    margin-top: 16px;
    color: var(--muted);
    font-size: 1.08rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.feature {
    border-top: 1px solid var(--line);
    padding-top: 22px;
}

.feature h3 {
    font-size: 1.28rem;
    margin-bottom: 10px;
}

.feature p {
    color: var(--muted);
}

.showcase {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
    gap: clamp(28px, 6vw, 80px);
    align-items: center;
}

.showcase.reverse {
    grid-template-columns: minmax(320px, 1.08fr) minmax(0, 0.92fr);
}

.showcase-copy h2 {
    font-size: clamp(2.2rem, 4.7vw, 5rem);
    line-height: 0.98;
}

.showcase-copy p {
    margin-top: 18px;
    color: var(--soft);
    font-size: 1.08rem;
}

.screen-panel {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.035);
    padding: clamp(18px, 3vw, 34px);
    border-radius: var(--radius);
    overflow: hidden;
}

.screen-panel.phone img {
    max-height: 780px;
    margin: 0 auto;
    border-radius: 36px;
}

.screen-panel.ipad img {
    border-radius: 20px;
}

.mini-list {
    display: grid;
    gap: 12px;
    margin-top: 26px;
}

.mini-list > span {
    display: grid;
    grid-template-columns: minmax(118px, 0.42fr) minmax(0, 1fr);
    gap: 20px;
    align-items: start;
    border-bottom: 1px solid var(--line);
    padding-bottom: 12px;
    color: var(--muted);
}

.mini-list > span > strong {
    color: var(--text);
    min-width: 0;
}

.mini-list .value {
    min-width: 0;
}

.intent-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.intent-link {
    display: block;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px;
    background: rgba(255, 255, 255, 0.035);
}

.intent-link:hover {
    border-color: var(--line-strong);
    background: rgba(43, 198, 184, 0.08);
}

.intent-link h3 {
    margin-bottom: 8px;
}

.intent-link p {
    color: var(--muted);
}

.faq {
    display: grid;
    gap: 16px;
}

.faq details {
    border-top: 1px solid var(--line);
    padding: 18px 0;
}

.faq summary {
    cursor: pointer;
    font-weight: 760;
    font-size: 1.08rem;
}

.faq p {
    color: var(--muted);
    margin-top: 12px;
    max-width: 840px;
}

.cta-band {
    border-top: 1px solid var(--line);
    padding: clamp(60px, 9vw, 110px) 22px;
}

.cta-inner {
    max-width: var(--max);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    align-items: center;
}

.cta-inner h2 {
    font-size: clamp(2.4rem, 5vw, 5.4rem);
    line-height: 0.96;
}

.cta-inner p {
    color: var(--muted);
    margin-top: 16px;
    max-width: 600px;
}

.site-footer {
    border-top: 1px solid var(--line);
    padding: 32px 22px;
    color: var(--muted);
}

.footer-inner {
    max-width: var(--max);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.footer-links {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
}

.footer-links a:hover {
    color: var(--text);
}

.page-hero {
    padding: clamp(64px, 10vw, 124px) 22px 52px;
}

.page-hero .inner {
    max-width: 980px;
}

.page-hero p {
    color: var(--soft);
    font-size: clamp(1.08rem, 2vw, 1.28rem);
    margin-top: 22px;
    max-width: 780px;
}

.page-section {
    max-width: 980px;
    margin: 0 auto;
    padding: 56px 22px;
}

.page-section h2 {
    font-size: clamp(1.9rem, 3.2vw, 3rem);
}

.copy-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 26px;
}

.copy-block {
    border-top: 1px solid var(--line);
    padding-top: 18px;
}

.copy-block h3 {
    margin-bottom: 10px;
}

.copy-block p,
.copy-block li,
.legal-body p,
.legal-body li {
    color: var(--muted);
}

.copy-block ul,
.legal-body ul {
    margin: 12px 0 0;
    padding-left: 20px;
}

.converter-hero {
    padding-bottom: clamp(68px, 10vw, 118px);
}

.converter-layout {
    max-width: var(--max);
    display: grid;
    grid-template-columns: minmax(0, 0.86fr) minmax(360px, 0.72fr);
    gap: clamp(32px, 7vw, 92px);
    align-items: center;
}

.converter-layout > * {
    min-width: 0;
}

.converter-notes {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
    color: var(--soft);
}

.converter-notes span {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 9px 13px;
    background: rgba(255, 255, 255, 0.045);
    font-size: 0.9rem;
}

.converter-panel {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background:
        linear-gradient(145deg, rgba(43, 198, 184, 0.12), rgba(255, 255, 255, 0.035) 48%),
        var(--panel);
    box-shadow: var(--shadow);
    padding: clamp(20px, 3vw, 30px);
}

.converter-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 26px;
}

.converter-panel h2 {
    font-size: clamp(1.55rem, 2vw, 2rem);
    line-height: 1.05;
}

.converter-panel-head p {
    color: var(--muted);
    margin-top: 8px;
    font-size: 0.94rem;
}

.converter-panel-head p.ready {
    color: var(--green);
}

.converter-panel-head p.warning {
    color: var(--amber);
}

.converter-panel-head p.error {
    color: var(--red);
}

.icon-button {
    width: 46px;
    height: 46px;
    flex: 0 0 auto;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--text);
    background: rgba(255, 255, 255, 0.055);
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.icon-button:hover {
    transform: translateY(-2px);
    border-color: var(--line-strong);
    background: rgba(43, 198, 184, 0.13);
}

.icon-button svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.converter-form {
    display: grid;
    gap: 14px;
}

.converter-form label {
    display: block;
    color: var(--soft);
    font-size: 0.82rem;
    font-weight: 760;
    margin-bottom: 8px;
}

.converter-form input,
.converter-form select {
    width: 100%;
    min-width: 0;
    min-height: 50px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    color: var(--text);
    background: rgba(8, 11, 11, 0.78);
    font: inherit;
    font-size: 1rem;
    padding: 0 14px;
}

.converter-form input {
    font-size: 1.45rem;
    font-weight: 760;
}

.converter-form input:focus,
.converter-form select:focus,
.icon-button:focus-visible {
    outline: 2px solid rgba(98, 240, 220, 0.72);
    outline-offset: 2px;
}

.currency-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.conversion-result {
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    margin: 24px 0 18px;
    padding: 22px 0;
    display: grid;
    gap: 8px;
}

.conversion-result span {
    color: var(--muted);
}

.conversion-result strong {
    color: var(--teal-bright);
    font-size: clamp(2rem, 4.6vw, 3.5rem);
    line-height: 0.98;
    overflow-wrap: anywhere;
}

.rate-disclaimer {
    color: var(--muted);
    font-size: 0.88rem;
}

.converter-copy {
    padding-top: 0;
}

.legal-body {
    max-width: 820px;
    margin: 0 auto;
    padding: 70px 22px;
}

.legal-body h1 {
    font-size: clamp(2.5rem, 6vw, 4.6rem);
    line-height: 1;
}

.legal-body h2 {
    color: var(--teal-bright);
    margin-top: 36px;
}

.legal-body p {
    margin-top: 14px;
}

.muted {
    color: var(--muted);
}

@media (max-width: 900px) {
    .nav-links a:not(.button) {
        display: none;
    }

    .hero {
        min-height: auto;
    }

    .hero-grid,
    .showcase,
    .showcase.reverse,
    .converter-layout,
    .cta-inner {
        grid-template-columns: 1fr;
    }

    .device-stage {
        min-height: 620px;
    }

    .phone-shot {
        width: min(66vw, 330px);
    }

    .phone-secondary {
        width: min(54vw, 270px);
    }

    .feature-grid,
    .intent-grid,
    .currency-fields,
    .copy-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .nav-shell {
        padding: 12px 16px;
    }

    .brand {
        font-size: 0;
    }

    .brand::after {
        content: "Flexchange";
        font-size: 1rem;
    }

    .hero,
    .section,
    .page-hero,
    .page-section,
    .cta-band {
        padding-left: 16px;
        padding-right: 16px;
    }

    .hero h1,
    .page-hero h1 {
        font-size: clamp(2.65rem, 13vw, 3.55rem);
    }

    .hero-proof {
        display: none;
    }

    .device-stage {
        min-height: 430px;
    }

    .phone-shot {
        width: min(70vw, 276px);
    }

    .phone-main {
        right: 0;
    }

    .phone-secondary {
        left: -8px;
        width: min(54vw, 210px);
    }

    .app-store-badge {
        height: 46px;
    }

    .mini-list > span {
        grid-template-columns: minmax(108px, 0.42fr) minmax(0, 1fr);
        gap: 12px;
    }
}
