/* ═══ Design System — v2 ═══ */
:root {
    --bg-base: #050508;
    --bg-surface: #08080f;
    --bg-card: #0c0c14;
    --bg-card-alt: #101018;
    --bg-elevated: #14141e;
    --bg-glass: rgba(12, 12, 20, 0.75);
    --border-dim: rgba(255, 255, 255, 0.03);
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-medium: rgba(255, 255, 255, 0.10);
    --text-bright: #f0f0f5;
    --text-primary: #d0d0dd;
    --text-secondary: #8888a0;
    --text-muted: #555568;
    --text-dim: #333344;
    --bitcoin: #f7931a;
    --bitcoin-light: #fbbf24;
    --emerald: #00e5a0;
    --emerald-dim: rgba(0, 229, 160, 0.12);
    --rose: #ff4d6a;
    --rose-dim: rgba(255, 77, 106, 0.12);
    --cyan: #00d4ff;
    --violet: #a78bfa;
    --blue: #4d8eff;
    --radius-sm: 10px;
    --radius-md: 14px;
    --radius-lg: 18px;
    --radius-xl: 24px;
}

/* ═══ Reset & Base ═══ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--bg-base);
    background-image:
        radial-gradient(ellipse at 20% -5%, rgba(247, 147, 26, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 105%, rgba(0, 212, 255, 0.04) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(167, 139, 250, 0.02) 0%, transparent 65%);
    background-attachment: fixed;
    font-family: 'Inter', -apple-system, sans-serif;
    color: var(--text-primary);
    min-height: 100vh;
    padding: 0.5rem 2rem 0;
    max-width: 1500px;
    margin: 0 auto;
}

/* ═══ Header ═══ */
.app-header {
    text-align: center;
    padding: 1.75rem 0 0.5rem;
    position: relative;
}

.app-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 300px;
    height: 250px;
    background: radial-gradient(circle, rgba(247, 147, 26, 0.07) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.app-logo {
    font-size: 1.9rem;
    font-weight: 900;
    letter-spacing: -1.5px;
    line-height: 1;
    position: relative;
    z-index: 1;
}

.app-logo .btc-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    background: linear-gradient(145deg, #f7931a 0%, #e88a10 100%);
    border-radius: 13px;
    color: #fff;
    font-size: 1.2rem;
    font-weight: 900;
    margin-right: 0.5rem;
    vertical-align: middle;
    box-shadow: 0 4px 20px rgba(247, 147, 26, 0.3), inset 0 1px 0 rgba(255,255,255,0.2);
    position: relative;
}

.app-logo .btc-icon::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 16px;
    border: 1.5px solid rgba(247, 147, 26, 0.2);
}

.app-logo .text-white { color: var(--text-bright); }
.app-logo .text-gold {
    background: linear-gradient(135deg, #f7931a 0%, #fbbf24 50%, #f7931a 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.app-subtitle {
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-top: 0.3rem;
    position: relative;
    z-index: 1;
}

/* ═══ Zone Badge ═══ */
.zone-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    margin: 0.75rem auto 0.6rem;
    padding: 0.55rem 1.4rem;
    border-radius: 100px;
    width: fit-content;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.zone-green {
    background: rgba(0, 229, 160, 0.08);
    border: 1px solid rgba(0, 229, 160, 0.15);
    color: var(--emerald);
}
.zone-yellow {
    background: rgba(251, 191, 36, 0.08);
    border: 1px solid rgba(251, 191, 36, 0.15);
    color: var(--bitcoin-light);
}
.zone-orange {
    background: rgba(247, 147, 26, 0.08);
    border: 1px solid rgba(247, 147, 26, 0.15);
    color: var(--bitcoin);
}
.zone-red {
    background: rgba(255, 77, 106, 0.08);
    border: 1px solid rgba(255, 77, 106, 0.15);
    color: var(--rose);
}

/* ═══ Tabs ═══ */
.tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border-dim);
    margin-bottom: 0;
}

