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

:root {
    --ink: #000000;
    --ink-soft: #4a4a4a;
    --ink-faint: rgba(0, 0, 0, 0.45);
    --paper: #F3F3EF;
    --blue: #0000FF;
    --blue-soft: rgba(0, 0, 255, 0.55);
    --line: rgba(0, 0, 0, 0.16);
    --select: rgba(0, 0, 255, 0.18);
    --blue-strong: #0000cc;
    --ink-body: #1a1a1a;

    --fleck-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='480' height='480'><g fill='rgba(0,0,255,0.24)'><circle cx='390' cy='135' r='1.05'/><circle cx='165' cy='105' r='1.05'/><circle cx='120' cy='105' r='1.05'/><circle cx='405' cy='60' r='1.05'/><circle cx='150' cy='240' r='1.05'/><circle cx='270' cy='300' r='1.05'/><circle cx='120' cy='75' r='1.05'/><circle cx='270' cy='315' r='1.05'/><circle cx='330' cy='255' r='1.05'/><circle cx='15' cy='420' r='1.05'/><circle cx='135' cy='15' r='1.05'/><circle cx='405' cy='240' r='1.05'/><circle cx='90' cy='390' r='1.05'/><circle cx='405' cy='105' r='1.05'/><circle cx='255' cy='405' r='1.05'/><circle cx='195' cy='90' r='1.05'/><circle cx='165' cy='165' r='1.05'/></g><g stroke='rgba(0,0,255,0.15)' stroke-width='1' fill='none'><path d='M60 45l-30 0'/><path d='M240 105l15 -15'/><path d='M45 45l30 -30'/><path d='M270 435l-30 -30'/><path d='M345 270l0 15l15 -15'/><path d='M360 165l0 15'/><path d='M285 225l0 30'/><path d='M60 135l-30 -30'/><path d='M375 450l0 15'/><path d='M435 255l15 0l15 -15'/><path d='M120 285l-15 -15'/><path d='M360 75l-15 15'/></g></svg>");

    --grid-step: 15px;
    --frame-offset: 15px;

    --frame-gap: var(--frame-offset);
    --frame-border: 5px;

    --safe-top: env(safe-area-inset-top);
    --safe-right: env(safe-area-inset-right);
    --safe-bottom: env(safe-area-inset-bottom);
    --safe-left: env(safe-area-inset-left);

    --content-w: 940px;
    --radius: 16px;

    --wash-a: 220 220 220;
    --wash-b: 180 180 180;
    --radius-lg: 22px;

    --t-ai: #2f7fbf;
    --t-product: #2f9e44;
    --t-market: #e03a3a;
    --t-people: #d98a1f;
    --t-city: #7c4dbd;
    --t-notes: #4a4a4a;
}

body {
    font-family: 'Inter', 'Space Grotesk', sans-serif;
    background-color: var(--paper);
    background-image:
        var(--fleck-image),
        url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='g'><feTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' seed='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.46 0 0 0 0 0.45 0 0 0 0 0.42 0 0 0 0.11 0'/></filter><rect width='120' height='120' filter='url(%23g)' opacity='0.42'/></svg>"),
        url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='480' height='480'><filter id='m'><feTurbulence type='fractalNoise' baseFrequency='0.02' numOctaves='4' seed='11' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.5 0 0 0 0 0.49 0 0 0 0 0.45 0 0 0 0.04 0'/></filter><rect width='480' height='480' filter='url(%23m)' opacity='0.45'/></svg>");
    background-repeat: repeat, repeat, repeat;
    background-size:
        calc(var(--grid-step) * 32) calc(var(--grid-step) * 32),
        calc(var(--grid-step) * 8) calc(var(--grid-step) * 8),
        calc(var(--grid-step) * 32) calc(var(--grid-step) * 32);
    background-position: var(--frame-offset) var(--frame-offset);
    background-attachment: scroll, scroll, scroll;
    color: var(--ink);
    min-height: 100dvh;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

body.lightbox-open { overflow: hidden; }

#bg-canvas {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100dvh;
    pointer-events: none;
    z-index: -1;
    opacity: 0.5;
}

::selection { background: var(--select); }

.blue-frame {
    position: relative;
    margin: calc(var(--frame-offset) + var(--safe-top)) calc(var(--frame-offset) + var(--safe-right)) calc(var(--frame-offset) + var(--safe-bottom)) calc(var(--frame-offset) + var(--safe-left));
    min-height: calc(100dvh - (var(--frame-offset) * 2));
    border: 5px solid var(--blue-pure);
    padding: 30px;
    display: flex;
    flex-direction: column;
    z-index: 2;
}

