:root {
    --paper: #FFFFFF;
    --ink: #111111;
    --ink-light: #666666;
}

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

body, html {
    margin: 0;
    padding: 0;
    background-color: #F0F0F0;
    color: var(--ink);
    overflow-x: hidden;
}

.page-border {
    background-color: var(--paper);
    border: 4px solid var(--ink);
    outline: 2px solid var(--ink);
    outline-offset: 4px;
    max-width: 900px;
    margin: 60px auto;
    padding: 40px;
    box-shadow: 16px 16px 0px var(--ink);
}

/* Typography */
h1 {
    font-family: 'Big Shoulders Display', sans-serif;
    font-size: 6.5rem; /* Slightly larger to compensate for condensed width */
    font-weight: 900;
    margin: 0;
    line-height: 1;
    letter-spacing: 1px;
    text-align: center;
    text-transform: uppercase;
}

body, input, textarea, button, .feed-item-text, .masthead-sub, .btn-outline, .shame-meta, .stat-label {
    font-family: 'Space Mono', monospace;
}

h2, h3, .btn-heavy, .shame-task, .stat-value {
    font-family: 'Big Shoulders Display', sans-serif;
    font-weight: 900;
}

.subtitle {
    font-family: 'Space Mono', monospace;
    text-align: center;
    border-top: 2px solid var(--ink);
    border-bottom: 2px solid var(--ink);
    padding: 5px 0;
    margin-bottom: 30px;
    font-weight: 700;
    font-size: 0.9rem;
}

/* Masthead */
.masthead {
    text-align: center;
    border-bottom: 4px double var(--ink);
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.masthead-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--ink);
    border-bottom: 1px solid var(--ink);
    padding: 4px 0;
    margin-bottom: 15px;
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
}
.meta-row-left {
    display: flex;
    align-items: center;
    gap: 8px;
}
.meta-row-right {
    display: flex;
    align-items: center;
    gap: 10px;
}
.meta-sep {
    color: var(--ink-light);
}
.midnight-toggle-btn {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 7px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: background 0.15s ease, color 0.15s ease, transform 0.1s ease;
    user-select: none;
}
.midnight-toggle-btn:hover {
    background: var(--ink);
    color: var(--paper);
}
.midnight-toggle-btn:active {
    transform: scale(0.96);
}
.midnight-toggle-btn .candle-icon {
    font-size: 0.75rem;
    line-height: 1;
}
.masthead-sub {
    font-size: 0.9rem;
    font-weight: bold;
    margin-top: 10px;
    letter-spacing: 1px;
}

/* Breaking News Telegraph Wire Ticker */
.telegraph-ticker {
    display: flex;
    align-items: center;
    background: var(--paper);
    border-top: 2px solid var(--ink);
    border-bottom: 2px solid var(--ink);
    margin-bottom: 22px;
    height: 30px;
    overflow: hidden;
    font-family: 'Space Mono', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    box-sizing: border-box;
    position: relative;
    user-select: none;
}

.ticker-badge {
    background: var(--ink);
    color: var(--paper);
    padding: 0 10px;
    height: 100%;
    display: flex;
    align-items: center;
    white-space: nowrap;
    letter-spacing: 0.8px;
    flex-shrink: 0;
    border-right: 2px solid var(--ink);
    font-size: 0.64rem;
}

.ticker-badge-short {
    display: none;
}

.ticker-window {
    flex-grow: 1;
    overflow: hidden;
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
    mask-image: linear-gradient(to right, transparent, black 15px, black calc(100% - 15px), transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 15px, black calc(100% - 15px), transparent);
}

.ticker-track {
    display: flex;
    white-space: nowrap;
    will-change: transform;
    animation: tickerCrawl 110s linear infinite;
}

.ticker-track:hover {
    animation-play-state: paused;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    padding: 0 12px;
    white-space: nowrap;
}

.ticker-tag {
    color: #b91c1c;
    font-weight: 900;
    margin-right: 6px;
    letter-spacing: 0.5px;
}

.ticker-text {
    letter-spacing: 0.3px;
}

.ticker-bullet {
    margin: 0 10px;
    color: var(--ink-light);
}

@keyframes tickerCrawl {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

body.sepia-edition .telegraph-ticker {
    background: #F6EED9 !important;
    border-color: #21150A !important;
}

body.sepia-edition .ticker-badge {
    background: #21150A !important;
    color: #F6EED9 !important;
    border-color: #21150A !important;
}

/* ==========================================
   FRONT-PAGE LEAD STORY OF THE DAY (CROWN DISPATCH)
   ========================================== */
.lead-story-banner {
    background: var(--paper);
    border: 3px double var(--ink);
    padding: 16px 20px 18px 20px;
    margin-bottom: 26px;
    position: relative;
    box-sizing: border-box;
    box-shadow: 4px 4px 0px rgba(17, 17, 17, 0.12);
    transition: background-color 0.25s ease, border-color 0.25s ease;
}

.lead-story-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.lead-story-ornament {
    font-size: 0.65rem;
    letter-spacing: 2px;
    color: var(--ink-light);
    opacity: 0.75;
}

.lead-story-eyebrow {
    background: var(--ink);
    color: var(--paper);
    padding: 2px 12px;
    display: inline-block;
    letter-spacing: 1.5px;
    font-size: 0.68rem;
    font-weight: 700;
}
.eyebrow-full {
    display: inline;
}
.eyebrow-short {
    display: none;
}

.lead-story-body {
    text-align: center;
}

.lead-story-headline {
    font-family: 'Big Shoulders Display', sans-serif;
    font-size: 2.35rem;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin: 8px 0 10px 0;
    word-break: break-word;
}

.lead-story-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--ink-light);
    text-transform: uppercase;
    margin-bottom: 12px;
}

.lead-story-dot {
    font-weight: bold;
    color: var(--ink);
}

.lead-story-badge {
    background: #FFF8E1;
    color: #4E342E;
    border: 1px solid #4E342E;
    padding: 2px 7px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.lead-story-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    border-top: 1px dashed rgba(17, 17, 17, 0.25);
    padding-top: 10px;
}

