/**
 * BlogCMS — Premium Luxury Design System
 * Public site + shared tokens
 */

:root {
    --primary: #7C3AED;
    --indigo: #4F46E5;
    --accent-pink: #EC4899;
    --accent-orange: #F97316;

    --bg: #F8FAFC;
    --section: #F5F3FF;
    --card: #FFFFFF;
    --sidebar: #1E1B4B;

    --heading: #111827;
    --text: #6B7280;
    --border: #E5E7EB;
    --border-input: #D1D5DB;

    --success: #10B981;
    --warning: #F59E0B;
    --danger: #EF4444;
    --info: #3B82F6;

    --gradient-primary: linear-gradient(135deg, #7C3AED 0%, #4F46E5 50%, #EC4899 100%);
    --gradient-secondary: linear-gradient(90deg, #4F46E5, #7C3AED);
    --gradient-soft: linear-gradient(135deg, rgba(124, 58, 237, 0.08), rgba(236, 72, 153, 0.06));

    --shadow-sm: 0 8px 24px rgba(17, 24, 39, 0.04);
    --shadow-md: 0 15px 40px rgba(17, 24, 39, 0.06);
    --shadow-lg: 0 24px 60px rgba(17, 24, 39, 0.10);
    --shadow-glow: 0 15px 35px rgba(124, 58, 237, 0.25);

    --radius-sm: 12px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;

    --font-display: "Manrope", system-ui, sans-serif;
    --font-body: "Inter", system-ui, sans-serif;

    --space-1: 8px;
    --space-2: 16px;
    --space-3: 24px;
    --space-4: 32px;
    --space-5: 48px;
    --space-6: 64px;

    --transition: 300ms ease;

    /* Site logo size — edit these two values */
    --logo-width: 130px;
    --logo-height: 80px;

    /* Public header — edit colors here */
    --header-bg: linear-gradient(135deg, #1e1b4b 0%, #312e81 48%, #4c1d95 100%);
    --header-border: rgba(236, 72, 153, 0.35);
    --header-text: #e0e7ff;
    --header-text-hover: #ffffff;
    --header-link-bg: rgba(255, 255, 255, 0.08);
    --header-link-active: rgba(124, 58, 237, 0.45);

    /* Public footer — edit colors here */
    --footer-bg: linear-gradient(180deg, #1e1b4b 0%, #151338 55%, #0f0d24 100%);
    --footer-accent: rgba(236, 72, 153, 0.45);
    --footer-text: #c7d2fe;
    --footer-heading: #a5b4fc;
}

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

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.65;
    color: var(--text);
    background:
        radial-gradient(ellipse 80% 50% at 10% -10%, rgba(124, 58, 237, 0.10), transparent 50%),
        radial-gradient(ellipse 60% 40% at 90% 0%, rgba(236, 72, 153, 0.08), transparent 45%),
        var(--bg);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6,
.brand,
.display-title {
    font-family: var(--font-display);
    color: var(--heading);
    letter-spacing: -0.03em;
    font-weight: 700;
    line-height: 1.15;
}

h1, .h1-lux { font-size: clamp(2.25rem, 5vw, 3.5rem); } /* ~56px */
h2, .h2-lux { font-size: clamp(1.85rem, 3.5vw, 2.625rem); } /* ~42px */
h3, .h3-lux { font-size: clamp(1.5rem, 2.5vw, 2rem); } /* ~32px */
h4, .h4-lux { font-size: 1.5rem; } /* 24px */

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--indigo);
}

img {
    max-width: 100%;
    display: block;
}

/* ---------- Buttons ---------- */
.btn-lux,
.btn-primary-lux {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 48px;
    padding: 0.75rem 1.5rem;
    border: 0;
    border-radius: var(--radius-md);
    background: var(--gradient-primary);
    color: #fff !important;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    box-shadow: var(--shadow-glow);
    transition: transform var(--transition), box-shadow var(--transition), filter var(--transition);
    text-decoration: none !important;
    cursor: pointer;
}

.btn-lux:hover,
.btn-primary-lux:hover {
    transform: scale(1.03);
    box-shadow: 0 18px 40px rgba(124, 58, 237, 0.35);
    color: #fff !important;
    filter: brightness(1.02);
}

.btn-lux-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 48px;
    padding: 0.75rem 1.4rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    color: var(--heading) !important;
    font-weight: 600;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
    text-decoration: none !important;
}

.btn-lux-ghost:hover {
    transform: translateY(-2px);
    border-color: #c4b5fd;
    box-shadow: var(--shadow-sm);
    color: var(--heading) !important;
}

/* Compatibility with older class names */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 48px;
    padding: 0.75rem 1.5rem;
    border: 0;
    border-radius: var(--radius-md);
    background: var(--gradient-primary);
    color: #fff;
    font-weight: 600;
    box-shadow: var(--shadow-glow);
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
    text-decoration: none;
}

