/* ================================================================
   Tide Garden — 潮汐花园 · Seaside Editorial Edition
   Typographic, airy, with botanical-tidal character.
   Keep original palette; everything else is new.
   ================================================================ */

:root {
    /* --- original palette (kept) --- */
    --gradient-bg: linear-gradient(135deg, #fdf2f8 0%, #ede9fe 30%, #dbeafe 60%, #f0fdf4 100%);
    --glass-bg: rgba(255, 255, 255, 0.55);
    --glass-border: rgba(255, 255, 255, 0.7);
    --glass-shadow: 0 8px 32px rgba(100, 100, 150, 0.08);
    --glass-blur: blur(16px);
    --text-primary: #1e1b4b;
    --text-secondary: #6366a1;
    --text-muted: #94a3b8;
    --accent: #8b5cf6;
    --accent-soft: rgba(139, 92, 246, 0.1);
    --accent-glow: rgba(139, 92, 246, 0.2);
    --radius: 16px;
    --radius-sm: 10px;
    --radius-xl: 20px;
    --font-body: 'Noto Sans SC', -apple-system, 'PingFang SC', sans-serif;
    --font-heading: 'Noto Serif SC', Georgia, 'Songti SC', serif;
    --font-display: 'Playfair Display', 'Noto Serif SC', Georgia, serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);

    /* --- new tokens for the redesign --- */
    --accent-gradient: linear-gradient(135deg, #8b5cf6, #c084fc);
    --accent-gradient-2: linear-gradient(135deg, #8b5cf6, #a78bfa, #c084fc);
    --card-bg: rgba(255, 255, 255, 0.72);
    --card-border: rgba(255, 255, 255, 0.85);
    --card-shadow: 0 2px 16px rgba(100, 100, 150, 0.06);
    --card-shadow-hover: 0 12px 40px rgba(100, 100, 150, 0.15);
    --nav-bg: rgba(255, 255, 255, 0.78);
    --radius-pill: 9999px;
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 56px;
    --content-max: 720px;
}

/* ================================================================
   Reset & Base
   ================================================================ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-body);
    font-weight: 400;
    background: var(--gradient-bg);
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.8;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Subtle grain overlay */
body::after {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.018;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: var(--accent); color: white; }
img { max-width: 100%; height: auto; }
a { color: var(--accent); transition: var(--transition); }
a:hover { color: #7c3aed; }

/* ================================================================
   Typography — editorial scale
   ================================================================ */
h1, h2, h3, h4 { font-family: var(--font-heading); font-weight: 700; line-height: 1.3; color: var(--text-primary); }
h1 { font-size: 2rem; letter-spacing: -0.01em; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.2rem; }

code, pre { font-family: var(--font-mono); }

/* ================================================================
   Loading spinner
   ================================================================ */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--text-muted);
    font-size: 0.9rem;
    gap: 12px;
}
.loading::after {
    content: '';
    width: 22px; height: 22px;
    border: 2.5px solid var(--accent-soft);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ================================================================
   CSS-only Icon System (preserved)
   ================================================================ */
.icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px; height: 24px;
    position: relative;
    flex-shrink: 0;
}
.icon-lg { width: 36px; height: 36px; }
.icon-sm { width: 18px; height: 18px; }

.icon-write::before {
    content: ''; position: absolute;
    width: 14px; height: 2px;
    background: currentColor;
    top: 7px; left: 5px;
    transform: rotate(-30deg);
    border-radius: 1px;
}
.icon-write::after {
    content: ''; position: absolute;
    width: 0; height: 0;
    border-left: 5px solid currentColor;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    bottom: 5px; right: 3px;
    transform: rotate(-30deg);
}
.icon-home::before {
    content: ''; position: absolute;
    width: 12px; height: 12px;
    border: 2px solid currentColor;
    border-bottom: none; border-right: none;
    transform: rotate(45deg);
    top: 6px; left: 6px;
}
.icon-home::after {
    content: ''; position: absolute;
    width: 16px; height: 11px;
    border: 2px solid currentColor;
    border-top: none;
    bottom: 1px; left: 4px;
    border-radius: 0 0 2px 2px;
}
.icon-user::before {
    content: ''; position: absolute;
    width: 8px; height: 8px;
    border: 2px solid currentColor;
    border-radius: 50%;
    top: 4px; left: 8px;
}
.icon-user::after {
    content: ''; position: absolute;
    width: 16px; height: 10px;
    border: 2px solid currentColor;
    border-top: none;
    border-radius: 0 0 10px 10px;
    bottom: 2px; left: 4px;
}
.icon-close::before, .icon-close::after {
    content: ''; position: absolute;
    width: 18px; height: 2px;
    background: currentColor;
    top: 50%; left: 50%;
    border-radius: 1px;
}
.icon-close::before { transform: translate(-50%,-50%) rotate(45deg); }
.icon-close::after { transform: translate(-50%,-50%) rotate(-45deg); }
.icon-search::before {
    content: ''; position: absolute;
    width: 10px; height: 10px;
    border: 2px solid currentColor;
    border-radius: 50%;
    top: 3px; left: 3px;
}
.icon-search::after {
    content: ''; position: absolute;
    width: 7px; height: 2px;
    background: currentColor;
    transform: rotate(45deg);
    bottom: 5px; right: 3px;
    border-radius: 1px;
}
.icon-tag::before {
    content: ''; position: absolute;
    width: 0; height: 0;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
    border-right: 10px solid currentColor;
    top: 4px; left: 2px;
}
.icon-tag::after {
    content: ''; position: absolute;
    width: 4px; height: 4px;
    border: 1.5px solid currentColor;
    border-radius: 50%;
    top: 8px; left: 11px;
}
.icon-plus::before, .icon-plus::after {
    content: ''; position: absolute;
    background: currentColor;
    top: 50%; left: 50%;
    border-radius: 1px;
}
.icon-plus::before { width: 16px; height: 2px; transform: translate(-50%,-50%); }
.icon-plus::after { width: 2px; height: 16px; transform: translate(-50%,-50%); }
.icon-chevron::before {
    content: ''; position: absolute;
    width: 8px; height: 8px;
    border: 2px solid currentColor;
    border-left: none; border-bottom: none;
    transform: rotate(45deg);
    top: 7px; left: 7px;
}
.icon-eye::before {
    content: ''; position: absolute;
    width: 18px; height: 9px;
    border: 2px solid currentColor;
    border-radius: 9px 9px 0 0;
    top: 5px; left: 3px;
}
.icon-eye::after {
    content: ''; position: absolute;
    width: 6px; height: 6px;
    border: 2px solid currentColor;
    border-radius: 50%;
    top: 6px; left: 9px;
}
.icon-cal::before {
    content: ''; position: absolute;
    width: 18px; height: 14px;
    border: 2px solid currentColor;
    border-radius: 2px;
    top: 5px; left: 3px;
}
.icon-cal::after {
    content: ''; position: absolute;
    width: 8px; height: 2px;
    background: currentColor;
    top: 9px; left: 8px;
    box-shadow: 0 3px 0 0 currentColor;
}
.icon-menu::before {
    content: ''; position: absolute;
    width: 18px; height: 2px;
    background: currentColor;
    top: 6px; left: 3px;
    border-radius: 1px;
    box-shadow: 0 6px 0 0 currentColor, 0 12px 0 0 currentColor;
}

/* ================================================================
   NAVIGATION — clean, minimal, no decoration
   ================================================================ */
.ssr-nav-header {
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 16px 20px;
    max-width: 1240px;
    margin: 0 auto;
}

.site-header { width: 100%; }

.header-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 24px;
    height: 56px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    box-shadow: 0 2px 20px rgba(100, 100, 150, 0.06);
    transition: var(--transition);
}

