/* Unified dark form primitives: applied after legacy stylesheets. */
:root { color-scheme:dark; --control-bg:#0d1c2b;--control-hover:#172c3d;--control-fg:#eff9ff;--control-muted:#aec5d2;--control-line:#456175;--control-accent:#67e4cf }
/* Searchable selects: dropdown, search input, keyboard highlight, grouped options */
body.ai-platform .search-select,
body.ai-platform .field .search-select{min-width:0;max-width:100%}
body.ai-platform .search-select__control,
body.ai-platform .field .search-select__control{background:var(--control-bg)!important;color:var(--control-fg)!important;border:1px solid var(--control-line)!important;box-shadow:none!important}
body.ai-platform .search-select__value,
body.ai-platform .field .search-select__value {color:var(--control-fg)!important}
body.ai-platform .search-select__value.is-placeholder{color:var(--control-muted)!important}
body.ai-platform .search-select__arrow,
body.ai-platform .search-select.is-open .search-select__arrow {background:#233949!important;border-color:var(--control-line)!important}
body.ai-platform .search-select__arrow::before {border-color:var(--control-fg)!important}
body.ai-platform .search-select__menu,
body.ai-platform .field .search-select__menu{background:#122638!important;border:1px solid #516c7e!important;color:var(--control-fg)!important;box-shadow:0 16px 40px #020810bd!important;z-index:1100!important;max-width:100%}
body.ai-platform .search-select__search,
body.ai-platform .search-select__search:focus {background:#091b29!important;border:1px solid #526b7e!important;color:#fff!important;box-shadow:none!important}
body.ai-platform .search-select__search::placeholder{color:#afc6d2!important;opacity:1}
body.ai-platform .search-select__option{background:transparent!important;color:#eaf4fd!important}
body.ai-platform .search-select__option:hover,
body.ai-platform .search-select__option.is-highlighted,
body.ai-platform .search-select__option.is-selected{background:#20515a!important;color:#efffff!important}
body.ai-platform .search-select__group{color:#b7ced9!important}
body.ai-platform .search-select__empty{color:#bdccd5!important}
body.ai-platform .search-select__options{scrollbar-color:#607b8b #172e40}
/* Local Persian date picker: wrapper, popup, navigation, day states */
body .persian-date-display,
body.ai-platform .persian-date-display{background:var(--control-bg)!important;color:var(--control-fg)!important;border:1px solid var(--control-line)!important;box-shadow:none!important}
body .persian-date-display::placeholder{color:var(--control-muted)!important}
body .persian-date-display:focus{border-color:var(--control-accent)!important;box-shadow:0 0 0 3px #69e6d52e!important}
body .persian-date-trigger {background:#1c3c44!important;color:#9ef5e5!important;border:1px solid #456f71!important}
body .persian-datepicker {background:#132636!important;border:1px solid #527083!important;box-shadow:0 22px 55px #010712c2!important;color:#ecf7fd!important;overflow:hidden}
body .persian-datepicker__title{color:#eef8ff!important}
body .persian-datepicker__weekdays span{color:#bad0df!important}
body .persian-datepicker__nav{background:#1f394b!important;border:1px solid #55778a!important;color:#e6faff!important}
body .persian-datepicker__nav:hover{background:#2a5960!important;color:#fff!important}
body .persian-datepicker__day{background:transparent!important;color:#e3f4fd!important;border-radius:8px}
body .persian-datepicker__day:hover{background:#2c5364!important;color:#fff!important}
body .persian-datepicker__day.is-today{box-shadow:inset 0 0 0 1px #72dace!important;color:#adfaee!important}
body .persian-datepicker__day.is-selected{background:#39bbab!important;color:#061f1d!important;box-shadow:none!important;font-weight:900}
body .persian-datepicker__time{color:#d1e4eb!important;border-color:#405b6f!important}
body .persian-datepicker__time input{background:#0e1e2d!important;color:#fff!important;border:1px solid #4d6a7e!important}
body .persian-datepicker__footer{background:transparent!important}
/* Serial lookup and full-screen progress state */
body.ai-platform .serial-loader{background:#122b38!important;border:1px solid #426778!important;color:#e9f9ff!important;padding:14px 16px!important;box-shadow:none!important;display:flex;align-items:center;gap:14px}
body.ai-platform .serial-loader.hidden{display:none!important}
body.ai-platform .serial-loader strong{color:#ebfaff!important}
body.ai-platform .serial-loader .loader-ring{border-color:#386073!important;border-top-color:#70f5d5!important;border-right-color:#44bbaa!important}
body.ai-platform .global-loader{background:#020c18bc!important;backdrop-filter:blur(4px)}
body.ai-platform .global-loader .loader-card,
body.ai-platform .progress-card{background:#132636!important;color:#effaff!important;border:1px solid #426779!important;box-shadow:0 24px 68px #010610ad!important}
body.ai-platform .global-loader .loader-card b,
body.ai-platform .progress-card h3,
body.ai-platform .progress-card p{color:#f0faff!important}
body.ai-platform .global-loader .loader-ring,
body.ai-platform .progress-card .loader-ring{border-color:#385b70!important;border-top-color:#67e6d2!important;border-right-color:#6cc0e6!important}
body.ai-platform .progress-bar{background:#233e4f!important}
body.ai-platform .progress-bar i{background:#60dcc6!important}
/* Switch and payment details */
.token-switch-form{padding:11px 12px;margin:10px 0;border:1px solid #3d586a;border-radius:10px;background:#182d3b}
.token-switch-form label{color:#ebf6fc!important;font-size:13px;gap:12px}
.token-switch-form .check input[type=checkbox]{flex-shrink:0}
#costAmountField[hidden]{display:none!important}
.cost-amount-field{margin-top:14px}
.cost-amount-field input{width:100%;max-width:300px;text-align:left}
.amount-in-words{color:#aef2dd;line-height:1.8;font-size:13px;min-height:24px;padding-top:5px;font-weight:650}
@media(max-width:700px){
 body.ai-platform .search-select__menu{width:100%!important;max-width:100%!important}
 body .persian-datepicker{max-width:calc(100vw - 22px)!important;padding:12px!important;box-sizing:border-box}
 .token-switch-form{margin-block:8px}
 .cost-amount-field input{max-width:100%}
}


/* Neural illustration reused on the inspection hero. Scoped to avoid impacting authentication. */
.ai-hero .ai-hero-art.neural-hero {
    display: grid !important;
    position: relative;
    align-self: stretch;
    place-items: center;
    min-height: 252px;
    overflow: hidden;
    pointer-events: none;
    direction: ltr;
    background: radial-gradient(circle at center, rgba(28, 166, 156, .07), transparent 70%);
}
.ai-hero .neural-hero-illustration {
    display: grid !important;
    width: 100%;
    min-height: 252px;
    height: 100%;
    flex: none;
    transform: scale(.82);
    transform-origin: center;
}
.ai-hero .neural-hero-illustration .auth-core {
    transform: rotate(-4deg);
}
@media (max-width: 720px) {
    .ai-hero .ai-hero-art.neural-hero {
        position: absolute;
        inset: auto auto 6px 6px;
        z-index: 0;
        width: 128px;
        height: 128px;
        min-height: 0;
        opacity: .7;
        background: none;
    }
    .ai-hero .neural-hero-illustration {
        width: 128px;
        min-height: 128px;
        height: 128px;
        transform: scale(.48);
    }
    .ai-hero .ai-hero-copy {
        position: relative;
        z-index: 2;
    }
}
@media (prefers-reduced-motion: reduce) {
    .ai-hero .neural-hero-illustration .auth-orbit {
        animation: none !important;
    }
}

/* ===== AVAJANG FIVE-COLOR COHERENCE LAYER ===== */
:root { --control-bg: var(--ava-deep, #0D1D2B); --control-hover: var(--ava-surface-hover, #1C3445);
 --control-fg: var(--ava-text, #EAF5F4); --control-muted: var(--ava-muted, #A4BDCA);
 --control-line: var(--ava-border, #3E596A); --control-accent: var(--ava-accent, #FFB547); }
body.ai-platform .search-select__control,
body.ai-platform .field .search-select__control { background: var(--control-bg) !important; color: var(--control-fg) !important; border-color: var(--control-line) !important; }
body.ai-platform .search-select__menu,
body.ai-platform .field .search-select__menu { background: var(--ava-surface, #172A3A) !important; color: var(--control-fg) !important; border-color: var(--control-line) !important; }
body.ai-platform .search-select__search,
body.ai-platform .search-select__search:focus { background: var(--control-bg) !important; color: var(--control-fg) !important; border-color: var(--control-line) !important; }
body.ai-platform .search-select__option.is-highlighted,
body.ai-platform .search-select__option.is-selected { background: #23514E !important; color: #fff !important; }
body.ai-platform .search-select__option.is-highlighted::before { background: var(--ava-accent, #FFB547); }
body .persian-date-display, body.ai-platform .persian-date-display { background: var(--control-bg) !important; color: var(--control-fg) !important; border-color: var(--control-line) !important; }
body .persian-date-display:focus { border-color: var(--control-accent) !important; box-shadow: 0 0 0 3px rgba(255,181,71,.16) !important; }
body .persian-date-trigger { background: var(--ava-secondary, #121F2E) !important; border-color: var(--control-line) !important; color: var(--ava-accent, #FFB547) !important; }
body .persian-datepicker { background: var(--ava-surface, #172A3A) !important; border-color: var(--control-line) !important; color: var(--control-fg) !important; }
body .persian-datepicker__title,body .persian-datepicker__day { color: var(--control-fg) !important; }
body .persian-datepicker__weekdays span { color: var(--control-muted) !important; }
body .persian-datepicker__day.is-today { color: var(--ava-accent, #FFB547) !important; box-shadow: inset 0 0 0 1px var(--ava-accent, #FFB547) !important; }
body .persian-datepicker__day.is-selected { background: var(--ava-primary, #007470) !important; color:#fff !important; }
body.ai-platform .serial-loader,body.ai-platform .progress-card,body.ai-platform .global-loader .loader-card { background: var(--ava-surface, #172A3A) !important; color: var(--ava-text, #EAF5F4) !important; border-color: var(--ava-border, #3E596A) !important; }
body.ai-platform .progress-bar i { background: var(--ava-primary, #007470) !important; }
body.ai-platform .serial-loader .loader-ring { border-top-color: var(--ava-accent, #FFB547) !important; border-right-color: var(--ava-primary, #007470) !important; }
.token-switch-form { background: var(--ava-secondary, #121F2E); border-color: var(--ava-border, #3E596A); }
.amount-in-words { color: var(--ava-accent, #FFB547); }

/* ===== AVAJANG AURORA CIRCUIT • V6 | high contrast overlay controls ===== */
body.ai-platform .search-select__control,body.ai-platform .field .search-select__control {
 background:#0D2232!important;color:#EAF5F4!important;border:1px solid #587588!important;
 border-radius:11px!important;min-height:46px;transition:border-color .15s,box-shadow .15s;
}
body.ai-platform .search-select:focus-within .search-select__control,
body.ai-platform .search-select.is-open .search-select__control {
 border-color:#FFB547!important;box-shadow:0 0 0 3px rgba(255,181,71,.12)!important;
}
body.ai-platform .search-select__menu {
 background:#122839!important;color:#EAF5F4!important;border:1px solid #5A7888!important;
 border-radius:12px!important;box-shadow:0 22px 50px rgba(0,6,16,.5)!important;
}
body.ai-platform .search-select__search {background:#0B1E2B!important;border:1px solid #638093!important;border-radius:9px!important}
body.ai-platform .search-select__option:hover,
body.ai-platform .search-select__option.is-highlighted,
body.ai-platform .search-select__option.is-selected {
 background:#17574F!important;color:#FFF!important;
}
body .persian-datepicker {border-radius:15px!important;border-color:#537488!important;background:#152C3D!important}
body .persian-datepicker__nav {border-radius:9px!important;color:#EAF5F4!important}
body .persian-datepicker__day.is-selected {background:#007470!important;color:#fff!important}
body .persian-datepicker__day.is-today {box-shadow:inset 0 0 0 1px #FFB547!important;color:#FFDB98!important}
body .persian-date-display:focus {border-color:#FFB547!important;box-shadow:0 0 0 3px rgba(255,181,71,.14)!important}
body.ai-platform .serial-loader {
 border-radius:12px!important;background:linear-gradient(105deg,#1B3B44,#172B3F)!important;
 border:1px solid #577A83!important;color:#F0F8F8!important;
}
body.ai-platform .serial-loader .loader-ring {border-top-color:#FFB547!important;border-right-color:#008B80!important}
body.ai-platform .progress-card,body.ai-platform .global-loader .loader-card {
 background:#182E41!important;border:1px solid #547482!important;border-radius:17px!important;
 box-shadow:0 25px 70px rgba(0,7,16,.5)!important;
}
body.ai-platform .progress-bar i {background:linear-gradient(90deg,#007470,#FFB547)!important}