.lead-stamp-prompt {
    font-family: 'Space Mono', monospace;
    font-size: 0.66rem;
    font-weight: 700;
    color: var(--ink-light);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.lead-reactions {
    display: inline-flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

body.sepia-edition .lead-story-banner {
    background-color: #F6EED9 !important;
    border-color: #21150A !important;
    box-shadow: 4px 4px 0px rgba(33, 21, 10, 0.15) !important;
}

body.sepia-edition .lead-story-eyebrow {
    background-color: #21150A !important;
    color: #F6EED9 !important;
}

body.sepia-edition .lead-story-badge {
    background-color: #E2D7BE !important;
    color: #21150A !important;
    border-color: #21150A !important;
}

body.sepia-edition .midnight-toggle-btn {
    border-color: #21150A !important;
    color: #21150A !important;
}

body.sepia-edition .midnight-toggle-btn:hover {
    background-color: #21150A !important;
    color: #F6EED9 !important;
}

/* Grid Layout */
.newspaper-grid {
    display: grid;
    grid-template-columns: 1.2fr 2fr;
    gap: 30px;
}

.right-col {
    border-left: 2px solid var(--ink);
    padding-left: 30px;
}

.section-title {
    font-size: 1.5rem;
    text-transform: uppercase;
    border-bottom: 2px solid var(--ink);
    padding-bottom: 5px;
    margin-top: 0;
    margin-bottom: 15px;
}

/* Left Column Elements */
.article-box {
    margin-bottom: 40px;
}

.input-section {
    position: relative;
    transform-origin: center center;
}

.field-group {
    margin-bottom: 10px;
}

.field-label {
    display: block;
    font-family: 'Space Mono', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.8px;
    margin-bottom: 5px;
    color: var(--ink);
    text-transform: uppercase;
}

textarea {
    width: 100%;
    box-sizing: border-box;
    height: 80px;
    background: transparent;
    border: 1.5px solid var(--ink);
    padding: 10px;
    font-size: 1rem;
    resize: none;
    outline: none;
    font-family: 'Space Mono', monospace;
    color: var(--ink);
    transition: background 0.15s, border-color 0.15s;
}

textarea:focus {
    background: rgba(23, 23, 23, 0.05);
}

.byline-input-row {
    display: flex;
    align-items: center;
    border: 1.5px solid var(--ink);
    background: transparent;
    transition: background 0.15s, border-color 0.15s;
    box-sizing: border-box;
}

.byline-input-row:focus-within {
    background: rgba(23, 23, 23, 0.04);
}

.byline-tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0 10px;
    background: var(--ink);
    color: var(--paper);
    align-self: stretch;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0.8px;
    user-select: none;
    flex-shrink: 0;
}

.byline-input-row input {
    flex: 1;
    min-width: 0;
    border: none;
    background: transparent;
    padding: 9px 10px;
    font-family: 'Space Mono', monospace;
    font-size: 0.88rem;
    outline: none;
    color: var(--ink);
}

.byline-input-row input:focus {
    background: transparent;
}

.task-char-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
    margin-bottom: 6px;
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    color: var(--ink-light);
}

.task-char-count.near-limit {
    color: #b91c1c;
    font-weight: 700;
}

.desktop-hint {
    font-size: 0.6rem;
    letter-spacing: 0.4px;
    opacity: 0.85;
}

@media (max-width: 768px) {
    .desktop-hint {
        display: none;
    }
}

/* Quick Chips (Preset Tasks) */
.quick-chips-wrapper {
    margin-top: 12px;
    margin-bottom: 5px;
}

.chips-label {
    display: block;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.8px;
    color: var(--ink-light);
    font-family: 'Space Mono', monospace;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.quick-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.chip-btn {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 5px 8px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: background 0.12s ease, color 0.12s ease, transform 0.05s ease;
    line-height: 1.2;
}

.chip-btn:hover {
    background: var(--ink);
    color: var(--paper);
}

.chip-btn:active {
    transform: scale(0.96);
}

.chip-btn.chip-random {
    border: 1px dashed var(--ink);
    background: rgba(17, 17, 17, 0.04);
}

.chip-btn.chip-random:hover {
    background: var(--ink);
    color: var(--paper);
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.primary-action-row {
    display: flex;
    align-items: stretch;
    gap: 8px;
    width: 100%;
}

.primary-action-row .btn-heavy {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

#later-btn-text,
#panic-btn-text {
    display: inline-block;
    transition: opacity 0.15s ease-out, transform 0.15s ease-out;
}

.btn-dice {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 14px;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    cursor: pointer;
    font-size: 1.25rem;
    transition: all 0.15s ease;
    flex-shrink: 0;
}

.btn-dice:hover {
    background: var(--ink);
    color: var(--paper);
}

.btn-dice:active {
    transform: translate(2px, 2px);
}

.btn-dice.spinning .dice-icon {
    animation: diceSpin 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes diceSpin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.25); }
    100% { transform: rotate(360deg) scale(1); }
}

button {
    cursor: pointer;
    text-transform: uppercase;
    font-size: 1.2rem;
    padding: 12px;
    transition: all 0.15s ease;
    border: 2px solid var(--ink);
}

.btn-heavy {
    background: var(--ink);
    color: var(--paper);
    font-weight: bold;
    letter-spacing: 2px;
}

.btn-heavy:hover {
    background: var(--paper);
    color: var(--ink);
}

.btn-heavy:active {
    transform: translate(2px, 2px);
}

.btn-outline {
    background: var(--paper);
    color: var(--ink);
    font-weight: bold;
}

.btn-outline:hover {
    background: var(--ink);
    color: var(--paper);
}

.btn-outline:active {
    transform: translate(2px, 2px);
}

.status-msg {
    margin-top: 10px;
    font-size: 0.85rem;
    font-weight: bold;
    min-height: 1.2em;
    text-align: center;
}

/* Distressed Red Rubber Stamp Overlay */
.stamp-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 500;
}

.rubber-stamp {
    display: inline-block;
    padding: 6px;
    border: 4px solid #b91c1c;
    border-radius: 4px;
    background: #FAF8F5;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28), inset 0 0 0 1px rgba(185, 28, 28, 0.4);
    text-align: center;
    font-family: 'Space Mono', monospace;
    text-transform: uppercase;
    transform-origin: center center;
    max-width: 92%;
    user-select: none;
}

.rubber-stamp.stamped-delay {
    color: #b91c1c;
    border-color: #b91c1c;
}

.rubber-stamp.stamped-panic {
    color: #b43403;
    border-color: #b43403;
}

.stamp-border {
    border: 2px dashed currentColor;
    padding: 8px 14px;
}

.stamp-header {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 2px;
    opacity: 0.88;
}

.stamp-title {
    font-size: 1.35rem;
    font-weight: 900;
    letter-spacing: 2px;
    line-height: 1.15;
    margin: 3px 0;
    text-shadow: 0 0 0.5px currentColor;
}

.stamp-sub {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-top: 3px;
    opacity: 0.92;
}

.stamp-meta {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-top: 5px;
    border-top: 1px solid currentColor;
    padding-top: 3px;
    opacity: 0.82;
}