.main-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.nav-link {
    padding: 8px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.nav-link:hover {
    background: var(--accent-soft);
    color: var(--accent);
}

/* ================================================================
   Home Welcome Section
   ================================================================ */
.home-welcome {
    text-align: center;
    padding: 48px 20px 32px;
    max-width: 640px;
    margin: 0 auto;
}
.home-logo {
    margin: 0 auto 18px;
    text-align: center;
}
.home-logo-img {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.15);
}
.home-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 10px;
    line-height: 1.3;
}
.home-desc {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
}
.home-stats {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-top: 14px;
    letter-spacing: 0.04em;
}
/* Subtle decorative divider */
.home-welcome::after {
    content: '';
    display: block;
    width: 40px;
    height: 2px;
    background: var(--accent-gradient);
    border-radius: 1px;
    margin: 24px auto 0;
}

/* ================================================================
   PAGE CONTAINER
   ================================================================ */
.ssr-landing {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px 80px;
}

/* ================================================================
   POST CARDS — clean, flat, content-first
   ================================================================ */
.ssr-posts {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 32px;
}

.ssr-post {
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.85);
    border-radius: 12px;
    padding: 28px 26px;
    box-shadow: 0 1px 8px rgba(100, 100, 150, 0.05);
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
    animation: fadeUp 0.5s ease both;
}
.ssr-post:nth-child(1) { animation-delay: 0.04s; }
.ssr-post:nth-child(2) { animation-delay: 0.08s; }
.ssr-post:nth-child(3) { animation-delay: 0.12s; }
.ssr-post:nth-child(4) { animation-delay: 0.16s; }
.ssr-post:nth-child(5) { animation-delay: 0.2s; }
.ssr-post:nth-child(6) { animation-delay: 0.24s; }
.ssr-post:nth-child(7) { animation-delay: 0.28s; }
.ssr-post:nth-child(8) { animation-delay: 0.32s; }

