* {
    box-sizing: border-box;
}

:root {
    --bg: #071019;
    --bg-deep: #04070b;
    --panel: rgba(13, 19, 29, 0.9);
    --panel-strong: rgba(10, 15, 23, 0.98);
    --border: rgba(153, 179, 219, 0.16);
    --border-strong: rgba(153, 179, 219, 0.28);
    --text: #f5f8fc;
    --muted: #a1adbe;
    --muted-2: #788399;
    --teal: #53d7c8;
    --teal-soft: rgba(83, 215, 200, 0.16);
    --gold: #f2c46d;
    --gold-soft: rgba(242, 196, 109, 0.16);
    --red: #ff6f81;
    --red-soft: rgba(255, 111, 129, 0.16);
    --green: #5fe08a;
    --green-soft: rgba(95, 224, 138, 0.16);
    --blue: #7aa8ff;
    --blue-soft: rgba(122, 168, 255, 0.16);
    --shadow: 0 26px 90px rgba(0, 0, 0, 0.46);
    --shadow-soft: 0 14px 32px rgba(0, 0, 0, 0.22);
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    color: var(--text);
    font-family: "Space Grotesk", system-ui, sans-serif;
    background:
        radial-gradient(circle at 15% 0%, rgba(83, 215, 200, 0.16), transparent 30%),
        radial-gradient(circle at 85% 10%, rgba(242, 196, 109, 0.14), transparent 26%),
        radial-gradient(circle at 55% 100%, rgba(122, 168, 255, 0.08), transparent 28%),
        linear-gradient(180deg, #09111a 0%, #04070b 100%);
    overflow-x: hidden;
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
}

body::before {
    opacity: 0.055;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.58) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.58) 1px, transparent 1px);
    background-size: 42px 42px;
    mix-blend-mode: screen;
}

body::after {
    background:
        radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.05), transparent 34%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 20%, rgba(0, 0, 0, 0.18));
}

button,
input,
textarea {
    font: inherit;
}

a {
    color: inherit;
}

.shell {
    width: min(1360px, calc(100% - 24px));
    margin: 0 auto;
    padding: 22px 0 42px;
    position: relative;
    z-index: 1;
}

.topbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 16px;
}

.topbar-copy {
    max-width: 68ch;
}

.topbar h1 {
    margin: 6px 0 0;
    font-size: clamp(2.15rem, 4vw, 3.8rem);
    line-height: 0.95;
    letter-spacing: -0.055em;
}

.topbar-note {
    margin: 0.85rem 0 0;
    max-width: 60ch;
    color: var(--muted);
    line-height: 1.62;
}

.topbar-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.topbar-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
    color: var(--muted);
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.86rem;
}

.eyebrow,
.section-kicker,
.mini-label {
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.72rem;
    color: var(--muted);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.82rem 1.15rem;
    cursor: pointer;
    transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.78rem;
}

.button:hover {
    transform: translateY(-1px);
}

.button-primary {
    background: linear-gradient(135deg, rgba(83, 215, 200, 0.22), rgba(122, 168, 255, 0.22));
    color: var(--text);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-soft);
}

.button-primary:hover {
    box-shadow: var(--shadow);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border-radius: 999px;
    padding: 0.45rem 0.75rem;
    font-size: 0.78rem;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-family: "IBM Plex Mono", monospace;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.badge-soft {
    color: var(--muted);
}

.badge-bullish {
    background: var(--green-soft);
    border-color: rgba(95, 224, 138, 0.22);
    color: #d3f9df;
}

.badge-bearish {
    background: var(--red-soft);
    border-color: rgba(255, 111, 129, 0.22);
    color: #ffd5db;
}

.badge-wait {
    background: var(--gold-soft);
    border-color: rgba(242, 196, 109, 0.22);
    color: #ffe7b4;
}

.badge-neutral {
    background: var(--blue-soft);
    border-color: rgba(122, 168, 255, 0.22);
    color: #d4e3ff;
}

.tone-bullish {
    --accent: var(--green);
    --tone-color: var(--green);
    --tone-bar: linear-gradient(90deg, rgba(95, 224, 138, 1), rgba(83, 215, 200, 0.45));
}

.tone-bearish {
    --accent: var(--red);
    --tone-color: var(--red);
    --tone-bar: linear-gradient(90deg, rgba(255, 111, 129, 1), rgba(242, 196, 109, 0.45));
}

.tone-wait {
    --accent: var(--gold);
    --tone-color: var(--gold);
    --tone-bar: linear-gradient(90deg, rgba(242, 196, 109, 1), rgba(122, 168, 255, 0.45));
}

.tone-neutral {
    --accent: var(--blue);
    --tone-color: var(--blue);
    --tone-bar: linear-gradient(90deg, rgba(122, 168, 255, 1), rgba(83, 215, 200, 0.45));
}

.status-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 18px 0;
}