.btn-primary:hover {
    transform: scale(1.03);
    color: #fff;
    text-decoration: none;
}

/* ---------- Cards ---------- */
.lux-card,
.blog-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 0;
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
}

.lux-card:hover,
.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.lux-card-pad {
    padding: 24px;
}

/* ---------- Inputs ---------- */
.form-control-lux,
.lux-input,
.search-overlay-form input,
.filters-bar input,
.filters-bar select,
.comment-form input,
.comment-form textarea,
.newsletter-box input,
.search-page-form input,
.sidebar-search input,
.sidebar-block input {
    width: 100%;
    min-height: 50px;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-input);
    border-radius: var(--radius-sm);
    background: #fff;
    color: var(--heading);
    font: inherit;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-control-lux:focus,
.lux-input:focus,
.search-overlay-form input:focus,
.filters-bar input:focus,
.filters-bar select:focus,
.comment-form input:focus,
.comment-form textarea:focus,
.newsletter-box input:focus,
.search-page-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.15);
}

textarea.lux-input,
.comment-form textarea {
    min-height: 140px;
    resize: vertical;
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--header-bg);
    border-bottom: 1px solid var(--header-border);
    box-shadow:
        0 10px 40px rgba(30, 27, 75, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-2);
    min-height: calc(var(--logo-height) + 24px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    flex-shrink: 0;
    font-size: 1.35rem;
    font-weight: 800;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-decoration: none;
}

.brand:has(.brand-logo) {
    background: none;
    -webkit-background-clip: unset;
    background-clip: unset;
    color: inherit;
}

/* Uses --logo-width / --logo-height from :root above */
.brand-logo {
    display: block;
    width: var(--logo-width);
    height: var(--logo-height);
    object-fit: contain;
    background: transparent;
    flex-shrink: 0;
}

.site-header .brand:not(:has(.brand-logo)) {
    background: linear-gradient(90deg, #ffffff, #e9d5ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand:hover {
    color: transparent;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.site-nav > a,
.nav-drop-btn {
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    border: 0;
    background: transparent;
    color: var(--header-text);
    font: inherit;
    font-weight: 500;
    font-size: 0.92rem;
    cursor: pointer;
    transition: background var(--transition), color var(--transition), box-shadow var(--transition);
    text-decoration: none;
}

.site-nav > a:hover,
.nav-drop-btn:hover {
    background: var(--header-link-bg);
    color: var(--header-text-hover);
    text-decoration: none;
}

.site-nav > a.is-active,
.nav-drop-btn.is-active {
    background: var(--header-link-active);
    color: var(--header-text-hover);
    font-weight: 600;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.site-header .icon-btn {
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.08);
    color: var(--header-text-hover);
}

.site-header .icon-btn:hover {
    background: rgba(255, 255, 255, 0.16);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.icon-btn {
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.8);
    color: var(--heading);
    cursor: pointer;
    transition: transform var(--transition), box-shadow var(--transition);
}

.icon-btn:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-sm);
}

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

.nav-toggle {
    display: none;
    border: 0;
    background: transparent;
    color: var(--header-text-hover);
    padding: 0.4rem;
}

.nav-toggle svg {
    width: 24px;
    height: 24px;
}

.nav-dropdown {
    position: relative;
}