.ssr-post:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 8px 28px rgba(100, 100, 150, 0.1);
}

.ssr-post .meta {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 10px;
}

/* Category — small subtle label */
.ssr-post .cat {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 4px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 0.7rem;
    font-weight: 600;
}

.ssr-post h2 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin: 8px 0 10px;
    line-height: 1.45;
}
.ssr-post h2 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}
.ssr-post h2 a:hover { color: var(--accent); }

.ssr-post .summary {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.7;
    flex-grow: 1;
}

/* Tags in card */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}
.tag {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 6px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 500;
    transition: var(--transition);
    text-decoration: none;
}
.tag:hover {
    background: rgba(139, 92, 246, 0.18);
    color: #7c3aed;
}

/* ================================================================
   Empty state
   ================================================================ */
.ssr-empty {
    text-align: center;
    padding: 80px 20px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
}
.ssr-empty p { color: var(--text-secondary); font-size: 1rem; }

/* ================================================================
   POST DETAIL — editorial reading layout
   ================================================================ */
.post-detail {
    max-width: var(--content-max);
    margin: 32px auto 0;
    padding: 44px 52px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    position: relative;
    overflow: hidden;
    animation: fadeUp 0.5s ease;
}
/* Decorative top accent bar */
.post-detail::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 4px;
    background: var(--accent-gradient-2);
}

.post-title {
    font-family: var(--font-heading);
    font-size: 2.1rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 18px;
    letter-spacing: -0.005em;
}

.post-meta-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    font-size: 0.85rem;
    color: var(--text-muted);
    padding-bottom: 22px;
    border-bottom: 1px solid rgba(99, 102, 161, 0.1);
    margin-bottom: 28px;
}
.post-meta-bar .post-category {
    display: inline-block;
    padding: 4px 16px;
    border-radius: var(--radius-pill);
    background: var(--accent-gradient);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    letter-spacing: 0.04em;
}
.post-meta-bar time,
.post-meta-bar .post-author,
.post-meta-bar .post-views {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.post-meta-bar .btn-sm {
    margin-left: auto;
}

.post-content {
    font-size: 1.05rem;
    line-height: 1.9;
    color: var(--text-primary);
}
.post-content p {
    margin-bottom: 1.3em;
}

/* Tags at bottom of post */
.post-detail .post-tags {
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1px solid rgba(99, 102, 161, 0.1);
}

/* ================================================================
   BUTTONS — all pill-shaped with slide/glow hover
   ================================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 26px;
    border-radius: var(--radius-pill);
    border: 1.5px solid rgba(139, 92, 246, 0.2);
    background: transparent;
    color: var(--accent);
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition);
    line-height: 1.4;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}
/* Slide-fill hover */
.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--accent-soft);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: inherit;
}
.btn:hover::before {
    transform: scaleX(1);
    transform-origin: left;
}
.btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}
.btn:active { transform: scale(0.96); }