.tab {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    position: relative;
}
.tab-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.6;
    transition: opacity 0.25s ease;
}
.tab.active .tab-icon { opacity: 1; }
.tab:hover .tab-icon { opacity: 0.85; }

.tab:hover { color: var(--text-secondary); }
.tab.active {
    color: var(--bitcoin);
    border-bottom-color: var(--bitcoin);
}

.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ═══ Metric Cards ═══ */
.metric-row {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.6rem;
    margin: 0.25rem 0 0.6rem;
}

.m-card {
    background: var(--bg-card);
    border: 1px solid var(--border-dim);
    border-radius: var(--radius-md);
    padding: 1rem 0.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.m-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    opacity: 0;
    transition: opacity 0.35s ease;
}

.m-card:hover {
    border-color: var(--border-medium);
    background: var(--bg-card-alt);
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
}

.m-card:hover::before { opacity: 1; }

.m-card-orange::before { background: linear-gradient(90deg, transparent, var(--bitcoin), transparent); }
.m-card-white::before { background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); }
.m-card-green::before { background: linear-gradient(90deg, transparent, var(--emerald), transparent); }
.m-card-red::before { background: linear-gradient(90deg, transparent, var(--rose), transparent); }
.m-card-cyan::before { background: linear-gradient(90deg, transparent, var(--cyan), transparent); }

.m-label {
    color: var(--text-muted);
    font-size: 0.55rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    margin-bottom: 0.5rem;
}

