/* ============================================
   KREVIA BLOG STYLES
   ============================================ */

/* ----------------------------------------
   Resources Experience
   ---------------------------------------- */
.resources-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(132px, 16vw, 190px) 0 clamp(56px, 7vw, 96px);
    background:
        radial-gradient(circle at 20% 15%, rgba(181, 74, 74, 0.14), transparent 34%),
        radial-gradient(circle at 82% 28%, rgba(10, 10, 10, 0.08), transparent 30%),
        linear-gradient(180deg, #f7f4f2 0%, #ffffff 62%, #faf8f7 100%);
    border-bottom: 1px solid rgba(10, 10, 10, 0.08);
}

.resources-hero::before,
.resources-hero::after {
    content: '';
    position: absolute;
    inset: auto;
    pointer-events: none;
}

.resources-hero::before {
    top: 0;
    right: min(6vw, 64px);
    width: min(36vw, 420px);
    height: 100%;
    background-image:
        linear-gradient(rgba(10, 10, 10, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(10, 10, 10, 0.06) 1px, transparent 1px);
    background-size: 28px 28px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent 90%);
}

.resources-hero::after {
    left: max(-6vw, -90px);
    bottom: min(8vw, 72px);
    width: min(30vw, 360px);
    aspect-ratio: 1;
    border: 1px solid rgba(10, 10, 10, 0.08);
    border-radius: 999px;
    box-shadow:
        0 0 0 28px rgba(255, 255, 255, 0.42),
        0 0 0 56px rgba(181, 74, 74, 0.06);
}

.resources-hero-shell {
    position: relative;
    max-width: 860px;
    z-index: 1;
}

.resources-eyebrow,
.resources-kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--accent-dark);
}

.resources-eyebrow::before,
.resources-kicker::before {
    content: '';
    width: 44px;
    height: 1px;
    background: currentColor;
}

.resources-title {
    margin-top: 18px;
    font-size: clamp(4rem, 13vw, 8.6rem);
    line-height: 0.92;
    letter-spacing: -0.08em;
    font-weight: 900;
    color: var(--black);
}

.resources-subtext {
    max-width: 560px;
    margin-top: 22px;
    font-size: clamp(1rem, 2vw, 1.18rem);
    line-height: 1.75;
    color: var(--grey-600);
}

.resources-featured-section {
    padding-top: 34px;
}

.resources-browser-section {
    background:
        linear-gradient(180deg, rgba(250, 248, 247, 0.8) 0%, #ffffff 25%, #ffffff 100%);
}

.resources-section-head,
.resources-browser-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 28px;
}

.resources-section-title {
    margin-top: 12px;
    max-width: 760px;
    font-size: clamp(1.8rem, 4vw, 3.1rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.resources-section-note,
.resources-results {
    max-width: 360px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--grey-500);
    text-align: right;
}

.featured-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 32px;
    background:
        radial-gradient(circle at top left, rgba(181, 74, 74, 0.26), transparent 36%),
        linear-gradient(135deg, #131313 0%, #181818 48%, #101010 100%);
    color: var(--white);
    box-shadow: 0 30px 60px rgba(10, 10, 10, 0.12);
}

.featured-stage {
    overflow: hidden;
}

.featured-track {
    display: flex;
    transition: transform 0.75s var(--ease-out-expo);
    will-change: transform;
}

.featured-slide {
    min-width: 100%;
}

.featured-slide-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
    min-height: 540px;
}

.featured-copy {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(32px, 5vw, 56px);
    z-index: 1;
}

.featured-copy::after {
    content: '';
    position: absolute;
    left: clamp(24px, 4vw, 42px);
    bottom: clamp(26px, 4vw, 40px);
    width: 120px;
    height: 120px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(181, 74, 74, 0.2), transparent 70%);
    filter: blur(12px);
    z-index: -1;
}

.featured-topline,
.featured-meta,
.resource-row-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.featured-topline,
.featured-meta {
    color: rgba(255, 255, 255, 0.72);
}

.featured-index {
    color: rgba(255, 255, 255, 0.46);
}

