/* Premium Sovereign Design System */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@400;500;600;700;800;900&family=Playfair+Display:ital,wght@0,600;0,700;0,800;1,600&display=swap');

:root {
    /* Brand Design Tokens */
    --primary: #c9a24d; 
    --gold-main: #c9a24d;
    --gold-dark: #b08c40;
    --gold-soft: #e7d6a8;
    --gold-light: #f6f0e1;
    --bg-cream: #f6f0e1;
    --bg-light: #faf8f3;
    
    /* Text Contrasts (Darkened for maximum high-contrast reading comfort) */
    --text-main: #111111;
    --text-secondary: #3f3f46;
    --text-muted: #5b5b66;
    
    /* System Tokens */
    --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    --shadow-premium: 0 10px 40px rgba(0, 0, 0, 0.03);
    --shadow-gold: 0 15px 35px rgba(201, 162, 77, 0.15);
    --shadow-gold-hover: 0 20px 45px rgba(201, 162, 77, 0.25);
    --radius-premium: 24px;
    
    /* Current structural mappings */
    --bg-dark: #faf8f3; 
    --card-bg: #ffffff;
    --border: rgba(201, 162, 77, 0.18);
    --glass: rgba(250, 248, 243, 0.8);
}

.dark {
    --bg-light: #06070a;
    --text-main: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --bg-cream: #0c0d12;
    
    --bg-dark: #06070a;
    --card-bg: #0d0e14;
    --border: rgba(201, 162, 77, 0.22);
    --glass: rgba(6, 7, 10, 0.85);
}

/* ── Mega Menu Backdrop (dims page content behind open mega menu) ── */
.mega-backdrop {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.25);
    z-index: 9990;
    backdrop-filter: blur(2px);
}
.mega-backdrop.active { display: block; }

/* ── Global select fix: options must always be readable ── */
select option {
    background: #ffffff;
    color: #1f1f1f;
}
.dark select option {
    background: #1e1e1e;
    color: #f5f5f5;
}

/* chk-input select specific fix */
.chk-input option {
    background: #ffffff;
    color: #1f1f1f;
    padding: 0.5rem;
}
.dark .chk-input option {
    background: #1e1e1e;
    color: #f5f5f5;
}

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

body {
    background: linear-gradient(135deg, #fdfbf7 0%, #f5eee0 50%, #eadeca 100%) no-repeat;
    background-attachment: fixed;
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

.dark body {
    background: var(--bg-dark);
}

::placeholder {
    color: var(--text-muted) !important;
    opacity: 0.7;
}

/* Navbar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--glass);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    padding: 1rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-main);
    text-decoration: none;
    background: linear-gradient(135deg, var(--gold-main) 0%, var(--gold-dark) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.theme-btn {
    background: var(--card-bg);
    border: 1px solid var(--border);
    color: var(--text-main);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    transition: 0.3s;
}

.theme-btn:hover {
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow-gold-hover);
}

.nav-center {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    margin: 0 auto;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-auth {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

/* Dropdown Menu Styles */
.nav-item {
    position: relative;
    white-space: nowrap;
}

.nav-item > a {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 600;
    padding: 1.2rem 0;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    transition: 0.3s;
}

.nav-item:hover > a {
    color: var(--primary);
}

/* ── Standard Dropdown ── */
.dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 50%;
    transform: translateX(-50%) translateY(12px);
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 1rem;
    min-width: 200px;
    padding: 0.6rem 0;
    display: none;
    opacity: 0;
    box-shadow: 0 20px 50px rgba(0,0,0,0.15), 0 0 0 1px var(--border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 9999;
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
}
.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -30px;
    left: 0;
    width: 100%;
    height: 35px;
    background: transparent;
}
.nav-item:hover .dropdown-menu,
.nav-item:focus-within .dropdown-menu {
    display: block;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: all;
}
.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.65rem 1.4rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: 0.2s;
    border-left: 2px solid transparent;
}
.dropdown-menu a:hover {
    color: var(--primary);
    background: rgba(201,162,77,0.07);
    border-left-color: var(--primary);
    padding-left: 1.7rem;
}

