/* storiographer.net — frutiger-aero portfolio dashboard */

:root {
    --bg-a: #d8e4ec;
    --bg-b: #e8eff4;
    --aero-blue: #4a8ab8;
    --aero-teal: #3aaa98;
    --cloud: #f4f8fc;
    --steel: #2a3a4a;
    --hud: #7a8a9a;
    --green: #5ab868;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    color: var(--steel);
    font-family: 'Source Sans 3', system-ui, sans-serif;
    font-size: clamp(15px, 1.5vw, 18px);
    line-height: 1.75;
    overflow-x: hidden;
    min-height: 100vh;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(74, 138, 184, 0.12), transparent 55%),
        radial-gradient(ellipse at 80% 100%, rgba(58, 170, 152, 0.10), transparent 55%),
        linear-gradient(180deg, var(--bg-a) 0%, var(--bg-b) 100%);
    background-attachment: fixed;
}

/* HERO ============================================ */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(40px, 6vw, 80px);
    position: relative;
}

.hud-frame {
    position: relative;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.65) 0%, rgba(244, 248, 252, 0.85) 100%);
    border: 1px solid rgba(122, 138, 154, 0.4);
    border-radius: 18px;
    padding: clamp(40px, 6vw, 80px) clamp(28px, 4vw, 64px);
    max-width: 880px;
    width: 100%;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.9) inset,
        0 24px 48px rgba(74, 138, 184, 0.12),
        0 4px 12px rgba(42, 58, 74, 0.08);
    text-align: center;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.hud-frame::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 50%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
    border-radius: 18px 18px 0 0;
    pointer-events: none;
}

.bracket {
    position: absolute;
    font-family: 'Share Tech Mono', monospace;
    font-size: 22px;
    color: var(--hud);
    opacity: 0.7;
}

.bracket-tl { top: 12px; left: 14px; }
.bracket-tr { top: 12px; right: 14px; }
.bracket-bl { bottom: 12px; left: 14px; }
.bracket-br { bottom: 12px; right: 14px; }

.hud-arc {
    position: absolute;
    width: clamp(160px, 22vw, 260px);
    height: clamp(160px, 22vw, 260px);
    pointer-events: none;
    opacity: 0;
    animation: arcIn 1100ms ease 200ms forwards;
}

.hud-arc-l { top: -60px; left: -80px; }
.hud-arc-r { bottom: -60px; right: -80px; animation-delay: 400ms; }

@keyframes arcIn {
    from { opacity: 0; transform: rotate(-30deg) scale(0.92); }
    to   { opacity: 0.55; transform: rotate(0deg) scale(1); }
}

.hero-tag {
    display: inline-block;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--aero-blue);
    margin-bottom: 18px;
    background: rgba(74, 138, 184, 0.10);
    padding: 4px 14px;
    border-radius: 999px;
    border: 1px solid rgba(74, 138, 184, 0.25);
}

.hero-title {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(36px, 6vw, 72px);
    color: var(--steel);
    letter-spacing: 0.04em;
    line-height: 1.0;
    font-weight: 400;
    margin-bottom: 18px;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.hero-sub {
    color: var(--hud);
    font-size: clamp(15px, 1.5vw, 19px);
    max-width: 56ch;
    margin: 0 auto 36px;
}

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: clamp(14px, 2vw, 28px);
}

.hud-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 10px 18px;
    background: linear-gradient(180deg, var(--cloud), rgba(255, 255, 255, 0.5));
    border: 1px solid rgba(122, 138, 154, 0.35);
    border-radius: 10px;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset, 0 2px 8px rgba(74, 138, 184, 0.1);
}

.hud-key {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--hud);
}

.hud-val {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(18px, 2vw, 24px);
    color: var(--aero-blue);
}

.hud-val.ok {
    color: var(--green);
}

/* SECTIONS ========================================== */
main {
    padding: clamp(40px, 6vw, 96px) clamp(20px, 4vw, 80px);
    display: flex;
    flex-direction: column;
    gap: clamp(48px, 6vw, 96px);
}

.section-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 12px;
    margin-bottom: clamp(24px, 3vw, 40px);
}

.section-bracket {
    font-family: 'Share Tech Mono', monospace;
    color: var(--hud);
    font-size: clamp(22px, 2.6vw, 32px);
}

.section-title {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(22px, 2.6vw, 32px);
    color: var(--steel);
    letter-spacing: 0.04em;
    font-weight: 400;
}

.section-meta {
    margin-left: auto;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--hud);
}

/* CARDS ============================================= */
.grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(20px, 2.4vw, 32px);
}

.card {
    position: relative;
    background: linear-gradient(180deg, var(--cloud) 0%, rgba(244, 248, 252, 0.82) 100%);
    border: 1px solid rgba(122, 138, 154, 0.35);
    border-radius: 14px;
    padding: clamp(20px, 2.4vw, 32px);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.9) inset,
        0 12px 28px rgba(74, 138, 184, 0.10),
        0 2px 6px rgba(42, 58, 74, 0.05);
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 500ms ease, transform 500ms ease, box-shadow 240ms ease;
}