.status-card,
.panel,
.action-card,
.watch-card,
.rule-card,
.source-card,
.source-link-card {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    border: 1px solid var(--border);
    backdrop-filter: blur(18px);
}

.status-card::after,
.panel::after,
.action-card::after,
.watch-card::after,
.rule-card::after,
.source-card::after,
.source-link-card::after {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, var(--accent, var(--teal)), transparent 75%);
    opacity: 0.9;
    pointer-events: none;
}

.status-card {
    background: linear-gradient(180deg, rgba(15, 24, 38, 0.9), rgba(8, 13, 20, 0.96));
    box-shadow: var(--shadow-soft);
    padding: 16px;
    min-height: 152px;
}

.status-top,
.action-card-top,
.watch-head,
.panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.status-top,
.action-card-top,
.watch-head {
    margin-bottom: 12px;
}

.status-main {
    display: block;
    margin-top: 4px;
    font-family: "IBM Plex Mono", monospace;
    font-size: 1.18rem;
    letter-spacing: -0.02em;
}

.status-value {
    color: var(--muted);
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.status-detail {
    margin: 0 0 12px;
    color: var(--muted);
    line-height: 1.5;
}

.status-track,
.score-track {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

.status-track span,
.score-track span {
    display: block;
    height: 100%;
    width: 0%;
    background: var(--tone-bar, linear-gradient(90deg, rgba(83, 215, 200, 1), rgba(122, 168, 255, 0.45)));
    box-shadow: 0 0 18px rgba(255, 255, 255, 0.15);
}

.panel {
    background: linear-gradient(180deg, rgba(16, 24, 37, 0.9), rgba(7, 10, 15, 0.97));
    box-shadow: var(--shadow);
    padding: 20px;
}

.hero-panel {
    --accent: var(--teal);
}

.session-panel {
    --accent: var(--gold);
}

.note-panel {
    --accent: var(--blue);
}

.strategy-panel {
    --accent: var(--green);
}

.catalyst-panel {
    --accent: var(--gold);
}

.panel h2,
.panel h3,
.panel h4 {
    margin: 0;
    letter-spacing: -0.04em;
}

.panel h2 {
    font-size: clamp(1.65rem, 3vw, 2.55rem);
}

.panel h3 {
    font-size: 1.22rem;
}

.regime-headline {
    margin: 0.1rem 0 0.8rem;
    font-size: clamp(1.35rem, 2.4vw, 1.95rem);
    line-height: 1.18;
    letter-spacing: -0.045em;
    color: var(--text);
}

.lede {
    margin: 0;
    color: var(--muted);
    line-height: 1.65;
}

.hero-grid,
.section-grid {
    display: grid;
    gap: 16px;
}

.hero-grid {
    grid-template-columns: 1.04fr 1.1fr 0.95fr;
    margin-bottom: 16px;
}

.section-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 16px;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.stat {
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.03);
    min-height: 110px;
}

.stat-label {
    display: block;
    color: var(--muted-2);
    font-size: 0.82rem;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.stat strong {
    display: block;
    font-family: "IBM Plex Mono", monospace;
    font-size: 1.25rem;
    letter-spacing: -0.02em;
}

.stat-note {
    display: block;
    margin-top: 8px;
    color: var(--muted-2);
    font-size: 0.82rem;
    line-height: 1.4;
}

.pulse-columns {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.pulse-column {
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.025);
    min-height: 192px;
}

.pulse-column-head {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.pulse-column-head span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-family: "IBM Plex Mono", monospace;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.76rem;
    color: var(--text);
}

.pulse-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 10px;
}

.pulse-list li {
    position: relative;
    padding: 11px 12px 11px 18px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--text);
    line-height: 1.45;
}

.pulse-list li::before {
    content: "";
    position: absolute;
    left: 8px;
    top: 1rem;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--tone-color, var(--teal));
    box-shadow: 0 0 0 4px rgba(83, 215, 200, 0.12);
}