/* ── Mega Menu (centered, full-width panel) ── */
.mega-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100vw;
    background: var(--card-bg);
    border-top: 2px solid var(--primary);
    border-bottom: 1px solid var(--border);
    padding: 2.5rem 5% 2.5rem;
    display: none;
    opacity: 0;
    z-index: 9998;
    box-shadow: 0 25px 60px rgba(0,0,0,0.15);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transform: translateY(-8px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
}
.mega-menu::before {
    content: '';
    position: absolute;
    top: -45px;
    left: 0;
    width: 100%;
    height: 50px;
    background: transparent;
}
.nav-item:has(.mega-menu) {
    position: static !important;
}
.nav-item:hover .mega-menu,
.nav-item:focus-within .mega-menu {
    display: block;
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}
.mega-menu-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    gap: 2rem;
}
.mega-col-header {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--primary);
    padding-bottom: 0.6rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.mega-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    border-radius: 6px;
    transition: 0.18s;
    border-left: 2px solid transparent;
}
.mega-link:hover {
    color: var(--primary);
    background: rgba(201,162,77,0.08);
    border-left-color: var(--primary);
    padding-left: 0.85rem;
}
.mega-link-sub {
    padding: 0.3rem 0.5rem 0.3rem 1.4rem;
    font-size: 0.82rem;
    color: var(--text-muted);
}
.mega-link-sub:hover {
    color: var(--primary);
    background: rgba(201,162,77,0.05);
    padding-left: 1.8rem;
}
.mega-viewall {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.75rem;
    padding: 0.45rem 1rem;
    border-radius: 50px;
    background: rgba(201,162,77,0.1);
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 700;
    text-decoration: none;
    transition: 0.2s;
    border: 1px solid rgba(201,162,77,0.25);
}
.mega-viewall:hover {
    background: var(--primary);
    color: #fff;
}
.dropdown-menu i {
    font-size: 0.8rem;
}

.login-link {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 600;
    margin-right: 1rem;
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 250px;
    height: 100vh;
    background: var(--card-bg);
    padding: 6rem 2rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -10px 0 30px rgba(0,0,0,0.5);
    z-index: 1000;
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu a {
    color: var(--text-main);
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 600;
}

@media (max-width: 1100px) {
    .desktop-menu, .nav-auth.desktop-only, .nav-center.desktop-only {
        display: none !important;
    }
    .mobile-toggle {
        display: block !important;
    }
    .logo {
        font-size: 1.2rem;
    }
    .mega-menu {
        display: none !important;
    }
}

.btn-premium {
    background: var(--primary);
    color: white;
    padding: 0.8rem 2rem;
    border-radius: 99px;
    text-decoration: none;
    font-weight: 600;
    box-shadow: 0 4px 15px var(--primary-glow);
    transition: 0.3s;
    display: inline-block;
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--primary-glow);
}

.btn-secondary {
    background: transparent;
    color: var(--text-main);
    padding: 0.8rem 2rem;
    border-radius: 99px;
    text-decoration: none;
    font-weight: 600;
    border: 1px solid var(--border);
    transition: 0.3s;
    display: inline-block;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: white;
    transform: translateY(-2px);
}

/* ── Hero Section ── */
.hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 5%;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    /* Dark mode default — solid dark bg, no images */
    background: linear-gradient(135deg, #0f0d09 0%, #1a1610 50%, #0f0d09 100%);
}

/* ── Carousel bg slides (light mode only) ── */
.hero-bg-carousel {
    display: none; /* hidden in dark mode */
    position: absolute;
    inset: 0;
    z-index: 0;
}
.hero-bg-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity;
}
.hero-bg-slide.active {
    opacity: 1;
}

/* ── Overlay (light mode: gold-tinted; darkens image enough to read text) ── */
.hero-bg-overlay {
    display: none; /* hidden in dark mode */
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        160deg,
        rgba(250, 248, 243, 0.82) 0%,
        rgba(246, 240, 225, 0.75) 40%,
        rgba(201, 162, 77, 0.18) 100%
    );
    backdrop-filter: blur(0px);
}

/* ── Dot indicators ── */
.hero-carousel-dots {
    display: none; /* hidden in dark mode */
    position: absolute;
    bottom: 1.8rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 0.5rem;
}
.hero-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(201, 162, 77, 0.35);
    border: 1.5px solid rgba(201, 162, 77, 0.6);
    cursor: pointer;
    transition: all 0.3s;
}
.hero-dot.active {
    background: var(--primary);
    border-color: var(--primary);
    width: 22px;
    border-radius: 4px;
}

/* ── Hero content sits above carousel ── */
.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    animation: fadeInUp 1s ease-out;
}

/* ── Light mode: show carousel, overlay, dots; darken text for readability ── */
:root:not(.dark-root) body:not(.dark) .hero {
    background: transparent;
}
body:not(.dark) .hero-bg-carousel { display: block; }
body:not(.dark) .hero-bg-overlay  { display: block; }
body:not(.dark) .hero-carousel-dots { display: flex; }

/* In light mode hero: text colours for legibility over light images */
body:not(.dark) .hero h1 {
    color: #1f1f1f;
    text-shadow: 0 2px 12px rgba(255,255,255,0.6);
}
body:not(.dark) .hero p {
    color: #444444;
}
body:not(.dark) .hero strong {
    color: var(--primary);
}