.featured-type {
    color: rgba(255, 255, 255, 0.86);
}

.featured-label {
    margin-top: 22px;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.58);
}

.featured-title {
    margin-top: 16px;
    font-size: clamp(2rem, 4.8vw, 4rem);
    line-height: 0.98;
    letter-spacing: -0.06em;
    max-width: 12ch;
}

.featured-excerpt {
    max-width: 46ch;
    margin-top: 18px;
    font-size: 1rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.74);
}

.featured-meta {
    margin-top: 24px;
}

.featured-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    margin-top: 28px;
    padding: 12px 18px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--white);
    font-weight: 600;
    transition: transform var(--duration-fast) var(--ease-out-expo),
                background var(--duration-fast) var(--ease-out-expo);
}

.featured-link:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.14);
}

.featured-link svg {
    width: 16px;
    height: 16px;
}

.featured-media {
    position: relative;
    overflow: hidden;
    min-height: 100%;
    background: rgba(255, 255, 255, 0.03);
}

.featured-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(16, 16, 16, 0.18) 0%, rgba(16, 16, 16, 0) 26%);
}

.featured-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.4);
}

.featured-image-placeholder svg {
    width: 56px;
    height: 56px;
}

.featured-slide-empty .featured-slide-shell {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.72fr);
    min-height: 420px;
}

.featured-media-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
}

.featured-placeholder-grid {
    width: min(82%, 320px);
    aspect-ratio: 1;
    border-radius: 28px;
    background:
        linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px);
    background-size: 22px 22px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.featured-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 24px 24px;
}

.featured-control-btn {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.86);
    transition: background var(--duration-fast) var(--ease-out-expo),
                transform var(--duration-fast) var(--ease-out-expo);
}

.featured-control-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

.featured-control-btn svg {
    width: 18px;
    height: 18px;
}

.featured-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex: 1;
}

.featured-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.26);
    transition: transform var(--duration-fast) var(--ease-out-expo),
                background var(--duration-fast) var(--ease-out-expo);
}

.featured-dot.active {
    background: var(--white);
    transform: scale(1.45);
}

.resources-filters {
    display: grid;
    gap: 20px;
    margin-bottom: 34px;
    padding: 26px;
    border: 1px solid rgba(10, 10, 10, 0.08);
    border-radius: 28px;
    background:
        linear-gradient(180deg, rgba(250, 248, 247, 0.72) 0%, rgba(255, 255, 255, 0.96) 100%);
}

.resources-search {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border: 1px solid rgba(10, 10, 10, 0.08);
    border-radius: 18px;
    background: var(--white);
}

.resources-search svg {
    width: 18px;
    height: 18px;
    color: var(--grey-500);
    flex-shrink: 0;
}

.resources-search input,
.resources-sort select {
    width: 100%;
    border: none;
    background: transparent;
    font: inherit;
    color: var(--black);
}

.resources-search input:focus,
.resources-sort select:focus {
    outline: none;
}

.resources-filter-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
}

.resources-type-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.resources-pill {
    padding: 10px 16px;
    border: 1px solid rgba(10, 10, 10, 0.08);
    border-radius: 999px;
    background: var(--white);
    color: var(--grey-600);
    font-size: 0.9rem;
    font-weight: 600;
    transition: all var(--duration-fast) var(--ease-out-expo);
}

.resources-pill:hover,
.resources-pill.active {
    border-color: rgba(181, 74, 74, 0.26);
    background: rgba(181, 74, 74, 0.08);
    color: var(--accent-dark);
}

.resources-sort {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 14px;
    border: 1px solid rgba(10, 10, 10, 0.08);
    background: var(--white);
}

.resources-sort span {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--grey-500);
}

.resources-list {
    display: grid;
    gap: 18px;
}