.bullet-list {
    list-style: none;
    padding: 0;
    margin: 18px 0 0;
    display: grid;
    gap: 10px;
}

.bullet-list li {
    position: relative;
    padding-left: 16px;
    color: var(--muted);
    line-height: 1.55;
}

.bullet-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.65rem;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 0 4px rgba(83, 215, 200, 0.12);
}

.operator-panel {
    --accent: var(--teal);
}

.operator-clusters,
.operator-stacks {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.operator-clusters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.operator-stacks {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cluster-card {
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.028);
    min-height: 132px;
}

.tag-cluster {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.tag-cluster span {
    display: inline-flex;
    align-items: center;
    padding: 0.38rem 0.6rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.stack-list {
    list-style: none;
    padding: 0;
    margin: 10px 0 0;
    display: grid;
    gap: 10px;
}

.stack-list li {
    position: relative;
    padding-left: 16px;
    color: var(--muted);
    line-height: 1.55;
}

.stack-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.6rem;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 0 4px rgba(242, 196, 109, 0.11);
}

.action-board,
.strategy-board,
.catalyst-board,
.watch-grid,
.rule-list,
.source-notes,
.source-links {
    display: grid;
    gap: 14px;
}

.action-card,
.strategy-card,
.catalyst-card,
.watch-card,
.rule-card,
.source-card,
.source-link-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.018));
    padding: 16px;
    box-shadow: var(--shadow-soft);
}

.action-card,
.watch-card {
    --accent: var(--teal);
}

.strategy-card {
    --accent: var(--green);
}

.catalyst-card {
    --accent: var(--gold);
}

.action-card h4,
.watch-card h4,
.strategy-card h4,
.catalyst-card h4 {
    margin-top: 4px;
    font-size: 1.05rem;
}

.action-stack,
.watch-stack {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.score-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.28rem 0.6rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.8rem;
    color: var(--tone-color, var(--text));
    letter-spacing: 0.06em;
}

.action-text,
.watch-action,
.rule-card p,
.source-card p {
    color: var(--muted);
    line-height: 1.6;
}

.signal-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0;
}

.signal-pills span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.38rem 0.62rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.action-meta,
.watch-metrics,
.strategy-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.78rem;
    color: var(--muted-2);
}

.action-meta span,
.watch-metrics span,
.strategy-grid span {
    display: inline-flex;
    align-items: center;
    padding: 0.34rem 0.5rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    background: rgba(255, 255, 255, 0.025);
}

.strategy-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 12px;
}

.strategy-text {
    color: var(--muted);
    line-height: 1.6;
    margin: 0 0 12px;
}

.watch-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.watch-price-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.watch-price {
    font-family: "IBM Plex Mono", monospace;
    font-size: 1.32rem;
    letter-spacing: -0.02em;
}

.watch-change {
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.86rem;
}

.sparkline-wrap {
    height: 46px;
    margin-bottom: 10px;
}

.sparkline {
    width: 100%;
    height: 46px;
}

.sparkline polyline {
    fill: none;
    stroke-width: 2.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.rule-card {
    display: grid;
    gap: 10px;
}

.rule-row {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 12px;
}

.rule-row strong {
    font-size: 0.84rem;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.source-card h4,
.source-link-card h4,
.rule-card h4 {
    margin: 0 0 8px;
}

.source-link-card a {
    color: var(--text);
    text-decoration: none;
}

.source-link-card a:hover {
    color: var(--teal);
}

.footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 4px;
    padding: 10px 2px 0;
    color: var(--muted-2);
    font-size: 0.92rem;
    flex-wrap: wrap;
}

.footer-note {
    color: var(--muted);
}

@media (max-width: 1180px) {
    .hero-grid {
        grid-template-columns: 1fr;
    }

    .status-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .operator-clusters,
    .operator-stacks {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 960px) {
    .topbar,
    .topbar-actions,
    .panel-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .section-grid {
        grid-template-columns: 1fr;
    }

    .pulse-columns {
        grid-template-columns: 1fr;
    }

    .hero-stats {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .shell {
        width: min(100% - 18px, 1360px);
        padding-top: 14px;
    }

    .status-strip {
        grid-template-columns: 1fr;
    }

    .rule-row {
        grid-template-columns: 1fr;
    }

    .topbar-meta {
        justify-content: flex-start;
    }
}