.card.in-view {
    opacity: 1;
    transform: translateY(0);
}

.card:hover {
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.9) inset,
        0 18px 36px rgba(74, 138, 184, 0.16),
        0 4px 10px rgba(42, 58, 74, 0.08);
}

.card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 50%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0));
    border-radius: 14px 14px 0 0;
    pointer-events: none;
}

/* Data viz region */
.card-data {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 14px 16px;
    background: linear-gradient(180deg, rgba(74, 138, 184, 0.06), rgba(58, 170, 152, 0.04));
    border: 1px solid rgba(74, 138, 184, 0.18);
    border-radius: 10px;
    margin-bottom: 18px;
    position: relative;
    z-index: 1;
}

.dataviz {
    flex: 1;
    min-width: 0;
}

.bar-set {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    height: 56px;
}

.bar {
    flex: 1;
    height: 0;
    background: linear-gradient(180deg, var(--aero-blue), var(--aero-teal));
    border-radius: 3px 3px 0 0;
    position: relative;
    transition: height 800ms ease;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.4) inset;
}

.card.in-view .bar {
    height: var(--w);
}

.bar-label {
    position: absolute;
    bottom: -16px;
    left: 0;
    right: 0;
    text-align: center;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 9px;
    letter-spacing: 0.1em;
    color: var(--hud);
}

.timeline-svg {
    width: 100%;
    height: 56px;
}

.ring {
    position: relative;
    width: 76px;
    height: 76px;
    flex-shrink: 0;
}

.ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.ring-bg {
    fill: none;
    stroke: rgba(122, 138, 154, 0.25);
    stroke-width: 6;
}

.ring-fg {
    fill: none;
    stroke: var(--aero-blue);
    stroke-width: 6;
    stroke-linecap: round;
    stroke-dasharray: 264;
    stroke-dashoffset: 264;
    transition: stroke-dashoffset 1200ms ease;
}

.ring-fg.teal { stroke: var(--aero-teal); }
.ring-fg.green { stroke: var(--green); }

.ring-num {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Share Tech Mono', monospace;
    font-size: 16px;
    color: var(--steel);
    font-weight: 400;
}

.ring-pct {
    font-size: 10px;
    color: var(--hud);
    margin-left: 1px;
}

.card-body {
    position: relative;
    z-index: 1;
}

.card-tag {
    display: inline-block;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--aero-teal);
    margin-bottom: 10px;
}

.card-title {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: clamp(20px, 2vw, 26px);
    line-height: 1.2;
    color: var(--steel);
    margin-bottom: 10px;
}

.card-text {
    color: var(--hud);
    margin-bottom: 16px;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    padding-top: 14px;
    border-top: 1px dashed rgba(122, 138, 154, 0.4);
}

.meta-pair {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.meta-key {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 9px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--hud);
}

.meta-val {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 13px;
    color: var(--steel);
    font-weight: 500;
}

/* DASHBOARD ========================================= */
.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: clamp(16px, 2vw, 24px);
}

.dash-card {
    background: linear-gradient(180deg, var(--cloud) 0%, rgba(244, 248, 252, 0.82) 100%);
    border: 1px solid rgba(122, 138, 154, 0.3);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset, 0 8px 20px rgba(74, 138, 184, 0.08);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dash-key {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--hud);
}

.dash-val {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(24px, 3vw, 36px);
    color: var(--aero-blue);
    font-variant-numeric: tabular-nums;
}

.dash-bar {
    height: 6px;
    background: rgba(122, 138, 154, 0.18);
    border-radius: 3px;
    overflow: hidden;
}

.dash-fill {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--aero-blue), var(--aero-teal));
    border-radius: 3px;
    transition: width 1100ms ease;
}

.dash-fill.teal {
    background: linear-gradient(90deg, var(--aero-teal), var(--aero-blue));
}

.dash-fill.green {
    background: linear-gradient(90deg, var(--green), var(--aero-teal));
}

.dash-card.in-view .dash-fill {
    width: var(--w);
}

/* FOOTER ============================================ */
.footer {
    padding: 28px clamp(20px, 4vw, 80px);
    border-top: 1px solid rgba(122, 138, 154, 0.3);
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.foot-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 18px;
    flex-wrap: wrap;
}

.foot-bottom {
    margin-top: 8px;
}

.foot-mark {
    font-family: 'Share Tech Mono', monospace;
    color: var(--steel);
    letter-spacing: 0.06em;
    font-size: 16px;
}

.foot-meta,
.foot-fine {
    font-family: 'IBM Plex Mono', monospace;
    color: var(--hud);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.foot-clock {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 13px;
    color: var(--aero-blue);
    letter-spacing: 0.1em;
}

/* Responsive ======================================== */
@media (max-width: 760px) {
    .grid { grid-template-columns: 1fr; }
    .card-data { flex-direction: column; align-items: stretch; }
    .ring { align-self: center; }
    .hud-arc { display: none; }
    .hero-stats { gap: 10px; }
    .hud-stat { padding: 8px 14px; }
}
