﻿/* ============================================================
   FinVillaHub — Educational Risk Calculator V3
   Single-frame cinematic dashboard
   ============================================================ */

:root {
    --bg: #020812;
    --panel: rgba(7, 22, 38, .94);
    --panel-2: rgba(4, 15, 28, .96);
    --line: rgba(66, 211, 255, .22);
    --cyan: #36d9ff;
    --teal: #45e0bd;
    --gold: #f1cc68;
    --text: #f3f7fc;
    --muted: #91a5b8;
    --danger: #ff7188;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    min-height: 100vh;
    color: var(--text);
    font-family:
        "Plus Jakarta Sans",
        Inter,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    background:
        radial-gradient(
            circle at 8% 12%,
            rgba(54, 217, 255, .13),
            transparent 28%
        ),
        radial-gradient(
            circle at 92% 18%,
            rgba(241, 204, 104, .08),
            transparent 24%
        ),
        linear-gradient(
            135deg,
            #020812 0%,
            #061728 52%,
            #020812 100%
        );

    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: .14;

    background-image:
        linear-gradient(
            rgba(255,255,255,.04) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(255,255,255,.04) 1px,
            transparent 1px
        );

    background-size: 42px 42px;
    mask-image: linear-gradient(
        to bottom,
        black,
        transparent 88%
    );
}

/* ---------- Header ---------- */

.fv-header {
    height: 68px;
    border-bottom: 1px solid rgba(87, 205, 238, .13);
    background: rgba(2, 10, 19, .82);
    backdrop-filter: blur(20px);
}

.fv-header-inner {
    width: min(1440px, calc(100% - 48px));
    height: 100%;
    margin: auto;

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

.fv-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.fv-logo {
    width: 38px;
    height: 38px;
    border-radius: 12px;

    display: grid;
    place-items: center;

    color: #03101a;
    font-size: 18px;
    font-weight: 900;

    background:
        linear-gradient(
            135deg,
            var(--teal),
            var(--cyan)
        );

    box-shadow:
        0 0 25px rgba(54,217,255,.22);
}

.fv-brand-name {
    font-weight: 800;
    font-size: 16px;
}

.fv-brand-sub {
    margin-top: 2px;
    color: var(--cyan);
    font-size: 8px;
    font-weight: 800;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.fv-market-link {
    padding: 9px 14px;
    border: 1px solid rgba(54,217,255,.17);
    border-radius: 11px;

    color: #b6c7d5;
    text-decoration: none;
    font-size: 11px;
    font-weight: 700;

    background: rgba(8,25,41,.72);
    transition: .2s ease;
}

.fv-market-link:hover {
    color: white;
    border-color: var(--cyan);
    transform: translateY(-1px);
}

/* ---------- Main frame ---------- */

.fv-main {
    position: relative;
    z-index: 1;

    width: min(1420px, calc(100% - 48px));
    margin: 0 auto;

    padding: 20px 0 16px;
}

/* ---------- Hero ---------- */

.fv-hero {
    text-align: center;
    padding: 4px 0 18px;
}

.fv-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 7px 13px;
    border: 1px solid rgba(54,217,255,.18);
    border-radius: 999px;

    color: var(--cyan);
    background: rgba(8,31,50,.68);

    font-size: 9px;
    font-weight: 800;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.fv-kicker-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 12px var(--teal);
}

.fv-hero h1 {
    margin: 12px auto 8px;
    max-width: 900px;

    font-size: clamp(2rem, 4vw, 3.7rem);
    line-height: 1.02;
    letter-spacing: -.045em;
    font-weight: 900;
}

.fv-gradient-text {
    background:
        linear-gradient(
            90deg,
            #fff,
            #75e6ff,
            #f1cc68
        );

    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.fv-hero-copy {
    max-width: 760px;
    margin: 0 auto;

    color: var(--muted);
    font-size: 12px;
    line-height: 1.55;
}

/* ---------- Dashboard ---------- */

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

.fv-card {
    position: relative;
    min-width: 0;

    padding: 20px;
    border: 1px solid var(--line);
    border-radius: 22px;

    background:
        linear-gradient(
            145deg,
            rgba(8,28,47,.96),
            rgba(3,14,27,.97)
        );

    box-shadow:
        0 22px 55px rgba(0,0,0,.28),
        inset 0 1px 0 rgba(255,255,255,.04);

    overflow: hidden;
}

.fv-card::after {
    content: "";
    position: absolute;
    width: 230px;
    height: 230px;
    right: -120px;
    top: -120px;

    border-radius: 50%;
    background: rgba(54,217,255,.06);
    filter: blur(20px);
    pointer-events: none;
}

.fv-card-head {
    position: relative;
    z-index: 1;

    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 15px;
    padding-bottom: 12px;

    border-bottom: 1px solid rgba(255,255,255,.07);
}

.fv-card-title {
    color: #f5f9ff;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.fv-card-status {
    color: var(--teal);
    font-size: 8px;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
}

/* ---------- Inputs ---------- */

.fv-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 11px;
}

.fv-field {
    min-width: 0;
}

.fv-field.full {
    grid-column: 1 / -1;
}

.fv-field label {
    display: block;
    margin-bottom: 5px;

    color: #9fb2c3;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.fv-input-wrap {
    position: relative;
}

.fv-input-prefix,
.fv-input-suffix {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);

    color: #61798d;
    font-size: 11px;
    font-weight: 800;

    pointer-events: none;
}