/* Keep children above the ::before overlay */
.btn > * { position: relative; z-index: 1; }

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.25);
}
.btn-primary::before { display: none; }
.btn-primary:hover {
    background: linear-gradient(135deg, #7c3aed, #a78bfa);
    color: white;
    box-shadow: 0 6px 24px rgba(139, 92, 246, 0.4);
    transform: translateY(-2px);
}
.btn-primary:active {
    transform: scale(0.96) translateY(0);
}

.btn-block { display: flex; width: 100%; }
.btn-sm {
    padding: 6px 16px;
    font-size: 0.8rem;
    border-radius: var(--radius-pill);
}
.btn-danger {
    color: #e11d48;
    border-color: rgba(244, 63, 94, 0.25);
}
.btn-danger::before { background: rgba(244, 63, 94, 0.08); }
.btn-danger:hover { border-color: #e11d48; color: #be123c; }

/* ================================================================
   FORMS — rounded, minimal, with glowing focus
   ================================================================ */
.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    letter-spacing: 0.02em;
}
.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 18px;
    background: rgba(255, 255, 255, 0.7);
    border: 1.5px solid rgba(99, 102, 161, 0.15);
    border-radius: 14px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text-primary);
    transition: var(--transition);
    outline: none;
    /* Custom select arrow */
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236366a1' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
    cursor: pointer;
}
.form-group select:hover {
    border-color: rgba(99, 102, 161, 0.3);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft), 0 0 20px rgba(139, 92, 246, 0.08);
    background: rgba(255, 255, 255, 0.9);
}
.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}
.form-group textarea {
    resize: vertical;
    min-height: 110px;
}
.form-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
}
.form-checkbox label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    cursor: pointer;
    margin-bottom: 0;
}
.form-checkbox input[type="checkbox"] {
    width: 18px; height: 18px;
    accent-color: var(--accent);
    cursor: pointer;
}
.form-row {
    display: flex;
    gap: 16px;
}
.form-row .form-group { flex: 1; }

/* ================================================================
   AUTH (login / register) — centered glass card
   ================================================================ */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 100px);
    padding: 40px 20px;
}
.auth-card {
    width: 100%;
    max-width: 420px;
    padding: 40px 40px 36px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    position: relative;
    overflow: hidden;
    animation: fadeUp 0.5s ease;
}
/* Gradient top bar */
.auth-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 4px;
    background: var(--accent-gradient-2);
}
.auth-title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 28px;
}
.auth-switch {
    text-align: center;
    margin-top: 22px;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.auth-switch a {
    color: var(--accent);
    font-weight: 500;
}

/* ================================================================
   COMMENTS — clean, minimal, with timeline feel
   ================================================================ */
.comments-section {
    max-width: var(--content-max);
    margin: 28px auto 50px;
    padding: 36px 44px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    animation: fadeUp 0.5s ease;
}
.comments-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin-bottom: 22px;
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(99, 102, 161, 0.08);
}

.comment-form {
    margin-bottom: 30px;
}
.comment-form textarea {
    width: 100%;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.55);
    border: 1.5px solid rgba(99, 102, 161, 0.12);
    border-radius: 14px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text-primary);
    resize: vertical;
    min-height: 76px;
    margin-bottom: 14px;
    transition: var(--transition);
    outline: none;
}
.comment-form textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
    background: rgba(255, 255, 255, 0.75);
}
.comment-form textarea::placeholder { color: var(--text-muted); }

.comment-form .guest-fields {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
}
.comment-form .guest-fields .form-group {
    margin-bottom: 0;
}
.comment-form .guest-fields input {
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.55);
    border: 1.5px solid rgba(99, 102, 161, 0.12);
    border-radius: 12px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--text-primary);
    transition: var(--transition);
    outline: none;
    width: 100%;
}
.comment-form .guest-fields input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}
.comment {
    display: flex;
    gap: 16px;
    padding: 18px 0;
    border-bottom: 1px solid rgba(99, 102, 161, 0.06);
}
.comment:last-child { border-bottom: none; }
.comment-avatar { flex-shrink: 0; }
.comment-avatar-initial {
    width: 42px; height: 42px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 600;
}
.comment-body { flex: 1; min-width: 0; }
.comment-author {
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--text-primary);
    display: inline;
}
.comment-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: inline;
    margin-left: 10px;
}
.comment-content {
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--text-primary);
    margin-top: 6px;
    word-break: break-word;
}
.no-comments {
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
    font-size: 0.9rem;
}
.comment-count {
    display: inline-block;
    min-width: 24px;
    padding: 1px 10px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    vertical-align: middle;
    text-align: center;
}