/* Rubber Stamp Slam Animation (Impact, bounce & settle) */
.stamp-anim-slam {
    animation: stampSlam 0.42s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.stamp-anim-fade {
    animation: stampFadeOut 0.35s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes stampSlam {
    0% {
        opacity: 0;
        transform: scale(3.5) rotate(-28deg);
        filter: blur(5px);
    }
    40% {
        opacity: 0.92;
        transform: scale(0.92) rotate(-8deg);
        filter: blur(0);
    }
    65% {
        opacity: 1;
        transform: scale(1.05) rotate(-10deg);
    }
    85% {
        transform: scale(0.98) rotate(-8.8deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(-9deg);
    }
}

@keyframes stampFadeOut {
    0% {
        opacity: 1;
        transform: scale(1) rotate(-9deg);
    }
    100% {
        opacity: 0;
        transform: scale(0.94) translateY(12px) rotate(-7deg);
    }
}

/* Physical Desk Shockwave on Rubber Stamp Impact */
.desk-impact {
    animation: deskJolt 0.32s cubic-bezier(0.25, 1, 0.5, 1);
}

@keyframes deskJolt {
    0% { transform: translateY(0); }
    25% { transform: translateY(4px) rotate(0.4deg); }
    50% { transform: translateY(-3px) rotate(-0.3deg); }
    75% { transform: translateY(1.5px) rotate(0.1deg); }
    100% { transform: translateY(0) rotate(0); }
}

/* Post-Submission Share Card */
.share-card {
    margin-top: 15px;
    border: 2px dashed var(--ink);
    padding: 12px 14px;
    background-color: #FAFAFA;
    animation: slideIn 0.25s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

.share-stamp-badge {
    display: inline-block;
    color: #b91c1c;
    border: 2px solid #b91c1c;
    outline: 1px dashed #b91c1c;
    outline-offset: -3px;
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 1px;
    padding: 3px 8px;
    margin-bottom: 10px;
    text-transform: uppercase;
    transform: rotate(-3deg);
    background: rgba(185, 28, 28, 0.05);
    mix-blend-mode: multiply;
}

.share-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-bottom: 1px solid var(--ink);
    padding-bottom: 6px;
    margin-bottom: 8px;
}

.share-close-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    color: var(--ink);
    padding: 0 4px;
    font-family: monospace;
}

.share-close-btn:hover {
    font-weight: 900;
}

.share-card-task {
    font-size: 0.95rem;
    font-weight: 700;
    font-style: italic;
    margin-bottom: 12px;
    word-break: break-word;
    color: var(--ink);
}

.share-btn-cert {
    width: 100%;
    background: var(--ink);
    color: var(--paper);
    border: 2px solid var(--ink);
    padding: 10px 12px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 1px;
    cursor: pointer;
    font-family: 'Space Mono', monospace;
    text-align: center;
    margin-bottom: 10px;
    transition: background 0.15s, color 0.15s, transform 0.05s;
    box-shadow: 2px 2px 0px rgba(17, 17, 17, 0.2);
}

.share-btn-cert:hover {
    background: var(--paper);
    color: var(--ink);
}

.share-btn-cert:active {
    transform: translate(1px, 1px);
    box-shadow: 1px 1px 0px rgba(17, 17, 17, 0.2);
}

.share-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.share-btn {
    flex: 1 1 80px;
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    padding: 8px 4px;
    font-size: 0.7rem;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 0.5px;
    transition: background 0.15s, color 0.15s, transform 0.05s;
    font-family: 'Space Mono', monospace;
    text-align: center;
}

.share-btn:hover {
    background: var(--ink);
    color: var(--paper);
}

.share-btn:active {
    transform: translate(1px, 1px);
}

.stats-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stat-group {
    text-align: center;
    border: 1px solid var(--ink);
    padding: 15px;
}

.stat-value {
    font-size: 3rem;
    line-height: 1;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.8rem;
    font-weight: bold;
    text-transform: uppercase;
}

/* Global Procrastination Index */
.leaderboard-meta {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1px;
    border-bottom: 1px solid var(--ink);
    padding-bottom: 5px;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.leaderboard-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.leaderboard-row {
    display: flex;
    align-items: baseline;
    font-size: 0.8rem;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
}

.leaderboard-rank {
    width: 26px;
    opacity: 0.6;
    font-size: 0.75rem;
}

.leaderboard-country {
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}

.leaderboard-dots {
    flex-grow: 1;
    border-bottom: 1px dotted var(--ink);
    margin: 0 6px;
    height: 1px;
    opacity: 0.5;
}

.leaderboard-count {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    font-size: 0.8rem;
}

.leaderboard-empty {
    font-size: 0.8rem;
    font-style: italic;
    opacity: 0.7;
    text-align: center;
    padding: 10px 0;
}

/* Hall of Shame */
.hall-of-shame {
    border: 4px double var(--ink);
    padding: 20px;
    text-align: center;
    margin-bottom: 30px;
}

.shame-badge {
    background: var(--ink);
    color: var(--paper);
    display: inline-block;
    padding: 2px 10px;
    font-size: 0.75rem;
    font-weight: bold;
    margin-bottom: 15px;
}

.shame-task {
    font-size: 2.5rem;
    line-height: 1.1;
    margin-bottom: 10px;
}

.shame-meta {
    font-size: 0.85rem;
    font-style: italic;
}

/* Feed */
.feed-container {
    height: 560px;
    max-height: 560px;
    overflow-y: auto;
    padding: 15px;
    border: 2px solid var(--ink);
    scrollbar-width: thin;
    scrollbar-color: var(--ink) var(--paper);
}

.feed-container::-webkit-scrollbar {
    width: 6px;
}

.feed-container::-webkit-scrollbar-track {
    background: var(--paper);
    border-left: 1px solid var(--ink);
}

.feed-container::-webkit-scrollbar-thumb {
    background: var(--ink);
}

.feed-item {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--ink);
}

.feed-item-meta {
    font-size: 0.75rem;
    font-weight: bold;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.feed-item-text {
    font-size: 1.2rem;
    line-height: 1.4;
}

/* Broadsheet Newspaper Redaction (NSFW Censorship) */
.nsfw-censor {
    display: inline-block;
    background-color: var(--ink);
    color: var(--ink);
    filter: blur(2.5px);
    user-select: none;
    line-height: 0.95;
    padding: 0 1px;
    margin: 0 1px;
    border-radius: 1px;
    vertical-align: baseline;
    cursor: help;
    transition: filter 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.nsfw-censor:hover,
.nsfw-censor:active {
    filter: blur(0);
    background-color: rgba(17, 17, 17, 0.12);
    color: var(--ink);
    text-decoration: underline dotted;
}

.feed-item-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.feed-item-time {
    font-size: 0.75rem;
    color: var(--ink-light);
    display: inline-block;
}

.feed-reactions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.reaction-stamp-btn {
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    border: 1px solid var(--ink);
    color: var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 3px 8px;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    user-select: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    position: relative;
    border-radius: 0;
}

.reaction-stamp-btn:hover {
    background: rgba(17, 17, 17, 0.08);
    transform: translateY(-1px);
}

.reaction-stamp-btn:active {
    transform: scale(0.92);
}

.reaction-stamp-btn.stamped {
    background: var(--ink);
    color: var(--paper);
    border-color: var(--ink);
    box-shadow: 1px 1px 0 rgba(0, 0, 0, 0.2);
}

.reaction-stamp-btn[data-type="same"].stamped {
    border-color: #b91c1c;
    background: #b91c1c;
    color: #ffffff;
    transform: rotate(-1.5deg);
}

.reaction-stamp-btn[data-type="valid"].stamped {
    border-color: #047857;
    background: #047857;
    color: #ffffff;
    transform: rotate(1.2deg);
}

.reaction-stamp-btn[data-type="rip"].stamped {
    border-color: var(--ink);
    background: var(--ink);
    color: var(--paper);
    transform: rotate(-1.2deg);
}

.reaction-stamp-btn.stamp-slam {
    animation: reactionSlam 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes reactionSlam {
    0% { transform: scale(1.35) rotate(5deg); opacity: 0.7; }
    50% { transform: scale(0.88) rotate(-2deg); }
    100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

.reaction-count {
    font-weight: 900;
    opacity: 0.9;
}

/* Special Broadcast Video Box */
.video-box {
    margin-top: 25px;
    margin-bottom: 0;
}

.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    border: 2px solid var(--ink);
    background: #000;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.video-caption {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-top: 8px;
    text-transform: uppercase;
    text-align: center;
    color: var(--ink);
}

/* Footer / Visitor Counter */
.site-footer {
    border-top: 4px double var(--ink);
    margin-top: 40px;
    padding-top: 25px;
    text-align: center;
}

.visitor-counter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    border: 2px solid var(--ink);
    padding: 10px 15px;
    font-family: 'Space Mono', monospace;
    font-weight: bold;
    font-size: 0.9rem;
}

.counter-value {
    background: var(--ink);
    color: var(--paper);
    padding: 4px 10px;
    font-size: 1.1rem;
    letter-spacing: 2px;
}

/* Animations */
@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateY(-15px) scale(0.98);
    }
    70% {
        transform: translateY(2px) scale(1);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.slide-in {
    animation: slideIn 0.3s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes statPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); color: #555; }
    100% { transform: scale(1); }
}

.stat-pop {
    animation: statPop 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

@keyframes flyOff {
    0% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
    100% { transform: translate(150px, -50px) rotate(10deg); opacity: 0; }
}

.fly-off {
    animation: flyOff 0.4s ease-in forwards;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.shake {
    animation: shake 0.4s;
}

/* Daily Diversions (Options 2, 4, 5) */
.diversion-box {
    margin-top: 25px;
    margin-bottom: 0;
    border: 2px solid var(--ink);
    padding: 12px 14px;
    background: var(--paper);
    font-family: 'Space Mono', monospace;
}

.diversion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid var(--ink);
    padding-bottom: 6px;
    margin-bottom: 10px;
    gap: 8px;
}

.diversion-label {
    font-family: 'Big Shoulders Display', sans-serif;
    font-size: 1.3rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1;
}

.diversion-tabs {
    display: flex;
    gap: 0;
}

.div-tab {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--ink);
    margin-left: -1px;
    padding: 4px 8px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    cursor: pointer;
    font-family: 'Space Mono', monospace;
    transition: all 0.15s ease;
    white-space: nowrap;
}

.div-tab:first-child {
    margin-left: 0;
}

.div-tab:hover {
    background: rgba(17, 17, 17, 0.08);
}

.div-tab.active {
    background: var(--ink);
    color: var(--paper);
}

.tab-panel {
    min-height: 105px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Clicker styles */
.clicker-body {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.clicker-btn {
    background: var(--paper);
    color: var(--ink);
    border: 2px solid var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 10px 12px;
    cursor: pointer;
    box-shadow: 3px 3px 0px var(--ink);
    transition: transform 0.05s, box-shadow 0.05s;
    white-space: nowrap;
}

.clicker-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 1px 1px 0px var(--ink);
}

.clicker-stats {
    flex: 1;
    font-size: 0.75rem;
    line-height: 1.35;
}

.clicker-count-line {
    font-weight: 700;
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 4px;
}

.clicker-num {
    display: inline-block;
    background: var(--ink);
    color: var(--paper);
    padding: 1px 6px;
    font-size: 0.85rem;
    font-weight: 700;
    transition: transform 0.1s ease;
}

.clicker-time {
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--ink-light);
}

.clicker-rank-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 3px;
    gap: 6px;
}

.clicker-rank {
    font-size: 0.7rem;
    color: #b91c1c;
    font-weight: 700;
    text-transform: uppercase;
    transition: transform 0.2s ease, color 0.2s ease;
}

.rank-promoted {
    animation: rankPulse 0.4s ease;
}

@keyframes rankPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); color: #dc2626; }
}

