@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@400;500;600;700&family=Nunito:wght@400;500;600;700;800&display=swap');

:root {
    --bg-deep: #0b0c10;
    --bg-main: #0f1118;
    --bg-card: #1a1d28;
    --bg-card-hover: #1f2330;
    --bg-input: #12141c;
    --border: #252838;
    --border-hover: #353950;
    --orange: #E8680C;
    --orange-bright: #FF7A1A;
    --orange-dim: rgba(232, 104, 12, 0.12);
    --orange-glow: rgba(232, 104, 12, 0.25);
    --amber: #F0A030;
    --text: #E4E7F0;
    --text-secondary: #959BB0;
    --text-muted: #5A5F75;
    --success: #2ECC71;
    --success-dim: rgba(46, 204, 113, 0.12);
    --error: #FF3D57;
    --error-dim: rgba(255, 61, 87, 0.12);
    --radius: 12px;
    --radius-lg: 20px;
    --radius-sm: 8px;
    --font-head: 'Rajdhani', sans-serif;
    --font-body: 'Nunito', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-body); background: var(--bg-main);
    color: var(--text); line-height: 1.65;
    -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

/* === DUCK BG === */
.duck-bg {
    position: fixed; top: 54%; left: 50%;
    transform: translate(-50%, -50%);
    width: 88vmin; height: 88vmin;
    opacity: 0.35; pointer-events: none; z-index: 0;
    border-radius: 50%; filter: saturate(0.4);
    background: url('/img/mascot.png') center/cover no-repeat;
}

/* === NAV === */
.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    background: rgba(15, 17, 24, 0.88);
    backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--border);
    height: 56px; display: flex; align-items: center; justify-content: center;
}
.nav-inner {
    max-width: 1100px; width: 100%; padding: 0 24px;
    display: flex; align-items: center; justify-content: space-between;
}
.nav-logo {
    text-decoration: none; color: var(--text);
    font-family: var(--font-head); font-weight: 700; font-size: 24px;
    flex-shrink: 0;
}
.nav-logo span { color: var(--orange); }

.nav-center { display: flex; gap: 4px; align-items: center; }
.nav-center a {
    color: var(--text-secondary); text-decoration: none;
    padding: 7px 16px; border-radius: var(--radius-sm);
    font-size: 14px; font-weight: 600; transition: 0.2s; white-space: nowrap;
}
.nav-center a:hover { color: var(--text); background: rgba(255,255,255,0.04); }

.nav-right { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }

.nav-btn {
    padding: 7px 18px; border-radius: 20px; border: none;
    font-family: var(--font-body); font-size: 13px; font-weight: 700;
    cursor: pointer; transition: 0.2s; text-decoration: none; display: inline-block;
}
.nav-btn-ghost { background: none; color: var(--text-secondary); border: 1px solid var(--border); }
.nav-btn-ghost:hover { border-color: var(--orange); color: var(--orange); }
.nav-btn-primary { background: var(--orange); color: #fff; }
.nav-btn-primary:hover { background: var(--orange-bright); }

/* === BUTTONS === */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px 32px; border-radius: 50px; border: none;
    font-family: var(--font-body); font-size: 15px; font-weight: 700;
    cursor: pointer; transition: 0.2s; text-decoration: none;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary {
    background: linear-gradient(135deg, var(--orange), var(--orange-bright));
    color: #fff; box-shadow: 0 6px 28px rgba(232,104,12,0.3);
}
.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px); box-shadow: 0 8px 36px rgba(232,104,12,0.4);
}
.btn-ghost { background: none; color: var(--orange); border: 1px solid var(--orange); }
.btn-ghost:hover:not(:disabled) { background: var(--orange-dim); }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 20px; font-size: 13px; }

/* === INPUTS === */
.input-group { margin-bottom: 20px; }
.input-group label {
    display: block; font-size: 13px; font-weight: 600;
    color: var(--text-secondary); margin-bottom: 6px;
    text-transform: uppercase; letter-spacing: 0.5px;
}
.input {
    width: 100%; padding: 14px 16px;
    background: var(--bg-input); border: 1px solid var(--border);
    border-radius: var(--radius); color: var(--text);
    font-family: var(--font-body); font-size: 15px;
    transition: 0.2s; outline: none;
}
.input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-dim); }
.input::placeholder { color: var(--text-muted); }
textarea.input { min-height: 120px; resize: vertical; }

/* === CODE INPUT === */
.code-inputs { display: flex; gap: 10px; justify-content: center; margin: 24px 0; }
.code-inputs input {
    width: 52px; height: 64px; text-align: center;
    font-size: 28px; font-weight: 700; font-family: var(--font-head);
    background: var(--bg-input); border: 2px solid var(--border);
    border-radius: var(--radius); color: var(--orange);
    outline: none; transition: 0.2s;
}
.code-inputs input:focus { border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-dim); }

