/* GMWP order form — Opezario-inspired split layout */
:root {
    --navy-900: #061528;
    --navy-800: #0a1f3e;
    --navy-700: #122a52;
    --navy-600: #1e3a6e;
    --navy-500: #2c4f8a;
    --ink: #0f172a;
    --muted: #64748b;
    --muted-2: #475569;
    --line: #e2e8f0;
    --line-strong: #cbd5e1;
    --bg: #f8fafc;
    --teal: #4dd4c7;
    --teal-dark: #2bb8aa;
    --teal-light: #aef0e7;
    --inmed-red: #be2a16;
    --ok-bg: #ecfdf5;
    --ok-ink: #065f46;
    --ok-line: #10b981;
    --err-bg: #fef2f2;
    --err-ink: #991b1b;
    --err-line: #ef4444;
    --warn-bg: #fffbeb;
    --warn-ink: #78350f;
    --warn-line: #f59e0b;
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 18px;
    --shadow-sm: 0 1px 2px rgba(15,23,42,.04);
    --shadow: 0 1px 2px rgba(15,23,42,.04), 0 8px 24px rgba(15,23,42,.06);
    --shadow-lg: 0 4px 6px rgba(15,23,42,.05), 0 20px 50px rgba(15,23,42,.10);
    /* legacy aliases for admin panel */
    --primary: var(--navy-700);
    --primary-dark: var(--navy-800);
    --primary-light: #eff4fb;
    --card: #ffffff;
    --accent: var(--teal);
}

* { box-sizing: border-box; }
html, body {
    margin: 0; padding: 0;
    background: var(--bg);
    color: var(--ink);
    font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

/* =============== Split layout =============== */
.app {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(0, 380px) minmax(0, 1fr);
}
@media (max-width: 1100px) {
    .app { grid-template-columns: minmax(0, 340px) minmax(0, 1fr); }
}
@media (max-width: 980px) {
    .app { grid-template-columns: 1fr; }
}

/* =============== Left panel =============== */
.brand {
    position: relative;
    background:
        radial-gradient(800px 500px at 0% 0%, rgba(77,212,199,.10), transparent 60%),
        radial-gradient(700px 400px at 100% 100%, rgba(30,58,110,.55), transparent 65%),
        linear-gradient(155deg, var(--navy-900) 0%, var(--navy-800) 35%, var(--navy-700) 70%, var(--navy-600) 100%);
    color: #e6edf7;
    padding: 36px 40px 28px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.brand::before {
    content: '';
    position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255,255,255,.05) 1px, transparent 1px);
    background-size: 22px 22px;
    opacity: .7;
    pointer-events: none;
}
@media (min-width: 981px) {
    .brand { position: sticky; top: 0; max-height: 100vh; }
}
@media (max-width: 980px) {
    .brand { padding: 32px 24px 28px; }
}

.brand__logo {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 36px;
    position: relative; z-index: 2;
    flex-wrap: wrap;
}
.brand__logo img { height: 30px; display: block; }
.brand__logo-divider {
    width: 1px; height: 22px; background: rgba(255,255,255,.18);
}
.brand__logo-label {
    font-size: 11px; font-weight: 600;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: rgba(255,255,255,.7);
}
@media (max-width: 980px) {
    .brand__logo { margin-bottom: 28px; }
}

.brand__inner {
    position: relative; z-index: 2;
    flex: 1;
    display: flex; flex-direction: column; justify-content: flex-start;
    max-width: 100%;
}

.brand__eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(77,212,199,.12);
    color: var(--teal);
    border: 1px solid rgba(77,212,199,.28);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 12px; font-weight: 600;
    letter-spacing: 0.06em; text-transform: uppercase;
    margin-bottom: 24px;
    align-self: flex-start;
}
.brand__eyebrow::before {
    content: ''; width: 6px; height: 6px;
    background: var(--teal);
    border-radius: 999px;
    box-shadow: 0 0 0 4px rgba(77,212,199,.18);
}