.m-val {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.m-val-orange { color: var(--bitcoin); }
.m-val-white { color: var(--text-bright); }
.m-val-green { color: var(--emerald); }
.m-val-red { color: var(--rose); }
.m-val-cyan { color: var(--cyan); }

/* ═══ Chart ═══ */
.chart-container {
    background: #06060c;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-dim);
    padding: 0.5rem;
    margin-top: 0.25rem;
    position: relative;
    height: 700px;
}

.chart-container canvas {
    width: 100% !important;
    height: 100% !important;
}

/* ── HTML Legend overlay ── */
.chart-legend {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(5, 5, 8, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 8px 12px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    z-index: 10;
    pointer-events: none;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: #8888a0;
    white-space: nowrap;
    letter-spacing: 0.02em;
}

.legend-rect {
    display: inline-block;
    width: 22px;
    height: 11px;
    border-radius: 3px;
    flex-shrink: 0;
}

.legend-line-sw {
    display: inline-block;
    width: 22px;
    height: 2.5px;
    border-radius: 2px;
    flex-shrink: 0;
    margin: auto 0;
}

.legend-sep {
    width: 100%;
    height: 1px;
    background: rgba(255, 255, 255, 0.05);
    margin: 1px 0;
}

@media (max-width: 768px) {
    .chart-legend { padding: 5px 8px; gap: 3px; }
    .legend-item { font-size: 10px; gap: 6px; }
    .legend-rect { width: 18px; height: 9px; }
    .legend-line-sw { width: 18px; }
}

/* ═══ Calculator ═══ */
.calculator-card {
    max-width: 560px;
    margin: 0 auto;
}

.calc-header {
    text-align: center;
    padding: 2rem 0 1.5rem;
}

.calc-header h2 {
    color: var(--text-bright);
    font-size: 1.4rem;
    font-weight: 800;
    margin: 0 0 0.25rem;
    letter-spacing: -0.5px;
}

.calc-header h2 .hl {
    background: linear-gradient(135deg, var(--bitcoin), var(--bitcoin-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.calc-header p {
    color: var(--text-muted);
    font-size: 0.75rem;
    margin: 0;
}

/* ─── Calculator Input ─── */
.calc-input-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 240px;
    margin: 0 auto;
    position: relative;
}

.calc-input-prefix {
    position: absolute;
    left: 0.7rem;
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.4rem;
    font-weight: 700;
    pointer-events: none;
}

.calc-input-wrap input {
    background: var(--bg-elevated);
    border: 1.5px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    color: var(--text-bright);
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.4rem;
    font-weight: 700;
    padding: 0.75rem 0.7rem 0.75rem 2rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    outline: none;
}

.calc-input-wrap input:hover { border-color: rgba(247, 147, 26, 0.3); }
.calc-input-wrap input:focus {
    border-color: var(--bitcoin);
    box-shadow: 0 0 0 4px rgba(247, 147, 26, 0.1), 0 0 30px rgba(247, 147, 26, 0.05);
}

.calc-input-wrap input::-webkit-outer-spin-button,
.calc-input-wrap input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.calc-input-wrap input[type=number] {
    -moz-appearance: textfield;
}

/* ─── Calculator Error ─── */
.calc-error {
    text-align: center;
    color: var(--rose);
    font-size: 0.72rem;
    font-weight: 500;
    margin-top: 0.5rem;
    opacity: 0.9;
}

/* ─── Result Card ─── */
.result-card {
    text-align: center;
    padding: 2rem 1.5rem;
    margin: 1.25rem auto 0;
    background: linear-gradient(160deg, rgba(247, 147, 26, 0.04) 0%, rgba(251, 191, 36, 0.02) 50%, rgba(247, 147, 26, 0.04) 100%);
    border: 1px solid rgba(247, 147, 26, 0.10);
    border-radius: var(--radius-lg);
    position: relative;
    overflow: hidden;
}

.result-card::before {
    content: '';
    position: absolute;
    top: 0; left: 20%; right: 20%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--bitcoin), transparent);
    opacity: 0.6;
}

.result-card::after {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle at 50% 100%, rgba(247, 147, 26, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

.result-badge {
    position: relative;
    z-index: 1;
    display: inline-block;
    background: rgba(247, 147, 26, 0.1);
    border: 1px solid rgba(247, 147, 26, 0.15);
    border-radius: 100px;
    padding: 0.3rem 1rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--bitcoin);
    letter-spacing: 1.5px;
    margin-bottom: 1rem;
}

.result-date {
    position: relative;
    z-index: 1;
    font-size: 2.2rem;
    font-weight: 900;
    letter-spacing: -1.5px;
    line-height: 1.1;
    margin-bottom: 0.4rem;
    background: linear-gradient(135deg, #f7931a 0%, #fbbf24 40%, #f7931a 80%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.result-sub {
    position: relative;
    z-index: 1;
    color: var(--text-secondary);
    font-size: 0.8rem;
}

/* ─── Floor Card ─── */
.floor-card {
    text-align: center;
    padding: 1.25rem 1rem;
    margin: 0.6rem auto 0;
    background: linear-gradient(160deg, rgba(0, 229, 160, 0.03) 0%, rgba(0, 180, 130, 0.02) 100%);
    border: 1px solid rgba(0, 229, 160, 0.08);
    border-radius: var(--radius-md);
    position: relative;
    overflow: hidden;
}

.floor-card::before {
    content: '';
    position: absolute;
    top: 0; left: 25%; right: 25%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--emerald), transparent);
    opacity: 0.4;
}

.floor-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: var(--emerald-dim);
    border: 1px solid rgba(0, 229, 160, 0.12);
    border-radius: 100px;
    padding: 0.25rem 0.8rem;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.55rem;
    font-weight: 700;
    color: var(--emerald);
    letter-spacing: 1.5px;
    margin-bottom: 0.6rem;
}

.floor-date {
    color: var(--emerald);
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 0.25rem;
}

.floor-sub {
    color: var(--text-muted);
    font-size: 0.68rem;
    line-height: 1.5;
}

/* ─── Stats Row ─── */
.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin: 0.6rem auto 0;
}

.stat-box {
    text-align: center;
    padding: 0.85rem 0.4rem;
    background: var(--bg-card);
    border: 1px solid var(--border-dim);
    border-radius: var(--radius-sm);
    transition: all 0.25s ease;
}

