/* ============================================================
   FONT IMPORTS
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Young+Serif&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:wght@300;400;500&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,wght@1,300&display=swap');

/* ============================================================
   COLOR SYSTEM (Warm Minimal)
   ============================================================ */

:root {
    --primary: #222;
    --primary-text: #222;

    /* Warm neutrals */
    --warm-bg: #faf7f3;
    --warm-card: #fffefa;
    --warm-border: #e8e2da;

    /* Accent colors (fun, sparing usage) */
    --accent-1: #c973ff;
    --accent-2: #ff6f61;
    --accent-3: #ffd43b;

    /* Text neutrals */
    --text-dark: #222;
    --text-medium: #555;
    --text-light: #777;

    /* Shadow */
    --shadow: rgba(0,0,0,0.08);

    /* Radius */
    --radius-lg: 22px;     /* exaggerated rounded corners */
    --radius-pill: 999px;  /* pill shape */
}

/* ============================================================
   BASE ELEMENTS
   ============================================================ */

body.site-body {
    margin: 0;
    padding: 0;
    font-family: "Source Serif 4", serif;
    background: var(--warm-bg);
    color: var(--text-dark);
}

.site-main {
    padding-top: 40px;
    padding-bottom: 60px;
    width: 92%;
    max-width: 1100px;
    margin: 0 auto;
}

h1, h2, h3, h4 {
    font-family: "Young Serif", serif;
    color: var(--primary-text);
    margin-top: 0;
}

p {
    line-height: 1.55;
}

/* Links */
a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    opacity: 0.8;
}

/* ============================================================
   TYPOGRAPHIC SCALE — Editorial Serif Ramp
   ============================================================ */

/* Fluid clamp values for responsive elegance */

h1 {
    font-family: "Young Serif", serif;
    font-size: 3rem;
    line-height: 1.15;
    margin-bottom: 0.5em;
}

h2 {
    font-family: "Young Serif", serif;
    font-size: 2.2rem;
    line-height: 1.2;
    margin-bottom: 0.45em;
}

h3 {
    font-family: "Young Serif", serif;
    font-size: 1.8rem;
    line-height: 1.25;
    margin-bottom: 0.4em;
}

h4 {
    font-family: "Young Serif", serif;
    font-size: 1.4rem;
    line-height: 1.3;
    margin-bottom: 0.35em;
}

/* Optional: Section heading variant */
.heading-section {
    font-family: "Young Serif", serif;
    font-size: 1.1rem;
    line-height: 1.25;
    margin-bottom: 0.75em;
    letter-spacing: 0.3px;
}

.display-xxl {
    font-family: "Young Serif", serif;
    font-size: 4.5rem;
    line-height: 1.1;
    margin-bottom: 0.5em;
}



/* ============================================================
   HEADER
   ============================================================ */

.site-header {
    background: white;
    border-bottom: 1px solid var(--warm-border);
    padding: 14px 0;
    position: sticky;
    top: 0;
    z-index: 999;
}

.header-inner {
    width: 92%;
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-logo {
    font-family: "Young Serif", serif;
    font-size: 1.1rem;
    color: var(--primary);
}

.site-nav {
    display: flex;
    gap: 20px;
}

.nav-link {
    font-weight: 500;
}

/* HEADER SEARCH */
.header-search-form {
    display: flex;
    align-items: center;
    gap: 6px;
}

.header-search-input {
    padding: 8px 12px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--warm-border);
    font-family: "Source Serif 4", serif;
    background: #fff;
}

.header-search-button {
    padding: 8px 14px;
    border-radius: var(--radius-pill);
    border: none;
    background: white;
    color: white;
    cursor: pointer;
}

/* ============================================================
   GRID LAYOUT
   ============================================================ */

.story-grid,
.related-grid,
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 26px;
}

/* ============================================================
   STORY CARDS
   ============================================================ */

.story-card,
.related-card,
.category-card {
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 10px var(--shadow);
    padding: 20px;
    display: block;
    transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.story-card:hover,
.related-card:hover,
.category-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 14px var(--shadow);
}