.resource-row {
    display: grid;
    grid-template-columns: minmax(240px, 320px) minmax(0, 1fr);
    gap: 24px;
    padding: 20px;
    border: 1px solid rgba(10, 10, 10, 0.08);
    border-radius: 28px;
    background:
        linear-gradient(180deg, rgba(250, 248, 247, 0.68) 0%, rgba(255, 255, 255, 1) 72%);
    transition: transform var(--duration-medium) var(--ease-out-expo),
                border-color var(--duration-medium) var(--ease-out-expo),
                box-shadow var(--duration-medium) var(--ease-out-expo);
}

.resource-row:hover {
    transform: translateY(-6px);
    border-color: rgba(181, 74, 74, 0.18);
    box-shadow: 0 22px 48px rgba(10, 10, 10, 0.08);
}

.resource-row-media {
    overflow: hidden;
    border-radius: 20px;
    background: linear-gradient(135deg, var(--grey-100), #f1eceb);
}

.resource-row-image {
    width: 100%;
    height: 100%;
    min-height: 230px;
    object-fit: cover;
    transition: transform var(--duration-slow) var(--ease-out-expo);
}

.resource-row:hover .resource-row-image {
    transform: scale(1.03);
}

.resource-row-image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--grey-400);
}

.resource-row-image-placeholder svg {
    width: 48px;
    height: 48px;
}

.resource-row-content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-width: 0;
}

.resource-row-meta {
    color: var(--grey-500);
}

.resource-label-pill {
    display: inline-flex;
    align-items: center;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(181, 74, 74, 0.1);
    color: var(--accent-dark);
}

.resource-row-title {
    margin-top: 18px;
    font-size: clamp(1.5rem, 3vw, 2.3rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.resource-row-title a {
    transition: color var(--duration-fast) var(--ease-out-expo);
}

.resource-row:hover .resource-row-title a {
    color: var(--accent-dark);
}

.resource-row-excerpt {
    max-width: 58ch;
    margin-top: 16px;
    font-size: 1rem;
    line-height: 1.75;
    color: var(--grey-600);
}

.resource-row-footer {
    margin-top: 24px;
}

.resource-row-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--black);
    font-weight: 700;
    letter-spacing: 0.02em;
}

.resource-row-link svg {
    width: 16px;
    height: 16px;
    transition: transform var(--duration-fast) var(--ease-out-expo);
}

.resource-row:hover .resource-row-link svg {
    transform: translateX(4px);
}

#post-label {
    font-weight: 700;
    color: var(--accent-dark);
}

.blog-post-type {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    margin-bottom: 18px;
    border-radius: 999px;
    background: rgba(181, 74, 74, 0.1);
    color: var(--accent-dark);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

@media (max-width: 1024px) {
    .resources-section-head,
    .resources-browser-head,
    .featured-slide-shell,
    .resource-row {
        grid-template-columns: 1fr;
    }

    .resources-section-head,
    .resources-browser-head {
        display: grid;
    }

    .resources-section-note,
    .resources-results {
        text-align: left;
        max-width: none;
    }

    .featured-slide-shell {
        min-height: auto;
    }

    .featured-media {
        min-height: 320px;
    }
}

@media (max-width: 768px) {
    .resources-hero {
        padding-top: 128px;
    }

    .resources-title {
        letter-spacing: -0.06em;
    }

    .featured-copy,
    .resources-filters,
    .resource-row {
        padding: 18px;
    }

    .featured-controls {
        padding: 16px 18px 18px;
    }

    .resources-filter-row {
        align-items: stretch;
    }

    .resources-sort {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 640px) {
    .resources-eyebrow::before,
    .resources-kicker::before {
        width: 26px;
    }

    .featured-slide-shell {
        display: flex;
        flex-direction: column;
    }

    .featured-media {
        order: -1;
        min-height: 220px;
    }

    .featured-copy {
        padding: 22px 20px 18px;
    }

    .featured-title {
        max-width: none;
        font-size: clamp(1.85rem, 9vw, 2.5rem);
    }

    .featured-excerpt {
        margin-top: 14px;
        font-size: 0.95rem;
        line-height: 1.65;
    }

    .featured-link {
        margin-top: 20px;
        padding: 11px 16px;
    }

    .featured-control-btn {
        width: 40px;
        height: 40px;
    }

    .featured-dots {
        gap: 8px;
    }

    .featured-controls {
        padding: 12px 16px 16px;
    }

    .resource-row-image {
        min-height: 210px;
    }
}

/* ----------------------------------------
   Blog Grid (Public Blog Listing)
   ---------------------------------------- */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-top: 48px;
}

@media (max-width: 1024px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

@media (max-width: 640px) {
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

.blog-card {
    background: var(--white);
    border: 1px solid var(--grey-200);
    border-radius: 12px;
    overflow: hidden;
    transition: transform var(--duration-medium) var(--ease-out-expo),
                box-shadow var(--duration-medium) var(--ease-out-expo);
    cursor: pointer;
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.blog-card-image {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    background: var(--grey-100);
}

.blog-card-image.placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--grey-100), var(--grey-200));
}

.blog-card-image.placeholder svg {
    width: 48px;
    height: 48px;
    color: var(--grey-400);
}

.blog-card-content {
    padding: 24px;
}

.blog-card-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 0.8125rem;
    color: var(--grey-500);
}