/* Reply button */
.btn-reply {
    display: inline-block;
    padding: 2px 10px;
    margin-top: 6px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    border-radius: 4px;
    transition: var(--transition);
}
.btn-reply:hover {
    background: var(--accent-soft);
    color: var(--accent);
}

/* Nested replies */
.comment-replies {
    margin-left: 32px;
    padding-left: 16px;
    border-left: 2px solid rgba(139, 92, 246, 0.12);
    margin-top: 4px;
}
.comment-replies .comment {
    padding: 12px 0;
}
.comment-replies .comment-avatar-initial {
    width: 32px;
    height: 32px;
    font-size: 0.75rem;
}

/* Reply indicator bar */
.reply-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    padding: 6px 14px;
    background: var(--accent-soft);
    border-radius: 8px;
    font-size: 0.82rem;
    color: var(--accent);
    font-weight: 500;
}
.btn-cancel-reply {
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 0.78rem;
    cursor: pointer;
    padding: 2px 8px;
    border-radius: 4px;
    transition: var(--transition);
    margin-left: auto;
}
.btn-cancel-reply:hover {
    color: var(--accent);
    background: rgba(139, 92, 246, 0.08);
}

/* ================================================================
   EDITOR — minimal, title + category + content + image upload
   ================================================================ */
.editor-page {
    max-width: 900px;
    margin: 24px auto 40px;
    padding: 0 24px;
    animation: fadeUp 0.4s ease;
}
.editor-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
    padding: 18px 28px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
}
.editor-header h1 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
}
.editor-actions {
    display: flex;
    gap: 10px;
}

.editor-form {
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--card-shadow);
}
.editor-form input#editor-title {
    font-size: 1.25rem;
    padding: 16px 20px;
    font-weight: 600;
    border-radius: 14px;
}

/* Textarea: full width, no split */
.editor-textarea-wrap {
    margin-top: 4px;
}
.editor-textarea-wrap textarea {
    width: 100%;
    min-height: 420px;
    padding: 18px 20px;
    background: rgba(255, 255, 255, 0.55);
    border: 1.5px solid rgba(99, 102, 161, 0.12);
    border-radius: 14px;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    line-height: 1.8;
    color: var(--text-primary);
    resize: vertical;
    outline: none;
    transition: var(--transition);
}
.editor-textarea-wrap textarea:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-soft);
    background: rgba(255, 255, 255, 0.75);
}
.editor-textarea-wrap textarea::placeholder {
    color: var(--text-muted);
}

/* Mini toolbar: only image button */
.editor-toolbar-mini {
    display: flex;
    gap: 6px;
    margin-top: 10px;
    padding: 6px 0;
}
.btn-toolbar {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 18px;
    border-radius: var(--radius-pill);
    background: var(--accent-soft);
    color: var(--accent);
    border: 1px solid transparent;
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}
.btn-toolbar:hover {
    background: rgba(139, 92, 246, 0.18);
    border-color: rgba(139, 92, 246, 0.2);
}
.btn-toolbar:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ================================================================
   ADMIN PANEL — gradient sidebar, clean content
   ================================================================ */
.admin-page {
    max-width: 1200px;
    margin: 28px auto 40px;
    padding: 0 24px;
    animation: fadeUp 0.4s ease;
}
.admin-layout {
    display: flex;
    gap: 28px;
}
.admin-sidebar {
    width: 200px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 20px 14px;
    background: var(--accent-gradient-2);
    border-radius: var(--radius);
    box-shadow: 0 8px 32px rgba(139, 92, 246, 0.2);
    align-self: flex-start;
    position: sticky;
    top: 84px;
}
.admin-nav-item {
    display: block;
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--transition);
}
.admin-nav-item:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
}
.admin-nav-item.active {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-weight: 600;
}

.admin-content {
    flex: 1;
    min-width: 0;
}
.admin-content h1 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 22px;
}