.fv-input-prefix {
    left: 13px;
}

.fv-input-suffix {
    right: 13px;
}

.fv-input {
    width: 100%;
    height: 43px;

    padding: 0 13px;

    border: 1px solid rgba(75,166,202,.22);
    border-radius: 11px;

    color: white;
    background: rgba(1,10,20,.88);

    font: inherit;
    font-size: 13px;
    font-weight: 800;

    outline: none;
    transition: .2s ease;
}

.fv-input.has-prefix {
    padding-left: 32px;
}

.fv-input.has-suffix {
    padding-right: 32px;
}

.fv-input:focus {
    border-color: var(--cyan);
    box-shadow:
        0 0 0 3px rgba(54,217,255,.08),
        0 0 22px rgba(54,217,255,.08);
}

/* ---------- Button ---------- */

.fv-calculate {
    width: 100%;
    height: 45px;
    margin-top: 12px;

    border: 0;
    border-radius: 12px;

    color: #021018;
    background:
        linear-gradient(
            90deg,
            var(--teal),
            var(--cyan)
        );

    font: inherit;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .1em;
    text-transform: uppercase;

    cursor: pointer;

    box-shadow:
        0 10px 28px rgba(54,217,255,.16);

    transition: .2s ease;
}

.fv-calculate:hover {
    transform: translateY(-2px);
    box-shadow:
        0 15px 35px rgba(54,217,255,.24);
}

/* ---------- Results ---------- */

.fv-result-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.fv-result {
    min-height: 82px;
    padding: 13px;

    border: 1px solid rgba(75,166,202,.13);
    border-radius: 14px;

    background: rgba(2,13,25,.72);
}

.fv-result-label {
    margin-bottom: 7px;

    color: #71899c;
    font-size: 8px;
    font-weight: 800;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.fv-result-value {
    color: #f5faff;
    font-size: 20px;
    line-height: 1;
    font-weight: 900;
}

.fv-result.risk .fv-result-value {
    color: var(--danger);
}

.fv-result.primary .fv-result-value {
    color: var(--cyan);
}

.fv-result.lots {
    grid-column: 1 / -1;

    background:
        linear-gradient(
            110deg,
            rgba(10,45,65,.88),
            rgba(5,28,45,.72)
        );

    border-color: rgba(54,217,255,.25);
}

.fv-result.lots .fv-result-value {
    color: var(--teal);
    font-size: 23px;
}

/* ---------- Result note ---------- */

.fv-analysis-note {
    margin-top: 10px;
    padding: 11px 13px;

    border: 1px solid rgba(241,204,104,.15);
    border-radius: 13px;

    background: rgba(241,204,104,.035);

    color: #91a7b8;
    font-size: 9px;
    line-height: 1.55;
}

.fv-analysis-note strong {
    color: var(--gold);
}

/* ---------- Motivation ---------- */

.fv-motivation {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 9px;

    margin-top: 12px;
}

.fv-motivation-item {
    padding: 10px 12px;

    border: 1px solid rgba(75,166,202,.12);
    border-radius: 12px;

    background: rgba(5,20,34,.66);
}

.fv-motivation-item strong {
    display: block;

    color: #eaf5ff;
    font-size: 9px;
    letter-spacing: .07em;
    text-transform: uppercase;
}

.fv-motivation-item span {
    display: block;
    margin-top: 2px;

    color: #71899c;
    font-size: 8px;
}

/* ---------- Disclaimer ---------- */

.fv-disclaimer {
    margin-top: 10px;
    padding: 9px 13px;

    border: 1px solid rgba(255,255,255,.07);
    border-radius: 11px;

    color: #6f8496;
    background: rgba(2,10,18,.55);

    font-size: 8px;
    line-height: 1.5;
    text-align: center;
}

/* ---------- Footer ---------- */

.fv-footer {
    padding: 12px;

    color: #536a7c;
    font-size: 8px;
    text-align: center;
}

/* ---------- Desktop viewport optimisation ---------- */

@media (min-width: 1100px) and (max-height: 900px) {
    .fv-main {
        padding-top: 12px;
    }

    .fv-hero {
        padding-bottom: 12px;
    }

    .fv-hero h1 {
        margin-top: 9px;
        font-size: 3rem;
    }

    .fv-card {
        padding: 17px;
    }
}

/* ---------- Tablet ---------- */

@media (max-width: 900px) {
    .fv-dashboard {
        grid-template-columns: 1fr;
    }

    .fv-main {
        width: min(94%, 760px);
    }
}

/* ---------- Mobile ---------- */

@media (max-width: 600px) {
    .fv-header-inner,
    .fv-main {
        width: calc(100% - 20px);
    }

    .fv-header {
        height: 60px;
    }

    .fv-brand-sub {
        display: none;
    }

    .fv-hero h1 {
        font-size: 2.15rem;
    }

    .fv-form-grid,
    .fv-result-grid {
        grid-template-columns: 1fr;
    }

    .fv-field.full,
    .fv-result.lots {
        grid-column: auto;
    }

    .fv-motivation {
        grid-template-columns: 1fr 1fr;
    }
}