.nav-drop-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 220px;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    z-index: 30;
}

.nav-dropdown:hover .nav-drop-menu,
.nav-dropdown:focus-within .nav-drop-menu {
    display: grid;
    gap: 0.15rem;
    animation: fadeSlide 0.25s ease;
}

.nav-drop-menu a {
    padding: 0.65rem 0.85rem;
    border-radius: 10px;
    color: var(--heading);
    font-weight: 500;
}

.nav-drop-menu a:hover {
    background: var(--section);
    color: var(--primary);
    text-decoration: none;
}

/* ---------- Search overlay ---------- */
.search-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: grid;
    place-items: start center;
    padding-top: 14vh;
    background: rgba(17, 24, 39, 0.45);
    backdrop-filter: blur(6px);
    animation: fadeIn 0.25s ease;
}

.search-overlay[hidden] {
    display: none;
}

.search-overlay-form {
    width: min(720px, 92%);
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 0.65rem;
    align-items: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.search-close {
    border: 0;
    background: transparent;
    color: var(--text);
    font-size: 1.25rem;
    cursor: pointer;
}

/* ---------- Hero ---------- */
.hero-lux,
.hero-slider {
    position: relative;
    min-height: clamp(420px, 68vh, 640px);
    overflow: hidden;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.7s ease;
}

.hero-slide.is-active {
    position: relative;
    opacity: 1;
}

.hero-media {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(120deg, rgba(30, 27, 75, 0.62) 0%, rgba(79, 70, 229, 0.38) 55%, rgba(236, 72, 153, 0.28) 100%);
}

.hero-content {
    position: relative;
    z-index: 1;
    min-height: clamp(420px, 68vh, 640px);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--space-6) var(--space-4) calc(var(--space-5) + 2.75rem);
    color: #fff;
}

.hero-content h1 {
    color: #fff;
    max-width: 16ch;
    margin: 0.75rem 0 1.25rem;
}

.hero-content .badge-cat {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.25);
}

.hero-dots {
    position: absolute;
    bottom: 1.75rem;
    left: 0;
    right: 0;
    display: flex;
    gap: 0.45rem;
    z-index: 2;
    padding-left: var(--space-4);
    padding-right: var(--space-4);
}

.hero-dots button {
    width: 10px;
    height: 10px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: width var(--transition), background var(--transition);
}

.hero-dots button.is-active {
    width: 28px;
    background: #fff;
}

/* ---------- Sections ---------- */
.section {
    padding: var(--space-6) 0;
}

.section-muted,
.section-soft {
    background: var(--section);
}

.section-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: var(--space-2);
    margin-bottom: var(--space-4);
}

.section-head h2 {
    margin: 0;
}

.section-head a {
    font-weight: 600;
}

.page-pad {
    padding: var(--space-5) 0 var(--space-6);
}

/* ---------- Side ads (Google AdSense) ---------- */
.site-shell {
    width: 100%;
}

.site-shell--ads {
    display: grid;
    grid-template-columns: minmax(120px, 160px) minmax(0, 1fr) minmax(120px, 160px);
    gap: 1rem;
    align-items: start;
    max-width: 1560px;
    margin: 0 auto;
    padding: 0 0.75rem;
}

.site-shell-main {
    min-width: 0;
}

.site-ad {
    position: relative;
    display: none;
}

.site-ad-inner {
    position: sticky;
    top: calc(var(--logo-height) + 36px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 0.35rem;
    border-radius: 16px;
    border: 1px solid rgba(229, 231, 235, 0.9);
    background: rgba(255, 255, 255, 0.82);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(8px);
}

.site-ad-label {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text);
    opacity: 0.65;
}

.site-ad-unit {
    width: 100%;
    min-height: 250px;
}

@media (min-width: 1280px) {
    .site-shell--ads .site-ad {
        display: block;
    }
}

@media (min-width: 1480px) {
    .site-shell--ads {
        grid-template-columns: 180px minmax(0, 1fr) 180px;
        gap: 1.25rem;
    }
}

@media (max-width: 1279px) {
    .site-shell--ads {
        display: block;
        max-width: none;
        padding: 0;
    }
}