/* Stats grid — clean cards with gradient accents */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 18px;
    margin-bottom: 28px;
}
.stat-card {
    padding: 24px 22px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-sm);
    box-shadow: var(--card-shadow);
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%;
    height: 3px;
    background: var(--accent-gradient);
}
.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--card-shadow-hover);
}
.stat-number {
    display: block;
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
    line-height: 1.2;
}
.stat-label {
    display: block;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 6px;
    font-weight: 500;
}

/* Admin table — clean, borderless, with subtle hover */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}
.admin-table th {
    text-align: left;
    padding: 14px 16px;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border-bottom: 2px solid rgba(99, 102, 161, 0.08);
}
.admin-table td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(99, 102, 161, 0.04);
    color: var(--text-primary);
}
.admin-table tr:hover td {
    background: rgba(139, 92, 246, 0.03);
}
.admin-table td a {
    color: var(--text-primary);
    text-decoration: none;
}
.admin-table td a:hover {
    color: var(--accent);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: var(--radius-pill);
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.badge-published, .badge-approved { background: rgba(34, 197, 94, 0.12); color: #16a34a; }
.badge-draft, .badge-pending { background: rgba(245, 158, 11, 0.12); color: #d97706; }
.badge-private { background: rgba(99, 102, 161, 0.1); color: var(--text-secondary); }
.badge-spam { background: rgba(239, 68, 68, 0.1); color: #dc2626; }

/* ================================================================
   FOOTER — minimal, with gradient top border
   ================================================================ */
.site-footer {
    text-align: center;
    padding: 48px 20px 28px;
    position: relative;
}
.site-footer::before {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-gradient);
    border-radius: 2px;
    margin: 0 auto 20px;
}
.footer-inner p {
    font-size: 0.8rem;
    color: var(--text-muted);
    letter-spacing: 0.04em;
}

/* ================================================================
   FLOATING ACTION BUTTON — pill shape
   ================================================================ */
.fab {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 56px; height: 56px;
    border-radius: var(--radius-pill);
    background: var(--accent-gradient);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.3);
    transition: var(--transition);
    z-index: 50;
    text-decoration: none;
}
.fab:hover {
    transform: scale(1.08) translateY(-3px);
    box-shadow: 0 8px 32px rgba(139, 92, 246, 0.45);
}
.fab:active { transform: scale(0.94); }

/* ================================================================
   PAGINATION — pill-shaped links
   ================================================================ */
.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 40px;
    flex-wrap: wrap;
}
.page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 20px;
    border-radius: var(--radius-pill);
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-decoration: none;
    transition: var(--transition);
}
.page-link:hover {
    background: var(--accent-soft);
    color: var(--accent);
    border-color: transparent;
}
.page-link.active {
    background: var(--accent-gradient);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.25);
}

/* ================================================================
   MARKDOWN BODY
   ================================================================ */
