/* Shared theme for jaredluyster.com and the tools under it.
 *
 * The "zine" look the subdomains use: paper on ink, one orange accent, thick square
 * borders, and hard offset shadows with no blur — print, not glass. Anything soft
 * (blurred shadows, backdrop-filter, rounded corners, gradient text) is off-style here.
 *
 * news/, sports/, bluegrasscube/ and docs/ deploy separately and each carry their own
 * copy of these tokens, so keep the values below in step with docs/shared-theme.css.
 */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;700&family=Inter:wght@400;500;600;700&display=swap');

*, *::before, *::after { box-sizing: border-box; }

:root {
    --paper: #f3ede0;
    --ink: #131113;
    --accent: #f2971d;
    --accent-ink: #1c1206;
    --border-w: 3px;

    /* Named for the older palette so existing rules keep working unchanged. */
    --bg: #131113;
    --surface: #1c191c;
    --card: #1c191c;
    --text: #f3ede0;
    --muted: #9c948a;
    --border: var(--paper);
    --border-strong: var(--accent);

    /* Offset, not blurred — the shadow reads as a second printing pass. */
    --shadow: 6px 6px 0 var(--accent);
    --shadow-soft: 4px 4px 0 var(--accent);

    --font-display: "Space Grotesk", "Arial Black", sans-serif;
    --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

    /* Semantics, deliberately outside the palette. These encode meaning rather than
     * brand — MTG color identity and rarity — so they must stay distinguishable from
     * each other and must never be folded into --accent. */
    --mtg-w: #e8e4c8;
    --mtg-u: #8bbfe8;
    --mtg-b: #c0b0c8;
    --mtg-r: #e89090;
    --mtg-g: #7fc890;
    --mtg-gold: #dfc060;
    --mtg-colorless: #c0c0c0;
    --mtg-land: #c0b090;

    --rarity-common: #d6d0c5;
    --rarity-uncommon: #c5d0dc;
    --rarity-rare: #dfc060;
    --rarity-mythic: #d2601f;

    --danger: #ff8a7a;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
}

button {
    font: inherit;
    color: inherit;
    appearance: none;
    -webkit-appearance: none;
}

.shell {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

/* Topbar */
.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    background: var(--ink);
    border-bottom: var(--border-w) solid var(--accent);
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 0;
    border: 2px solid var(--paper);
    object-fit: cover;
}

.brand-wordmark {
    height: 34px;
    width: auto;
}

.brand-copy strong {
    display: block;
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    text-transform: uppercase;
}

.brand-copy span {
    display: block;
    color: var(--muted);
    font-size: 0.72rem;
}

/* Nav */
.nav {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--paper);
    font-size: 0.88rem;
}

.nav a {
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    padding: 8px 14px;
    border: 2px solid var(--paper);
    transition: background-color 120ms, color 120ms;
}

.nav a:hover,
.nav a.active {
    background: var(--paper);
    color: var(--ink);
}

/* Buttons */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 20px;
    border-radius: 0;
    border: 2px solid var(--ink);
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 120ms, box-shadow 120ms;
    white-space: nowrap;
    box-shadow: 4px 4px 0 var(--accent);
}

/* The press: the button slides into its own shadow rather than lifting. */
.button:hover:not(:disabled) {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0 var(--accent);
}

.button:disabled { opacity: 0.4; cursor: not-allowed; }

.button-primary {
    background: var(--accent);
    color: var(--accent-ink);
    border-color: var(--ink);
}

.button-secondary {
    background: var(--ink);
    border-color: var(--paper);
    color: var(--paper);
}

/* Eyebrow */
.eyebrow {
    display: inline-flex;
    align-items: center;
    padding: 5px 14px;
    border-radius: 0;
    background: var(--accent);
    border: 2px solid var(--ink);
    box-shadow: 4px 4px 0 var(--paper);
    color: var(--accent-ink);
    font-family: var(--font-display);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* Footer */
.footer {
    border-top: var(--border-w) solid var(--paper);
    padding: 32px 0;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.footer-copy {
    font-size: 0.78rem;
    color: var(--muted);
}

/* Typography */
h1, h2 {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.1;
}

h1 {
    margin: 16px 0 14px;
    font-size: clamp(2.4rem, 7vw, 5rem);
}

h2 {
    margin: 12px 0 10px;
    font-size: clamp(1.5rem, 3vw, 2.4rem);
}

.lead {
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.7;
    max-width: 38rem;
}

.tag-kw, .tag-type {
    font-weight: 700;
    letter-spacing: 0.01em;
}

@media (max-width: 720px) {
    .shell { width: min(100%, calc(100% - 20px)); }
    .topbar-inner { display: grid; }
    .nav { flex-wrap: wrap; gap: 12px; }
    .footer-inner { flex-direction: column; align-items: flex-start; }
}