/* ---------- Blog cards ---------- */
.blog-card-media {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    display: block;
}

.blog-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 500ms ease;
}

.blog-card:hover .blog-card-media img {
    transform: scale(1.05);
}

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

.blog-card-title {
    font-size: 1.2rem;
    margin: 0.55rem 0;
}

.blog-card-title a {
    color: var(--heading);
    text-decoration: none;
}

.blog-card-title a:hover {
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.blog-card-excerpt {
    color: var(--text);
    margin: 0 0 1rem;
}

.blog-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    color: var(--text);
    font-size: 0.85rem;
    margin-bottom: 0.85rem;
}

.badge-cat {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: var(--section);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
}

.badge-cat:hover {
    background: #ede9fe;
    color: var(--indigo);
    text-decoration: none;
}

.badge-guest {
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.7rem;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.14), rgba(236, 72, 153, 0.12));
    border: 1px solid rgba(124, 58, 237, 0.22);
    color: var(--primary);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.badge-guest-sm {
    font-size: 0.68rem;
    padding: 0.2rem 0.55rem;
    vertical-align: middle;
}

.text-link {
    font-weight: 600;
    color: var(--primary);
}

/* ---------- Categories ---------- */
.category-row .category-card,
.category-card {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 160px;
    padding: 1.25rem;
    border-radius: var(--radius-lg);
    background: var(--gradient-primary);
    color: #fff !important;
    text-decoration: none !important;
    box-shadow: var(--shadow-glow);
    transition: transform var(--transition), box-shadow var(--transition);
}

.category-card:nth-child(2) {
    background: linear-gradient(135deg, #4F46E5, #7C3AED);
}

.category-card:nth-child(3) {
    background: linear-gradient(135deg, #EC4899, #7C3AED);
}

.category-card:nth-child(4) {
    background: linear-gradient(135deg, #F97316, #EC4899);
}

.category-card:nth-child(5) {
    background: linear-gradient(135deg, #4F46E5, #EC4899);
}

.category-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 45px rgba(124, 58, 237, 0.3);
    color: #fff !important;
}

.category-card-name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.15rem;
}

.category-card-count {
    opacity: 0.9;
    font-size: 0.85rem;
}

/* ---------- Lists ---------- */
.ranked-list {
    margin: 0;
    padding-left: 1.25rem;
}

.ranked-list li {
    margin: 0.85rem 0;
    font-weight: 500;
}

.ranked-list a {
    color: var(--heading);
}

.popular-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.popular-list li a {
    display: grid;
    grid-template-columns: 72px 1fr auto;
    gap: 1rem;
    align-items: center;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 14px;
    color: var(--heading);
    text-decoration: none;
    transition: background var(--transition);
}

.popular-list li a:hover {
    background: var(--section);
}

.popular-list img {
    width: 72px;
    height: 54px;
    object-fit: cover;
    border-radius: 10px;
}

/* ---------- Newsletter ---------- */
.newsletter-section {
    padding: var(--space-5) 0 var(--space-6);
}

.newsletter-box {
    position: relative;
    overflow: hidden;
    padding: clamp(2rem, 5vw, 3.5rem);
    border-radius: var(--radius-xl);
    background: var(--gradient-primary);
    color: #fff;
    text-align: center;
    box-shadow: var(--shadow-glow);
}

.newsletter-box::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.18), transparent 40%);
    pointer-events: none;
}

.newsletter-box h2 {
    position: relative;
    color: #fff;
    margin: 0 0 0.5rem;
}