.clicker-reset-btn {
    background: none;
    border: none;
    padding: 0;
    font-family: 'Space Mono', monospace;
    font-size: 0.62rem;
    color: var(--ink-light);
    text-decoration: underline;
    cursor: pointer;
    text-transform: uppercase;
    transition: color 0.15s ease;
}

.clicker-reset-btn:hover {
    color: #b91c1c;
}

.clicker-quote {
    font-size: 0.7rem;
    font-style: italic;
    color: var(--ink-light);
    border-top: 1px dashed rgba(17, 17, 17, 0.25);
    padding-top: 6px;
}

/* Weather styles */
.weather-grid {
    font-size: 0.75rem;
    line-height: 1.45;
}

.weather-row {
    display: flex;
    align-items: center;
    margin-bottom: 4px;
    flex-wrap: wrap;
}

.weather-k {
    font-weight: 700;
    text-transform: uppercase;
    margin-right: 6px;
}

.weather-v {
    background: rgba(17, 17, 17, 0.06);
    padding: 1px 6px;
    border: 1px solid rgba(17, 17, 17, 0.2);
}

.weather-forecast-line {
    font-size: 0.72rem;
    font-style: italic;
    margin-top: 6px;
    padding-top: 4px;
    border-top: 1px dashed rgba(17, 17, 17, 0.25);
    min-height: 2.2em;
}

.weather-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 4px;
}

.div-action-btn {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 3px 8px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.div-action-btn:hover {
    background: var(--ink);
    color: var(--paper);
}

/* Comic styles */
.comic-display {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 70px;
}

.comic-ascii {
    font-family: 'Space Mono', monospace;
    font-size: 0.62rem;
    line-height: 1.15;
    margin: 0;
    white-space: pre;
    color: var(--ink);
    background: rgba(17, 17, 17, 0.03);
    padding: 4px 6px;
    border: 1px solid rgba(17, 17, 17, 0.15);
    flex-shrink: 0;
}

.comic-caption {
    font-size: 0.72rem;
    line-height: 1.3;
    font-style: italic;
}

.comic-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px dashed rgba(17, 17, 17, 0.25);
    padding-top: 6px;
    margin-top: 6px;
}

.comic-nav-btn {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 7px;
    cursor: pointer;
}

.comic-nav-btn:hover {
    background: var(--ink);
    color: var(--paper);
}