.story-card-inner,
.related-card-inner,
.category-card-inner {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.story-category {
    font-size: 0.9rem;
    color: var(--accent-1);
    font-weight: 500;
    text-transform: capitalize;
}

.story-excerpt,
.related-excerpt {
    font-size: 1.05rem;
    line-height: 1.5;
}

.story-meta {
    font-size: 0.85rem;
    color: var(--text-medium);
    display: flex;
    justify-content: space-between;
}

/* ============================================================
   CATEGORY CARDS
   ============================================================ */

.category-card-name {
    font-size: 1.2rem;
    font-weight: 500;
}

.category-card-count {
    color: var(--text-medium);
    font-size: 0.9rem;
}

/* ============================================================
   SUBMIT FORM
   ============================================================ */

.submit-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 640px;
}

.form-textarea {
    width: 100%;
    min-height: 160px;
    padding: 14px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--warm-border);
    font-family: "Source Serif 4", serif;
}

.form-input,
.form-select {
    padding: 10px 12px;
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-lg);
    background: white;
    font-family: "Source Serif 4", serif;
}

.form-button {
    padding: 12px 22px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-pill);
    cursor: pointer;
    font-size: 1rem;
}

/* Honeypot */
.hp-field {
    display: none;
}


/* ============================================================
   SUBMIT PAGE — CORE LAYOUT
============================================================ */

.submit-wrapper {
    max-width: 720px;
    margin: 0 auto;
    padding: 30px 20px 50px;
}

.submit-title {
    font-size: 2rem;
    margin-bottom: 24px;
}

/* ============================================================
   FORM ELEMENTS
============================================================ */

.submit-form {
    display: flex;
    flex-direction: column;
}

.form-label {
    font-weight: 600;
    margin: 18px 0 6px;
}

.form-textarea {
    width: 100%;
    min-height: 180px;
    padding: 14px 16px;
    font-size: 1rem;
    line-height: 1.6;
    border-radius: 8px;
    border: 1px solid #ccc;
    resize: vertical;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-textarea:focus {
    outline: none;
    border-color: #111;
    box-shadow: 0 0 0 2px rgba(0,0,0,0.06);
}

/* ============================================================
   CHARACTER COUNTER
============================================================ */

.char-helper {
    margin-top: 6px;
    font-size: 0.85rem;
    color: #777;
}

.char-hint {
    margin-left: 6px;
    color: #999;
}

/* ============================================================
   ERROR STATES
============================================================ */

.form-errors {
    background: #fff4f4;
    border: 1px solid #e3bcbc;
    border-radius: 6px;
    padding: 12px 14px;
    margin-bottom: 20px;
}

.error-item {
    color: #b80000;
    font-size: 0.95rem;
}

.form-error {
    margin-top: 6px;
    font-size: 0.9rem;
    color: #b80000;
}

/* Optional: highlight textarea when invalid */
.form-textarea.error {
    border-color: #b80000;
    background: #fffafa;
}

/* ============================================================
   CATEGORY PILLS (SINGLE SELECT)
============================================================ */

.category-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 8px 0 4px;
}

.category-pill {
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid #ccc;
    background: #fff;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.15s ease;
}

.category-pill:hover {
    background: #f4f4f4;
}

.category-pill.active {
    background: #111;
    color: #fff;
    border-color: #111;
}

/* ============================================================
   SUBMIT BUTTON
============================================================ */

.form-button {
    margin-top: 26px;
    padding: 12px 18px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    background: #111;
    color: #fff;
    cursor: pointer;
    transition: background 0.15s ease;
}

.form-button:hover {
    background: #000;
}

/* ============================================================
   HONEYPOT (HIDDEN)
============================================================ */

.hp-field {
    position: absolute;
    left: -9999px;
    top: -9999px;
}

/* ============================================================
   MOBILE TWEAKS
============================================================ */

@media (max-width: 600px) {
    .submit-title {
        font-size: 1.6rem;
    }

    .form-textarea {
        min-height: 150px;
    }
}


/* ============================================================
   SUCCESS BANNER (Submit Redirect)
   ============================================================ */

.story-success {
    background: var(--accent-3);
    color: var(--primary-text);
    padding: 14px 20px;
    border-radius: var(--radius-lg);
    margin-bottom: 20px;
    font-weight: 500;
    animation: slideDown 0.35s ease-out;
}

.story-success-share {
    display: block;
    font-size: 0.9rem;
    margin-top: 4px;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.fade-out {
    opacity: 0;
    transition: opacity 0.6s linear;
}

.story-react-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
}

.react-button {
    font-size: 1.4rem;
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-pill);
    padding: 12px 15px;
    cursor: pointer;
    transition: 0.15s ease;
}

.react-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px var(--shadow);
}