.main-content {
    display: flex;
    flex-direction: column;
    gap: calc(var(--grid-step) * 1.2);
    width: 100%;
    max-width: var(--content-w);
    margin: 0 auto;
    padding-top: calc(var(--grid-step) * 5);
    padding-bottom: calc(var(--grid-step) * 3);
    flex: 1 1 auto;
}

.page-header {
    display: flex;
    flex-direction: column;
    gap: calc(var(--grid-step) * 1.2);
}

.hero {
    display: flex;
    flex-direction: column;
}

.hero-main {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--blue);
}

.kicker::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: var(--blue);
    animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.35; transform: scale(0.72); }
}

@font-face {
    font-family: 'Certa Sans';
    src: url('/fonts/certa-sans-medium.woff2') format('woff2');
    font-weight: 500;
    font-style: normal;
    font-display: block;
}

.page-title {
    font-family: 'Certa Sans', 'Inter', sans-serif;
    font-weight: 500;
    font-size: min(calc((100vw - 110px) / 6.49), 144px);
    line-height: 1;
    letter-spacing: 0;
    color: var(--ink);
    white-space: nowrap;
}

.caret {
    display: inline-block;
    width: 0.09em;
    height: 0.78em;
    margin-left: 0.06em;
    background: var(--blue);
    vertical-align: baseline;
    animation: blink 1.1s steps(1) infinite;
}

@keyframes blink { 50% { opacity: 0; } }

.page-subtitle {
    font-family: var(--hand);
    font-synthesis-weight: none;
    font-size: clamp(21px, 3.2vw, 30px);
    font-weight: 600;
    line-height: 1;
    color: var(--blue);
    align-self: flex-start;
    transform: rotate(-4.5deg);
    transform-origin: left center;
    margin: 6px 0 calc(var(--grid-step) * 0.6) 4px;
}

.hero-note {
    max-width: 52ch;
    font-size: 15px;
    line-height: 1.55;
    color: var(--ink-soft);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 6px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 999px;
    padding: 11px 20px;
    border: 1.5px solid var(--ink);
    background: transparent;
    color: var(--ink);
    cursor: pointer;
    transition: color 0.22s ease, background 0.22s ease, border-color 0.22s ease, transform 0.22s ease;
}

.btn:hover {
    transform: translateY(-2px);
    border-color: var(--blue);
    color: var(--blue);
}

.btn-primary {
    background: var(--blue);
    border-color: var(--blue);
    color: var(--on-accent);
}

.btn-primary:hover {
    background: var(--blue-strong);
    border-color: var(--blue-strong);
    color: var(--on-accent);
}

.btn .ico { width: 15px; height: 15px; }
.btn[hidden] { display: none; }

.toolbar {
    position: sticky;
    top: calc(var(--grid-step) * 0.6);
    z-index: 6;
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0;
}

.search {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgb(var(--surface-rgb) / 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    width: 0;
    margin-right: 0;
    padding: 6px 0;
    border-width: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
    transition: width 0.25s ease, margin-right 0.25s ease, padding 0.25s ease,
                opacity 0.2s ease, border-color 0.2s ease;
}

.toolbar.search-open .search {
    width: min(320px, 55%);
    margin-right: 2px;
    padding: 6px 12px;
    border-width: 1px;
    opacity: 1;
    pointer-events: auto;
}

.toolbar.search-open .search:focus-within { border-color: var(--blue); }
.search .ico { width: 15px; height: 15px; color: var(--ink-soft); flex-shrink: 0; }

.search input {
    flex: 1 1 auto;
    min-width: 0;
    border: none;
    outline: none;
    background: transparent;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: var(--ink);
}

.search input::placeholder { color: var(--ink-faint); }

.search-clear {
    border: none;
    background: none;
    cursor: pointer;
    color: var(--ink-soft);
    font-size: 15px;
    line-height: 1;
    padding: 2px;
    display: none;
}

.search.has-value .search-clear { display: block; }
.search-clear:hover { color: var(--blue); }

.chips {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 6px;
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 2px;
}

.chips.has-more {
    -webkit-mask-image: linear-gradient(to right, black calc(100% - 32px), transparent 100%);
    mask-image: linear-gradient(to right, black calc(100% - 32px), transparent 100%);
}

.chips::-webkit-scrollbar { display: none; }

.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.03em;
    color: var(--ink-soft);
    border: 1px solid rgb(var(--ink-rgb) / 0.2);
    border-radius: 999px;
    padding: 6px 13px;
    background: rgb(var(--surface-rgb) / 0.88);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    flex: 0 0 auto;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.chip:hover { color: var(--blue); border-color: var(--blue); }

.chip.active {
    color: var(--paper);
    background: var(--ink);
    border-color: var(--ink);
}

.chip-search {
    flex: 0 0 auto;
    margin-right: 6px;
    padding: 6px 9px;
}

.chip-search .ico { width: 15px; height: 15px; display: block; }

.chip-count {
    font-size: 10px;
    opacity: 0.6;
    font-variant-numeric: tabular-nums;
}

.feed {
    display: flex;
    flex-direction: column;
    gap: calc(var(--grid-step) * 2.4);
    width: 100%;
}

.feed-group {
    display: flex;
    flex-direction: column;
    gap: calc(var(--grid-step) * 0.6);
}

.group-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--grid-step);
    padding-bottom: 8px;
    border-bottom: 1.5px solid var(--ink);
}