.comic-page-num {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Feed Rank Flair */
.feed-rank-flair {
    display: inline-block;
    background: var(--ink);
    color: var(--paper);
    font-size: 0.62rem;
    font-weight: 700;
    padding: 1px 5px;
    letter-spacing: 0.5px;
    margin-right: 5px;
    vertical-align: baseline;
    border: 1px solid var(--ink);
    text-transform: uppercase;
}

/* Sepia 1890s Newsprint Edition */
body.sepia-edition {
    background-color: #E2D7BE !important;
    color: #21150A !important;
}

body.sepia-edition .page-border {
    background-color: #F6EED9 !important;
    border-color: #21150A !important;
    outline-color: #21150A !important;
    box-shadow: 16px 16px 0px #21150A !important;
}

body.sepia-edition .rubber-stamp {
    background-color: #F6EED9 !important;
}

/* Unlockables styles */
.clicker-perks-row {
    display: flex;
    gap: 6px;
    margin-top: 6px;
    flex-wrap: wrap;
}

.claim-pass-btn {
    background: var(--ink);
    color: var(--paper);
    animation: pulseGlow 1.5s infinite alternate;
}

@keyframes pulseGlow {
    0% { transform: scale(1); }
    100% { transform: scale(1.02); box-shadow: 0 0 6px rgba(17, 17, 17, 0.4); }
}

.camo-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    padding-top: 6px;
    border-top: 1px dashed rgba(17, 17, 17, 0.25);
    flex-wrap: wrap;
}

.camo-label {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--ink-light);
}

.camo-btn {
    background: transparent;
    border: 1px solid var(--ink);
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 7px;
    cursor: pointer;
    transition: background 0.12s, color 0.12s;
}

.camo-btn:hover, .camo-btn.playing {
    background: var(--ink);
    color: var(--paper);
}

.secret-column {
    margin-top: 8px;
    padding: 8px 10px;
    background: rgba(17, 17, 17, 0.05);
    border: 1px dashed var(--ink);
    font-size: 0.7rem;
    line-height: 1.35;
}

.secret-column-header {
    font-weight: 700;
    margin-bottom: 4px;
    color: #b91c1c;
    letter-spacing: 0.5px;
}

/* Credential Modal */
.credential-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.credential-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(17, 17, 17, 0.75);
    backdrop-filter: blur(3px);
}

.credential-modal-dialog {
    position: relative;
    background: var(--paper);
    border: 4px solid var(--ink);
    outline: 2px solid var(--ink);
    outline-offset: 3px;
    box-shadow: 12px 12px 0px var(--ink);
    max-width: 650px;
    width: 100%;
    padding: 20px;
    z-index: 1001;
    box-sizing: border-box;
    font-family: 'Space Mono', monospace;
    max-height: 90vh;
    overflow-y: auto;
}

.credential-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid var(--ink);
    padding-bottom: 8px;
    margin-bottom: 15px;
    font-weight: 700;
    font-size: 0.85rem;
}

.credential-preview-wrapper {
    width: 100%;
    margin-bottom: 15px;
    border: 2px solid var(--ink);
    background: #FAF8F5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.credential-canvas {
    width: 100%;
    height: auto;
    display: block;
}

.credential-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.credential-sub-actions {
    display: flex;
    gap: 8px;
}

.site-footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-top: 2px solid var(--ink);
    margin-top: 40px;
    padding: 25px 0 20px 0;
    text-transform: uppercase;
    gap: 15px;
}

/* Responsive text span controllers */
.meta-title-full { display: inline; }
.meta-title-short { display: none; }
.footer-share-full { display: inline; }
.footer-share-short { display: none; }
.footer-share-mini { display: none; }

.footer-share-btn {
    background: var(--ink);
    color: var(--paper);
    border: 2px solid var(--ink);
    padding: 10px clamp(10px, 2vw, 22px);
    font-size: clamp(0.72rem, 2.8vw, 0.85rem);
    font-weight: 700;
    letter-spacing: clamp(0.2px, 0.5vw, 1px);
    cursor: pointer;
    font-family: 'Space Mono', monospace;
    transition: background 0.15s, color 0.15s, transform 0.05s;
    text-align: center;
    box-shadow: 4px 4px 0px rgba(17, 17, 17, 0.15);
    white-space: nowrap;
    width: auto;
    max-width: 100%;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.footer-share-btn:hover {
    background: var(--paper);
    color: var(--ink);
}

.footer-share-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px rgba(17, 17, 17, 0.15);
}

.footer-quote {
    font-size: clamp(0.78rem, 2.2vw, 0.9rem);
    font-weight: 700;
    text-align: center;
    max-width: min(90%, 560px);
    margin: 0 auto;
    line-height: 1.45;
    text-wrap: balance;
    hyphens: none;
    -webkit-hyphens: none;
    word-break: normal;
    overflow-wrap: break-word;
}

.footer-credit {
    font-size: 0.65rem;
    font-weight: 400;
    opacity: 0.6;
    letter-spacing: 1px;
    text-align: center;
}

/* ==========================================
   ROCK-SOLID RESPONSIVE MOBILE OVERHAUL
   ========================================== */
/* ==========================================
   ROCK-SOLID RESPONSIVE MOBILE OVERHAUL (v2.5.0)
   ========================================== */