/* ── Dark mode hero: text keeps default light colour ── */
.dark .hero h1 { color: #f5f5f5; }
.dark .hero p  { color: #aaaaaa; }

.hero h1 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -1px;
    color: #f5f5f5; /* default (dark mode) */
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.hero-btns {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}


/* Note Cards */
.notes-grid-section {
    padding: 6rem 5% 4rem;
}

.notes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.note-card {
    background: var(--card-bg);
    border-radius: 1.5rem;
    border: 2px solid var(--border); /* Thicker border */
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

body.light-mode .note-card {
    border-color: rgba(0, 0, 0, 0.1);
}

.note-card:hover {
    transform: translateY(-12px) scale(1.02);
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2), 0 0 20px var(--primary-glow);
    z-index: 2;
}

body.light-mode .note-card:hover {
    box-shadow: 0 20px 40px rgba(99, 102, 241, 0.15);
}

.note-content {
    padding: 1.5rem;
}

.note-category {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--primary);
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: block;
}

.note-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

/* Search Bar */
.search-container {
    padding: 0 5%;
    margin-top: -30px;
    position: relative;
    z-index: 10;
}

.search-box {
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 0.5rem;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    max-width: 800px;
    margin: 0 auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.search-box i {
    padding: 0 1.5rem;
    color: var(--text-muted);
}

.search-box input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-main);
    padding: 1rem 0;
    font-size: 1.1rem;
    font-family: inherit;
    outline: none;
}

.search-box button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.search-box button:hover {
    filter: brightness(1.1);
}

/* Popular Categories */
.popular-categories {
    padding: 6rem 5% 2rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 3rem;
}

.section-header.centered {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

.section-header h2 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.section-header h2 span {
    text-shadow: none;
}

.btn-text {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: 0.3s;
}

.btn-text:hover {
    gap: 0.8rem;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.category-card {
    position: relative;
    border-radius: 1.8rem;
    overflow: hidden;
    aspect-ratio: 3/2;
    text-decoration: none;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--card-bg);
    border: 2px solid var(--border);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

body.light-mode .category-card {
    border-color: rgba(0, 0, 0, 0.1);
}

.category-card:hover {
    transform: translateY(-12px) scale(1.03);
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 30px var(--primary-glow);
    z-index: 2;
}

body.light-mode .category-card:hover {
    box-shadow: 0 20px 40px rgba(99, 102, 241, 0.2);
}

.category-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-card:hover img {
    transform: scale(1.15);
}

.category-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(transparent, rgba(2, 6, 23, 0.9));
    display: flex;
    align-items: flex-end;
    padding: 2rem;
}

.category-overlay h3 {
    color: white;
    font-size: 1.3rem;
    font-weight: 600;
}

.category-card:hover {
    transform: scale(1.02);
    border-color: var(--primary);
}

.category-card:hover img {
    transform: scale(1.1);
}

/* Footer Styles */
.main-footer {
    background: var(--bg-dark);
    border-top: 1px solid var(--border);
    padding: 5rem 5% 2rem;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-section h3 {
    color: var(--text-main);
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.footer-section.brand p {
    color: var(--text-muted);
    margin: 1.5rem 0;
    max-width: 350px;
}

.tagline {
    font-style: italic;
    color: var(--primary) !important;
    font-weight: 500;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--text-main);
    text-decoration: none;
    transition: 0.3s;
}

.social-links a:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: translateY(-3px);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 1rem;
}

.footer-section ul li a {
    color: var(--text-muted);
    text-decoration: none;
    transition: 0.3s;
}

.footer-section ul li a:hover {
    color: var(--primary);
    padding-left: 5px;
}

.newsletter-form {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.newsletter-form input {
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: 0.75rem;
    color: var(--text-main);
    outline: none;
}

.newsletter-form button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.newsletter-form button:hover {
    filter: brightness(1.1);
}

.privacy-note {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 1rem;
}

.privacy-note a {
    color: var(--primary);
    text-decoration: none;
}

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 2rem;
}

.bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.policy-links {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.policy-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: 0.3s;
}

.policy-links a:hover {
    color: white;
}

/* Mobile Adjustments */
@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    .footer-section.brand p {
        margin: 1.5rem auto;
    }
    .social-links {
        justify-content: center;
    }
    .newsletter-form {
        max-width: 400px;
        margin: 0 auto;
        width: 100%;
    }
    .bottom-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
    .policy-links {
        justify-content: center;
        gap: 1rem 1.5rem !important;
    }
    .hero h1 { font-size: 2.5rem; }
    .desktop-only { display: none !important; }
    .mobile-toggle { display: block !important; }
    .section-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 1rem;
    }
}
/* Legal Pages Premium UI */
.legal-page {
    padding: 8rem 5% 5rem;
    min-height: 80vh;
}

.legal-page .container {
    max-width: 900px;
    margin: 0 auto;
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 4rem;
    border-radius: 2rem;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
}

.legal-header {
    text-align: center;
    margin-bottom: 4rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 2rem;
}