.newsletter-box form {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.newsletter-box input {
    min-width: min(340px, 100%);
    border: 0;
}

.newsletter-box .btn-primary,
.newsletter-box button[type="submit"],
.newsletter-box .btn-lux {
    background: #fff !important;
    color: var(--primary) !important;
    box-shadow: none;
}

.newsletter-box .btn-primary:hover,
.newsletter-box button[type="submit"]:hover,
.newsletter-box .btn-lux:hover {
    color: var(--indigo) !important;
    background: #fff !important;
}

.newsletter-box.compact {
    text-align: left;
    padding: 1.5rem;
    background: var(--card);
    color: inherit;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}

.newsletter-box.compact h3 {
    color: var(--heading);
}

.newsletter-box.compact::before {
    display: none;
}

.newsletter-box.compact form {
    display: grid;
}

.newsletter-box.compact .btn-primary,
.newsletter-box.compact button[type="submit"] {
    background: var(--gradient-primary);
    color: #fff;
}

/* ---------- Footer ---------- */
.site-footer {
    position: relative;
    margin-top: var(--space-4);
    padding: var(--space-6) 0 0;
    background: var(--footer-bg);
    color: var(--footer-text);
    border-top: 1px solid var(--footer-accent);
    overflow: hidden;
}

.site-footer::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 70% 55% at 50% 0%, rgba(124, 58, 237, 0.18), transparent 70%),
        radial-gradient(circle at 85% 80%, rgba(236, 72, 153, 0.08), transparent 45%);
    pointer-events: none;
}

.site-footer-glow {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: min(720px, 80%);
    height: 2px;
    background: linear-gradient(90deg, transparent, #ec4899, #7c3aed, #ec4899, transparent);
    box-shadow: 0 0 32px rgba(236, 72, 153, 0.45);
    pointer-events: none;
}

.footer-inner {
    position: relative;
    z-index: 1;
    padding-bottom: var(--space-5);
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.site-footer .brand {
    background: none;
    -webkit-background-clip: unset;
    background-clip: unset;
    color: #fff;
}

.footer-tagline {
    margin: 1rem 0 0;
    max-width: 34ch;
    line-height: 1.75;
    color: rgba(199, 210, 254, 0.88);
    font-size: 0.95rem;
}

.footer-heading {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 0.55rem;
    margin: 0 0 0.85rem;
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #fff;
    text-align: center;
}

.footer-heading::after {
    content: "";
    width: 48px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, #7c3aed, #ec4899);
    box-shadow: 0 0 16px rgba(236, 72, 153, 0.45);
}

.footer-connect {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1.5rem 1.25rem 1.65rem;
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(124, 58, 237, 0.1)),
        rgba(255, 255, 255, 0.03);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 18px 40px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(10px);
}

.footer-connect-text {
    margin: 0 0 1.35rem;
    max-width: 30ch;
    font-size: 0.92rem;
    line-height: 1.65;
    color: rgba(199, 210, 254, 0.82);
}

.footer-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.55rem;
}

.footer-social {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.85rem;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
}

.site-footer a {
    color: var(--footer-text);
    text-decoration: none;
    transition: color var(--transition), transform var(--transition), background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.footer-links a {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0;
    font-weight: 500;
    font-size: 0.95rem;
}

.footer-links a::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7c3aed, #ec4899);
    opacity: 0;
    transform: scale(0.5);
    transition: opacity var(--transition), transform var(--transition);
}

.footer-links a:hover {
    color: #fff;
    transform: translateX(4px);
}

.footer-links a:hover::before {
    opacity: 1;
    transform: scale(1);
}

.footer-social-link {
    position: relative;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.04));
    color: #fff;
    overflow: hidden;
    backdrop-filter: blur(8px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.14),
        0 8px 20px rgba(0, 0, 0, 0.16);
    transition:
        transform var(--transition),
        border-color var(--transition),
        box-shadow var(--transition),
        background var(--transition);
}

.footer-social-link::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.45), rgba(236, 72, 153, 0.35));
    opacity: 0;
    transition: opacity var(--transition);
}

.footer-social-link i,
.footer-social-link svg {
    position: relative;
    z-index: 1;
    display: block;
    width: 20px;
    height: 20px;
    margin: 0;
    stroke-width: 2;
    pointer-events: none;
}

.footer-social-link:hover {
    color: #fff;
    transform: translateY(-4px) scale(1.06);
}

.footer-social-link:hover::before {
    opacity: 1;
}

.footer-social-link--twitter:hover {
    border-color: rgba(29, 155, 240, 0.65);
    box-shadow: 0 14px 32px rgba(29, 155, 240, 0.32);
}