.markdown-body {
    line-height: 1.9;
    font-size: 1.05rem;
    color: var(--text-primary);
    word-wrap: break-word;
}
.markdown-body h1, .markdown-body h2, .markdown-body h3,
.markdown-body h4, .markdown-body h5, .markdown-body h6 {
    font-family: var(--font-heading);
    margin-top: 1.6em;
    margin-bottom: 0.5em;
    line-height: 1.35;
}
.markdown-body h1 { font-size: 1.8rem; }
.markdown-body h2 { font-size: 1.5rem; }
.markdown-body h3 { font-size: 1.25rem; }
.markdown-body p { margin-bottom: 1.1em; }
.markdown-body ul, .markdown-body ol {
    padding-left: 1.6em;
    margin-bottom: 1.1em;
}
.markdown-body li { margin-bottom: 0.3em; }
.markdown-body blockquote {
    border-left: 3px solid var(--accent);
    padding: 10px 20px;
    margin: 1.2em 0;
    color: var(--text-secondary);
    background: var(--accent-soft);
    border-radius: 0 12px 12px 0;
}
.markdown-body code {
    font-family: var(--font-mono);
    font-size: 0.85em;
    padding: 2px 8px;
    background: rgba(99, 102, 161, 0.08);
    border-radius: 6px;
}
.markdown-body pre {
    margin: 1.2em 0;
    padding: 18px 22px;
    background: rgba(30, 27, 75, 0.03);
    border: 1px solid rgba(99, 102, 161, 0.1);
    border-radius: 14px;
    overflow-x: auto;
}
.markdown-body pre code {
    background: none;
    padding: 0;
    font-size: 0.85rem;
}
.markdown-body a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.markdown-body a:hover { color: #7c3aed; }
.markdown-body img {
    max-width: 100%;
    border-radius: 12px;
    margin: 1.2em 0;
}
.markdown-body hr {
    border: none;
    height: 1px;
    background: rgba(99, 102, 161, 0.12);
    margin: 2.2em 0;
}

/* ================================================================
   ANIMATIONS
   ================================================================ */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* SPA transition */
#app { display: none; }
.js-enabled #app { display: block; }
.js-enabled #ssr-landing { display: none; }


/* ================================================================
   Custom Select Dropdown
   ================================================================ */
.custom-select-wrap {
    position: relative;
    width: 100%;
}
.custom-select-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 12px 18px;
    background: rgba(255, 255, 255, 0.7);
    border: 1.5px solid rgba(99, 102, 161, 0.15);
    border-radius: 14px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
    gap: 8px;
}
.custom-select-trigger::after {
    content: '';
    width: 12px; height: 8px;
    flex-shrink: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236366a1' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center;
    transition: transform 0.2s ease;
}
.custom-select-trigger:hover {
    border-color: rgba(99, 102, 161, 0.3);
}
.custom-select-wrap.open .custom-select-trigger::after {
    transform: rotate(180deg);
}
.custom-select-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 50;
    background: white;
    border: 1px solid rgba(99, 102, 161, 0.12);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(100, 100, 150, 0.12);
    max-height: 220px;
    overflow-y: auto;
    display: none;
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity 0.15s ease, transform 0.15s ease;
}
.custom-select-dropdown.open {
    display: block;
    opacity: 1;
    transform: translateY(0);
}
.custom-select-option {
    padding: 10px 16px;
    font-size: 0.9rem;
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
}
.custom-select-option:hover {
    background: var(--accent-soft);
    color: var(--accent);
}
.custom-select-option.active {
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 600;
}
.custom-select-option:first-child {
    border-radius: 12px 12px 0 0;
}
.custom-select-option:last-child {
    border-radius: 0 0 12px 12px;
}
.custom-select-option:only-child {
    border-radius: 12px;
}

/* ================================================================
   User Avatar Floating Button
   ================================================================ */
.user-avatar-btn {
    position: fixed;
    left: 24px;
    top: 84px;
    z-index: 90;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.3);
    transition: var(--transition);
    cursor: pointer;
}
.user-avatar-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 24px rgba(139, 92, 246, 0.45);
}
.user-avatar-btn .avatar-initial {
    font-size: 1.1rem;
    font-weight: 700;
    font-family: var(--font-display);
}

/* ================================================================
   Profile Page
   ================================================================ */
.profile-page {
    max-width: 800px;
    margin: 28px auto 60px;
    padding: 0 24px;
    animation: fadeUp 0.4s ease;
}
.profile-header {
    display: flex;
    gap: 32px;
    padding: 32px 40px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    margin-bottom: 28px;
    align-items: flex-start;
}
.profile-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    min-width: 120px;
}
.profile-btn-row {
    display: flex;
    gap: 8px;
    margin-top: 2px;
}
.profile-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-top: 6px;
}
.profile-avatar {
    flex-shrink: 0;
}
.profile-avatar-initial {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 700;
    font-family: var(--font-display);
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.2);
}
.profile-avatar-img {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.15);
}
.profile-edit-form {
    padding: 24px 28px;
    margin-bottom: 28px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    animation: fadeUp 0.3s ease;
}
.profile-username-tag {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-weight: 500;
    text-align: center;
}
.profile-name {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}
.profile-bio {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
}
.profile-btn-row {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}
.profile-section-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.profile-posts {
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    overflow: hidden;
}
.profile-post-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 24px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
    border-bottom: 1px solid rgba(99, 102, 161, 0.04);
}
.profile-post-item:last-child {
    border-bottom: none;
}
.profile-post-item:hover {
    background: rgba(139, 92, 246, 0.03);
}
.profile-post-item:hover .profile-post-title {
    color: var(--accent);
}
.profile-post-title {
    font-size: 0.92rem;
    font-weight: 500;
    transition: var(--transition);
}
.profile-post-date {
    font-size: 0.78rem;
    color: var(--text-muted);
    flex-shrink: 0;
    margin-left: 16px;
}