/* === CARDS === */
.card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 28px; transition: 0.2s;
}
.card:hover { border-color: var(--border-hover); }
.card-title {
    font-family: var(--font-head); font-size: 22px; font-weight: 600; margin-bottom: 16px;
}

/* === BADGES === */
.badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 4px 12px; border-radius: 20px;
    font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px;
}
.badge-active { background: var(--success-dim); color: var(--success); }
.badge-trial { background: var(--orange-dim); color: var(--orange); }
.badge-expired { background: var(--error-dim); color: var(--error); }

/* === LAYOUT === */
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }
.section { padding: 80px 0; position: relative; z-index: 1; }
.section-head { text-align: center; margin-bottom: 48px; }
.section-head h2 {
    font-family: var(--font-head); font-size: clamp(28px, 4vw, 40px);
    font-weight: 700; margin-bottom: 8px;
}
.section-head p { color: var(--text-secondary); font-size: 15px; margin: 0 auto; }
.text-center { text-align: center; }
.mt-2 { margin-top: 16px; }
.mt-4 { margin-top: 32px; }
.hidden { display: none !important; }

/* === AUTH === */
.auth-wrapper {
    min-height: 100vh; display: flex; align-items: center; justify-content: center;
    padding: 24px; padding-top: 80px;
}
.auth-card {
    width: 100%; max-width: 440px;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 40px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.6);
}
.auth-card h1 {
    font-family: var(--font-head); font-size: 32px; font-weight: 700;
    margin-bottom: 8px; text-align: center;
}
.auth-card .subtitle {
    color: var(--text-secondary); text-align: center; margin-bottom: 32px; font-size: 15px;
}
.auth-card .alt-action {
    text-align: center; margin-top: 24px; font-size: 14px; color: var(--text-secondary);
}
.auth-card .alt-action a { color: var(--orange); text-decoration: none; font-weight: 600; }
.auth-card .alt-action a:hover { text-decoration: underline; }
.auth-card .divider { border: none; border-top: 1px solid var(--border); margin: 24px 0; }