.stat-box:hover {
    border-color: var(--border-medium);
    transform: translateY(-1px);
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.stat-val {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.05rem;
    font-weight: 800;
}

/* ═══ Footer ═══ */
.app-footer {
    text-align: center;
    color: var(--text-dim);
    font-size: 0.62rem;
    margin-top: 2.5rem;
    padding-bottom: 1.5rem;
    letter-spacing: 0.5px;
}

/* ═══ Preset Buttons ═══ */
.preset-row {
    display: flex;
    gap: 0.4rem;
    justify-content: center;
    margin-top: 0.6rem;
}
.preset-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 100px;
    color: var(--text-secondary);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.35rem 0.9rem;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.5px;
}
.preset-btn:hover {
    border-color: rgba(247, 147, 26, 0.3);
    color: var(--bitcoin);
    background: rgba(247, 147, 26, 0.06);
    transform: translateY(-1px);
}
.preset-btn.active {
    border-color: rgba(247, 147, 26, 0.4);
    color: var(--bitcoin);
    background: rgba(247, 147, 26, 0.1);
}

/* ═══ Updated Badge ═══ */
.updated-badge {
    text-align: center;
    font-size: 0.6rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
    letter-spacing: 0.5px;
}
.updated-dot {
    display: inline-block;
    width: 6px; height: 6px;
    background: var(--emerald);
    border-radius: 50%;
    margin-right: 0.3rem;
    vertical-align: middle;
    animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* ═══ Skeleton Loading ═══ */
.skeleton {
    background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-alt) 50%, var(--bg-card) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
    border-radius: var(--radius-sm);
}
@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
.skeleton-val {
    height: 1.2rem;
    width: 70%;
    margin: 0 auto;
    border-radius: 4px;
}

/* ═══ Pull to Refresh ═══ */
.ptr-wrap {
    height: 0;
    overflow: hidden;
    transition: height 0.2s ease;
    position: relative;
    z-index: 50;
}
.ptr-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 50px;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.ptr-arrow {
    color: var(--bitcoin);
    transition: transform 0.1s linear;
}
.ptr-text {
    color: var(--text-muted);
    font-size: 0.7rem;
    font-weight: 600;
}
.ptr-indicator.ready .ptr-arrow { color: var(--emerald); }
.ptr-indicator.ready .ptr-text { color: var(--emerald); }
.ptr-indicator.refreshing .ptr-arrow {
    animation: ptrSpin 0.8s linear infinite;
    color: var(--bitcoin);
}
.ptr-indicator.refreshing .ptr-text { color: var(--bitcoin); }
@keyframes ptrSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ═══ Gain Total Return ═══ */
.gain-total {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-top: 0.2rem;
}

/* ═══ Gain Calculator ═══ */
.gain-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    margin-top: 1rem;
}
.gain-card {
    background: var(--bg-card);
    border: 1px solid var(--border-dim);
    border-radius: var(--radius-md);
    padding: 0.9rem 0.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.gain-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.gain-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(0,0,0,0.4);
    border-color: var(--border-medium);
}
.gain-card:hover::before { opacity: 1; }
.gain-year {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}
.gain-price {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
}
.gain-mult {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.1rem;
    font-weight: 800;
}
.gain-card.gain-green::before { background: linear-gradient(90deg, transparent, var(--emerald), transparent); }
.gain-card.gain-green .gain-mult { color: var(--emerald); }
.gain-card.gain-gold::before { background: linear-gradient(90deg, transparent, var(--bitcoin), transparent); }
.gain-card.gain-gold .gain-mult { color: var(--bitcoin); }
.gain-card.gain-cyan::before { background: linear-gradient(90deg, transparent, var(--cyan), transparent); }
.gain-card.gain-cyan .gain-mult { color: var(--cyan); }