@media (max-width: 768px) {
    body, html {
        overflow-x: hidden;
        -webkit-text-size-adjust: 100%;
    }

    /* Fast tap & remove mobile tap highlights */
    *, *::before, *::after {
        -webkit-tap-highlight-color: transparent;
    }

    button, input, textarea, select, a, .chip-btn, .reaction-stamp-btn {
        touch-action: manipulation;
    }

    /* CRITICAL: Prevent iOS Safari auto-zoom by enforcing >= 16px */
    input[type="text"],
    textarea,
    select {
        font-size: 16px !important;
    }

    .page-border {
        margin: 6px clamp(2px, 1.5vw, 6px);
        padding: 12px clamp(8px, 2.5vw, 14px) 16px clamp(8px, 2.5vw, 14px);
        box-shadow: 4px 4px 0px var(--ink);
        outline: 1.5px solid var(--ink);
        outline-offset: 2px;
        max-width: 100%;
        box-sizing: border-box;
    }

    /* Compact 2-Line Masthead */
    .masthead {
        margin-bottom: 12px;
        padding-bottom: 8px;
    }

    .masthead-meta {
        display: flex;
        flex-direction: column;
        gap: 5px;
        align-items: center;
        text-align: center;
        font-size: clamp(0.62rem, 2.2vw, 0.68rem);
        padding: 5px 2px;
    }

    .meta-row-left {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        width: 100%;
        flex-wrap: nowrap;
    }

    .meta-row-right {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        width: 100%;
    }

    .midnight-toggle-btn {
        padding: 3px clamp(5px, 1.5vw, 8px);
        font-size: clamp(0.6rem, 2.2vw, 0.65rem);
        min-height: 28px;
    }

    h1 {
        font-size: clamp(2.4rem, 10.5vw, 3.2rem);
        letter-spacing: clamp(0.3px, 0.4vw, 0.8px);
        line-height: 0.95;
        margin: 4px 0;
        text-align: center;
    }

    .subtitle {
        font-size: clamp(0.66rem, 2.4vw, 0.74rem);
        padding: 3px 0;
        margin-bottom: 14px;
        letter-spacing: clamp(0.5px, 0.3vw, 1.2px);
    }

    /* Telegraph Wire Ticker */
    .telegraph-ticker {
        height: 26px;
        font-size: 0.62rem;
        margin-bottom: 14px;
    }

    .ticker-badge {
        padding: 0 6px;
        font-size: 0.6rem;
    }

    .ticker-badge-full {
        display: none;
    }

    .ticker-badge-short {
        display: inline;
    }

    .ticker-track {
        animation-duration: 90s;
    }

    /* Front-Page Lead Story of the Day (Single-line Eyebrow + Touch Reactions) */
    .lead-story-banner {
        padding: 10px clamp(6px, 2vw, 10px) 12px clamp(6px, 2vw, 10px);
        margin-bottom: 16px;
    }

    .lead-story-header {
        font-size: 0.62rem;
        gap: 4px;
        margin-bottom: 4px;
    }

    .lead-story-eyebrow {
        font-size: clamp(0.58rem, 2vw, 0.62rem);
        padding: 2px clamp(4px, 1.5vw, 8px);
        letter-spacing: 0.6px;
        white-space: nowrap;
    }

    .eyebrow-full {
        display: none;
    }

    .eyebrow-short {
        display: inline;
    }

    .lead-story-headline {
        font-size: clamp(1.2rem, 5vw, 1.45rem);
        line-height: 1.15;
        margin: 5px 0 6px 0;
        text-wrap: balance;
    }

    .lead-story-meta {
        font-size: 0.62rem;
        gap: 4px;
        margin-bottom: 8px;
    }

    .lead-story-badge {
        font-size: 0.6rem;
        padding: 2px 5px;
    }

    .lead-story-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
        padding-top: 8px;
    }

    .lead-stamp-prompt {
        text-align: center;
        font-size: 0.62rem;
    }

    .lead-reactions {
        display: flex;
        width: 100%;
        gap: 6px;
    }

    .lead-reactions .reaction-stamp-btn {
        flex: 1;
        min-height: 40px;
        font-size: 0.68rem;
        padding: 6px 2px;
        white-space: nowrap;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* ==========================================
       CONTENT HIERARCHY REORDERING (Mobile Flaw #4 Fix)
       ========================================== */
    .newspaper-grid {
        display: flex;
        flex-direction: column;
        gap: 0;
    }

    .left-col, .right-col {
        display: contents; /* Flattens columns into a single unified flex flow */
    }

    /* Mobile Order:
       1. Input Form
       2. Wall of Shame
       3. The Public Wire (Directly visible without scrolling through 10 countries!)
       4. Live Statistics
       5. Global Index
       6. Unique Visitors
       7. Daily Diversions
       8. Commercial Break
    */
    #box-input {
        order: 1;
        margin-bottom: 22px;
    }

    #hall-of-shame {
        order: 2;
        margin-bottom: 18px;
    }

    #box-wire {
        order: 3;
        margin-bottom: 24px;
    }

    #box-stats {
        order: 4;
        margin-bottom: 22px;
    }

    #box-index {
        order: 5;
        margin-bottom: 18px;
    }

    #box-visitors {
        order: 6;
        margin-top: 0;
        margin-bottom: 22px;
    }

    #box-diversions {
        order: 7;
        margin-bottom: 22px;
    }

    #box-video {
        order: 8;
        margin-bottom: 18px;
    }

    /* Input Section & Inputs */
    .section-title {
        font-size: 1.25rem;
        margin-bottom: 10px;
        padding-bottom: 3px;
    }

    .field-group {
        margin-bottom: 8px;
    }

    .field-label {
        font-size: 0.64rem;
        margin-bottom: 4px;
    }

    .byline-input-row input {
        font-size: 16px !important; /* Critical: Prevent iOS Safari auto-zoom */
        padding: 10px 8px;
    }

    .byline-tag {
        font-size: 0.7rem;
        padding: 0 8px;
    }

    textarea {
        padding: 10px 10px;
        height: 82px;
        border-width: 1.5px;
    }

    /* Quick Chips: 3 Neat Columns with >= 38px Touch Targets */
    .quick-chips-wrapper {
        margin-top: 10px;
        margin-bottom: 8px;
    }

    .chips-label {
        font-size: 0.64rem;
        margin-bottom: 6px;
    }

    .quick-chips {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }

    .chip-btn {
        font-size: clamp(0.64rem, 2.2vw, 0.72rem);
        padding: 8px clamp(2px, 1vw, 4px);
        min-height: 38px;
        flex: 1 1 calc(33.333% - 6px);
        display: flex;
        align-items: center;
        justify-content: center;
        box-sizing: border-box;
        text-align: center;
        white-space: nowrap;
        letter-spacing: -0.2px;
    }

    .chip-random {
        flex: 1 1 100%;
        min-height: 38px;
        font-weight: 700;
        margin-top: 2px;
    }

    /* Action Buttons (Generous Touch Targets >= 48px) */
    .action-buttons {
        margin-top: 12px;
    }

    .primary-action-row {
        display: flex;
        gap: 8px;
        width: 100%;
    }

    .btn-heavy {
        flex: 1;
        min-height: 52px;
        font-size: clamp(0.95rem, 3.8vw, 1.15rem);
        padding: 10px clamp(4px, 1.5vw, 8px);
        letter-spacing: clamp(0.2px, 0.3vw, 0.5px);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .btn-dice {
        min-width: 52px;
        min-height: 52px;
        font-size: 1.4rem;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0;
        flex-shrink: 0;
    }

    .btn-outline {
        width: 100%;
        min-height: 46px;
        font-size: clamp(0.85rem, 3.2vw, 1rem);
        margin-top: 8px;
        padding: 10px 8px;
    }

    /* Public Wire & Cards (Scroll Trap Fix) */
    .feed-container {
        max-height: clamp(380px, 50vh, 480px);
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-y: contain;
        border-width: 2px;
    }

    .feed-item {
        padding: 12px 10px;
    }

    .feed-item-meta {
        font-size: 0.65rem;
        margin-bottom: 4px;
    }

    .feed-item-text {
        font-size: 0.95rem;
        line-height: 1.35;
        margin-bottom: 8px;
    }

    .feed-item-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .feed-item-time {
        font-size: 0.65rem;
    }

    .feed-reactions {
        display: flex;
        width: 100%;
        gap: clamp(3px, 1.2vw, 6px);
    }

    .feed-reactions .reaction-stamp-btn {
        flex: 1 1 0;
        min-width: 0;
        min-height: 40px; /* High tactile touch targets (was 19px) */
        font-size: clamp(0.6rem, 2.2vw, 0.68rem);
        padding: 6px 1px;
        white-space: nowrap;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-width: 1.5px;
        letter-spacing: -0.3px;
    }

    /* Statistics & Leaderboards */
    .visitor-counter {
        width: 100%;
        padding: 8px 10px;
        box-sizing: border-box;
        font-size: 0.75rem;
        justify-content: center;
    }

    .counter-label {
        font-size: 0.68rem;
        text-align: center;
    }

    .counter-value {
        font-size: 0.95rem;
    }

    /* Diversions */
    .diversion-header {
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
    }

    .diversion-label {
        text-align: center;
        font-size: 1.15rem;
    }

    .diversion-tabs {
        width: 100%;
        display: flex;
    }

    .div-tab {
        flex: 1;
        text-align: center;
        padding: 8px 2px;
        min-height: 38px;
        font-size: 0.65rem;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .clicker-body {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .clicker-btn {
        width: 100%;
        text-align: center;
        font-size: 0.82rem;
        padding: 12px 8px;
        min-height: 46px;
    }

    .clicker-stats {
        text-align: center;
    }

    .clicker-count-line {
        justify-content: center;
    }

    .clicker-rank-row {
        justify-content: center;
        gap: 10px;
    }

    /* Footer */
    .site-footer {
        flex-direction: column;
        gap: 12px;
        margin-top: 24px;
        padding: 16px 0 12px 0;
    }

    .footer-share-btn {
        width: 100%;
        max-width: 460px;
        margin: 0 auto;
        box-sizing: border-box;
        font-size: clamp(0.72rem, 2.9vw, 0.82rem);
        letter-spacing: clamp(0.2px, 0.5vw, 0.8px);
        padding: 12px clamp(6px, 2vw, 12px);
        min-height: 46px;
        white-space: nowrap;
    }

    .footer-quote {
        font-size: clamp(0.72rem, 2.5vw, 0.8rem);
        line-height: 1.45;
        max-width: min(92%, 480px);
        margin: 0 auto;
        text-align: center;
        text-wrap: balance;
        hyphens: none;
        -webkit-hyphens: none;
        word-break: normal;
        overflow-wrap: break-word;
    }

    .footer-credit {
        position: static;
        text-align: center;
        max-width: 100%;
    }

    .credential-modal {
        padding: 8px;
    }

    .credential-modal-dialog {
        padding: 12px 8px;
        max-height: 94vh;
        width: min(94vw, 560px);
    }
}

/* ==========================================
   IPHONE SE & COMPACT SMARTPHONES (<= 380px)
   ========================================== */
@media (max-width: 380px) {
    .footer-share-full {
        display: none;
    }

    .footer-share-short {
        display: inline;
    }

    .footer-share-mini {
        display: none;
    }

    .footer-share-btn {
        font-size: 0.74rem;
        letter-spacing: 0.3px;
        padding: 11px 6px;
    }
}

/* ==========================================
   ULTRA-NARROW SCREENS (<= 360px: iPhone SE 1st gen, Galaxy Fold Cover)
   ========================================== */
@media (max-width: 360px) {
    .page-border {
        margin: 4px 2px;
        padding: 10px 6px 14px 6px;
        box-shadow: 3px 3px 0px var(--ink);
    }

    .meta-title-full {
        display: none;
    }

    .meta-title-short {
        display: inline;
    }

    .meta-row-left {
        gap: 4px;
    }

    .midnight-toggle-btn {
        padding: 2px 5px;
        font-size: 0.58rem;
    }

    .lead-reactions {
        gap: 4px;
    }

    .lead-reactions .reaction-stamp-btn {
        font-size: 0.62rem;
        padding: 6px 1px;
    }

    .quick-chips {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 5px;
    }

    .chip-btn {
        font-size: 0.64rem;
        min-height: 36px;
        padding: 6px 2px;
        flex: none;
        width: 100%;
    }

    .chip-random {
        grid-column: 1 / -1;
    }

    .feed-reactions {
        gap: 3px;
    }

    .feed-reactions .reaction-stamp-btn {
        font-size: 0.58rem;
        padding: 6px 1px;
        letter-spacing: -0.4px;
        min-height: 38px;
    }

    .footer-share-btn {
        font-size: 0.68rem;
        padding: 10px 4px;
        letter-spacing: 0.2px;
    }
}

/* ==========================================
   NANO FOLD SCREENS (<= 290px)
   ========================================== */
@media (max-width: 290px) {
    .footer-share-short {
        display: none;
    }

    .footer-share-mini {
        display: inline;
    }
}

/* ==========================================
   SHORT SCREENS & 16:9 RATIO (iPhone SE 568px/667px, Short Androids)
   ========================================== */
@media (max-height: 700px) and (max-width: 768px) {
    .masthead {
        margin-bottom: 8px;
        padding-bottom: 6px;
    }

    h1 {
        font-size: clamp(2.2rem, 8.5vw, 2.7rem);
        margin: 2px 0;
    }

    .subtitle {
        font-size: 0.66rem;
        margin-bottom: 10px;
        padding: 2px 0;
    }

    .telegraph-ticker {
        height: 24px;
        margin-bottom: 10px;
    }

    .lead-story-banner {
        padding: 8px 6px 10px 6px;
        margin-bottom: 12px;
    }

    .lead-story-headline {
        font-size: clamp(1.15rem, 4.5vw, 1.35rem);
        margin: 2px 0 4px 0;
    }

    .lead-story-actions {
        gap: 4px;
        padding-top: 6px;
    }

    .lead-story-actions .reaction-stamp-btn {
        min-height: 38px;
    }

    #box-input {
        margin-bottom: 16px;
    }

    .section-title {
        font-size: 1.15rem;
        margin-bottom: 8px;
    }

    .field-group {
        margin-bottom: 5px;
    }

    .field-label {
        font-size: 0.58rem;
        margin-bottom: 2px;
    }

    textarea {
        height: 64px;
    }

    .byline-input-row input {
        padding: 7px 8px;
    }

    .quick-chips-wrapper {
        margin-top: 6px;
        margin-bottom: 6px;
    }

    .primary-action-row {
        gap: 6px;
    }

    .btn-heavy {
        min-height: 48px;
        font-size: 1.05rem;
    }

    .btn-dice {
        min-width: 48px;
        min-height: 48px;
    }

    .btn-outline {
        min-height: 42px;
    }
}

/* ==========================================
   TABLET & MID-SIZE SCREENS (769px - 1024px: iPad Mini, iPad Air, Surface)
   ========================================== */
@media (min-width: 769px) and (max-width: 1024px) {
    .page-border {
        margin: 16px auto;
        padding: 18px 16px 28px 16px;
        max-width: 95%;
    }

    .newspaper-grid {
        gap: 16px;
    }

    h1 {
        font-size: clamp(3.2rem, 6.5vw, 4.4rem);
    }

    .btn-heavy {
        font-size: 1.15rem;
    }
}

/* ==========================================
   LARGE SCREENS & ULTRAWIDE (> 1440px)
   ========================================== */
@media (min-width: 1441px) {
    .page-border {
        max-width: 1080px;
        margin: 40px auto;
        padding: 30px 30px 48px 30px;
    }
}

/* ==========================================
   THE MIDNIGHT EDITION (NOCTURNAL BROADSHEET)
   ========================================== */
body.midnight-edition {
    --paper: #1A1713;
    --ink: #EFE3D3;
    --ink-light: #A89885;
    background-color: #0E0C0A !important;
    color: #EFE3D3 !important;
}

body.midnight-edition .page-border {
    background-color: #1A1713 !important;
    border-color: #EFE3D3 !important;
    outline-color: #EFE3D3 !important;
    box-shadow: 16px 16px 0px #060504 !important;
}

@media (max-width: 768px) {
    body.midnight-edition .page-border {
        box-shadow: 5px 5px 0px #060504 !important;
    }
}

body.midnight-edition .masthead {
    border-bottom-color: #EFE3D3 !important;
}

body.midnight-edition .masthead-meta {
    border-top-color: #EFE3D3 !important;
    border-bottom-color: #EFE3D3 !important;
}

body.midnight-edition .midnight-toggle-btn {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
    border-color: #EFE3D3 !important;
}

body.midnight-edition .telegraph-ticker {
    background: #14110E !important;
    border-color: #EFE3D3 !important;
    color: #EFE3D3 !important;
}

body.midnight-edition .ticker-badge {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
    border-right-color: #EFE3D3 !important;
}

body.midnight-edition .lead-story-banner {
    background: #221D18 !important;
    border-color: #EFE3D3 !important;
    box-shadow: 4px 4px 0px rgba(0, 0, 0, 0.4) !important;
}

body.midnight-edition .lead-story-eyebrow {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
}

body.midnight-edition .lead-story-badge {
    background: #3B2E1C !important;
    color: #F8D588 !important;
    border-color: #F8D588 !important;
}

body.midnight-edition .lead-story-meta,
body.midnight-edition .lead-story-ornament,
body.midnight-edition .lead-stamp-prompt {
    color: #A89885 !important;
}

body.midnight-edition .lead-story-dot {
    color: #EFE3D3 !important;
}

body.midnight-edition .lead-story-actions {
    border-top-color: rgba(239, 227, 211, 0.2) !important;
}

body.midnight-edition .right-col {
    border-left-color: #EFE3D3 !important;
}

body.midnight-edition .section-title {
    border-bottom-color: #EFE3D3 !important;
}

body.midnight-edition .subtitle {
    border-color: #EFE3D3 !important;
}

body.midnight-edition input[type="text"],
body.midnight-edition textarea,
body.midnight-edition select {
    background: #25201A !important;
    color: #EFE3D3 !important;
    border-color: #6E5C49 !important;
}

body.midnight-edition .byline-input-row {
    border-color: #6E5C49 !important;
    background: #25201A !important;
}

body.midnight-edition .byline-input-row:focus-within {
    border-color: #EFE3D3 !important;
}

body.midnight-edition .byline-tag {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
}

body.midnight-edition .byline-input-row input {
    background: transparent !important;
    color: #EFE3D3 !important;
    border: none !important;
}

body.midnight-edition input[type="text"]::placeholder,
body.midnight-edition textarea::placeholder {
    color: #8C7B69 !important;
}

body.midnight-edition input[type="text"]:focus,
body.midnight-edition textarea:focus {
    border-color: #EFE3D3 !important;
    outline-color: #EFE3D3 !important;
}

body.midnight-edition .task-char-count {
    color: #A89885 !important;
}

body.midnight-edition .chips-label {
    color: #A89885 !important;
}

body.midnight-edition .chip-btn {
    background: #241F1A !important;
    color: #EFE3D3 !important;
    border-color: #6E5C49 !important;
}

body.midnight-edition .chip-btn:hover {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
}

body.midnight-edition .btn-heavy {
    background: #EFE3D3 !important;
    color: #1A1714 !important;
    border-color: #EFE3D3 !important;
}

body.midnight-edition .btn-heavy:hover {
    background: #FFF7EE !important;
    box-shadow: 0 0 14px rgba(239, 227, 211, 0.35) !important;
}

body.midnight-edition .btn-dice {
    background: #25201A !important;
    color: #EFE3D3 !important;
    border-color: #6E5C49 !important;
}

body.midnight-edition .btn-outline {
    background: transparent !important;
    color: #EFE3D3 !important;
    border-color: #EFE3D3 !important;
}

body.midnight-edition .btn-outline:hover {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
}

body.midnight-edition .feed-container {
    border-color: #EFE3D3 !important;
}

body.midnight-edition .feed-item {
    background: #201B16 !important;
    border-bottom-color: #383027 !important;
}

body.midnight-edition .feed-item-meta {
    color: #A89885 !important;
}

body.midnight-edition .feed-item-time {
    color: #7D6F5E !important;
}

body.midnight-edition .feed-item-text {
    color: #EFE3D3 !important;
}

body.midnight-edition .shame-box {
    background: #291818 !important;
    border-color: #9C3838 !important;
}

body.midnight-edition .reaction-stamp-btn {
    background: #25201A !important;
    border-color: #6E5C49 !important;
    color: #EFE3D3 !important;
}

body.midnight-edition .reaction-stamp-btn[data-type="same"].stamped {
    background: #4F1D1D !important;
    border-color: #FF6666 !important;
    color: #FF8585 !important;
}

body.midnight-edition .reaction-stamp-btn[data-type="valid"].stamped {
    background: #173824 !important;
    border-color: #4EBF85 !important;
    color: #64E5A8 !important;
}

body.midnight-edition .reaction-stamp-btn[data-type="rip"].stamped {
    background: #3B3125 !important;
    border-color: #EFE3D3 !important;
    color: #FFF7EE !important;
}

body.midnight-edition .rubber-stamp {
    background: #1A1713 !important;
}

body.midnight-edition .video-box,
body.midnight-edition .diversion-box {
    background: #221D18 !important;
    border-color: #EFE3D3 !important;
}

body.midnight-edition .div-tab {
    background: #28221C !important;
    color: #A89885 !important;
    border-color: #6E5C49 !important;
}

body.midnight-edition .div-tab.active {
    background: #EFE3D3 !important;
    color: #1A1713 !important;
}

body.midnight-edition .clicker-btn {
    background: #2E2720 !important;
    border-color: #6E5C49 !important;
    color: #EFE3D3 !important;
}

body.midnight-edition .clicker-btn:hover {
    background: #40362C !important;
    border-color: #EFE3D3 !important;
}

body.midnight-edition .site-footer {
    border-top-color: #EFE3D3 !important;
}

body.midnight-edition .footer-share-btn {
    background: #25201A !important;
    color: #EFE3D3 !important;
    border-color: #6E5C49 !important;
}

body.midnight-edition .footer-quote {
    color: #A89885 !important;
}

body.midnight-edition .credential-modal-dialog {
    background: #1A1713 !important;
    color: #EFE3D3 !important;
    border-color: #EFE3D3 !important;
}