.blog-card-date {
    display: flex;
    align-items: center;
    gap: 6px;
}

.blog-card-reading-time {
    display: flex;
    align-items: center;
    gap: 6px;
}

.blog-card-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 12px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card-excerpt {
    font-size: 0.9375rem;
    color: var(--grey-600);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-card-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--accent);
    transition: gap var(--duration-fast) var(--ease-out-expo);
}

.blog-card:hover .blog-card-link {
    gap: 12px;
}

.blog-card-link svg {
    width: 16px;
    height: 16px;
}

/* Empty State */
.blog-empty {
    text-align: center;
    padding: 80px 20px;
    color: var(--grey-500);
}

.blog-empty svg {
    width: 64px;
    height: 64px;
    margin-bottom: 24px;
    color: var(--grey-300);
}

.blog-empty h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--grey-700);
    margin-bottom: 8px;
}

/* ----------------------------------------
   Single Post View
   ---------------------------------------- */
.blog-post {
    max-width: 800px;
    margin: 0 auto;
    padding-top: 40px;
}

.blog-post-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--grey-600);
    margin-bottom: 32px;
    transition: color var(--duration-fast);
}

.blog-post-back:hover {
    color: var(--accent);
}

.blog-post-back svg {
    width: 18px;
    height: 18px;
}

.blog-post-header {
    margin-bottom: 40px;
}

.blog-post-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    font-size: 0.875rem;
    color: var(--grey-500);
}

.blog-post-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: var(--black);
    line-height: 1.2;
    margin-bottom: 20px;
}

.blog-post-excerpt {
    font-size: 1.25rem;
    color: var(--grey-600);
    line-height: 1.6;
}

.blog-post-cover {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 48px;
}

/* ----------------------------------------
   Prose Styles (Post Content)
   ---------------------------------------- */
.prose {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--grey-800);
}

.prose h1,
.prose h2,
.prose h3,
.prose h4 {
    color: var(--black);
    font-weight: 600;
    margin-top: 2em;
    margin-bottom: 0.75em;
    line-height: 1.3;
}

.prose h1 { font-size: 2rem; }
.prose h2 { font-size: 1.5rem; }
.prose h3 { font-size: 1.25rem; }
.prose h4 { font-size: 1.125rem; }

.prose p {
    margin-bottom: 1.5em;
}

.prose a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.prose a:hover {
    color: var(--accent-dark);
}

.prose strong {
    font-weight: 600;
    color: var(--black);
}

.prose em {
    font-style: italic;
}

.prose ul,
.prose ol {
    margin-bottom: 1.5em;
    padding-left: 1.5em;
}

.prose li {
    margin-bottom: 0.5em;
}

.prose ul li {
    list-style-type: disc;
}

.prose ol li {
    list-style-type: decimal;
}

.prose blockquote {
    border-left: 4px solid var(--accent);
    padding-left: 24px;
    margin: 2em 0;
    font-style: italic;
    color: var(--grey-700);
}

.prose img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 2em 0;
}