/* ================================================================
   Toggle Switch (replaces checkbox for "remember me")
   ================================================================ */
.form-checkbox {
    display: flex;
    align-items: center;
}
.form-checkbox label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    cursor: pointer;
    margin-bottom: 0;
    line-height: 1.4;
    user-select: none;
}
/* Hidden native checkbox */
.form-checkbox input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}
/* Label acts as toggle container */
.form-checkbox label {
    position: relative;
    padding-left: 50px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    cursor: pointer;
    margin-bottom: 0;
    line-height: 1.4;
    user-select: none;
    min-height: 22px;
}
/* Toggle track */
.form-checkbox label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 22px;
    background: rgba(99, 102, 161, 0.2);
    border-radius: 11px;
    transition: background 0.25s ease;
    flex-shrink: 0;
}
/* Toggle knob */
.form-checkbox label::after {
    content: '';
    position: absolute;
    left: 2px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 50%;
    transition: left 0.25s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    z-index: 1;
}
/* Checked: track turns purple */
.form-checkbox input[type="checkbox"]:checked + label::before {
    background: var(--accent);
}
/* Checked: knob slides right */
.form-checkbox input[type="checkbox"]:checked + label::after {
    left: 20px;
}


/* ================================================================
   Custom CSS Modal
   ================================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(30, 27, 75, 0.35);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.15s ease;
}
.modal-box {
    background: white;
    border-radius: 20px;
    padding: 32px 36px 24px;
    max-width: 380px;
    width: 90%;
    box-shadow: 0 24px 64px rgba(30, 27, 75, 0.2);
    animation: modalPop 0.25s ease;
    text-align: center;
}
@keyframes modalPop {
    from { opacity: 0; transform: scale(0.92) translateY(12px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}
.modal-message {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 20px;
}
.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}
.modal-actions .btn {
    min-width: 80px;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 900px) {
    .admin-layout { flex-direction: column; }
    .admin-sidebar {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
        position: static;
        padding: 14px;
        border-radius: var(--radius-sm);
    }
    .admin-sidebar .admin-nav-item {
        padding: 6px 14px;
        font-size: 0.82rem;
    }
    .post-detail { padding: 32px 28px; }
    .comments-section { padding: 28px 24px; }
    .post-title { font-size: 1.6rem; }
}

@media (max-width: 768px) {
    .home-welcome { padding: 32px 16px 24px; }
    .home-title { font-size: 1.5rem; }
    .ssr-posts {
        grid-template-columns: 1fr;
        gap: 18px;
        margin-top: 24px;
    }
    .ssr-post { padding: 22px 20px 26px; }
    .ssr-landing { padding: 0 16px 50px; }

    .header-inner {
        padding: 0 14px;
        height: 54px;
    }
    .site-logo .logo-text { font-size: 1rem; }
    .site-logo .logo-badge { width: 32px; height: 32px; }
    .site-logo .logo-badge::after { width: 8px; height: 8px; top: -3px; right: -3px; }
    .nav-link { padding: 6px 12px; font-size: 0.82rem; }

    .fab {
        bottom: 20px; right: 20px;
        width: 50px; height: 50px;
    }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .auth-card { padding: 32px 24px; }
    .editor-form { padding: 20px; }
    .editor-header { padding: 14px 18px; }
    .form-row { flex-direction: column; gap: 0; }
    .comment-form .guest-fields { flex-direction: column; gap: 8px; }
    .admin-table { font-size: 0.78rem; }
    .admin-table th, .admin-table td { padding: 8px 10px; }
    .ssr-nav-header { padding: 10px 14px; }
}

@media (max-width: 480px) {
    .post-detail,
    .comments-section {
        padding: 20px 16px;
        border-radius: 12px;
    }
    .ssr-post h2 { font-size: 1.05rem; }
    .nav-link span:not(.icon) { display: none; }
    .post-title { font-size: 1.3rem; }
}