.footer-social-link--linkedin:hover {
    border-color: rgba(10, 102, 194, 0.65);
    box-shadow: 0 14px 32px rgba(10, 102, 194, 0.32);
}

.footer-social-link--facebook:hover {
    border-color: rgba(24, 119, 242, 0.65);
    box-shadow: 0 14px 32px rgba(24, 119, 242, 0.32);
}

.footer-social-link--instagram:hover {
    border-color: rgba(236, 72, 153, 0.65);
    box-shadow: 0 14px 32px rgba(236, 72, 153, 0.35);
}

.footer-social-link--youtube:hover {
    border-color: rgba(255, 0, 0, 0.55);
    box-shadow: 0 14px 32px rgba(255, 0, 0, 0.28);
}

.footer-social-link--github:hover {
    border-color: rgba(255, 255, 255, 0.45);
    box-shadow: 0 14px 32px rgba(255, 255, 255, 0.12);
}

.footer-bottom {
    position: relative;
    z-index: 1;
    padding: 1.35rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}

.footer-copy {
    margin: 0;
    font-size: 0.875rem;
    color: rgba(199, 210, 254, 0.72);
}

/* ---------- Filters / pagination ---------- */
.filters-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin: 1.5rem 0 2rem;
}

.filters-bar input,
.filters-bar select {
    width: auto;
    min-width: 160px;
    flex: 1 1 160px;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: center;
    margin-top: 2.5rem;
}

.pagination a {
    min-width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    padding: 0 0.75rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--heading);
    font-weight: 600;
    text-decoration: none;
    transition: transform var(--transition), box-shadow var(--transition);
}

.pagination a:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.pagination a.is-active {
    background: var(--gradient-primary);
    border-color: transparent;
    color: #fff;
    box-shadow: var(--shadow-glow);
}

.breadcrumb {
    color: var(--text);
    margin-bottom: 0.85rem;
    font-size: 0.9rem;
}

/* ---------- Single post ---------- */
.post-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 48px;
}

.post-featured {
    width: 100%;
    border-radius: var(--radius-lg);
    margin-bottom: 1.25rem;
    box-shadow: var(--shadow-md);
}

.post-meta,
.post-share,
.post-tags,
.post-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    margin: 1rem 0;
    align-items: center;
}

.post-nav {
    justify-content: space-between;
}

.prose {
    font-size: 1.05rem;
    color: #374151;
}

.prose pre {
    background: #1E1B4B;
    color: #e0e7ff;
    padding: 1.15rem;
    border-radius: 14px;
    overflow: auto;
}

.prose blockquote {
    border-left: 4px solid var(--primary);
    margin: 1.25rem 0;
    padding: 0.5rem 0 0.5rem 1.15rem;
    color: var(--text);
    background: var(--section);
    border-radius: 0 12px 12px 0;
}

.tag-chip {
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.3rem 0.85rem;
    font-size: 0.85rem;
    color: var(--heading);
    background: #fff;
}

.author-bio,
.comments-section,
.sidebar-block {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-md);
    margin: 1.5rem 0;
}

.author-avatar {
    width: 56px;
    height: 56px;
    border-radius: 999px;
    background: var(--gradient-primary);
    color: #fff;
    display: grid;
    place-items: center;
    overflow: hidden;
    font-weight: 700;
}

.author-avatar.lg {
    width: 100px;
    height: 100px;
    font-size: 2rem;
}

.author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.author-bio {
    display: flex;
    gap: 1rem;
    align-items: start;
}

.comment {
    padding: 0.9rem 0;
    border-bottom: 1px solid #F3F4F6;
}

.comment-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
}

.field-error {
    color: var(--danger);
    font-size: 0.85rem;
}

.post-sidebar {
    display: grid;
    gap: 1rem;
    align-content: start;
}

.sidebar-block ul {
    margin: 0;
    padding-left: 1rem;
}

.mini-posts {
    list-style: none;
    padding: 0;
}

.mini-posts li {
    margin: 0.65rem 0;
}