.legal-header h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #fff, #818cf8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

body.light-mode .legal-header h1 {
    -webkit-text-fill-color: var(--text-main);
}

.legal-content section {
    margin-bottom: 3rem;
}

.legal-content h3 {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.legal-content p {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.legal-content ul {
    list-style: none;
    margin-bottom: 1.5rem;
}

.legal-content ul li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--text-muted);
}

.legal-content ul li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--primary);
}

.legal-footer {
    margin-top: 4rem;
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 2rem;
    border: 1px solid var(--border);
    border-radius: 1rem;
    color: var(--text-main);
    text-decoration: none;
    transition: 0.3s;
}

.btn-back:hover {
    background: var(--border);
    transform: translateX(-5px);
}

/* =========================================================================
   SOVEREIGN DESIGN SYSTEM: LUXURY COMPONENTS
   ========================================================================= */

/* Glass Header */
.glass-header {
    background: rgba(250, 248, 243, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(201, 162, 77, 0.08);
}

.dark .glass-header {
    background: rgba(18, 18, 18, 0.8);
    border-bottom: 1px solid rgba(201, 162, 77, 0.15);
}

/* Premium Card */
.premium-card {
    background: var(--card-bg);
    border-radius: var(--radius-premium);
    border: 1px solid rgba(201, 162, 77, 0.08);
    box-shadow: var(--shadow-premium);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.premium-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-gold-hover);
    border-color: var(--gold-soft);
}

.premium-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--gold-main), var(--gold-soft));
    opacity: 0;
    transition: var(--transition-smooth);
}

.premium-card:hover::before {
    opacity: 1;
}

/* Gold Gradient Text Overlay */
.text-gold-gradient {
    background: linear-gradient(135deg, var(--gold-main) 0%, var(--gold-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Buttons */
.btn-gold {
    background: linear-gradient(135deg, var(--gold-main), var(--gold-dark));
    color: #ffffff !important;
    border-radius: 999px;
    padding: 14px 36px;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: var(--shadow-gold);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    font-family: 'Poppins', sans-serif;
    text-decoration: none;
}

.btn-gold::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.6s;
    z-index: -1;
}

.btn-gold:hover {
    background: #ffffff;
    color: var(--gold-main) !important;
    border-color: var(--gold-main);
    transform: translateY(-4px) scale(1.02);
    box-shadow: var(--shadow-gold-hover);
}

.btn-gold:hover::after {
    left: 100%;
}

.dark .btn-gold:hover {
    background: var(--card-bg);
}

.btn-outline-gold {
    background: transparent;
    color: var(--gold-main) !important;
    border: 2px solid var(--gold-main);
    border-radius: 999px;
    padding: 12px 34px;
    font-weight: 600;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: 'Poppins', sans-serif;
    text-decoration: none;
}

.btn-outline-gold:hover {
    background: linear-gradient(135deg, var(--gold-main), var(--gold-dark));
    color: #ffffff !important;
    border-color: transparent;
    transform: translateY(-4px);
    box-shadow: var(--shadow-gold);
}

/* Secure Glass Billing UI */
.secure-glass {
    background: rgba(18, 18, 18, 0.7);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(201, 162, 77, 0.1);
}

.light-mode .secure-glass {
    background: rgba(250, 248, 243, 0.7);
}

/* WhatsApp Pulse */
.whatsapp-pulse {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25D366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
    z-index: 9999;
    transition: var(--transition-smooth);
    text-decoration: none;
}

@media (max-width: 768px) {
    .whatsapp-pulse {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 24px;
    }
}

.whatsapp-pulse:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.5);
    color: white;
}

.whatsapp-pulse::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #25D366;
    top: 0;
    left: 0;
    animation: pulseBorder 2s infinite;
    pointer-events: none;
}

@keyframes pulseBorder {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

/* ── Products Grid and Responsive Mobile Optimizations ── */
.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

/* ── Resources Grid ── */
.resources-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

/* Base Product Card Actions Grid */
.product-card-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    width: 100%;
}

