:root {
    --bg: #050505;
    --panel: #0b0b0a;
    --panel-2: #11100d;
    --line: rgba(211, 157, 45, .34);
    --line-soft: rgba(211, 157, 45, .14);
    --gold: #d7a63d;
    --gold-2: #f1d277;
    --gold-dark: #8e6216;
    --text: #f5f1e8;
    --muted: #9c978f;
    --green: #59d879;
    --red: #ff7377;
    --shadow: 0 18px 48px rgba(0, 0, 0, .44);
    --radius-lg: 18px;
    --radius-md: 13px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    min-height: 100vh;
    overflow-x: hidden;
    color: var(--text);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    background:
        radial-gradient(circle at 12% 10%, rgba(199, 141, 29, .09), transparent 25%),
        radial-gradient(circle at 86% 34%, rgba(199, 141, 29, .06), transparent 24%),
        linear-gradient(180deg, #030303 0%, #080705 55%, #030303 100%);
}
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: .16;
    background-image:
        linear-gradient(rgba(255, 255, 255, .015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .015) 1px, transparent 1px);
    background-size: 38px 38px;
    mask-image: linear-gradient(to bottom, #000, transparent 80%);
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

.ambient {
    position: fixed;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    opacity: .09;
    animation: ambientFloat 12s ease-in-out infinite alternate;
}
.ambient-one { left: -145px; top: 90px; background: #d7a63d; }
.ambient-two { right: -165px; top: 390px; background: #8e6216; animation-delay: -5s; }

.topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    height: 70px;
    padding: 0 max(22px, calc((100vw - 1240px) / 2));
    display: flex;
    align-items: center;
    gap: 24px;
    border-top: 1px solid rgba(255, 208, 93, .64);
    border-bottom: 1px solid rgba(211, 157, 45, .28);
    background: rgba(3, 3, 3, .9);
    backdrop-filter: blur(16px);
    transform: translateY(-12px);
    opacity: 0;
    transition: transform .6s ease, opacity .6s ease;
}
body.is-ready .topbar { transform: none; opacity: 1; }
.brand { display: flex; align-items: center; gap: 10px; min-width: 210px; }
.brand img {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(235, 190, 82, .42);
    box-shadow: 0 0 20px rgba(215, 166, 61, .12);
    transition: transform .35s ease, box-shadow .35s ease;
}
.brand:hover img { transform: rotate(-3deg) scale(1.04); box-shadow: 0 0 26px rgba(215, 166, 61, .22); }
.brand span { display: grid; line-height: 1; }
.brand strong { font-family: Georgia, serif; font-size: 20px; letter-spacing: .16em; color: var(--gold-2); }
.brand small { margin-top: 5px; font-size: 7px; letter-spacing: .48em; color: #c59a3b; }
.nav { display: flex; align-items: center; gap: 23px; margin-left: auto; }
.nav a {
    position: relative;
    padding: 25px 1px 21px;
    color: #c5c0b8;
    font-size: 12px;
    transition: color .25s ease, transform .25s ease;
}
.nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 14px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    transform: scaleX(0);
    transition: transform .25s ease;
}
.nav a:hover, .nav a.active { color: var(--gold-2); transform: translateY(-1px); }
.nav a:hover::after, .nav a.active::after { transform: scaleX(1); }
.telegram-mini {
    border: 1px solid var(--gold-dark);
    border-radius: 10px;
    padding: 9px 14px;
    color: var(--gold-2);
    background: linear-gradient(180deg, rgba(218, 164, 47, .11), rgba(218, 164, 47, .025));
    font-weight: 700;
    font-size: 11px;
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.telegram-mini:hover { transform: translateY(-2px); border-color: var(--gold); box-shadow: 0 8px 22px rgba(218, 164, 47, .13); }
.menu-toggle { display: none; width: 40px; height: 38px; border: 1px solid var(--line); border-radius: 9px; background: #0a0a0a; padding: 9px; cursor: pointer; }
.menu-toggle span { display: block; height: 1px; margin: 4px 0; background: var(--gold-2); transition: transform .25s ease, opacity .25s ease; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }

main { width: min(1240px, calc(100% - 34px)); margin: 0 auto; padding: 20px 0 34px; }
.hero-shell {
    display: grid;
    grid-template-columns: minmax(260px, .7fr) minmax(560px, 1.5fr);
    gap: 13px;
    position: relative;
    overflow: hidden;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, rgba(18, 17, 14, .96), rgba(5, 5, 5, .98));
    box-shadow: var(--shadow);
}
.hero-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(112deg, transparent 0 42%, rgba(243, 208, 111, .028) 50%, transparent 58%);
    transform: translateX(-55%);
    animation: heroSweep 7s ease-in-out infinite;
}
.hero-copy {
    padding: 31px 25px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid var(--line-soft);
}
.eyebrow, .section-kicker { font-size: 9px; letter-spacing: .24em; color: var(--gold); font-weight: 800; }
.hero-copy h1 {
    margin: 12px 0 14px;
    font-family: Georgia, serif;
    font-size: clamp(30px, 3.3vw, 46px);
    line-height: 1.03;
    text-transform: uppercase;
    background: linear-gradient(180deg, #fff9e7 8%, #d49c2a 86%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.hero-copy p { max-width: 450px; margin: 0; color: #b4afa6; font-size: 13px; line-height: 1.7; }
.trust-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 23px; }
.trust-row div { display: flex; align-items: center; gap: 7px; color: #d3cec5; font-size: 10px; }
.trust-row i {
    display: grid;
    place-items: center;
    width: 27px;
    height: 27px;
    flex: 0 0 27px;
    border: 1px solid var(--line);
    border-radius: 50%;
    color: var(--gold);
    font-style: normal;
    background: rgba(215, 166, 61, .04);
    transition: transform .25s ease, background .25s ease;
}
.trust-row div:hover i { transform: translateY(-2px) rotate(6deg); background: rgba(215, 166, 61, .1); }

.rate-zone {
    position: relative;
    padding: 21px;
    border: 1px solid rgba(214, 164, 55, .24);
    border-radius: 14px;
    background: radial-gradient(circle at 72% 18%, rgba(208, 152, 33, .08), transparent 30%), #070707;
    transition: transform .28s ease, box-shadow .28s ease;
}
.rate-zone.currency-switch { animation: currencySwitch .5s ease; }
.rate-topline { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.rate-topline h2 { margin: 6px 0 0; font-family: Georgia, serif; font-size: 23px; color: #efe6d0; letter-spacing: .01em; }
.rate-topline h2 em {
    margin-left: 7px;
    padding: 5px 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    color: var(--gold-2);
    font-family: Inter, "Segoe UI", sans-serif;
    font-size: 9px;
    font-style: normal;
    letter-spacing: .1em;
    vertical-align: middle;
}
.live-meta { display: flex; gap: 18px; }
.live-meta > div { padding-left: 12px; border-left: 1px solid var(--line-soft); }
.live-meta span { display: block; margin-bottom: 5px; color: #85817a; font-size: 8px; }
.live-meta strong { color: #e4ded4; font-size: 10px; white-space: nowrap; }
.market-state b {
    display: inline-block;
    width: 6px;
    height: 6px;
    margin-right: 5px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 10px rgba(89, 216, 121, .62);
    animation: livePulse 1.8s ease-in-out infinite;
}
.market-state.closed b { background: var(--red); box-shadow: 0 0 10px rgba(255, 111, 114, .48); }
.rate-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; margin-top: 18px; }
.rate-card {
    position: relative;
    overflow: hidden;
    min-height: 135px;
    padding: 17px 19px;
    border: 1px solid rgba(224, 174, 67, .66);
    border-radius: 14px;
    background: linear-gradient(145deg, rgba(20, 18, 14, .95), rgba(5, 5, 5, .98));
    box-shadow: inset 0 1px rgba(255, 255, 255, .025), 0 11px 26px rgba(0, 0, 0, .3);
    transition: transform .28s ease, border-color .28s ease, box-shadow .28s ease;
}
.rate-card:hover { transform: translateY(-3px); border-color: rgba(241, 210, 119, .88); box-shadow: 0 14px 34px rgba(0, 0, 0, .38), 0 0 20px rgba(215, 166, 61, .08); }
.rate-card::before {
    content: "";
    position: absolute;
    top: -60%;
    left: -75%;
    width: 55%;
    height: 220%;
    background: linear-gradient(90deg, transparent, rgba(255, 232, 166, .08), transparent);
    transform: rotate(18deg);
    animation: cardShine 6s ease-in-out infinite;
}
.rate-card:nth-child(2)::before { animation-delay: 2.3s; }
.rate-card::after {
    content: "";
    position: absolute;
    inset: auto 12% 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold-2), transparent);
    box-shadow: 0 0 12px var(--gold);
}
.rate-label { display: flex; align-items: center; gap: 8px; color: #d7aa4b; font-family: Georgia, serif; font-size: 15px; }
.rate-icon { display: grid; place-items: center; width: 29px; height: 29px; border: 1px solid var(--line); border-radius: 50%; font-family: Inter, sans-serif; }
.rate-value { display: flex; align-items: flex-end; gap: 8px; margin: 12px 0 6px; }
.rate-value > span {
    color: var(--gold-2);
    font-family: Georgia, serif;
    font-size: clamp(36px, 4vw, 56px);
    line-height: .9;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 3px 20px rgba(217, 168, 60, .2);
}
.rate-value small { margin-bottom: 5px; color: #c89935; font-family: Georgia, serif; font-size: 12px; }
.rate-card p { margin: 0; color: #8d8982; font-size: 10px; }
.shine { position: absolute; width: 120px; height: 120px; right: -65px; top: -75px; border-radius: 50%; background: rgba(240, 199, 95, .1); filter: blur(38px); }
.price-up { animation: upFlash .85s; }
.price-down { animation: downFlash .85s; }
.refresh-line { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--line-soft); color: #85817a; font-size: 9px; }
.refresh-line b { color: var(--gold-2); }

.rates-board {
    margin-top: 14px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(14, 13, 11, .98), rgba(6, 6, 6, .98));
    box-shadow: var(--shadow);
}
.rates-board-head { padding: 19px 21px; display: flex; justify-content: space-between; align-items: center; gap: 18px; border-bottom: 1px solid var(--line-soft); }
.rates-board-head h2 { margin: 5px 0 5px; color: #f2ead7; font-family: Georgia, serif; font-size: 23px; }
.rates-board-head p { margin: 0; color: #8d8981; font-size: 10px; }
.rates-tools { display: flex; align-items: center; gap: 9px; }
.search-box { width: min(280px, 36vw); height: 39px; display: flex; align-items: center; gap: 8px; padding: 0 12px; border: 1px solid var(--line); border-radius: 10px; background: #080808; transition: border-color .25s ease, box-shadow .25s ease; }
.search-box:focus-within { border-color: rgba(241, 210, 119, .75); box-shadow: 0 0 0 3px rgba(215, 166, 61, .07); }
.search-box span { color: var(--gold); font-size: 17px; }
.search-box input { width: 100%; border: 0; outline: 0; color: #eee9df; background: transparent; font-size: 11px; }
.search-box input::placeholder { color: #716d66; }
.currency-count { height: 39px; min-width: 66px; display: flex; align-items: baseline; justify-content: center; gap: 4px; border: 1px solid var(--line); border-radius: 10px; background: rgba(215, 166, 61, .045); }
.currency-count strong { color: var(--gold-2); font-size: 17px; }
.currency-count span { color: #817d76; font-size: 8px; text-transform: uppercase; }
.rates-table { width: 100%; }
.rates-row { display: grid; grid-template-columns: minmax(250px, 1.65fr) minmax(110px, .78fr) minmax(110px, .78fr) minmax(105px, .65fr) 26px; align-items: center; gap: 12px; padding: 11px 20px; }
.rates-head { min-height: 39px; color: #817d75; background: rgba(255, 255, 255, .01); border-bottom: 1px solid var(--line-soft); font-size: 8px; letter-spacing: .11em; text-transform: uppercase; }
.currency-rows { max-height: 560px; overflow: auto; scrollbar-color: #755419 #111; scrollbar-width: thin; }
.currency-row { width: 100%; border: 0; border-bottom: 1px solid rgba(213, 162, 54, .085); color: inherit; background: transparent; text-align: left; cursor: pointer; transition: background .2s ease, box-shadow .2s ease, transform .2s ease; }
.currency-row:hover { background: linear-gradient(90deg, rgba(211, 157, 45, .095), rgba(211, 157, 45, .015)); transform: translateX(2px); }
.currency-row.active { background: linear-gradient(90deg, rgba(211, 157, 45, .12), rgba(211, 157, 45, .02)); box-shadow: inset 2px 0 var(--gold); }
.currency-row.row-enter { opacity: 0; transform: translateY(8px); animation: rowEnter .38s ease forwards; animation-delay: var(--row-delay, 0ms); }
.currency-name { display: flex; align-items: center; gap: 10px; min-width: 0; }
.currency-name > i { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 34px; border: 1px solid var(--line); border-radius: 9px; background: linear-gradient(145deg, #17140e, #090909); color: var(--gold-2); font-style: normal; font-size: 8px; font-weight: 800; }
.currency-name > span { min-width: 0; }
.currency-name strong { display: block; overflow: hidden; color: #eee9de; font-size: 11px; white-space: nowrap; text-overflow: ellipsis; }
.currency-name small { display: block; margin-top: 3px; color: #706c65; font-size: 8px; letter-spacing: .08em; }
.table-price { color: #eee6d3; font-family: Georgia, serif; font-size: 16px; font-variant-numeric: tabular-nums; }
.table-price small { color: #767169; font-family: Inter, sans-serif; font-size: 7px; }
.table-price.buy { color: #e5d2a4; }
.table-price.sell { color: var(--gold-2); }
.per-usd { color: #9e9991; font-size: 10px; }
.row-arrow { color: #8f681e; font-size: 21px; text-align: right; }
.rates-loading, .rates-empty { padding: 38px; color: #88837b; text-align: center; font-size: 10px; }
.rates-loading span { display: inline-block; width: 15px; height: 15px; margin-right: 8px; border: 2px solid rgba(215, 166, 61, .16); border-top-color: var(--gold); border-radius: 50%; vertical-align: middle; animation: spin .8s linear infinite; }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(285px, .82fr) minmax(245px, .62fr); gap: 14px; margin-top: 14px; }
.panel { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: linear-gradient(150deg, rgba(14, 13, 11, .97), rgba(5, 5, 5, .98)); box-shadow: 0 14px 38px rgba(0, 0, 0, .32); }
.panel-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 17px; border-bottom: 1px solid var(--line-soft); }
.panel-head span { color: var(--gold); font-size: 7px; letter-spacing: .16em; }
.panel-head h3 { margin: 4px 0 0; font-family: Georgia, serif; font-size: 15px; }
.status-chip { padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; color: var(--gold-2); font-size: 8px; }
.chart-wrap { position: relative; height: 255px; padding: 10px 10px 4px; }
.chart-wrap canvas { width: 100%; height: 100%; }
.chart-empty { position: absolute; inset: 0; display: grid; place-items: center; color: #7d7972; font-size: 10px; }
.gold-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 14px rgba(215, 166, 61, .65); animation: livePulse 1.8s ease-in-out infinite; }
.history-table { padding: 0 15px 13px; }
.history-row { display: grid; grid-template-columns: 1.35fr .8fr .8fr; gap: 8px; align-items: center; min-height: 34px; border-bottom: 1px solid rgba(211, 157, 45, .09); color: #8f8a82; font-size: 9px; }
.history-row strong { color: #e4dccd; font-size: 10px; text-align: right; }
.history-head { min-height: 32px; color: #a77c28; font-size: 7px; letter-spacing: .08em; text-transform: uppercase; }
.history-head span:not(:first-child) { text-align: right; }
.history-loading { padding: 27px 0; color: #747068; font-size: 9px; text-align: center; }
.telegram-panel { min-height: 100%; padding: 21px; display: flex; flex-direction: column; justify-content: flex-end; background: radial-gradient(circle at 70% 16%, rgba(223, 171, 60, .14), transparent 28%), linear-gradient(145deg, #12100b, #050505); }
.telegram-orbit { position: absolute; right: 18px; top: 18px; width: 58px; height: 58px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; animation: orbitFloat 4s ease-in-out infinite; }
.telegram-orbit::after, .telegram-orbit span { content: ""; position: absolute; inset: 7px; border: 1px dashed rgba(220, 168, 54, .25); border-radius: 50%; animation: orbitSpin 8s linear infinite; }
.telegram-orbit strong { color: var(--gold-2); font-size: 21px; }
.panel-tag { color: var(--gold); font-size: 7px; letter-spacing: .18em; }
.telegram-panel h3 { max-width: 200px; margin: 8px 0 8px; font-family: Georgia, serif; font-size: 21px; }
.telegram-panel p { margin: 0 0 15px; color: #938e86; font-size: 9px; line-height: 1.65; }
.telegram-panel > a { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; border-radius: 8px; background: linear-gradient(135deg, #e3b547, #9d6e16); color: #120e06; font-size: 10px; font-weight: 800; box-shadow: 0 9px 22px rgba(215, 166, 61, .14); transition: transform .25s ease, filter .25s ease; }
.telegram-panel > a:hover { transform: translateY(-2px); filter: brightness(1.08); }

.about-strip { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: #080808; }
.about-strip > div { position: relative; padding: 18px; border-right: 1px solid var(--line-soft); }
.about-strip > div:last-child { border-right: 0; }
.about-strip > div > span { position: absolute; right: 13px; top: 9px; color: rgba(215, 166, 61, .08); font-family: Georgia, serif; font-size: 27px; }
.about-strip h4 { margin: 0 0 6px; color: #d8c080; font-size: 10px; }
.about-strip p { margin: 0; color: #7e7a73; font-size: 9px; line-height: 1.55; }

footer { min-height: 72px; padding: 15px max(22px, calc((100vw - 1240px) / 2)); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 18px; border-top: 1px solid var(--line); background: #030303; color: #736f68; font-size: 9px; }
.footer-brand { display: flex; align-items: center; gap: 8px; color: #c79b3a; letter-spacing: .12em; }
.footer-brand img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.footer-brand span { font-family: Georgia, serif; }
.footer-brand ~ p { text-align: center; }
footer > a { justify-self: end; color: #c99d3b; }
.toast { position: fixed; right: 16px; bottom: 16px; z-index: 100; max-width: min(380px, calc(100vw - 32px)); padding: 11px 13px; border: 1px solid var(--line); border-radius: 10px; background: rgba(10, 10, 10, .96); color: #ddd5c4; font-size: 10px; box-shadow: var(--shadow); transform: translateY(25px); opacity: 0; pointer-events: none; transition: .25s ease; }
.toast.show { transform: none; opacity: 1; }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .62s ease, transform .62s cubic-bezier(.2, .75, .25, 1); }
.reveal.is-visible { opacity: 1; transform: none; }
.dashboard-grid > .reveal:nth-child(2) { transition-delay: .08s; }
.dashboard-grid > .reveal:nth-child(3) { transition-delay: .16s; }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes ambientFloat { to { transform: translate3d(25px, -18px, 0) scale(1.08); } }
@keyframes heroSweep { 0%, 42% { transform: translateX(-60%); opacity: 0; } 52% { opacity: 1; } 68%, 100% { transform: translateX(70%); opacity: 0; } }
@keyframes cardShine { 0%, 68% { left: -75%; opacity: 0; } 76% { opacity: 1; } 92%, 100% { left: 135%; opacity: 0; } }
@keyframes livePulse { 0%, 100% { transform: scale(.9); opacity: .72; } 50% { transform: scale(1.18); opacity: 1; } }
@keyframes orbitSpin { to { transform: rotate(360deg); } }
@keyframes orbitFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@keyframes rowEnter { to { opacity: 1; transform: none; } }
@keyframes currencySwitch { 0% { transform: scale(.992); opacity: .82; } 100% { transform: none; opacity: 1; } }
@keyframes upFlash { 35% { color: #7af598; text-shadow: 0 0 22px rgba(122, 245, 152, .55); transform: translateY(-1px); } }
@keyframes downFlash { 35% { color: #ff777b; text-shadow: 0 0 22px rgba(255, 119, 123, .5); transform: translateY(1px); } }

@media (max-width: 1050px) {
    .hero-shell { grid-template-columns: 1fr; }
    .hero-copy { border-right: 0; border-bottom: 1px solid var(--line-soft); padding: 26px 28px; }
    .hero-copy h1 { max-width: 700px; }
    .dashboard-grid { grid-template-columns: 1.25fr .75fr; }
    .telegram-panel { grid-column: 1 / -1; min-height: 190px; }
    .rates-row { grid-template-columns: minmax(220px, 1.45fr) 1fr 1fr .7fr 22px; }
    .nav { gap: 16px; }
}

@media (max-width: 760px) {
    .topbar { height: 62px; padding: 0 14px; gap: 10px; }
    .brand { min-width: auto; }
    .brand img { width: 42px; height: 42px; }
    .brand span { display: none; }
    .telegram-mini { margin-left: auto; padding: 8px 10px; font-size: 10px; }
    .menu-toggle { display: block; }
    .nav {
        position: absolute;
        left: 12px;
        right: 12px;
        top: 67px;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 8px;
        border: 1px solid var(--line);
        border-radius: 12px;
        background: rgba(7, 7, 7, .98);
        box-shadow: var(--shadow);
        transform: translateY(-8px) scale(.98);
        opacity: 0;
        pointer-events: none;
        transition: transform .22s ease, opacity .22s ease;
    }
    .nav.open { transform: none; opacity: 1; pointer-events: auto; }
    .nav a { padding: 12px; font-size: 11px; }
    .nav a::after { bottom: 7px; }
    main { width: min(100% - 20px, 1240px); padding-top: 10px; }
    .hero-shell { padding: 8px; border-radius: 15px; }
    .hero-copy { padding: 23px 18px; }
    .hero-copy h1 { font-size: clamp(29px, 9vw, 38px); }
    .trust-row { grid-template-columns: repeat(3, 1fr); }
    .trust-row div { align-items: flex-start; font-size: 9px; }
    .rate-zone { padding: 17px; }
    .rate-topline { display: block; }
    .live-meta { margin-top: 14px; }
    .rate-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
    .rate-card { min-height: 124px; padding: 15px; }
    .rate-value > span { font-size: clamp(31px, 9vw, 45px); }
    .rates-board-head { display: block; padding: 17px; }
    .rates-tools { margin-top: 13px; }
    .search-box { width: 100%; }
    .dashboard-grid { grid-template-columns: 1fr; }
    .telegram-panel { grid-column: auto; min-height: 180px; }
    .about-strip { grid-template-columns: 1fr 1fr; }
    .about-strip > div:nth-child(2) { border-right: 0; }
    .about-strip > div:nth-child(-n + 2) { border-bottom: 1px solid var(--line-soft); }
    footer { grid-template-columns: 1fr; text-align: center; }
    .footer-brand { justify-content: center; }
    .footer-brand ~ p { text-align: center; }
    footer > a { justify-self: center; }
}

@media (max-width: 540px) {
    .hero-copy p { font-size: 12px; }
    .trust-row { grid-template-columns: 1fr; gap: 7px; margin-top: 18px; }
    .trust-row i { width: 24px; height: 24px; flex-basis: 24px; }
    .live-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
    .rate-topline h2 { font-size: 19px; }
    .rate-grid { grid-template-columns: 1fr; }
    .rate-card { min-height: 116px; }
    .rate-value > span { font-size: 43px; }
    .rates-tools { display: grid; grid-template-columns: 1fr 64px; }
    .rates-head { display: none; }
    .rates-row { grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; padding: 11px 13px; }
    .currency-name { grid-column: 1 / -1; padding-bottom: 8px; border-bottom: 1px solid rgba(211, 157, 45, .07); }
    .table-price { font-size: 15px; }
    .table-price::before, .per-usd::before { content: attr(data-label); display: block; margin-bottom: 3px; color: #6b675f; font-family: Inter, sans-serif; font-size: 7px; letter-spacing: .08em; text-transform: uppercase; }
    .per-usd { display: none; }
    .row-arrow { align-self: end; }
    .currency-rows { max-height: none; }
    .chart-wrap { height: 225px; }
    .about-strip { grid-template-columns: 1fr; }
    .about-strip > div { border-right: 0; border-bottom: 1px solid var(--line-soft); }
    .about-strip > div:last-child { border-bottom: 0; }
    .refresh-line { gap: 9px; align-items: flex-start; }
    .refresh-line span:last-child { white-space: nowrap; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .01ms !important; }
    .reveal { opacity: 1; transform: none; }
}

/* ISTAP_LUXURY_MOTION_V4_START */
body{position:relative;isolation:isolate}
.istap-cinematic-bg{position:fixed;inset:0;z-index:0;overflow:hidden;pointer-events:none;contain:strict}
.istap-cinematic-bg canvas{position:absolute;inset:0;width:100%;height:100%;opacity:.72}
.motion-aurora{position:absolute;width:min(78vw,980px);aspect-ratio:1;left:50%;top:-47%;translate:-50% 0;border-radius:50%;background:conic-gradient(from 0deg,transparent 0 13%,rgba(246,203,95,.15) 18%,transparent 28% 47%,rgba(153,98,11,.12) 55%,transparent 68% 100%);filter:blur(72px);opacity:.75;animation:istapAuroraSpin 25s linear infinite}
.motion-aurora.two{width:min(62vw,780px);left:91%;top:33%;opacity:.34;animation-duration:31s;animation-direction:reverse}
.motion-grid{position:absolute;inset:-80px;background-image:linear-gradient(rgba(221,171,62,.028) 1px,transparent 1px),linear-gradient(90deg,rgba(221,171,62,.028) 1px,transparent 1px);background-size:46px 46px;transform:perspective(700px) rotateX(62deg) translateY(36%);transform-origin:center bottom;mask-image:linear-gradient(to bottom,transparent 5%,#000 58%,transparent 100%);animation:istapGridDrift 16s linear infinite;opacity:.7}
.motion-rays{position:absolute;inset:-35%;background:repeating-conic-gradient(from 205deg at 50% 15%,transparent 0 8deg,rgba(242,200,91,.026) 9deg 10deg,transparent 11deg 20deg);filter:blur(1px);animation:istapRayBreath 9s ease-in-out infinite alternate;opacity:.72}
.motion-noise{position:absolute;inset:0;opacity:.035;background-image:url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");animation:istapNoiseShift .42s steps(2) infinite}
.cursor-halo{position:absolute;width:420px;height:420px;left:0;top:0;border-radius:50%;background:radial-gradient(circle,rgba(240,193,77,.12),rgba(193,126,14,.045) 34%,transparent 70%);filter:blur(18px);translate:-50% -50%;opacity:0;transition:opacity .35s ease;will-change:transform}
body.fx-pointer-active .cursor-halo{opacity:1}
.topbar,main,footer,.toast{z-index:2}
.ambient{z-index:1}

.topbar::after{content:"";position:absolute;left:0;right:0;bottom:-1px;height:1px;background:linear-gradient(90deg,transparent,rgba(245,205,104,.22),#e6b84c,rgba(245,205,104,.22),transparent);background-size:220% 100%;animation:istapLineTravel 6s linear infinite;pointer-events:none}
.brand img{animation:istapLogoFloat 5.8s ease-in-out infinite;will-change:transform,filter}
.brand strong{background:linear-gradient(105deg,#f9ebbd 0%,#bd7c18 32%,#fff0b0 52%,#b06f0c 73%,#f6d979 100%);background-size:220% auto;-webkit-background-clip:text;background-clip:text;color:transparent;animation:istapGoldText 7s linear infinite}
.hero-copy h1,.rates-board-head h2,.panel-head h3{position:relative;background-size:220% auto;animation:istapGoldText 9s linear infinite}
.hero-shell{box-shadow:0 22px 70px rgba(0,0,0,.5),0 0 0 1px rgba(236,190,80,.025) inset;animation:istapHeroBreath 7s ease-in-out infinite}
.hero-shell::after{content:"";position:absolute;inset:0;border-radius:inherit;padding:1px;background:linear-gradient(118deg,transparent 5%,rgba(249,217,129,.48) 26%,transparent 43%,rgba(167,103,9,.33) 71%,transparent 92%);background-size:260% 100%;animation:istapBorderFlow 8s linear infinite;pointer-events:none;opacity:.55;-webkit-mask:linear-gradient(#000 0 0) content-box,linear-gradient(#000 0 0);-webkit-mask-composite:xor;mask-composite:exclude}
.rate-card{transform-style:preserve-3d;transition:transform .42s cubic-bezier(.2,.8,.2,1),box-shadow .42s ease,border-color .42s ease}
.rate-card:hover{transform:translateY(-4px) scale(1.008);box-shadow:0 22px 58px rgba(0,0,0,.5),0 0 28px rgba(218,166,53,.09)}
.rate-card .shine{width:42%;height:180%;top:-40%;left:-65%;transform:rotate(18deg);background:linear-gradient(90deg,transparent,rgba(255,231,157,.19),transparent);filter:blur(2px);animation:istapCardSweep 7.5s ease-in-out infinite}
.sell-card .shine{animation-delay:-3.6s}
.rate-icon{animation:istapIconPulse 3.2s ease-in-out infinite}
.sell-card .rate-icon{animation-delay:-1.6s}
.market-state b,.live-badge i{box-shadow:0 0 0 0 rgba(89,216,121,.55);animation:istapLivePulse 2.1s ease-out infinite}

.fx-surface{position:relative;overflow:hidden;--fx-x:50%;--fx-y:50%}
.fx-pointer-glow{position:absolute;inset:0;z-index:0;pointer-events:none;opacity:0;background:radial-gradient(240px circle at var(--fx-x) var(--fx-y),rgba(246,207,107,.095),transparent 66%);transition:opacity .3s ease;mix-blend-mode:screen}
.fx-surface:hover>.fx-pointer-glow{opacity:1}
.fx-surface>*:not(.fx-pointer-glow){position:relative;z-index:1}
.panel,.rates-board,.about-strip>div,.telegram-panel{transition:border-color .35s ease,box-shadow .35s ease,transform .35s ease}
.panel:hover,.rates-board:hover,.about-strip>div:hover{border-color:rgba(220,168,54,.48);box-shadow:0 18px 50px rgba(0,0,0,.42),0 0 24px rgba(208,151,32,.055)}
.about-strip>div:hover{transform:translateY(-3px)}
.currency-row{isolation:isolate}
.currency-row::before{content:"";position:absolute;inset:0;z-index:-1;background:linear-gradient(100deg,transparent,rgba(226,174,62,.065),transparent);translate:-115% 0;transition:translate .65s cubic-bezier(.16,1,.3,1)}
.currency-row:hover::before,.currency-row.active::before{translate:115% 0}
.currency-name i{position:relative;overflow:hidden}
.currency-name i::after{content:"";position:absolute;inset:-30%;background:linear-gradient(120deg,transparent 35%,rgba(255,239,185,.32),transparent 65%);translate:-120% 0;animation:istapMiniShine 6.2s ease-in-out infinite}
.telegram-orbit{animation:istapOrbitFloat 5.5s ease-in-out infinite}
.telegram-orbit span{animation:istapOrbitSpin 7s linear infinite}
.telegram-panel a{position:relative;overflow:hidden}
.telegram-panel a::before{content:"";position:absolute;inset:0;background:linear-gradient(110deg,transparent 30%,rgba(255,255,255,.3),transparent 70%);translate:-130% 0;animation:istapButtonSweep 5s ease-in-out infinite}
.chart-wrap::after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(110deg,transparent 0 45%,rgba(229,177,63,.035) 50%,transparent 55% 100%);background-size:240% 100%;animation:istapChartSweep 8s linear infinite}
footer{position:relative;overflow:hidden}
footer::before{content:"";position:absolute;width:45%;height:1px;top:0;left:-45%;background:linear-gradient(90deg,transparent,#e3b748,transparent);animation:istapFooterLine 7s linear infinite}

@keyframes istapAuroraSpin{to{transform:rotate(360deg) scale(1.08)}}
@keyframes istapGridDrift{to{background-position:0 46px,46px 0}}
@keyframes istapRayBreath{from{transform:rotate(-2deg) scale(1);opacity:.42}to{transform:rotate(3deg) scale(1.05);opacity:.8}}
@keyframes istapNoiseShift{0%{transform:translate(0)}25%{transform:translate(1%,-1%)}50%{transform:translate(-1%,1%)}75%{transform:translate(.5%,1%)}100%{transform:translate(-.5%,-1%)}}
@keyframes istapLineTravel{to{background-position:-220% 0}}
@keyframes istapLogoFloat{0%,100%{transform:translateY(0) rotate(0);filter:drop-shadow(0 0 0 rgba(223,174,64,0))}50%{transform:translateY(-3px) rotate(-1.2deg);filter:drop-shadow(0 8px 12px rgba(223,174,64,.18))}}
@keyframes istapGoldText{to{background-position:-220% center}}
@keyframes istapHeroBreath{0%,100%{box-shadow:0 22px 70px rgba(0,0,0,.5),0 0 0 rgba(218,166,53,0)}50%{box-shadow:0 27px 82px rgba(0,0,0,.58),0 0 30px rgba(218,166,53,.045)}}
@keyframes istapBorderFlow{to{background-position:-260% 0}}
@keyframes istapCardSweep{0%,36%{left:-65%;opacity:0}48%{opacity:1}68%,100%{left:130%;opacity:0}}
@keyframes istapIconPulse{0%,100%{box-shadow:0 0 0 0 rgba(225,173,59,0)}50%{box-shadow:0 0 0 7px rgba(225,173,59,.055)}}
@keyframes istapLivePulse{0%{box-shadow:0 0 0 0 rgba(89,216,121,.48)}75%,100%{box-shadow:0 0 0 8px rgba(89,216,121,0)}}
@keyframes istapMiniShine{0%,65%{translate:-120% 0}82%,100%{translate:120% 0}}
@keyframes istapOrbitFloat{0%,100%{transform:translateY(0)}50%{transform:translateY(-7px)}}
@keyframes istapOrbitSpin{to{transform:rotate(360deg)}}
@keyframes istapButtonSweep{0%,52%{translate:-130% 0}72%,100%{translate:130% 0}}
@keyframes istapChartSweep{to{background-position:-240% 0}}
@keyframes istapFooterLine{to{left:105%}}

@media (max-width:900px){
  .motion-aurora{width:900px;top:-35%;opacity:.52}.motion-aurora.two{display:none}.motion-grid{opacity:.4;background-size:38px 38px}.cursor-halo{display:none}
  .hero-shell{animation-duration:9s}.rate-card:hover{transform:translateY(-2px)}
}
@media (max-width:620px){
  .motion-rays{opacity:.34}.motion-noise{opacity:.02}.istap-cinematic-bg canvas{opacity:.43}
  .hero-shell::after{opacity:.35}.topbar::after{animation-duration:8s}.rate-card .shine{animation-duration:9s}
  .panel:hover,.rates-board:hover,.about-strip>div:hover{transform:none;box-shadow:var(--shadow)}
}
@media (hover:none),(pointer:coarse){.cursor-halo,.fx-pointer-glow{display:none}.rate-card:hover{transform:none}}
@media (prefers-reduced-motion:reduce){
  .motion-aurora,.motion-grid,.motion-rays,.motion-noise,.topbar::after,.brand img,.brand strong,.hero-copy h1,.rates-board-head h2,.panel-head h3,.hero-shell,.hero-shell::after,.rate-card .shine,.rate-icon,.market-state b,.live-badge i,.currency-name i::after,.telegram-orbit,.telegram-orbit span,.telegram-panel a::before,.chart-wrap::after,footer::before{animation:none!important}
  .istap-cinematic-bg canvas{opacity:.22}.rate-card:hover,.about-strip>div:hover{transform:none}
}
/* ISTAP_LUXURY_MOTION_V4_END */