.react-button.reacted {
    background: var(--accent-3);
    transform: scale(1.15);
}

.react-count {
    font-size: 1.1rem;
    font-weight: 500;
}

.shake {
    animation: shake 0.35s ease;
}

@keyframes shake {
    0%   { transform: translateX(0); }
    20%  { transform: translateX(-4px); }
    40%  { transform: translateX(4px); }
    60%  { transform: translateX(-3px); }
    80%  { transform: translateX(3px); }
    100% { transform: translateX(0); }
}

/* NEW Inline Reaction System for Cards */

.story-footer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
}

.story-reaction-inline {
    display: flex;
    align-items: center;
    gap: 6px;
}

.react-button-inline {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    transition: transform 0.1s ease;
}

.react-button-inline:hover {
    transform: scale(1.15);
}

.react-count-inline {
    font-size: 0.95rem;
    color: var(--text-medium);
}

.react-button-inline.reacted {
    opacity: 0.6;
}

/* Make card layout support pinned footer */
.story-card,
.related-card,
.category-card {
    display: flex;
    flex-direction: column;
}

.story-card-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* FOOTER pinned to bottom */
.story-card-footer {
    margin-top: auto; /* MAGIC: pushes footer to bottom */
    padding-top: 12px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
}

/* LEFT SIDE: stacked */
.story-card-meta-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.85rem;
    color: var(--text-medium);
}

/* RIGHT SIDE: reactions row */
.story-card-reactions {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Reaction button small version */
.react-button-small {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 1.25rem;
    line-height: 1;
    transition: transform 0.15s ease;
}

.react-button-small.reacted {
    transform: scale(1.15);
}

.react-button-small.shake {
    animation: shake 0.35s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-3px); }
    50% { transform: translateX(3px); }
    75% { transform: translateX(-2px); }
}

.story-meta-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 6px;
    font-size: 0.95rem;
    color: var(--text-medium);
}

/* Eyebrow label above the story */
.story-eyebrow {
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    color: var(--text-light);
    text-transform: uppercase;
    margin-bottom: 6px;
    font-weight: 500;
    opacity: 0.85;
}

/* Category label spacing */
.story-category {
    margin-bottom: 6px;
    font-size: 0.95rem;
    color: var(--accent-1);
    font-weight: 500;
}

/* Meta block (author/date stacked) */
.story-meta-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 10px;
    margin-bottom: 26px;
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.35;
}

.story-header {
    border-bottom: 1px solid var(--warm-border);
    margin-bottom: 24px;
}

.story-body {
    color: var(--text-medium);
    font-size: 1.2rem;
    line-height: 1.75;
}

/* ============================================================
   STORY SUCCESS BANNER — STICKY + DISMISSIBLE
============================================================ */