@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    /* 2-Column Popular Categories Grid */
    .category-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.8rem !important;
    }
    
    .category-card {
        border-radius: 1.25rem !important;
    }
    
    .category-overlay {
        padding: 1rem !important;
    }
    
    .category-overlay h3 {
        font-size: 0.95rem !important;
        font-weight: 700 !important;
    }

    /* 2-Column Products Grid */
    .products-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.8rem !important;
    }
    
    .products-grid .note-card {
        border-radius: 1.25rem !important;
    }
    
    .products-grid .note-content {
        padding: 0.85rem !important;
    }
    
    .products-grid .note-card h3 {
        font-size: 0.85rem !important;
        margin-bottom: 0.5rem !important;
        line-height: 1.3 !important;
        height: 2.6em !important;
        overflow: hidden;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
    }
    
    .products-grid .note-card div[style*="font-size: 1.4rem"],
    .products-grid .note-card div[style*="font-size: 1.4rem"] {
        font-size: 1rem !important;
        margin-bottom: 0.6rem !important;
    }
    
    /* Optimize buttons in 2-column card footer using semantic actions class */
    .product-card-actions {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }
    
    .product-card-actions .btn-gold,
    .product-card-actions .btn-outline-gold {
        padding: 0.5rem 0.5rem !important;
        font-size: 0.75rem !important;
        border-radius: 8px !important;
        height: auto !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
    }

    /* 2-Column Resources Grid on Tablet/Mobile */
    .resources-grid,
    .resource-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.8rem !important;
    }

    .resources-grid .resource-card,
    .resource-grid .resource-card {
        border-radius: 1.25rem !important;
    }

    .resources-grid .resource-card h3,
    .resource-grid .resource-card h3 {
        font-size: 0.9rem !important;
    }

    /* 2-Column Notes Grid on Tablet/Mobile */
    .notes-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.8rem !important;
    }
}

/* Global button text wrapping prevention */
.btn-gold,
.btn-outline-gold,
.product-card-actions .btn-gold,
.product-card-actions .btn-outline-gold {
    white-space: nowrap !important;
}


/* Premium Glassmorphic Store Toolbar Styles */
.store-filter-toolbar {
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(201, 162, 77, 0.1);
    border-radius: 1.25rem;
    padding: 1.5rem;
    margin-bottom: 3rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.light .store-filter-toolbar {
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.08);
}

.filter-form {
    display: grid;
    grid-template-columns: 2fr 1.2fr 1.2fr 1.2fr auto;
    gap: 1.2rem;
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-input-wrapper {
    position: relative;
    width: 100%;
}

.filter-input-wrapper i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.filter-input-wrapper input {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 2.5rem;
    background: rgba(18, 18, 18, 0.4);
    border: 1px solid rgba(201, 162, 77, 0.2);
    border-radius: 0.75rem;
    color: var(--text-main);
    font-size: 0.9rem;
    outline: none;
    transition: 0.3s;
}

.light .filter-input-wrapper input {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.15);
}

.filter-input-wrapper input:focus {
    border-color: var(--gold-main);
    box-shadow: 0 0 10px rgba(201, 162, 77, 0.15);
}

.filter-select {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(18, 18, 18, 0.4);
    border: 1px solid rgba(201, 162, 77, 0.2);
    border-radius: 0.75rem;
    color: var(--text-main);
    font-size: 0.9rem;
    outline: none;
    cursor: pointer;
    transition: 0.3s;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c9a24d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.2em;
}

.light .filter-select {
    background-color: #ffffff;
    border-color: rgba(0, 0, 0, 0.15);
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
}

.filter-select:focus {
    border-color: var(--gold-main);
}

.filter-btn-group {
    display: flex;
    gap: 0.75rem;
}

.filter-btn {
    padding: 0.8rem 1.5rem;
    border-radius: 0.75rem;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: 0.3s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border: none;
}

.filter-btn-reset {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    border: 1px solid var(--border);
}

.light .filter-btn-reset {
    background: #f1f5f9;
}

.filter-btn-reset:hover {
    background: rgba(259, 68, 68, 0.1);
    color: #ef4444;
    border-color: rgba(259, 68, 68, 0.2);
}

/* Responsive Filters */
@media (max-width: 1024px) {
    .filter-form {
        grid-template-columns: 1fr 1fr;
    }
    .filter-btn-group {
        grid-column: span 2;
        width: 100%;
    }
    .filter-btn {
        flex: 1;
    }
}

@media (max-width: 600px) {
    .filter-form {
        grid-template-columns: 1fr;
    }
    .filter-btn-group {
        grid-column: span 1;
    }
}

/* =========================================================================
   SOVEREIGN DESIGN SYSTEM: UPGRADES & PREMIUM ANIMATIONS
   ========================================================================= */

/* Entrance Transition for all pages */
body {
    animation: fadeInEntrance 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes fadeInEntrance {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 1. Live User Activity Top Bar Ticker */
.ticker-bar {
    width: 100%;
    background: #0f0f11;
    border-bottom: 1px solid rgba(201, 162, 77, 0.18);
    padding: 0;
    overflow: hidden;
    position: relative;
    z-index: 1001;
    font-family: 'Outfit', 'Poppins', sans-serif;
    font-size: 0.78rem;
    font-weight: 500;
    display: flex;
    align-items: stretch;
}
.dark .ticker-bar {
    background: #09090b;
    border-bottom-color: rgba(201, 162, 77, 0.22);
}

/* "LIVE" pill badge on the left */
.ticker-label {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.45rem 1.1rem;
    background: rgba(239, 68, 68, 0.12);
    border-right: 1px solid rgba(239, 68, 68, 0.2);
    color: #f87171;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    white-space: nowrap;
}
.ticker-label i {
    font-size: 0.55rem;
    animation: live-pulse 1.4s ease-in-out infinite;
}
@keyframes live-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.35; transform: scale(0.8); }
}