.group-title {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.group-count {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-soft);
}

.group-list {
    display: flex;
    flex-direction: column;
}

.post {
    position: relative;
    border-bottom: 1px solid rgb(var(--ink-rgb) / 0.09);
    border-radius: 0;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
                background 0.25s ease, border-color 0.25s ease;
}

.post.revealed { opacity: 1; transform: none; }

.post::before,
.post::after {
    content: '';
    position: absolute;
    z-index: -1;
    bottom: 9px;
    left: 14px;
    width: 46%;
    height: 26px;
    box-shadow: 0 16px 16px rgb(var(--shadow-rgb) / 0.22);
    transform: rotate(-2.4deg);
    transform-origin: 0 100%;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s ease;
}

.post::after {
    left: auto;
    right: 14px;
    transform: rotate(2.4deg);
    transform-origin: 100% 100%;
}

.post:hover::before,
.post:hover::after,
.post.open::before,
.post.open::after { opacity: 1; }

.post:hover { background: var(--surface); }

.post.open {
    background: var(--surface);
    border-bottom-color: rgb(var(--blue-rgb) / 0.35);
}

.post-head {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 34px;
    gap: var(--grid-step);
    align-items: start;
    padding: calc(var(--grid-step) * 1.15) calc(var(--grid-step) * 0.8) 12px;
    border: none;
    border-radius: 0;
    background: none;
    font: inherit;
    color: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.2s ease;
}

.post-head:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }

.post-main {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 0;
}

.post-sub {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 0 calc(var(--grid-step) * 0.8);
    border: none;
    border-radius: 0;
    background: none;
    font: inherit;
    color: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.2s ease;
}

.post-sub:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }

.post-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin-top: 2px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--ink-soft);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), color 0.2s ease,
                background 0.2s ease, border-color 0.2s ease;
}

.post-toggle svg { width: 15px; height: 15px; }
.post:hover .post-toggle { color: var(--blue); border-color: var(--blue); }

.post.open .post-toggle {
    transform: rotate(180deg);
    background: var(--blue);
    border-color: var(--blue);
    color: var(--on-accent);
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.post-date {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    font-weight: 600;
    color: var(--blue);
    font-variant-numeric: tabular-nums;
}

.post-time {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    color: var(--ink-faint);
}

.badge-digest {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--on-accent);
    background: var(--ink);
    border-radius: 999px;
    padding: 3px 9px;
}

.post-title {
    font-family: 'Inter', sans-serif;
    font-size: clamp(18px, 2.2vw, 22px);
    font-weight: 600;
    line-height: 1.28;
    letter-spacing: -0.02em;
    transition: color 0.2s ease;
}

.post:hover .post-title { color: var(--blue); }
.post.open .post-title { color: var(--blue); }

.post-lead {
    font-size: 14px;
    line-height: 1.55;
    color: var(--ink-soft);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
    overflow: hidden;
}

.post.open .post-lead { display: none; }

.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 2px;
}

.tag {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border-radius: 999px;
    padding: 4px 10px;
    white-space: nowrap;
    color: var(--on-accent);
    background: var(--t-notes);
}

.tag[data-tag="ai"] { background: var(--t-ai); }
.tag[data-tag="product"] { background: var(--t-product); }
.tag[data-tag="market"] { background: var(--t-market); }
.tag[data-tag="people"] { background: var(--t-people); }
.tag[data-tag="city"] { background: var(--t-city); }

.post-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 8px calc(var(--grid-step) * 0.8) calc(var(--grid-step) * 1.15);
}

