@import url('https://fonts.googleapis.com/css2?family=Newsreader:ital,opsz,wght@0,6..72,200..800;1,6..72,200..800&display=swap');

/* ROOT */
:root {
    --bg: #ffffff;
    --text: #111111;
    --dark: #3a3a3a;
    --muted: #7a7a7a;
    --line: #eeeeee;

    --container: 1200px;
}

/* RESET */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Newsreader", serif;
    background: var(--bg);
    color: var(--text);
    font-size: 14px;
}

img.icon {
  width: 38px;
  display: inline;
  padding-right: 14px;
}

.subtitle {
    padding-left: 42px;
    color: #999999;
}

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

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

.link-block {
    display:inline-block;
    padding:12px 16px;
    background:#111;
    color:#fff;
    border-radius:6px;
    text-decoration:none;
}

/* LAYOUT */
.page {
    max-width: var(--container);
    margin: 0 auto;
    padding: 24px 18px 60px;
}

/* HEADER */
.topbar {
    margin-bottom: 24px;
    border-bottom: solid 1px #efefef;
    padding-bottom: 3px;
}

.brand {
    font-size: 2rem;
    font-weight: 900;
    padding-bottom: 0.5rem;
}

/* GRID — CORE STRUCTURE */
.feed-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px;
}

/* TABLET */
@media (min-width: 700px) {
    .feed-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* DESKTOP */
@media (min-width: 1024px) {
    .feed-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* CARD */
.story-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;

    transition: transform 0.15s ease, box-shadow 0.15s ease;
    border-bottom: solid 1px #eeeeee;
    padding-bottom: 21px;
}

.story-card:hover {
    transform: translateY(-3px);
}

/* IMAGE */
.story-media {
    height: 180px;
    background: #f3f3f3;
    overflow: hidden;
}

/* CONTENT */
.story-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* SOURCE */
.kicker {
    font-size: 0.75rem;
    color: var(--muted);
}

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

/* TITLE */
.story-title {
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1.8rem;

    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;

    min-height: calc(1.8rem * 3);
}

/* EXCERPT (optional but controlled) */
.story-excerpt {
    font-size: 1.2rem;
    color: var(--dark);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0px;
}

.story-title {
    margin-bottom: 0.3rem;
}

.story-excerpt {
    margin-top: 0;
}

.audio-generate-btn {
    padding: 8px 14px;
    font-size: 14px;
    cursor: pointer;
    background: transparent;
    border: none;
}

.audio-generate-btn:hover {
    color: #666666;
}

.audio-loading {
    opacity: 0.6;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% { opacity: 0.3; }
    50% { opacity: 1; }
    100% { opacity: 0.3; }
}

.audio-loading {
    font-size: 14px;
    opacity: 0.6;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0% { opacity: 0.3; }
    50% { opacity: 1; }
    100% { opacity: 0.3; }
}

ul {
    padding: 0px;
    margin: 0px;
}

li::marker {
    color: var(--muted);
    font-size: 1.4rem;
}

.summary {
    font-size: 1.6rem;
    line-height: 2.2rem;
}

.summary ul {
    margin-left: 1.6rem;
}

.summary .bold {
    margin-bottom: 1rem;
    color: var(--muted);
}

/* META */
.meta {
    font-size: 0.75rem;
    color: var(--muted);
    padding-top: 0.3rem;
}

.speaker {
    transform: scaleX(-1);
    font-size: 1.4rem;
    display: inline-block;
}

/* ADMIN ACTIONS (CRITICAL — preserved but subtle) */
.story-actions {
    position: absolute;
    top: 8px;
    right: 8px;
    display: flex;
    gap: 6px;
}

/* BUTTONS */
.action-btn {
    background: rgba(0,0,0,0.65);
    color: #fff;
    font-size: 12px;
    padding: 4px 6px;
    border-radius: 4px;
    line-height: 1;
    transition: background 0.15s ease;
}

.action-btn:hover {
    background: rgba(0,0,0,0.9);
}

.story-read-summary {
    margin-top: 10px;
}

.read-summary-link {
    font-size: 12px;
    color: #666;
    text-decoration: none;
}

.read-summary-link:hover {
    color: #000;
}

.ai-icon {
    width: 18px;
    height: 18px;
    display: inline;
}

.back {
    font-size: 27px;
}

/* MOBILE TIGHTENING */
@media (max-width: 480px) {
    .story-media {
        height: 160px;
    }
}