.ticker-wrapper {
    flex: 1;
    overflow: hidden;
    display: flex;
    align-items: center;
    padding: 0.45rem 0;
}
.ticker-content {
    display: flex;
    white-space: nowrap;
    /* Slower: 120s for ~40 real names vs old 600s for 80 fakes */
    animation: ticker-scrolling 120s linear infinite;
    will-change: transform;
}
.ticker-bar:hover .ticker-content {
    animation-play-state: paused;
}
@keyframes ticker-scrolling {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Base ticker item */
.ticker-item {
    padding: 0 1.4rem;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: #c9a24d;
    font-weight: 500;
    position: relative;
}
/* Separator dot between items */
.ticker-item::after {
    content: '·';
    position: absolute;
    right: 0;
    color: rgba(201, 162, 77, 0.3);
    font-size: 1.1rem;
    line-height: 1;
}

/* Icon colour by activity type */
.ticker-item i {
    font-size: 0.72rem;
    opacity: 0.85;
}
/* Subscriber (paid) — gold crown */
.ticker-sub { color: #e7d6a8; }
.ticker-sub i { color: #f59e0b; }

/* New signup — soft green */
.ticker-signup { color: #a3e0c8; }
.ticker-signup i { color: #34d399; }

/* Active reader — sky blue */
.ticker-active { color: #bfdbfe; }
.ticker-active i { color: #60a5fa; }

/* Promo fallback — muted gold */
.ticker-promo { color: #c9a24d; }
.ticker-promo i { color: #d4af37; }


/* 2. Premium 3D perspective pre-loader */
.preloader-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: rgba(10, 10, 12, 0.98);
    backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.preloader-overlay.fade-out {
    opacity: 0;
    pointer-events: none;
}
.loader {
    width: 50px;
    height: 50px;
    position: relative;
    perspective: 120px;
}
.loader div {
    position: absolute;
    width: 100%;
    height: 100%;
    background: var(--gold-main);
    border-radius: 4px;
    animation: loader-perspective 1.2s infinite ease-in-out;
}
.loader div:nth-child(2) {
    animation-delay: 0.15s;
    background: var(--gold-dark);
}
.loader div:nth-child(3) {
    animation-delay: 0.3s;
    background: var(--gold-soft);
}
.loader div:nth-child(4) {
    animation-delay: 0.45s;
    background: var(--gold-light);
}
.loader div:nth-child(5) {
    animation-delay: 0.6s;
    background: #ffffff;
}
@keyframes loader-perspective {
    0% { transform: rotateX(0deg) rotateY(0deg); }
    50% { transform: rotateX(180deg) rotateY(0deg); }
    100% { transform: rotateX(180deg) rotateY(180deg); }
}

/* 3. Dark Theme Hero Background */
.dark .hero {
    background: linear-gradient(rgba(10, 10, 12, 0.85), rgba(10, 10, 12, 0.95)), url('https://i.ibb.co/TxrBT2zb/banner.png') no-repeat center center/cover !important;
}

/* 4. Strict Line Clamping on Grid Cards */
.note-card-title, .product-card-title, .grid-title, .note-card h3, .resource-card h3, .product-card h3, .blog-card h3 {
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    height: 2.8em !important;
    line-height: 1.4 !important;
}

/* 5. Symmetrical 60/40 Card Ratio */
.note-card, .product-card, .resource-card, .premium-card {
    display: flex;
    flex-direction: column;
    height: 480px; /* Rigid structure */
}
.premium-card:not(.note-card):not(.product-card):not(.resource-card) {
    height: auto !important;
}
.note-card > a:first-child,
.product-card > a:first-child,
.resource-card > a:first-child,
.premium-card > a:first-child,
.note-card .card-img-wrapper,
.note-card .note-image,
.product-card .card-img-wrapper,
.resource-card .resource-card-thumb-link,
.premium-card .card-banner {
    height: 60% !important;
    width: 100% !important;
    aspect-ratio: auto !important;
    overflow: hidden !important;
    position: relative !important;
    flex-shrink: 0;
}
.note-card img,
.product-card img,
.resource-card img,
.premium-card img,
.card-img-wrapper img,
.resource-card-thumb-link img,
.card-banner img {
    height: 100% !important;
    width: 100% !important;
    object-fit: cover !important;
    transition: transform 0.5s ease !important;
    display: block !important;
}
.note-card .note-content, 
.note-card .card-body,
.product-card .product-content, 
.product-card .card-body,
.resource-card .resource-content {
    height: 40% !important;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.25rem !important;
    box-sizing: border-box;
}
.product-price {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 1.25rem;
}

/* 6. Luxury Mobile Settings under 768px */
@media (max-width: 768px) {
    /* Tight mobile padding & gutters */
    body {
        font-size: 0.9rem;
    }
    .notes-grid-section, .popular-categories, .legal-page, .store-filter-toolbar {
        padding: 3rem 1rem 2rem !important;
    }
    .notes-grid, .products-grid, .resources-grid, .category-grid {
        gap: 0.75rem !important;
    }
    .note-card, .product-card, .resource-card, .premium-card {
        height: auto !important;
        min-height: 280px !important;
    }
    .note-card > a:first-child,
    .product-card > a:first-child,
    .resource-card > a:first-child,
    .premium-card > a:first-child,
    .note-card .card-img-wrapper, 
    .note-card .note-image, 
    .product-card .card-img-wrapper, 
    .resource-card .resource-card-thumb-link,
    .card-banner {
        aspect-ratio: 16/9 !important;
        height: auto !important;
        width: 100% !important;
        display: block !important;
        overflow: hidden !important;
        position: relative !important;
    }
    .note-card img,
    .product-card img,
    .resource-card img,
    .premium-card img,
    .card-img-wrapper img,
    .resource-card-thumb-link img,
    .card-banner img {
        height: 100% !important;
        width: 100% !important;
        object-fit: cover !important;
    }
    .note-card .note-content, 
    .note-card .card-body,
    .product-card .product-content, 
    .product-card .card-body,
    .resource-card .resource-content,
    .resource-card .card-body,
    .premium-card .card-body {
        height: auto !important;
        padding: 0.75rem !important;
    }
    .product-price {
        font-size: 1.05rem !important;
        margin-bottom: 0.75rem !important;
    }
    /* Mobile badge overrides to prevent overlap */
    .premium-card .card-badge,
    .note-card .card-badge {
        top: auto !important;
        bottom: 10px !important;
        left: 10px !important;
        font-size: 0.65rem !important;
        padding: 2px 8px !important;
    }
    .premium-card .premium-badge,
    .note-card .premium-badge {
        top: 10px !important;
        right: 10px !important;
        font-size: 0.65rem !important;
        padding: 2px 8px !important;
    }
    /* Card metadata wrap to prevent horizontal overflow */
    .card-meta {
        flex-wrap: wrap !important;
        gap: 0.5rem !important;
        font-size: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }
    .card-meta span {
        white-space: nowrap !important;
    }
    .note-card h3, .premium-card h3, .product-card h3, .resource-card h3, .product-card-title, .note-card-title, .grid-title {
        font-size: 0.85rem !important;
        margin-bottom: 0.5rem !important;
        line-height: 1.25 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        max-height: 2.5em !important;
        height: 2.5em !important;
    }
    
    /* 2-Column Mobile Shop Action Buttons */
    .product-card-actions {
        display: grid !important;
        grid-template-columns: 50px 1fr !important;
        gap: 8px !important;
        width: 100% !important;
    }
    
    /* Force column 1 (Cart) to be small and icon-only */
    .product-card-actions a:first-child,
    .product-card-actions button:first-child,
    .product-card-actions form:first-child,
    .product-card-actions form:first-child button {
        padding: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 1.1rem !important;
        border-radius: 12px !important;
        height: 45px !important;
        width: 50px !important;
        margin: 0 !important;
    }
    .product-card-actions a:first-child span,
    .product-card-actions button:first-child span,
    .product-card-actions form:first-child button span,
    .product-card-actions a:first-child text,
    .product-card-actions button:first-child text,
    .product-card-actions form:first-child button text {
        display: none !important; /* Remove any inline text */
    }
    
    /* Force column 2 (Buy Now) to expand */
    .product-card-actions a:nth-child(2),
    .product-card-actions button:nth-child(2) {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        height: 45px !important;
        border-radius: 12px !important;
        padding: 0 1rem !important;
        font-size: 0.85rem !important;
        letter-spacing: 0.5px !important;
        text-transform: uppercase !important;
        font-weight: 700 !important;
    }

    /* Universal Single-Column Stack */
    .footer-grid, .dashboard-grid {
        grid-template-columns: 1fr !important;
    }
    .category-grid, .notes-grid, .products-grid, .resources-grid, .resource-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    .admin-form-grid, .form-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    .dropzone-container, .dropzone {
        padding: 1.5rem !important;
    }
}

/* 7. Glassmorphic Stats Counter & CSS Infinite Logo/Badge Marquee */
.trust-authority-section {
    padding: 4rem 5% 2rem;
    position: relative;
    background: transparent;
    z-index: 10;
}

/* Glassmorphic Stats Counter Grid */
.stats-counter-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 3.5rem;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.stat-counter-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 2rem;
    padding: 1.25rem 0.5rem;
    text-align: center;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.4s, box-shadow 0.4s;
    position: relative;
    overflow: hidden;
}

.stat-counter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(201, 162, 77, 0.1), transparent 60%);
    opacity: 0;
    transition: opacity 0.4s;
}

.stat-counter-card:hover {
    transform: translateY(-8px);
    border-color: rgba(201, 162, 77, 0.3);
    box-shadow: 0 20px 45px rgba(201, 162, 77, 0.1);
}

.stat-counter-card:hover::before {
    opacity: 1;
}

.stat-icon {
    font-size: 1.5rem;
    color: var(--primary); /* Gold */
    margin-bottom: 0.75rem;
    filter: drop-shadow(0 4px 8px rgba(201, 162, 77, 0.3));
}

.stat-number-wrapper {
    font-size: 1.9rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 0.5rem;
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #FFF, #C9A24D);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-suffix {
    background: linear-gradient(135deg, #C9A24D, #9A772C);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* CSS Infinite Logo/Badge Marquee */
.trust-marquee-container {
    overflow: hidden;
    width: 100%;
    position: relative;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 1.5rem;
    padding: 1.5rem 0;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
}

/* Gradient Fade Overlays on marquee edges */
.trust-marquee-container::before,
.trust-marquee-container::after {
    content: '';
    position: absolute;
    top: 0;
    width: 100px;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.trust-marquee-container::before {
    left: 0;
    background: linear-gradient(to right, var(--card-bg), transparent);
}

.trust-marquee-container::after {
    right: 0;
    background: linear-gradient(to left, var(--card-bg), transparent);
}

.trust-marquee-track {
    display: flex;
    white-space: nowrap;
    animation: trustMarquee 30s linear infinite;
    width: max-content;
}

.trust-badge-item {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0 3rem;
    color: var(--text-main);
    font-weight: 600;
    font-size: 1.1rem;
    transition: color 0.3s;
}

.trust-badge-item i {
    color: var(--primary); /* Gold */
    font-size: 1.3rem;
    filter: drop-shadow(0 2px 4px rgba(201, 162, 77, 0.2));
}

.trust-badge-item:hover {
    color: var(--primary);
}

/* Infinite Scroll Animation keyframe */
@keyframes trustMarquee {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(calc(-100% / 3));
    }
}

/* ── Trust Responsiveness ── */
@media (max-width: 991px) {
    .stats-counter-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    .stat-number-wrapper {
        font-size: 1.85rem;
    }
    .stat-counter-card {
        padding: 1.25rem 0.5rem;
    }
}

@media (max-width: 768px) {
    .trust-authority-section {
        padding: 3rem 1rem 1.5rem;
    }
    .stats-counter-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.75rem !important;
    }
    .stat-counter-card {
        padding: 1rem 0.5rem !important;
        border-radius: 1rem !important;
    }
    .stat-number-wrapper {
        font-size: 1.8rem !important;
    }
    .stat-icon {
        font-size: 1.25rem !important;
        margin-bottom: 0.5rem !important;
    }
    .stat-label {
        font-size: 0.7rem !important;
    }
    .trust-marquee-container {
        border-radius: 1rem;
        padding: 1.25rem 0;
    }
    .trust-badge-item {
        padding: 0 2rem;
        font-size: 1rem;
    }
}

/* 8. Optimized Responsive Typography for Mobile Views Under 768px */
@media (max-width: 768px) {
    /* Optimize all main headings on mobile viewport */
    h1, .hero-title, .hero h1, .luxury-hero-title {
        font-size: 1.85rem !important;
        line-height: 1.25 !important;
        letter-spacing: -0.02em !important;
        margin-bottom: 0.75rem !important;
    }
    
    h2, .section-title, .section-heading, .block-title {
        font-size: 1.45rem !important;
        line-height: 1.3 !important;
        letter-spacing: -0.01em !important;
        margin-bottom: 0.75rem !important;
    }
    
    h3, .card-title, .note-title, .product-title, .blog-title {
        font-size: 1.12rem !important;
        line-height: 1.35 !important;
        margin-bottom: 0.5rem !important;
    }
    
    h4 {
        font-size: 1rem !important;
        line-height: 1.4 !important;
    }

    /* Optimize body copy and description blocks on mobile viewport */
    p, .hero-subtitle, .section-subtitle, .card-text, .note-desc, .blog-summary, .about-text {
        font-size: 0.88rem !important;
        line-height: 1.55 !important;
    }
    
    /* Ensure action buttons feel balanced and premium on mobile */
    .btn-gold, .btn-premium, .btn-primary, .plan-btn {
        font-size: 0.85rem !important;
        padding: 0.65rem 1.35rem !important;
        letter-spacing: 0.5px !important;
    }
}