/* ---------- Banners ---------- */
.category-banner,
.author-banner,
.page-hero {
    position: relative;
    padding: var(--space-6) 0;
    color: #fff;
    background-color: #4F46E5;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.category-banner::before,
.page-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(30, 27, 75, 0.55), rgba(124, 58, 237, 0.35));
    pointer-events: none;
}

.category-banner .container,
.page-hero .container {
    position: relative;
    z-index: 1;
}

.category-banner h1,
.author-banner h1,
.page-hero h1 {
    color: #fff;
}

.author-banner {
    background: var(--section);
    color: inherit;
}

.author-banner h1 {
    color: var(--heading);
}

.author-banner-inner {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

/* ---------- Search / empty / about / contact ---------- */
.search-page-form {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.75rem;
}

.search-page-form input {
    flex: 1;
}

.search-results {
    display: grid;
    gap: 1rem;
}

.search-result {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 1.25rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    padding: 1rem;
    transition: transform var(--transition), box-shadow var(--transition);
}

.search-result:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.search-result img {
    width: 180px;
    height: 120px;
    object-fit: cover;
    border-radius: 14px;
}

.empty-state {
    text-align: center;
    padding: 3.5rem 1rem;
}

.glass-panel {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 24px;
}

.content-prose {
    max-width: 720px;
}

.content-prose p {
    margin: 0 0 1.15rem;
}

/* ---------- Toasts ---------- */
.toast {
    position: fixed;
    top: 1.25rem;
    right: 1.25rem;
    z-index: 300;
    padding: 0.9rem 1.1rem;
    border-radius: 14px;
    border: 1px solid;
    max-width: 360px;
    background: #fff;
    box-shadow: var(--shadow-md);
    animation: fadeSlide 0.3s ease;
}

.toast-success { border-color: var(--success); color: #065f46; background: #ecfdf5; }
.toast-error { border-color: var(--danger); color: #991b1b; background: #fef2f2; }
.toast-warning { border-color: var(--warning); color: #92400e; background: #fffbeb; }
.toast-info { border-color: var(--info); color: #1e40af; background: #eff6ff; }

/* ---------- 404 / errors ---------- */
.error-page,
.page-404 {
    min-height: 80vh;
    display: grid;
    place-items: center;
    text-align: center;
    padding: var(--space-5) 1rem;
}

.error-page h1,
.page-404 h1 {
    font-size: clamp(4rem, 12vw, 7rem);
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin: 0;
}

.page-404-illu {
    width: min(280px, 70vw);
    margin: 0 auto 1.5rem;
    opacity: 0.95;
    animation: float 4s ease-in-out infinite;
}

/* ---------- Animations ---------- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeSlide {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: none; }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.reveal {
    animation: fadeSlide 0.5s ease both;
}

/* ---------- Bootstrap grid helpers used with custom look ---------- */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.split-60-40 {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 2rem;
}

.category-row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

@media (max-width: 1024px) {
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .category-row { grid-template-columns: repeat(3, 1fr); }
    .post-layout,
    .split-60-40 { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .nav-toggle { display: inline-grid; place-items: center; }
    .site-nav {
        display: none;
        position: absolute;
        left: 0;
        right: 0;
        top: calc(var(--logo-height) + 24px);
        flex-direction: column;
        align-items: stretch;
        padding: 1rem;
        background: var(--header-bg);
        border-bottom: 1px solid var(--header-border);
        box-shadow: 0 16px 40px rgba(30, 27, 75, 0.35);
    }
    .site-nav.is-open { display: flex; }
    .grid-3,
    .grid-2,
    .category-row,
    .search-result,
    .comment-form .form-row {
        grid-template-columns: 1fr;
    }
    .search-result img { width: 100%; height: 180px; }
    .author-banner-inner { flex-direction: column; align-items: flex-start; }
    .hero-lux,
    .hero-slider,
    .hero-content { min-height: 52vh; border-radius: 0; }
    .hero-content {
        padding: var(--space-5) var(--space-3) calc(var(--space-4) + 2.5rem);
    }
    .hero-dots {
        padding-left: var(--space-3);
        padding-right: var(--space-3);
    }
}