.prose pre {
    background: var(--grey-900);
    color: var(--grey-100);
    padding: 20px 24px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 2em 0;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
}

.prose code {
    background: var(--grey-100);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Monaco', 'Menlo', monospace;
    font-size: 0.875em;
}

.prose pre code {
    background: none;
    padding: 0;
}

.prose hr {
    border: none;
    border-top: 1px solid var(--grey-200);
    margin: 3em 0;
}

/* ============================================
   ADMIN DASHBOARD STYLES
   ============================================ */

/* ----------------------------------------
   Admin Login
   ---------------------------------------- */
.admin-login {
    max-width: 400px;
    margin: 0 auto;
    padding: 48px 32px;
    background: var(--white);
    border: 1px solid var(--grey-200);
    border-radius: 16px;
}

.admin-login h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 8px;
    text-align: center;
}

.admin-login p {
    color: var(--grey-600);
    text-align: center;
    margin-bottom: 32px;
}

.admin-login .form-group {
    margin-bottom: 20px;
}

.admin-login .btn {
    width: 100%;
    justify-content: center;
}

.admin-login-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.875rem;
    margin-bottom: 20px;
    display: none;
}

.admin-login-error.show {
    display: block;
}

/* ----------------------------------------
   Admin Dashboard
   ---------------------------------------- */
.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 32px;
    flex-wrap: wrap;
}

.admin-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--black);
}

.admin-actions {
    display: flex;
    gap: 12px;
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.875rem;
    color: var(--grey-600);
}

.admin-user-avatar {
    width: 32px;
    height: 32px;
    background: var(--accent);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
}

/* ----------------------------------------
   Posts Table
   ---------------------------------------- */
.admin-table-wrapper {
    background: var(--white);
    border: 1px solid var(--grey-200);
    border-radius: 12px;
    overflow-x: auto;
    overflow-y: hidden;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid var(--grey-100);
}

.admin-table th {
    background: var(--grey-50);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--grey-500);
}

.admin-table td {
    font-size: 0.9375rem;
    color: var(--grey-700);
}

.admin-table tbody tr:hover {
    background: var(--grey-50);
}

.admin-table tbody tr:last-child td {
    border-bottom: none;
}

.admin-post-title {
    font-weight: 500;
    color: var(--black);
    max-width: 300px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-post-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.admin-post-status.draft {
    background: var(--grey-100);
    color: var(--grey-600);
}

.admin-post-status.published {
    background: #dcfce7;
    color: #16a34a;
}

.admin-post-actions {
    display: flex;
    gap: 8px;
    min-width: 148px;
    justify-content: flex-end;
}

.admin-btn-icon {
    width: 36px;
    height: 36px;
    border: 1px solid var(--grey-200);
    border-radius: 8px;
    background: var(--white);
    color: var(--grey-600);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--duration-fast);
}

.admin-btn-icon:hover {
    border-color: var(--grey-300);
    color: var(--black);
}

.admin-btn-icon.delete:hover {
    border-color: #fecaca;
    background: #fef2f2;
    color: #dc2626;
}

.admin-btn-icon svg {
    width: 18px;
    height: 18px;
}

/* Responsive Table */
@media (max-width: 768px) {
    .admin-table-wrapper {
        overflow-x: auto;
    }

    .admin-table {
        min-width: 600px;
    }
}

/* ----------------------------------------
   Editor Modal
   ---------------------------------------- */
.editor-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all var(--duration-medium);
}

.editor-overlay.show {
    opacity: 1;
    visibility: visible;
}

.editor-modal {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    max-width: 900px;
    height: 100vh;
    background: var(--white);
    z-index: 1001;
    transform: translateX(100%);
    transition: transform var(--duration-medium) var(--ease-out-expo);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.editor-overlay.show + .editor-modal,
.editor-modal.show {
    transform: translateX(0);
}

.editor-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 32px;
    border-bottom: 1px solid var(--grey-200);
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 10;
}

.editor-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--black);
}

.editor-header-actions {
    display: flex;
    gap: 12px;
}