/* ═══ Responsive — Tablet ═══ */
@media (max-width: 768px) {
    body { padding: 0.3rem 0.6rem 0; }

    .app-header { padding: 1.25rem 0 0.3rem; }
    .app-logo { font-size: 1.5rem; }
    .app-logo .btc-icon { width: 34px; height: 34px; font-size: 1rem; border-radius: 10px; }
    .app-logo .btc-icon::after { border-radius: 13px; }
    .app-subtitle { font-size: 0.58rem; letter-spacing: 2.5px; }

    .zone-strip {
        font-size: 0.65rem;
        padding: 0.45rem 1rem;
        position: sticky;
        top: 0;
        z-index: 50;
        margin-left: -0.6rem;
        margin-right: -0.6rem;
        border-radius: 0;
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
    }

    .metric-row { grid-template-columns: repeat(3, 1fr); gap: 0.4rem; }
    .m-card { padding: 0.75rem 0.4rem; }
    .m-label { font-size: 0.48rem; margin-bottom: 0.35rem; }
    .m-val { font-size: 0.95rem; }

    .tab { font-size: 0.78rem; padding: 0.6rem 0.9rem; }

    .chart-container { height: 450px; }

    .calc-header { padding: 1.25rem 0 1rem; }
    .calc-header h2 { font-size: 1.2rem; }
    .calc-input-wrap { max-width: 200px; }
    .calc-input-wrap input { font-size: 1.2rem; padding: 0.6rem 0.6rem 0.6rem 1.8rem; }
    .calc-input-prefix { font-size: 1.2rem; }

    .result-card { padding: 1.5rem 0.8rem; }
    .result-date { font-size: 1.5rem; }
    .result-sub { font-size: 0.72rem; }

    .floor-card { padding: 1rem 0.7rem; }
    .floor-date { font-size: 1.1rem; }
    .floor-sub { font-size: 0.6rem; }

    .stats-row { gap: 0.35rem; }
    .stat-box { padding: 0.65rem 0.25rem; }
    .stat-val { font-size: 0.88rem; }
    .stat-label { font-size: 0.42rem; }

    .gain-grid { grid-template-columns: repeat(2, 1fr); gap: 0.4rem; }
    .gain-card { padding: 0.7rem 0.4rem; }
    .gain-year { font-size: 0.58rem; }
    .gain-price { font-size: 0.7rem; }
    .gain-mult { font-size: 0.95rem; }

    .preset-btn { font-size: 0.6rem; padding: 0.28rem 0.65rem; }
}

/* ═══ Responsive — Mobile ═══ */
@media (max-width: 480px) {
    body { padding: 0.2rem 0.35rem 0; }

    .app-header { padding: 1rem 0 0.2rem; }
    .app-logo { font-size: 1.25rem; }
    .app-logo .btc-icon { width: 28px; height: 28px; font-size: 0.85rem; border-radius: 8px; }
    .app-logo .btc-icon::after { border-radius: 11px; }
    .app-subtitle { font-size: 0.5rem; }

    .metric-row { grid-template-columns: repeat(3, 1fr); gap: 0.3rem; }
    .m-card { padding: 0.55rem 0.25rem; border-radius: var(--radius-sm); }
    .m-label { font-size: 0.4rem; }
    .m-val { font-size: 0.78rem; }

    .tab { font-size: 0.72rem; padding: 0.5rem 0.5rem; }

    .chart-container { height: 350px; }

    .calc-header h2 { font-size: 1rem; }
    .calc-input-wrap { max-width: 180px; }
    .calc-input-wrap input { font-size: 1.05rem; padding: 0.5rem 0.5rem 0.5rem 1.6rem; }
    .calc-input-prefix { font-size: 1.05rem; }

    .result-date { font-size: 1.3rem; }
    .result-card { padding: 1.2rem 0.6rem; }

    .floor-date { font-size: 0.95rem; }
    .stat-val { font-size: 0.75rem; }
    .stat-label { font-size: 0.38rem; }

    .gain-grid { grid-template-columns: repeat(2, 1fr); gap: 0.3rem; }
    .gain-card { padding: 0.6rem 0.3rem; }
    .gain-year { font-size: 0.52rem; }
    .gain-price { font-size: 0.65rem; }
    .gain-mult { font-size: 0.85rem; }
}