.story-success {
    position: sticky;
    top: 0;
    z-index: 50;
    background: #fff7d6;
    border: 1px solid #e6d38c;
    border-radius: 6px;
    padding: 14px 16px;
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.story-success-note {
    display: block;
    margin-top: 4px;
    font-size: 0.9rem;
    color: #555;
}

.success-close {
    position: absolute;
    top: 8px;
    right: 10px;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    opacity: 0.6;
}

.success-close:hover {
    opacity: 1;
}


/* ============================================================
   STORY PAGE TWO-COLUMN LAYOUT (Ad-Friendly)
   ============================================================ */

.story-content-layout {
    display: grid;
    grid-template-columns: 1fr minmax(260px, 320px);
    gap: 40px;
    align-items: flex-start;
    margin-top: 30px;
}

/* Left Column */
.story-content-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Right Column (Ad Sidebar) */
.story-sidebar {
    position: relative;
    align-self: start;
}

/* Sticky ad block */
.story-sidebar .story-ad-block {
    position: sticky;
    top: 100px;
}

/* Ad block styling */
.story-ad-block {
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: 0 3px 10px var(--shadow);
    text-align: center;
}

/* Ensure ads scale properly */
.story-ad-block img,
.story-ad-block iframe {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* Mobile Layout */
@media (max-width: 800px) {
    .story-content-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .story-sidebar .story-ad-block {
        position: static;
    }
}

/* ============================================================
   STORY SHARE SECTION
   ============================================================ */

.story-share {
    border-top: 1px solid var(--warm-border);
    border-bottom: 1px solid var(--warm-border);
    padding: 30px 0;
    margin: 40px 0;
}

.share-heading {
    font-family: "Young Serif", serif;
    font-size: 1.4rem;
    margin-bottom: 20px;
    letter-spacing: 0.2px;
}

.share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

/* Base share button style using your button system */
.share-btn {
    padding: 10px 18px;
    border-radius: var(--radius-pill);
    font-family: "Source Serif 4", serif;
    font-size: 0.95rem;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: 0.15s ease;
}

/* Variants (already have these but repeating for clarity) */
.btn-solid {
    background: var(--primary);
    color: white;
    border: none;
}

.btn-outline {
    border: 1px solid var(--primary);
    background: transparent;
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}
.copy-btn.copied {
    background: var(--accent-3);
    color: var(--primary-text);
}


/* Featured grid layout */
.featured-title {
    margin-bottom: 20px;
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 26px;
    margin-bottom: 40px;
}

.featured-card {
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 4px 10px var(--shadow);
    text-decoration: none;
    color: inherit;
    display: block;
    transition: 0.12s ease;
}

.featured-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 14px var(--shadow);
}

/* CTA */
.view-all-wrapper {
    text-align: center;
    margin: 40px 0 60px;
}

.view-all-btn {
    font-size: 1.1rem;
    padding: 12px 28px;
}

/* Featured card footer matches standard card footer */
.featured-card-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.story-footer-row {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 12px;
}

.featured-card .story-meta-col {
    display: flex;
    flex-direction: column;
    font-size: 0.9rem;
    color: var(--text-medium);
}

.featured-card .story-reactions {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 1.1rem;
    color: var(--primary);
}

.home-subhead {
    margin: 8px 0 26px;
    font-size: 1.05rem;
    line-height: 1.6;
    color: #555;
    max-width: 640px;
}

/* ============================================================
   PAGINATION
============================================================ */

.pagination-wrapper {
    margin: 40px auto 20px;
    text-align: center;
}

.pagination {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: center;
}

/* Shared link + number styles */
.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    font-size: 0.9rem;
    line-height: 1;
    border-radius: 6px;
    text-decoration: none;
    user-select: none;
}

/* Page numbers */
.pagination .page-number {
    background: #f4f4f4;
    color: #333;
    transition: background 0.15s ease, color 0.15s ease;
}

.pagination .page-number:hover {
    background: #e6e6e6;
}

/* Current page */
.pagination .current-page {
    background: #111;
    color: #fff;
    font-weight: 600;
    cursor: default;
}

/* Prev / Next links */
.pagination .page-link {
    background: #fff;
    border: 1px solid #ddd;
    color: #111;
    font-weight: 500;
    padding: 0 14px;
}

.pagination .page-link:hover {
    background: #f5f5f5;
}

/* Ellipsis */
.pagination .page-ellipsis {
    padding: 0 6px;
    font-size: 1rem;
    color: #999;
    cursor: default;
}

/* Disabled states (if ever added later) */
.pagination .disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* ============================================================
   MOBILE TWEAKS
============================================================ */

@media (max-width: 480px) {
    .pagination a,
    .pagination span {
        min-width: 32px;
        height: 32px;
        font-size: 0.85rem;
    }

    .pagination .page-link {
        padding: 0 10px;
    }
}


/* ============================================================
   AD BLOCKS
   ============================================================ */

.story-grid-ad,
.category-grid-ad {
    grid-column: 1 / -1;
    text-align: center;
    margin: 20px 0;
}

.story-ad-block {
    margin: 0px 0px 20px 0;
    text-align: center;
}


.ad-card .story-card-inner {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 260px; /* keeps the card uniform height */
}

.story-pullquote {
    background: var(--warm-card);
    border-left: 4px solid var(--accent-1);
    padding: 20px;
    margin-bottom: 20px;
    border-radius: var(--radius-lg);
    box-shadow: 0 3px 10px var(--shadow);
    font-family: "Source Serif 4", serif;
}

.story-pullquote p {
    font-size: 1.2rem;
    font-style: italic;
    line-height: 1.55;
    margin: 0;
    color: var(--primary);
}

.pullquote-mark {
    font-family: "Young Serif", serif;
    font-size: 2.6rem;
    line-height: 0.8;
    opacity: 0.25;
    display: block;
    margin-bottom: 6px;
}

/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
    padding: 30px 0;
    text-align: center;
    color: var(--text-light);
}

/* ============================================================
   RESPONSIVE TWEAKS
   ============================================================ */