.brand h1 {
    font-size: clamp(26px, 2.6vw, 34px);
    font-weight: 700;
    line-height: 1.15;
    margin: 0 0 14px;
    letter-spacing: -0.02em;
    color: #ffffff;
}
.brand h1 .accent {
    background: linear-gradient(120deg, var(--teal) 0%, #7be8dd 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-style: italic;
}
.brand__lead {
    color: rgba(230,237,247,.75);
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 24px;
    max-width: 100%;
}

.cover {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 20px 40px -15px rgba(0,0,0,.55), 0 8px 16px -8px rgba(0,0,0,.4);
    aspect-ratio: 16 / 10;
    background: #0a1f3e;
    margin-bottom: 22px;
    border: 1px solid rgba(255,255,255,.08);
}
.cover img {
    width: 100%; height: 100%;
    object-fit: cover; display: block;
    transition: transform .35s ease;
}
.cover::after {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(180deg, transparent 50%, rgba(6,21,40,.45) 100%);
    pointer-events: none;
}
.cover--btn {
    padding: 0;
    border: 1px solid rgba(255,255,255,.08);
    background: #0a1f3e;
    cursor: zoom-in;
    width: 100%;
    font: inherit;
    color: inherit;
    text-align: left;
}
.cover--btn:focus-visible {
    outline: 2px solid var(--teal);
    outline-offset: 3px;
}
.cover--btn:hover img { transform: scale(1.035); }
.cover__zoom {
    position: absolute;
    bottom: 12px; right: 12px;
    z-index: 2;
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 12px;
    background: rgba(6,21,40,.72);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 999px;
    color: #fff;
    font-size: 12px;
    font-weight: 500;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .2s, transform .2s;
    pointer-events: none;
}
.cover--btn:hover .cover__zoom,
.cover--btn:focus-visible .cover__zoom {
    opacity: 1;
    transform: translateY(0);
}

/* ===== Lightbox ===== */
.lightbox {
    position: fixed; inset: 0;
    z-index: 9999;
    display: flex; align-items: center; justify-content: center;
    padding: 32px;
    background: rgba(6,12,24,.92);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    animation: lb-fade .18s ease;
    cursor: zoom-out;
}
.lightbox[hidden] { display: none; }
.lightbox__img {
    max-width: min(96vw, 1600px);
    max-height: 90vh;
    width: auto; height: auto;
    border-radius: 10px;
    box-shadow: 0 30px 80px rgba(0,0,0,.55);
    animation: lb-pop .22s cubic-bezier(.22,1,.36,1);
    cursor: default;
}
.lightbox__close {
    position: absolute;
    top: 18px; right: 18px;
    width: 42px; height: 42px;
    background: rgba(255,255,255,.10);
    border: 1px solid rgba(255,255,255,.20);
    color: #fff;
    border-radius: 999px;
    cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
    transition: background .15s, transform .15s;
}
.lightbox__close:hover {
    background: rgba(255,255,255,.20);
    transform: scale(1.06);
}
@keyframes lb-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lb-pop {
    from { opacity: 0; transform: scale(.96); }
    to   { opacity: 1; transform: scale(1); }
}
body.lb-open { overflow: hidden; }

.tags {
    display: flex; flex-wrap: wrap; gap: 8px;
    margin-bottom: 18px;
}
.tag {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 12px;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 999px;
    font-size: 12px;
    color: rgba(230,237,247,.85);
    font-weight: 500;
}
.tag b { color: #fff; font-weight: 600; }
.tag--accent {
    background: rgba(77,212,199,.14);
    border-color: rgba(77,212,199,.40);
    color: var(--teal);
    font-weight: 600;
}

.sample-btn {
    display: flex; align-items: center; gap: 14px;
    padding: 14px 18px;
    background: linear-gradient(135deg, rgba(77,212,199,.16), rgba(77,212,199,.06));
    border: 1px solid rgba(77,212,199,.40);
    border-radius: 12px;
    color: #fff;
    text-decoration: none;
    font: inherit;
    transition: background .15s, border-color .15s, transform .05s, box-shadow .2s;
    box-shadow: 0 4px 16px -8px rgba(77,212,199,.30);
}
.sample-btn:hover {
    background: linear-gradient(135deg, rgba(77,212,199,.28), rgba(77,212,199,.12));
    border-color: rgba(77,212,199,.65);
    box-shadow: 0 8px 24px -8px rgba(77,212,199,.45);
}
.sample-btn:active { transform: translateY(1px); }
.sample-btn svg {
    flex-shrink: 0;
    color: var(--teal);
    transition: transform .2s;
}
.sample-btn:hover svg { transform: translateY(2px); }
.sample-btn span {
    display: flex; flex-direction: column; gap: 2px; line-height: 1.2;
}
.sample-btn strong {
    font-size: 15px; font-weight: 600; color: #fff;
    letter-spacing: -0.005em;
}
.sample-btn em {
    font-style: normal;
    font-size: 12px;
    color: rgba(230,237,247,.65);
}

.brand__foot {
    position: relative; z-index: 2;
    border-top: 1px solid rgba(255,255,255,.08);
    padding-top: 16px;
    margin-top: 20px;
    font-size: 11.5px;
    color: rgba(230,237,247,.55);
    display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.brand__foot a { color: rgba(230,237,247,.75); text-decoration: none; }
.brand__foot a:hover { color: var(--teal); }

/* =============== Right panel =============== */
.form-panel {
    background: #fff;
    padding: 56px 72px 80px;
    min-height: 100vh;
}
@media (max-width: 1280px) {
    .form-panel { padding: 48px 56px 72px; }
}
@media (max-width: 980px) {
    .form-panel { padding: 36px 24px 60px; }
}
@media (max-width: 560px) {
    .form-panel { padding: 24px 16px 48px; }
}

.form-head {
    margin-bottom: 36px;
    max-width: 600px;
}
.form-head__title {
    font-size: 22px;
    font-weight: 700;
    color: var(--ink);
    margin: 0 0 6px;
    letter-spacing: -0.01em;
}
.form-head__sub {
    color: var(--muted);
    font-size: 14px;
    margin: 0;
}

form#orderForm { max-width: 760px; }

.section {
    margin-bottom: 36px;
}
.section + .section {
    padding-top: 32px;
    border-top: 1px solid var(--line);
}
.section__head {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 22px;
}
.section__num {
    width: 30px; height: 30px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--navy-700), var(--navy-600));
    color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700;
    flex-shrink: 0;
}
.section__title {
    font-size: 15px;
    font-weight: 600;
    color: var(--ink);
    margin: 0;
    letter-spacing: -0.005em;
}
.section__hint {
    font-size: 13px;
    color: var(--muted);
    margin: -14px 0 18px 42px;
}

/* Fields */
.grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
.grid--2 { grid-template-columns: 1fr 1fr; }
.grid--3 { grid-template-columns: 2fr 1fr 1.5fr; }
@media (max-width: 640px) {
    .grid--2, .grid--3 { grid-template-columns: 1fr; }
}

.field { display: flex; flex-direction: column; gap: 6px; }
.field > span {
    font-size: 12px;
    color: var(--muted-2);
    font-weight: 600;
    letter-spacing: 0.01em;
}
.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    font: inherit;
    color: var(--ink);
    transition: border-color .15s, box-shadow .15s, background .15s;
}
.field input::placeholder, .field textarea::placeholder { color: #94a3b8; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--line-strong); }
.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--navy-600);
    box-shadow: 0 0 0 4px rgba(30,58,110,.10);
}
.field textarea { resize: vertical; min-height: 84px; }