.editor-close {
    width: 40px;
    height: 40px;
    border: none;
    background: none;
    color: var(--grey-500);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all var(--duration-fast);
}

.editor-close:hover {
    background: var(--grey-100);
    color: var(--black);
}

.editor-close svg {
    width: 24px;
    height: 24px;
}

.editor-body {
    flex: 1;
    padding: 32px;
    overflow-y: auto;
}

.editor-field {
    margin-bottom: 24px;
}

.editor-field label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--grey-700);
    margin-bottom: 8px;
}

.editor-field input,
.editor-field textarea,
.editor-field select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--grey-200);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color var(--duration-fast);
}

.editor-field input:focus,
.editor-field textarea:focus,
.editor-field select:focus {
    outline: none;
    border-color: var(--accent);
}

.editor-field textarea {
    resize: vertical;
    min-height: 100px;
}

.editor-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.editor-featured-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
    gap: 20px;
    align-items: start;
    padding: 20px;
    margin-bottom: 24px;
    border: 1px solid var(--grey-200);
    border-radius: 14px;
    background: linear-gradient(180deg, #fff9f8 0%, #ffffff 100%);
}

.editor-checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--grey-700);
    cursor: pointer;
}

.editor-checkbox input {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
}

.editor-featured-slot {
    margin-bottom: 0;
    display: none;
}

.editor-featured-slot.is-visible {
    display: block;
}

.editor-field-help {
    margin-top: 8px;
    font-size: 0.8125rem;
    line-height: 1.6;
    color: var(--grey-500);
}

@media (max-width: 640px) {
    .editor-field-row {
        grid-template-columns: 1fr;
    }

    .editor-featured-panel {
        grid-template-columns: 1fr;
    }
}

/* Cover Image Upload */
.cover-upload {
    border: 2px dashed var(--grey-300);
    border-radius: 12px;
    padding: 32px;
    text-align: center;
    cursor: pointer;
    transition: all var(--duration-fast);
    position: relative;
    overflow: hidden;
}

.cover-upload:hover {
    border-color: var(--accent);
    background: var(--grey-50);
}

.cover-upload.has-image {
    padding: 0;
    border-style: solid;
}

.cover-upload-preview {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.cover-upload-placeholder svg {
    width: 48px;
    height: 48px;
    color: var(--grey-400);
    margin-bottom: 12px;
}

.cover-upload-placeholder p {
    color: var(--grey-600);
    font-size: 0.9375rem;
}

.cover-upload-placeholder span {
    color: var(--accent);
    font-weight: 500;
}

.cover-upload-remove {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    background: var(--white);
    border: 1px solid var(--grey-200);
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--duration-fast);
}

.cover-upload-remove:hover {
    background: #fef2f2;
    border-color: #fecaca;
    color: #dc2626;
}

.cover-upload input[type="file"] {
    display: none;
}

/* Status Toggle */
.status-toggle {
    display: flex;
    gap: 12px;
}

.status-option {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--grey-200);
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all var(--duration-fast);
    font-size: 0.875rem;
    font-weight: 500;
}

.status-option:hover {
    border-color: var(--grey-300);
}

.status-option.active {
    border-color: var(--accent);
    background: var(--accent);
    color: white;
}

.status-option input {
    display: none;
}

/* ----------------------------------------
   TipTap Editor
   ---------------------------------------- */
.tiptap-wrapper {
    border: 1px solid var(--grey-200);
    border-radius: 12px;
    overflow: hidden;
}

.tiptap-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 12px;
    background: var(--grey-50);
    border-bottom: 1px solid var(--grey-200);
}

.tiptap-toolbar-group {
    display: flex;
    gap: 4px;
    padding-right: 12px;
    margin-right: 8px;
    border-right: 1px solid var(--grey-200);
}

.tiptap-toolbar-group:last-child {
    border-right: none;
    padding-right: 0;
    margin-right: 0;
}

.tiptap-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--grey-600);
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--duration-fast);
}

.tiptap-btn:hover {
    background: var(--grey-200);
    color: var(--black);
}

.tiptap-btn.active {
    background: var(--accent);
    color: white;
}