@media (max-width: 600px) {
    .header-inner {
        flex-wrap: wrap;
        gap: 12px;
    }

    .story-grid,
    .categories-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   COMPONENT LIBRARY — Figma-like Primitives
   ============================================================ */


/* ------------------------------------------------------------
   SPACING TOKENS (margin/padding utilities)
   ------------------------------------------------------------ */

:root {
    --space-2: 4px;
    --space-3: 6px;
    --space-4: 8px;
    --space-5: 12px;
    --space-6: 16px;
    --space-7: 20px;
    --space-8: 24px;
    --space-10: 32px;
    --space-12: 40px;
    --space-16: 64px;
}

/* Padding utility */
.p-4 { padding: var(--space-4); }
.p-5 { padding: var(--space-5); }
.p-6 { padding: var(--space-6); }
.p-8 { padding: var(--space-8); }

/* Margin utility */
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }


/* ============================================================
   LAYOUT PRIMITIVES
   ============================================================ */

/* Core container */
.container {
    
    max-width: 1100px;
    margin: 0 auto;
}

/* Stack: vertical spacing between children */
.stack > * + * {
    margin-top: var(--space-6);
}

/* Cluster: horizontally spaced items */
.cluster {
    display: flex;
    align-items: center;
    gap: var(--space-6);
}

/* Grid presets */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-8);
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
}

@media (max-width: 700px) {
    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }
}


/* ============================================================
   TYPOGRAPHIC UTILITIES
   ============================================================ */

.text-small {
    font-size: 0.85rem;
}

.text-muted {
    color: var(--text-light);
}

.text-medium {
    color: var(--text-medium);
}

.text-lead {
    font-size: 1.25rem;
    line-height: 1.55;
    font-weight: 300;
    font-family: "Source Serif 4", serif;
}

/* Capitlized headings for structured content */
.heading-section {
    font-family: "Young Serif", serif;
    font-size: 1.4rem;
    margin-bottom: var(--space-6);
}


/* ============================================================
   BUTTON SYSTEM
   ============================================================ */

.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: var(--radius-pill);
    font-family: "Source Serif 4", serif;
    cursor: pointer;
    font-size: 1rem;
    transition: 0.15s ease;
}

/* Solid */
.btn-solid {
    background: var(--primary);
    color: white;
    border: none;
}

.btn-solid:hover {
    opacity: 0.85;
}

/* Outline */
.btn-outline {
    border: 1px solid var(--primary);
    background: transparent;
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

/* Subtle */
.btn-subtle {
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    color: var(--text-dark);
}

.btn-subtle:hover {
    background: white;
    border-color: var(--primary);
}


/* ============================================================
   SURFACES + CARDS
   ============================================================ */

.surface {
    background: white;
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 3px 10px var(--shadow);
    padding: var(--space-8);
}

.card {
    background: var(--warm-card);
    border: 1px solid var(--warm-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 10px var(--shadow);
    padding: var(--space-8);
    transition: 0.12s ease;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 14px var(--shadow);
}

/* Panels (good for admin or options) */
.panel {
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--warm-border);
    padding: var(--space-6);
}

/* Compact card for UI metadata */
.card-compact {
    padding: var(--space-4);
    border-radius: var(--radius-lg);
}


/* ============================================================
   TAGS / BADGES / CATEGORY CHIPS
   ============================================================ */

.tag {
    display: inline-block;
    padding: 4px 10px;
    font-size: 0.85rem;
    border-radius: var(--radius-pill);
    background: var(--warm-border);
    color: var(--primary);
}

.tag-accent {
    background: var(--accent-1);
    color: white;
}

/* Category badge on story cards */
.category-chip {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 4px 0;
    border-radius: var(--radius-pill);
    background: white;
    color: var(--accent-1);
    display: inline-block;
}


/* ============================================================
   INTERACTIONS + ANIMATIONS
   ============================================================ */

.hover-lift {
    transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 14px var(--shadow);
}

.fade-in {
    animation: fadeIn 0.35s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Applies to success messages */
.fade-out {
    opacity: 0;
    transition: opacity 0.6s linear;
}


/* ============================================================
   AD BLOCK STYLES (Reusable Surface)
   ============================================================ */

.ad-block {
    grid-column: 1 / -1;
    background: #fffdfa;
    border: 1px solid var(--warm-border);
    padding: var(--space-6);
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: 0 2px 6px var(--shadow);
}