.err {
    color: var(--err-ink);
    font-size: 12px;
    margin-top: 2px;
    display: flex; align-items: center; gap: 4px;
}
.field:has(.err) input,
.field:has(.err) select { border-color: var(--err-line); background: #fef7f7; }

/* Radios */
.radios { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; margin-bottom: 18px; }
@media (max-width: 480px) { .radios { grid-template-columns: 1fr; } }
.radio {
    cursor: pointer;
    border: 1px solid var(--line);
    border-radius: 10px;
    padding: 14px 16px;
    display: flex; align-items: center; gap: 12px;
    background: #fff;
    transition: all .15s;
}
.radio:hover { border-color: var(--line-strong); }
.radio input { accent-color: var(--navy-600); width: 16px; height: 16px; flex-shrink: 0; }
.radio span { font-weight: 500; font-size: 14px; }
.radio:has(input:checked) {
    border-color: var(--navy-600);
    background: #f1f5fb;
    box-shadow: 0 0 0 1px var(--navy-600) inset;
}

/* Checkbox toggle */
.check {
    display: flex; align-items: center; gap: 10px;
    cursor: pointer;
    padding: 12px 14px;
    margin-bottom: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    transition: all .15s;
}
.check:hover { border-color: var(--line-strong); }
.check:has(input:checked) {
    border-color: var(--navy-600);
    background: #f1f5fb;
}
.check input { accent-color: var(--navy-600); width: 17px; height: 17px; }
.check span { font-size: 14px; font-weight: 500; }

/* Summary card */
.summary {
    background: linear-gradient(135deg, #f8fafc, #eef4fb);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 18px 22px;
    margin-top: 18px;
}
.summary__row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 6px 0;
    color: var(--muted-2);
    font-size: 14px;
}
.summary__row strong { color: var(--ink); font-weight: 600; }
.summary__row--total {
    border-top: 1px solid var(--line);
    margin-top: 8px;
    padding-top: 14px;
    font-size: 16px;
}
.summary__row--total > span { color: var(--ink); font-weight: 500; }
.summary__row--total strong {
    color: var(--navy-700);
    font-size: 20px;
    font-weight: 700;
}
.summary__row--quote strong { color: var(--teal-dark); font-style: italic; }

/* Note */
.note {
    background: var(--warn-bg);
    border-left: 3px solid var(--warn-line);
    color: var(--warn-ink);
    padding: 12px 16px;
    margin-top: 14px;
    border-radius: 8px;
    font-size: 13.5px;
    line-height: 1.6;
}

/* Actions */
.actions {
    margin-top: 36px;
    padding-top: 26px;
    border-top: 1px solid var(--line);
    display: flex; flex-direction: column; gap: 14px;
    align-items: flex-start;
}
.actions__hint {
    color: var(--muted);
    font-size: 13px;
    display: flex; align-items: center; gap: 6px;
}
.btn {
    border: 0;
    border-radius: 10px;
    padding: 14px 28px;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: transform .05s, box-shadow .15s, background .15s;
    display: inline-flex; align-items: center; gap: 10px;
}
.btn--primary {
    background: linear-gradient(135deg, var(--navy-700), var(--navy-600));
    color: #fff;
    box-shadow: 0 4px 14px rgba(18,42,82,.30);
}
.btn--primary:hover {
    box-shadow: 0 6px 22px rgba(18,42,82,.40);
    background: linear-gradient(135deg, var(--navy-700), var(--navy-500));
}
.btn--primary:active { transform: translateY(1px); }
.btn .arrow { transition: transform .15s; }
.btn:hover .arrow { transform: translateX(3px); }

/* Alerts */
.alert {
    border-radius: var(--radius);
    padding: 16px 20px;
    margin-bottom: 26px;
    border: 1px solid;
    font-size: 14.5px;
    display: flex; gap: 12px; align-items: flex-start;
}
.alert__icon { flex-shrink: 0; margin-top: 1px; }
.alert--ok  { background: var(--ok-bg);  color: var(--ok-ink);  border-color: rgba(16,185,129,.30); }
.alert--ok  .alert__icon { color: var(--ok-line); }
.alert--err { background: var(--err-bg); color: var(--err-ink); border-color: rgba(239,68,68,.30); }
.alert--err .alert__icon { color: var(--err-line); }

/* ===== Admin panel layout ===== */
.wrap { max-width: 860px; margin: 0 auto; padding: 32px 20px 60px; }
.admin-wrap { max-width: 1200px; }
.hero { text-align: center; padding: 28px 0 36px; }
.card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 32px;
}
.section h2 { font-size: 18px; font-weight: 600; margin: 0 0 18px; color: var(--navy-700); }

/* Login (admin) reuse */
.login-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background:
        radial-gradient(1000px 500px at 0% 0%, rgba(77,212,199,.10), transparent 60%),
        linear-gradient(155deg, var(--navy-900), var(--navy-700));
    padding: 24px;
}
.login-card {
    width: 100%; max-width: 380px;
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 36px 32px;
    box-shadow: var(--shadow-lg);
}
.login-card .brand__logo {
    margin: 0 0 24px;
    justify-content: center;
}
.login-card .brand__logo img { height: 28px; filter: none; }
.login-card h1 {
    font-size: 22px;
    margin: 0 0 6px;
    text-align: center;
}
.login-card .login-sub {
    color: var(--muted);
    font-size: 14px;
    text-align: center;
    margin: 0 0 24px;
}