/* === HERO === */
.hero {
    padding: 120px 0 80px; text-align: center; position: relative; z-index: 1;
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(ellipse at 50% 20%, rgba(232,104,12,0.06) 0%, transparent 60%);
    pointer-events: none;
}
.hero-mascot {
    width: 200px; height: 200px; border-radius: 50%; object-fit: cover;
    margin: 0 auto 28px; display: block;
    border: 3px solid rgba(232,104,12,0.5);
    box-shadow: 0 0 80px rgba(232,104,12,0.15);
    animation: heroFloat 6s ease-in-out infinite;
}
@keyframes heroFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
.hero-title {
    font-family: var(--font-head); font-size: 26px; font-weight: 700;
    margin-bottom: 16px;
}
.hero-title span { color: var(--orange); }
.hero-tagline {
    font-size: 17px; color: #e5e7eb;
    max-width: 540px; margin: 0 auto 28px; line-height: 1.65;
}
.hero-tagline .accent {
    color: var(--orange);
    font-weight: 600;
}
.hero-features { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; margin-bottom: 12px; }
.hero-feat { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.hero-feat .star { color: var(--amber); font-size: 12px; }
.hero-price { color: var(--text-muted); font-size: 14px; margin-bottom: 32px; }
.hero-price strong { color: var(--amber); font-weight: 700; }

/* === ABOUT === */
.about-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px;
}
.about-card {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 28px; transition: 0.25s;
}
.about-card:hover { border-color: var(--border-hover); transform: translateY(-3px); }
.about-card .icon {
    width: 44px; height: 44px; border-radius: 12px;
    background: var(--orange-dim); display: flex; align-items: center; justify-content: center;
    font-size: 20px; margin-bottom: 16px;
}
.about-card h3 { font-family: var(--font-head); font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.about-card p { color: var(--text-secondary); font-size: 14px; line-height: 1.6; }

/* === PRICING === */
.pricing-section { background: var(--bg-deep); }
.selector-group { max-width: 700px; margin: 0 auto 40px; display: flex; flex-direction: column; gap: 24px; }
.selector-row { display: flex; flex-direction: column; gap: 10px; }
.selector-label { font-size: 14px; color: var(--text-secondary); font-weight: 600; }
.selector-btns { display: flex; gap: 8px; }
.sel-btn {
    flex: 1; padding: 12px 8px; border: 1px solid var(--border);
    background: var(--bg-card); color: var(--text-secondary); border-radius: var(--radius-sm);
    cursor: pointer; font-family: var(--font-body); font-size: 14px; font-weight: 600;
    text-align: center; transition: 0.2s; white-space: nowrap;
}
.sel-btn:hover { border-color: var(--border-hover); color: var(--text); }
.sel-btn.active { border-color: var(--orange); background: var(--orange-dim); color: var(--orange); }

.price-display {
    max-width: 700px; margin: 0 auto;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 32px;
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 16px;
}
.price-plan { font-family: var(--font-head); font-size: 18px; font-weight: 600; }
.price-details { color: var(--text-muted); font-size: 13px; }
.price-rub { font-family: var(--font-head); font-size: 40px; font-weight: 700; color: var(--orange); }
.price-usd { color: var(--text-muted); font-size: 14px; }

/* === HOWTO === */
.steps-list { max-width: 640px; margin: 0 auto; display: flex; flex-direction: column; gap: 20px; }
.step-item {
    display: flex; gap: 18px; align-items: flex-start;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 24px; transition: 0.2s;
}
.step-item:hover { border-color: var(--orange); }
.step-num {
    width: 42px; height: 42px; flex-shrink: 0;
    background: var(--orange); color: #fff; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-head); font-size: 20px; font-weight: 700;
}
.step-item h3 { font-family: var(--font-head); font-size: 18px; margin-bottom: 6px; }
.step-item p { color: var(--text-secondary); font-size: 14px; }
.step-item a { color: var(--orange); text-decoration: none; font-weight: 700; }
.step-item a:hover { text-decoration: underline; }

/* === SUPPORT === */
.support-cta {
    text-align: center; padding: 48px 0;
    border-top: 1px solid var(--border); position: relative; z-index: 1;
}
.support-cta p { color: var(--text-secondary); font-size: 15px; margin-bottom: 16px; }
.support-cta a { color: var(--orange); text-decoration: none; font-weight: 700; font-size: 15px; }
.support-cta a:hover { text-decoration: underline; }

/* === FOOTER === */
.footer {
    border-top: 1px solid var(--border); padding: 32px 0;
    text-align: center; color: var(--text-muted); font-size: 13px;
    position: relative; z-index: 1;
}
.footer a { color: var(--text-muted); text-decoration: none; }
.footer a:hover { color: var(--text-secondary); }

/* === DASHBOARD === */
.dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.dash-grid .full-width { grid-column: 1 / -1; }
.sub-status { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.sub-dot {
    width: 12px; height: 12px; border-radius: 50%;
    background: var(--success); box-shadow: 0 0 12px var(--success);
}
.sub-dot.off { background: var(--text-muted); box-shadow: none; }
.sub-link-box {
    background: var(--bg-input); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 14px 16px;
    display: flex; align-items: center; gap: 12px;
    word-break: break-all; font-size: 13px; color: var(--text-secondary); font-family: monospace;
}
.copy-btn {
    flex-shrink: 0; background: var(--orange); color: #fff;
    border: none; padding: 8px 16px; border-radius: var(--radius-sm);
    cursor: pointer; font-size: 13px; font-weight: 600; transition: 0.2s;
}
.copy-btn:hover { background: var(--orange-bright); }
.stat-label { color: var(--text-muted); font-size: 13px; text-transform: uppercase; }
.tg-code {
    font-family: var(--font-head); font-size: 40px; font-weight: 700;
    letter-spacing: 6px; color: var(--amber); text-align: center;
    padding: 20px; background: var(--bg-input); border: 2px solid var(--amber);
    border-radius: var(--radius); margin: 20px 0;
}

/* === TOAST === */
.toast {
    position: fixed; top: 72px; right: 24px; z-index: 200;
    padding: 14px 24px; border-radius: var(--radius);
    font-size: 14px; font-weight: 500;
    box-shadow: 0 8px 40px rgba(0,0,0,0.6);
    transform: translateX(120%); transition: transform 0.3s; max-width: 380px;
}
.toast.show { transform: translateX(0); }
.toast-success { background: #0a2a10; border: 1px solid var(--success); color: var(--success); }
.toast-error { background: #2a0a0f; border: 1px solid var(--error); color: var(--error); }
.toast-info { background: #0a1a2a; border: 1px solid #3A7BD5; color: #3A7BD5; }

/* === SPINNER === */
.spinner {
    width: 24px; height: 24px; border: 3px solid var(--border);
    border-top-color: var(--orange); border-radius: 50%;
    animation: spin 0.6s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .nav-center { display: none; }
    .hero { padding: 100px 0 60px; }
    .hero-mascot { width: 150px; height: 150px; }
    .hero-features { flex-direction: column; align-items: center; gap: 10px; }
    .price-display { flex-direction: column; text-align: center; align-items: center; }
    .about-grid { grid-template-columns: 1fr; }
    .selector-btns { flex-wrap: wrap; }
    .sel-btn { min-width: calc(50% - 4px); flex: unset; }
    .dash-grid { grid-template-columns: 1fr; }
    .duck-bg { width: 100vmin; height: 100vmin; opacity: 0.325; }
}
@media (max-width: 480px) {
    .hero-title { font-size: 21px; }
    .price-rub { font-size: 32px; }
    .nav-right .nav-btn { padding: 6px 12px; font-size: 12px; }
    .auth-card { padding: 28px 20px; }
}

/* === AUTH INPUTS FIX === */
.auth-card .input {
    background: #1e2130;
    border: 1.5px solid #353950;
}
.auth-card {
    background: rgba(26, 29, 40, 0.97);
    backdrop-filter: blur(20px);
}