.post-stats {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    padding: 0;
    border: none;
    border-radius: 0;
    background: none;
    font: inherit;
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.post-stats:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

.post-stat {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    color: var(--ink-soft);
}

.post-stat .ico { width: 13px; height: 13px; flex-shrink: 0; }

.post-full {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.post.open .post-full { grid-template-rows: 1fr; }

.post-full-inner {
    overflow: hidden;
    min-height: 0;
    visibility: hidden;
    transition: visibility 0.4s;
}

.post.open .post-full-inner { visibility: visible; }

.post-full-pad {
    display: flex;
    flex-direction: column;
    gap: var(--grid-step);
    padding: 4px calc(var(--grid-step) * 0.8) calc(var(--grid-step) * 1.6);
}

.post-text {
    display: flex;
    flex-direction: column;
    gap: 14px;
    font-size: 16px;
    line-height: 1.65;
    color: var(--ink-body);
}

.post-text p { overflow-wrap: anywhere; }
.post-text strong { font-weight: 700; }
.post-text em { font-style: italic; }

.post-text a {
    color: var(--blue);
    text-decoration: none;
    border-bottom: 1px solid rgb(var(--blue-rgb) / 0.35);
}

.post-text a:hover { border-bottom-color: var(--blue); }

.post-text ul {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-left: 4px;
    list-style: none;
}

.post-text li {
    position: relative;
    padding-left: 20px;
}

.post-text li::before {
    content: '';
    position: absolute;
    left: 3px;
    top: 0.62em;
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--blue);
}

.post-text blockquote {
    padding: 12px 16px;
    border-left: 3px solid var(--blue);
    background: rgb(var(--blue-rgb) / 0.045);
    border-radius: 0 12px 12px 0;
    font-size: 15px;
    line-height: 1.6;
    color: var(--ink-body);
}

.post-media {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.post > .post-media {
    padding: 0 calc(var(--grid-step) * 0.8) calc(var(--grid-step) * 1.1);
}

.media-rows {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.media-row {
    display: flex;
    gap: 10px;
    align-items: stretch;
    max-width: var(--row-w, none);
    margin: 0 auto;
    width: 100%;
}

.media-row > .media-cell {
    flex: var(--r, 1.3333) 1 0;
    aspect-ratio: var(--r, 4 / 3);
    min-width: 0;
}

.media-cell img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.media-cell,
.slide {
    display: block;
    width: 100%;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 0;
    overflow: hidden;
    background: rgb(var(--surface-rgb) / 0.5);
    cursor: zoom-in;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.media-cell:hover,
.slide:hover {
    border-color: var(--blue);
    box-shadow: 0 12px 26px rgb(var(--shadow-rgb) / 0.12);
}

.media-slider { position: relative; }

.slider-track {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.slider-track::-webkit-scrollbar { display: none; }
.slider-track:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

.slide {
    flex: 0 0 100%;
    scroll-snap-align: start;
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: var(--slide-r, 16 / 10);
    max-height: 74dvh;
    background: rgb(var(--ink-rgb) / 0.04);
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid rgb(var(--on-accent-rgb) / 0.5);
    border-radius: 999px;
    background: rgb(var(--scrim-rgb) / 0.55);
    color: var(--on-accent);
    cursor: pointer;
    backdrop-filter: blur(6px);
    transition: background 0.2s ease, opacity 0.2s ease;
}

.slider-arrow .ico { width: 17px; height: 17px; }
.slider-arrow:hover:not(:disabled) { background: var(--blue); }
.slider-arrow:disabled { opacity: 0.25; cursor: default; }
.slider-arrow.prev { left: 10px; }
.slider-arrow.next { right: 10px; }

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 10px;
}

.slider-dot {
    width: 7px;
    height: 7px;
    padding: 0;
    border: none;
    border-radius: 999px;
    background: rgb(var(--ink-rgb) / 0.22);
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.slider-dot:hover { background: rgb(var(--blue-rgb) / 0.5); }
.slider-dot.active { background: var(--blue); transform: scale(1.3); }

.post-file {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border: 1px dashed rgb(var(--ink-rgb) / 0.3);
    border-radius: 12px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    color: var(--ink-soft);
}

.post-reactions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.post-reactions:empty { display: none; }

.reaction-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 5px 11px;
    background: rgb(var(--surface-rgb) / 0.6);
}

.post-sign {
    font-family: var(--hand);
    font-synthesis-weight: none;
    font-size: 26px;
    color: var(--blue);
    transform: rotate(-4deg);
    align-self: flex-start;
}

.post-sign:empty { display: none; }

.post-foot {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 16px;
    padding-top: 14px;
}

.post-foot a,
.post-foot button {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    text-decoration: none;
    border: none;
    background: none;
    padding: 0;
    color: var(--ink-soft);
    cursor: pointer;
    transition: color 0.2s ease;
}

.post-foot a:hover,
.post-foot button:hover { color: var(--blue); }
.post-foot svg { width: 14px; height: 14px; }
.post-permalink { color: var(--blue) !important; }
.post-permalink.copied { color: var(--t-product) !important; }
.post-collapse { margin-left: auto; }

.post.flash { animation: flash 1.6s ease; }

@keyframes flash {
    0%, 40% { background: rgb(var(--blue-rgb) / 0.1); }
    100% { background: rgb(var(--surface-rgb) / 0.6); }
}

.feed-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: calc(var(--grid-step) * 4) var(--grid-step);
    text-align: center;
    border: 1px dashed rgb(var(--ink-rgb) / 0.25);
    border-radius: var(--radius-lg);
}

.feed-empty[hidden] { display: none; }
.feed-empty p { color: var(--ink-soft); font-size: 15px; }

.feed-empty strong {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 22px;
    font-weight: 700;
}

.lightbox[hidden] { display: none; }

body.lightbox-open .menu-container {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgb(var(--surface-rgb) / 0.5);
    color: var(--ink);
    cursor: pointer;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.icon-btn:hover:not(:disabled) { color: var(--blue); border-color: var(--blue); }
.icon-btn:disabled { opacity: 0.3; cursor: default; }
.icon-btn svg { width: 16px; height: 16px; }

.post-spoiler {
    background: rgb(var(--scrim-rgb) / 0.86);
    color: transparent;
    border-radius: 5px;
    padding: 0 4px;
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease;
    user-select: none;
}

.post-spoiler.revealed {
    background: rgb(var(--blue-rgb) / 0.08);
    color: inherit;
    user-select: text;
}

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1020;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgb(var(--scrim-rgb) / 0.92);
    animation: fade 0.2s ease;
}

.lightbox img {
    max-width: 92vw;
    max-height: 86dvh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox .icon-btn {
    position: absolute;
    background: rgb(var(--on-accent-rgb) / 0.14);
    border-color: rgb(var(--on-accent-rgb) / 0.35);
    color: var(--on-accent);
    width: 42px;
    height: 42px;
}

.lightbox .icon-btn:hover:not(:disabled) { background: rgb(var(--on-accent-rgb) / 0.3); color: var(--on-accent); border-color: var(--on-accent); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 18px; }
.lb-next { right: 18px; }

.lb-counter {
    position: absolute;
    bottom: 20px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.1em;
    color: rgb(var(--on-accent-rgb) / 0.75);
}

@media (max-width: 720px) {
    .blue-frame { padding: 18px; border-width: 4px; }
    .main-content { padding-top: calc(var(--grid-step) * 4.5); gap: calc(var(--grid-step) * 1.8); }

    .page-title { font-size: calc((100vw - 78px) / 6.49); }

    .post-head {
        grid-template-columns: minmax(0, 1fr) 30px;
        gap: 12px;
        padding: var(--grid-step) 4px 10px;
    }

    .post > .post-media { padding: 0 4px var(--grid-step); }
    .post-sub { padding: 0 4px; }

    .post-meta-row { padding: 8px 4px var(--grid-step); gap: 10px; }
    .post-stats { gap: 10px; }

    .post-toggle { width: 28px; height: 28px; }
    .post-full-pad { padding: 4px 4px calc(var(--grid-step) * 1.4); }
    .post-text { font-size: 15px; }
    .post-collapse { margin-left: 0; }

    .media-rows { gap: 6px; }

    .media-row {
        flex-direction: column;
        max-width: none;
        gap: 6px;
    }

    .media-row > .media-cell { flex: none; }

    .slider-arrow { width: 32px; height: 32px; }

    .toolbar.search-open .search { width: 65%; }

    .lb-prev { left: 8px; }
    .lb-next { right: 8px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        transition-duration: 0.001ms !important;
    }

    .post { opacity: 1; transform: none; }
}

.post-open {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
    margin-left: auto;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1.2;
    color: var(--ink-soft);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color .18s ease, color .18s ease;
}

.post-open:hover,
.post-open:focus-visible {
    color: var(--ink);
    border-bottom-color: var(--ink-soft);
}

.post.open .post-open {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    .post-open { transition: none; }
}