.tiptap-btn svg {
    width: 18px;
    height: 18px;
}

.tiptap-editor {
    min-height: 400px;
    padding: 20px 24px;
    font-size: 1rem;
    line-height: 1.7;
    outline: none;
}

.tiptap-editor:focus {
    outline: none;
}

.tiptap-editor p.is-editor-empty:first-child::before {
    content: attr(data-placeholder);
    color: var(--grey-400);
    pointer-events: none;
    height: 0;
    float: left;
}

/* TipTap Content Styles */
.tiptap-editor h1 { font-size: 2rem; font-weight: 700; margin: 1em 0 0.5em; }
.tiptap-editor h2 { font-size: 1.5rem; font-weight: 600; margin: 1em 0 0.5em; }
.tiptap-editor h3 { font-size: 1.25rem; font-weight: 600; margin: 1em 0 0.5em; }
.tiptap-editor p { margin-bottom: 1em; }
.tiptap-editor ul, .tiptap-editor ol { padding-left: 1.5em; margin-bottom: 1em; }
.tiptap-editor li { margin-bottom: 0.25em; }
.tiptap-editor blockquote { border-left: 4px solid var(--accent); padding-left: 20px; margin: 1em 0; color: var(--grey-600); font-style: italic; }
.tiptap-editor a { color: var(--accent); text-decoration: underline; }
.tiptap-editor img { max-width: 100%; height: auto; border-radius: 8px; margin: 1em 0; }
.tiptap-editor code { background: var(--grey-100); padding: 2px 6px; border-radius: 4px; font-family: monospace; }
.tiptap-editor pre { background: var(--grey-900); color: var(--grey-100); padding: 16px 20px; border-radius: 8px; overflow-x: auto; margin: 1em 0; }
.tiptap-editor pre code { background: none; padding: 0; }

/* Image uploading state */
.tiptap-editor .uploading-image {
    display: inline-block;
    background: var(--grey-100);
    border-radius: 8px;
    padding: 40px;
    color: var(--grey-500);
    font-size: 0.875rem;
}

/* Link Input Modal */
.link-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--white);
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    z-index: 1100;
    width: 90%;
    max-width: 400px;
    display: none;
}

.link-modal.show {
    display: block;
}

.link-modal h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.link-modal input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--grey-200);
    border-radius: 8px;
    font-size: 1rem;
    margin-bottom: 16px;
}

.link-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* ----------------------------------------
   Loading & Empty States
   ---------------------------------------- */
.admin-loading,
.admin-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--grey-500);
}

.admin-loading svg,
.admin-empty svg {
    width: 48px;
    height: 48px;
    margin-bottom: 16px;
    color: var(--grey-300);
}

.admin-loading svg {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ----------------------------------------
   Confirm Dialog
   ---------------------------------------- */
.confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1100;
    display: none;
    align-items: center;
    justify-content: center;
}

.confirm-overlay.show {
    display: flex;
}

.confirm-dialog {
    background: var(--white);
    padding: 32px;
    border-radius: 16px;
    max-width: 400px;
    width: 90%;
    text-align: center;
}

.confirm-dialog svg {
    width: 48px;
    height: 48px;
    color: #dc2626;
    margin-bottom: 16px;
}

.confirm-dialog h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 8px;
}

.confirm-dialog p {
    color: var(--grey-600);
    margin-bottom: 24px;
}

.confirm-dialog-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.btn-danger {
    background: #dc2626;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: background var(--duration-fast);
}

.btn-danger:hover {
    background: #b91c1c;
}

/* ----------------------------------------
   Toast Notifications
   ---------------------------------------- */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1200;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toast {
    background: var(--grey-900);
    color: white;
    padding: 16px 20px;
    border-radius: 8px;
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: slideIn var(--duration-medium) var(--ease-out-expo);
}

.toast.success {
    background: #16a34a;
}

.toast.error {
    background: #dc2626;
}

.toast svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ----------------------------------------
   Utility Classes
   ---------------------------------------- */
.hidden {
    display: none !important;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
