/* ============ RESET & VARIABLES - STUDIO DARK THEME ============ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
    background: #0B0D10;
    color: #E9EEF5;
    line-height: 1.7;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    width: 100%;
    position: relative;
    transition: background-color 0.3s ease, color 0.3s ease;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 30%, rgba(64,224,255,0.03) 0%, transparent 45%),
                radial-gradient(circle at 80% 70%, rgba(64,224,255,0.03) 0%, transparent 45%);
    pointer-events: none;
    z-index: 0;
}

/* ============ LIGHT MODE STYLES ============ */
body.light-mode {
    background: #F5F5F5;
    color: #1e1e1e;
}

body.light-mode .article-card,
body.light-mode .header,
body.light-mode .story-card,
body.light-mode .license-tree,
body.light-mode .license-category,
body.light-mode .foundry-card,
body.light-mode .checker-teaser,
body.light-mode .checklist,
body.light-mode .author-bio,
body.light-mode .related-card,
body.light-mode .branch-item,
body.light-mode .newsletter-section,
body.light-mode .jump-dropdown select,
body.light-mode .license-table th,
body.light-mode .license-table td,
body.light-mode .info-box,
body.light-mode .tip-box,
body.light-mode .warning-box,
body.light-mode .success-box {
    background: #FFFFFF;
    color: #1e1e1e;
    border-color: #e0e0e0;
}

body.light-mode h2,
body.light-mode h3,
body.light-mode .meta-item,
body.light-mode p,
body.light-mode li,
body.light-mode .checklist-item span,
body.light-mode .branch-text,
body.light-mode .license-table td,
body.light-mode .foundry-card p {
    color: #1e1e1e;
}

body.light-mode h2 i,
body.light-mode .meta-item i,
body.light-mode .story-card i,
body.light-mode .checklist-item i {
    color: #2563eb;
}

body.light-mode .back-link {
    background: #FFFFFF;
    border-color: #e0e0e0;
}

body.light-mode .back-link:hover {
    background: rgba(37, 99, 235, 0.1);
}

body.light-mode .header {
    background: rgba(255, 255, 255, 0.98);
    border-bottom-color: #e0e0e0;
}

body.light-mode .brand-name {
    color: #1e1e1e;
}

body.light-mode .mobile-menu {
    background: #FFFFFF;
}

body.light-mode .mobile-nav-link {
    color: #1e1e1e;
}

body.light-mode .newsletter-input {
    background: #f5f5f5;
    border-color: #e0e0e0;
    color: #1e1e1e;
}

body.light-mode .newsletter-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

body.light-mode .newsletter-description {
    color: #4a4a4a;
}

body.light-mode .newsletter-title {
    background: linear-gradient(135deg, #2563eb, #3b82f6);
    -webkit-background-clip: text;
    background-clip: text;
}

body.light-mode .checker-input {
    background: #f5f5f5;
    border-color: #e0e0e0;
    color: #1e1e1e;
}

body.light-mode .checker-input:focus {
    border-color: #2563eb;
}

body.light-mode .branch-yes .branch-result {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
    border-color: #dc2626;
}

body.light-mode .branch-no .branch-result {
    background: rgba(34, 197, 94, 0.1);
    color: #16a34a;
    border-color: #16a34a;
}

body.light-mode .badge-free {
    background: rgba(34, 197, 94, 0.1);
    color: #16a34a;
    border-color: #16a34a;
}

body.light-mode .badge-paid {
    background: rgba(245, 158, 11, 0.1);
    color: #d97706;
    border-color: #d97706;
}

body.light-mode .badge-restricted {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
    border-color: #dc2626;
}

body.light-mode .license-table tr:hover td {
    background: rgba(37, 99, 235, 0.05);
}

body.light-mode .foundry-card:hover {
    border-color: #2563eb;
}

body.light-mode .related-card:hover {
    border-color: #2563eb;
}

body.light-mode .footer-bottom-links a {
    color: #6b7280;
}

body.light-mode .footer-bottom-links a:hover {
    color: #2563eb;
}

body.light-mode .footer-copyright span {
    color: #6b7280;
}

body.light-mode #footer-container footer,
body.light-mode .modern-footer {
    background: #f5f5f5;
    border-top-color: #e0e0e0;
}

main {
    flex: 1;
    position: relative;
    z-index: 1;
    width: 100%;
}

:root {
    --primary: #40E0FF;
    --primary-dark: #00B8D4;
    --primary-light: rgba(64,224,255,0.15);
    --primary-glow: rgba(64,224,255,0.25);
    --secondary: #40E0FF;
    --accent: #00B8D4;
    --warning: #FFB74D;
    --danger: #FF5252;
    --success: #4CAF50;
    --info: #40E0FF;
    --surface-0: #0B0D10;
    --surface-1: #151A21;
    --surface-2: #1E2630;
    --surface-3: #273140;
    --text-primary: #E9EEF5;
    --text-secondary: #C0C8D2;
    --text-tertiary: #9AA5B5;
    --text-muted: #6B7A8F;
    --border: #273140;
    --border-strong: #3A4A60;
    --shadow-sm: 0 4px 12px rgba(0,0,0,0.5);
    --shadow-md: 0 8px 24px rgba(0,0,0,0.6);
    --shadow-lg: 0 16px 32px rgba(0,0,0,0.7);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;
    --transition: all 0.2s cubic-bezier(0.4,0,0.2,1);
    --cyan-gradient: linear-gradient(135deg, #40E0FF, #00B8D4);
}

/* ============ PROGRESS BAR ============ */
.progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--cyan-gradient);
    z-index: 2000;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px rgba(64,224,255,0.5);
}

/* ============ SKIP TO CONTENT ============ */
.skip-to-content {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--cyan-gradient);
    color: #0B0D10;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 0 0 8px 0;
    font-weight: 600;
    z-index: 1001;
    transition: top 0.3s;
}
.skip-to-content:focus { top: 0; }

/* ============ TOAST NOTIFICATION ============ */
#toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    background: var(--cyan-gradient);
    color: #0B0D10;
    padding: 12px 24px;
    border-radius: 40px;
    font-size: 0.9rem;
    font-weight: 600;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 9999;
    transition: transform 0.3s ease;
    max-width: 90%;
    white-space: nowrap;
}
#toast.show { transform: translateX(-50%) translateY(0); }

/* ============ CONTAINER ============ */
.container {
    max-width: 1000px;
    margin: 20px auto;
    padding: 0 16px;
}
@media (min-width: 768px) { .container { margin: 40px auto; padding: 0 20px; } }

/* ============ HEADER STYLES ============ */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(11,13,16,0.98);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    width: 100%;
    transition: background-color 0.3s ease;
}
.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.logo-wrapper {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}
.logo-link {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}
.logo-icon {
    width: 36px; height: 36px;
    background: var(--cyan-gradient);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0B0D10;
    font-size: 1.1rem;
    box-shadow: 0 0 15px rgba(64,224,255,0.3);
    transition: var(--transition);
}
.logo-link:hover .logo-icon {
    transform: rotate(5deg) scale(1.05);
    box-shadow: 0 0 25px rgba(64,224,255,0.5);
}
.brand-name {
    font-size: 1.2rem;
    font-weight: 800;
    color: #E9EEF5;
    letter-spacing: -0.3px;
    white-space: nowrap;
}
.brand-name span { color: #40E0FF; position: relative; }
.slogan-badge {
    display: none;
    background: rgba(64,224,255,0.1);
    color: #40E0FF;
    font-size: 0.6rem;
    padding: 4px 8px;
    border-radius: 30px;
    border: 1px solid var(--border);
    align-items: center;
    gap: 4px;
}
@media (min-width:480px) { .slogan-badge { display: inline-flex; } }

/* ============ DESKTOP NAVIGATION ============ */
.nav-desktop { display: none; }
@media (min-width: 1024px) {
    .nav-desktop {
        display: flex;
        align-items: center;
        gap: 2px;
        margin: 0 auto;
        padding: 4px;
        background: rgba(21,26,33,0.6);
        border-radius: 60px;
        border: 1px solid var(--border);
        backdrop-filter: blur(8px);
    }
    .nav-link {
        color: #9AA5B5;
        text-decoration: none;
        font-size: 0.8rem;
        font-weight: 500;
        padding: 6px 12px;
        border-radius: 40px;
        display: inline-flex;
        align-items: center;
        gap: 4px;
        border: 1px solid transparent;
        transition: var(--transition);
    }
    .nav-link i { font-size: 0.75rem; color: #6B7A8F; }
    .nav-link:hover {
        color: #40E0FF;
        background: rgba(64,224,255,0.1);
        border-color: rgba(64,224,255,0.2);
        transform: translateY(-1px);
    }
    .nav-link:hover i { color: #40E0FF; }
    .nav-link.active {
        background: var(--cyan-gradient);
        color: #0B0D10;
        border-color: transparent;
        box-shadow: 0 4px 12px rgba(64,224,255,0.3);
    }
    .nav-link.active i { color: #0B0D10; }
    .nav-dropdown { position: relative; }
    .dropdown-menu {
        position: absolute;
        top: calc(100% + 8px);
        left: 50%;
        transform: translateX(-50%) translateY(10px);
        background: #151A21;
        border-radius: 16px;
        padding: 8px;
        min-width: 200px;
        box-shadow: var(--shadow-lg);
        border: 1px solid var(--border);
        opacity: 0;
        visibility: hidden;
        transition: all 0.2s;
        backdrop-filter: blur(12px);
    }
    .nav-dropdown:hover .dropdown-menu {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
    }
    .dropdown-menu a {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 16px;
        color: #9AA5B5;
        text-decoration: none;
        font-size: 0.8rem;
        border-radius: 10px;
    }
    .dropdown-menu a i { width: 16px; color: #40E0FF; }
    .dropdown-menu a:hover {
        background: rgba(64,224,255,0.1);
        color: #40E0FF;
        transform: translateX(4px);
    }
    .dropdown-menu a.active {
        background: rgba(64,224,255,0.15);
        color: #40E0FF;
        font-weight: 600;
    }
    .new-badge {
        margin-left: auto;
        font-size: 0.55rem;
        background: #40E0FF;
        color: #0B0D10;
        padding: 2px 6px;
        border-radius: 10px;
    }
    .dropdown-group-title {
        font-size: 0.7rem;
        text-transform: uppercase;
        letter-spacing: 1px;
        font-weight: 700;
        color: #40E0FF;
        padding: 8px 12px 4px;
        margin-top: 4px;
        border-bottom: 1px solid var(--border);
    }
    .dropdown-group-title:first-of-type { margin-top: 0; }
}

/* ============ ACTION BUTTONS ============ */
.action-buttons {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}
.guides-link {
    padding: 8px 16px;
    border-radius: 40px;
    font-size: 0.8rem;
    font-weight: 600;
    background: var(--cyan-gradient);
    color: #0B0D10;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
    min-height: 40px;
    box-shadow: 0 4px 12px rgba(64,224,255,0.3);
    text-decoration: none;
}
.guides-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(64,224,255,0.4);
}
.guides-link .link-text { display: none; }
@media (min-width:768px) { .guides-link .link-text { display: inline; } }

/* ============ AUTH BUTTON STYLES ============ */
.auth-btn {
    padding: 8px 16px;
    border-radius: 40px;
    font-size: 0.8rem;
    font-weight: 600;
    background: #1E2630;
    border: 1px solid #273140;
    color: #E9EEF5;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    transition: var(--transition);
    height: 44px;
}
.auth-btn i { font-size: 0.8rem; color: #40E0FF; }
.auth-btn:hover {
    background: var(--cyan-gradient);
    border-color: transparent;
    color: #0B0D10;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(64,224,255,0.3);
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #1E2630;
    border: 1px solid #273140;
    border-radius: 60px;
    padding: 3px 3px 3px 10px;
    transition: var(--transition);
    height: 44px;
}
.user-profile:hover {
    border-color: #40E0FF;
    background: rgba(64,224,255,0.1);
}
.user-avatar {
    width: 36px; height: 36px;
    border-radius: 50%;
    background: var(--cyan-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0B0D10;
    font-weight: 600;
    font-size: 0.9rem;
}
.sign-out-btn {
    width: 36px; height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: #9AA5B5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}
.sign-out-btn:hover {
    color: #FF5252;
    transform: scale(1.1);
    background: rgba(255,82,82,0.1);
}

@media (max-width: 768px) {
    .auth-btn { padding: 6px 12px; height: 40px; font-size: 0.75rem; }
    .user-profile { padding: 2px 2px 2px 8px; height: 40px; }
    .user-avatar { width: 32px; height: 32px; font-size: 0.8rem; }
    .sign-out-btn { width: 32px; height: 32px; }
}
@media (max-width: 480px) {
    .auth-btn { padding: 6px 10px; height: 36px; font-size: 0.7rem; }
    .auth-btn span { display: none; }
    .auth-btn i { font-size: 0.9rem; margin: 0; }
    .user-profile { padding: 2px; height: 36px; }
    .user-avatar { width: 28px; height: 28px; font-size: 0.7rem; }
    .sign-out-btn { width: 28px; height: 28px; }
}

@keyframes profileSlideIn {
    from { opacity: 0; transform: translateX(10px); }
    to { opacity: 1; transform: translateX(0); }
}
.user-profile { animation: profileSlideIn 0.3s ease-out; }

/* ============ KO-FI BUTTON ============ */
.kofi-link {
    position: relative;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: #1E2630;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.175,0.885,0.32,1.275);
    text-decoration: none;
    flex-shrink: 0;
}
.kofi-link:hover {
    transform: translateY(-3px) scale(1.05);
    border-color: #40E0FF;
    background: var(--cyan-gradient);
    box-shadow: 0 5px 20px rgba(64,224,255,0.4);
}
.coffee-cup { position: relative; width: 20px; height: 20px; display: flex; justify-content: center; align-items: center; }
.cup-body { position: relative; width: 16px; height: 14px; background: linear-gradient(135deg, #FFD700, #FFA500); border-radius: 0 0 8px 8px; animation: cupFill 2s infinite alternate; }
.cup-body::before { content: ''; position: absolute; top: 2px; left: 2px; width: 12px; height: 10px; background: linear-gradient(135deg, #FFE55C, #FFB347); border-radius: 0 0 6px 6px; opacity: 0.8; }
.cup-handle { position: absolute; top: 2px; right: -4px; width: 4px; height: 7px; border: 2px solid #FFD700; border-left: none; border-radius: 0 4px 4px 0; opacity: 0.8; }
.coffee-liquid { position: absolute; top: -2px; left: 2px; width: 12px; height: 3px; background: linear-gradient(90deg, #8B4513, #A0522D); border-radius: 2px; animation: liquidWave 2s infinite; }
.coffee-steam { position: absolute; top: -8px; left: 4px; display: flex; gap: 2px; opacity: 0; transition: opacity 0.3s; }
.kofi-link:hover .coffee-steam { opacity: 1; }
.coffee-steam span { width: 2px; height: 8px; background: linear-gradient(to top, rgba(255,255,255,0.8), transparent); border-radius: 1px; animation: steam 1.5s infinite; }
.coffee-steam span:nth-child(1) { animation-delay: 0s; }
.coffee-steam span:nth-child(2) { animation-delay: 0.3s; }
.coffee-steam span:nth-child(3) { animation-delay: 0.6s; }
.kofi-tooltip {
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%) scale(0.8);
    background: var(--cyan-gradient);
    color: #0B0D10;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    pointer-events: none;
}
.kofi-link:hover .kofi-tooltip {
    opacity: 1;
    visibility: visible;
    bottom: -40px;
    transform: translateX(-50%) scale(1);
}
.kofi-link::after {
    content: '';
    position: absolute;
    top: -2px; left: -2px; right: -2px; bottom: -2px;
    background: var(--cyan-gradient);
    border-radius: 50%;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s;
    filter: blur(10px);
}
.kofi-link:hover::after { opacity: 0.5; }

@keyframes cupFill { 0% { transform: scaleY(1); } 100% { transform: scaleY(1.05); } }
@keyframes liquidWave { 0%,100% { transform: translateX(0) scaleX(1); } 25% { transform: translateX(1px) scaleX(1.05); } 75% { transform: translateX(-1px) scaleX(0.95); } }
@keyframes steam { 0% { transform: translateY(0) scaleX(1); opacity:0.8; } 50% { transform: translateY(-5px) scaleX(1.5); opacity:0.4; } 100% { transform: translateY(-10px) scaleX(2); opacity:0; } }

/* ============ MOBILE MENU ============ */
.mobile-menu-btn {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: #1E2630;
    border: 1px solid var(--border);
    display: none;
    align-items: center;
    justify-content: center;
    color: #40E0FF;
    transition: var(--transition);
    flex-shrink: 0;
    cursor: pointer;
}
.mobile-menu-btn i { font-size: 1rem; }
.mobile-menu-btn:hover {
    background: var(--cyan-gradient);
    color: #0B0D10;
    transform: translateY(-2px);
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(64,224,255,0.3);
}
@media (max-width: 1024px) { .mobile-menu-btn { display: flex; } }

.mobile-menu {
    position: fixed;
    top: 0; right: -100%;
    width: 300px; height: 100vh;
    background: #151A21;
    z-index: 1001;
    transition: right 0.3s;
    padding: 80px 20px 20px;
    border-left: 1px solid var(--border);
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}
.mobile-menu.active { right: 0; }
.mobile-menu-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 30px; }
.mobile-menu-close {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: #1E2630;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #40E0FF;
    cursor: pointer;
    transition: var(--transition);
}
.mobile-menu-close:hover {
    background: var(--cyan-gradient);
    color: #0B0D10;
    transform: rotate(90deg);
}
.mobile-nav-links { display: flex; flex-direction: column; gap: 4px; }
.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    color: #9AA5B5;
    text-decoration: none;
    font-size: 0.95rem;
    border-radius: 12px;
    transition: var(--transition);
    min-height: 48px;
}
.mobile-nav-link i { width: 20px; color: #40E0FF; }
.mobile-nav-link:hover {
    background: rgba(64,224,255,0.1);
    color: #40E0FF;
    transform: translateX(5px);
}
.mobile-nav-link.active {
    background: rgba(64,224,255,0.15);
    color: #40E0FF;
    font-weight: 600;
}
.mobile-menu-overlay {
    position: fixed;
    top:0; left:0;
    width:100%; height:100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(4px);
    z-index:1000;
    opacity:0;
    visibility:hidden;
    transition: var(--transition);
}
.mobile-menu-overlay.active { opacity:1; visibility:visible; }

/* ============ RESPONSIVE BREAKPOINTS ============ */
@media (min-width: 768px) {
    .header-container { padding: 10px 20px; }
    .logo-icon { width: 38px; height: 38px; font-size: 1.2rem; }
    .brand-name { font-size: 1.3rem; }
    .kofi-link, .mobile-menu-btn { width: 42px; height: 42px; }
}
@media (min-width: 1024px) { .mobile-menu-btn { display: none; } }
@media (max-width: 768px) {
    .header-container { padding: 10px 14px; }
    .brand-name { font-size: 1.1rem; }
    .logo-icon { width: 34px; height: 34px; font-size: 1rem; }
    .kofi-link, .mobile-menu-btn { width: 38px; height: 38px; }
}
@media (max-width: 480px) {
    .header-container { padding: 6px 10px; gap: 4px; }
    .logo-icon { width: 30px; height: 30px; font-size: 0.9rem; }
    .brand-name { font-size: 0.95rem; }
    .slogan-badge { display: none; }
    .kofi-link, .mobile-menu-btn { width: 34px; height: 34px; }
}
@supports (padding: max(0px)) {
    .header-container, .container, .footer-container {
        padding-left: max(16px, env(safe-area-inset-left));
        padding-right: max(16px, env(safe-area-inset-right));
    }
}

/* ============ BACK LINK ============ */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #40E0FF;
    text-decoration: none;
    margin-bottom: 20px;
    padding: 8px 16px;
    background: #151A21;
    border-radius: 40px;
    border: 1px solid var(--border);
    transition: var(--transition);
    font-size: 0.85rem;
    width: fit-content;
}
.back-link:hover {
    background: rgba(64,224,255,0.1);
    transform: translateX(-4px);
    border-color: #40E0FF;
}

/* ============ JUMP DROPDOWN ============ */
.jump-dropdown-container {
    max-width: 800px;
    margin: 0 auto 20px;
    padding: 0 16px;
}
.jump-dropdown { width: 100%; }
.jump-dropdown select {
    width: 100%;
    padding: 14px 18px;
    background: #1E2630;
    border: 1px solid var(--border);
    border-radius: 40px;
    color: #E9EEF5;
    font-size: 0.95rem;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2340E0FF' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 18px center;
    background-size: 16px;
    font-family: 'Inter', sans-serif;
}
.jump-dropdown select:focus {
    outline: none;
    border-color: #40E0FF;
    box-shadow: 0 0 0 3px rgba(64,224,255,0.2);
}
.jump-dropdown select option {
    background: #151A21;
    color: #E9EEF5;
    padding: 10px;
}

/* ============ ARTICLE CARD ============ */
.article-card {
    background: #151A21;
    border-radius: var(--radius-xl);
    border: 1px solid var(--border);
    padding: 32px 24px;
    margin: 0 0 40px;
    box-shadow: var(--shadow-lg);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
@media (min-width:768px) { .article-card { padding: 48px; } }

/* ============ TRUST BADGE ============ */
.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(64,224,255,0.1);
    padding: 8px 16px;
    border-radius: 40px;
    border: 1px solid var(--border);
    font-size: 0.7rem;
    font-weight: 600;
    color: #40E0FF;
    margin-bottom: 24px;
}
@media (min-width:768px) { .trust-badge { padding: 8px 18px; font-size:0.75rem; margin-bottom:32px; } }

/* ============ ARTICLE TITLE ============ */
.article-title {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
    color: #E9EEF5;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: color 0.3s ease;
}
@media (min-width:768px) { .article-title { font-size:2.5rem; letter-spacing:-1px; margin-bottom:24px; } }
.title-highlight {
    background: var(--cyan-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ============ ARTICLE META ============ */
.article-meta {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
}
@media (min-width:640px) { .article-meta { flex-direction: row; align-items: center; gap:24px; } }
.author {
    display: flex;
    align-items: center;
    gap: 12px;
}
.author-avatar {
    width: 44px; height: 44px;
    background: var(--cyan-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0B0D10;
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
}
.author-info { display: flex; flex-direction: column; }
.author-name { font-weight: 700; color: #E9EEF5; font-size:0.95rem; transition: color 0.3s ease; }
.author-title { font-size:0.8rem; color: #9AA5B5; transition: color 0.3s ease; }
.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #9AA5B5;
    font-size:0.85rem;
}
.meta-item i { color: #40E0FF; width:16px; }
.last-updated {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #1E2630;
    padding: 4px 10px;
    border-radius: 30px;
    font-size: 0.7rem;
    color: #9AA5B5;
    border: 1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.last-updated i { color: #40E0FF; }

/* ============ ARTICLE SUBTITLE ============ */
.article-subtitle {
    font-size:1rem;
    line-height:1.7;
    color: #C0C8D2;
    margin-bottom:30px;
    border-left:4px solid #40E0FF;
    padding:20px 24px;
    background: #1E2630;
    border-radius: var(--radius-lg);
    font-style:italic;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* ============ LICENSE TREE ============ */
.license-tree {
    background: #1E2630;
    border-radius: var(--radius-lg);
    padding: 24px;
    margin: 24px 0;
    border: 1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.tree-question {
    font-size: 1.1rem;
    font-weight: 600;
    color: #40E0FF;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.tree-branch {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.branch-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    background: #151A21;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
@media (min-width: 480px) {
    .branch-item {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 12px 16px;
    }
}
.branch-question {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.branch-question i { font-size: 1rem; flex-shrink: 0; }
.branch-yes .branch-question i { color: #FF5252; }
.branch-no .branch-question i { color: #4CAF50; }
.branch-text { font-size: 0.95rem; word-break: break-word; }
.branch-result {
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 30px;
    font-size: 0.85rem;
    text-align: center;
    white-space: normal;
    word-break: break-word;
    display: inline-block;
    width: fit-content;
}
@media (min-width: 480px) {
    .branch-result {
        margin-left: auto;
        white-space: nowrap;
    }
}
.branch-yes .branch-result {
    background: rgba(255,82,82,0.1);
    color: #FF5252;
    border: 1px solid #FF5252;
}
.branch-no .branch-result {
    background: rgba(76,175,80,0.1);
    color: #4CAF50;
    border: 1px solid #4CAF50;
}
.tree-divider { margin: 20px 0 10px; border-top: 1px solid var(--border); }

/* ============ STORY CARD ============ */
.story-card {
    background: #1E2630;
    border-radius: var(--radius-lg);
    padding: 24px;
    margin: 24px 0;
    border: 1px solid var(--border);
    border-left: 4px solid #40E0FF;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.story-card i { color: #40E0FF; font-size: 1.8rem; margin-bottom: 12px; }
.story-card h3 { margin-top: 0; color: #E9EEF5; transition: color 0.3s ease; }

/* ============ HEADINGS ============ */
h2 {
    font-size:1.6rem;
    font-weight:700;
    margin:48px 0 20px;
    color:#40E0FF;
    letter-spacing:-0.3px;
    display:flex;
    align-items:center;
    gap:12px;
    font-family:'Plus Jakarta Sans',sans-serif;
}
h2 i { color:#40E0FF; font-size:1.5rem; }
h3 {
    font-size:1.2rem;
    font-weight:600;
    margin:32px 0 16px;
    color:#E9EEF5;
    transition: color 0.3s ease;
}
p {
    margin-bottom:1.2rem;
    color:#C0C8D2;
    font-size:0.95rem;
    line-height:1.7;
    transition: color 0.3s ease;
}
p strong { color:#40E0FF; }
ul, ol {
    margin:20px 0 28px 24px;
    color:#C0C8D2;
}
li { margin-bottom:8px; }
mark {
    background: rgba(64,224,255,0.2);
    color: #40E0FF;
    padding: 2px 6px;
    border-radius: 6px;
}

/* ============ LICENSE CATEGORY CARDS ============ */
.license-category {
    background: #1E2630;
    padding: 20px;
    border-radius: var(--radius-lg);
    margin-bottom: 16px;
    border: 1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.license-category h4 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: #E9EEF5;
    flex-wrap: wrap;
    transition: color 0.3s ease;
}
.badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 30px;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
}
.badge-free { background: rgba(76,175,80,0.2); color: #4CAF50; border: 1px solid #4CAF50; }
.badge-paid { background: rgba(255,183,77,0.2); color: #FFB74D; border: 1px solid #FFB74D; }
.badge-restricted { background: rgba(255,82,82,0.2); color: #FF5252; border: 1px solid #FF5252; }

/* ============ INFO/WARNING/SUCCESS/INFO BOXES ============ */
.success-box, .warning-box, .info-box, .tip-box {
    padding:20px;
    border-radius:var(--radius-lg);
    margin:24px 0;
    border:1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.success-box { background: rgba(76,175,80,0.1); border-left:4px solid #4CAF50; }
.warning-box { background: rgba(255,82,82,0.1); border-left:4px solid #FF5252; }
.info-box { background: rgba(64,224,255,0.1); border-left:4px solid #40E0FF; }
.tip-box { background: #1E2630; border-left:4px solid #40E0FF; }
.success-box i, .warning-box i, .info-box i, .tip-box i { margin-right:8px; }
.success-box i { color:#4CAF50; }
.warning-box i { color:#FF5252; }
.info-box i { color:#40E0FF; }
.tip-box i { color:#40E0FF; }

/* ============ LICENSE TABLE ============ */
.license-table-wrapper {
    overflow-x: auto;
    margin: 24px 0;
    border-radius: var(--radius-lg);
}
.license-table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    font-size: 0.9rem;
    min-width: 500px;
}
.license-table th {
    background: #1E2630;
    padding: 16px;
    text-align: left;
    font-weight: 700;
    color: #40E0FF;
    border-bottom: 2px solid var(--border);
    transition: background-color 0.3s ease, color 0.3s ease;
}
.license-table td {
    padding: 16px;
    border-bottom: 1px solid var(--border);
    color: #C0C8D2;
    transition: background-color 0.3s ease, color 0.3s ease;
}
.license-table tr:last-child td { border-bottom: none; }
.license-table tr:hover td { background: rgba(64,224,255,0.05); }

/* ============ CHECKER TEASER ============ */
.checker-teaser {
    background: #1E2630;
    border-radius: var(--radius-lg);
    padding: 24px;
    margin: 24px 0;
    border: 1px solid var(--border);
    text-align: center;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
.checker-input-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 500px;
    margin: 20px auto;
}
@media (min-width: 640px) { .checker-input-group { flex-direction: row; } }
.checker-input {
    flex: 1;
    padding: 12px 16px;
    background: #151A21;
    border: 1px solid var(--border);
    border-radius: 40px;
    color: #E9EEF5;
    font-size: 0.95rem;
    width: 100%;
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}
.checker-input:focus {
    outline: none;
    border-color: #40E0FF;
}
.checker-btn {
    padding: 12px 24px;
    background: var(--cyan-gradient);
    border: none;
    border-radius: 40px;
    color: #0B0D10;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.checker-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(64,224,255,0.3);
}

/* ============ CHECKLIST ============ */
.checklist {
    background: #1E2630;
    border-radius: var(--radius-xl);
    padding: 24px 20px;
    margin: 32px 0;
    border: 1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
@media (min-width:768px) { .checklist { padding: 40px; margin: 48px 0; } }
.checklist-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}
.checklist-item:last-child { border-bottom: none; }
.checklist-item i { color: #4CAF50; font-size: 1.1rem; flex-shrink:0; }
.checklist-item span { font-size: 0.9rem; color: #C0C8D2; transition: color 0.3s ease; }
.checklist-item span strong { color: #40E0FF; }

/* ============ FOUNDRY GRID ============ */
.foundry-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin: 24px 0;
}
@media (min-width:640px) { .foundry-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; } }
.foundry-card {
    background: #1E2630;
    padding: 20px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: var(--transition);
}
.foundry-card:hover {
    border-color: #40E0FF;
    transform: translateY(-4px);
}
.foundry-card h4 { color: #40E0FF; margin-bottom: 8px; }
.foundry-card p { margin-bottom: 12px; font-size:0.85rem; color: #C0C8D2; }
.foundry-link {
    color: #40E0FF;
    text-decoration: none;
    font-weight: 600;
    font-size:0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.foundry-link i { font-size:0.7rem; transition: transform 0.2s; }
.foundry-link:hover i { transform: translateX(4px); }

/* ============ AUTHOR BIO ============ */
.author-bio {
    background: #1E2630;
    border-radius: var(--radius-xl);
    padding: 28px 24px;
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    align-items: center;
    border: 1px solid var(--border);
    transition: background-color 0.3s ease, border-color 0.3s ease;
}
@media (min-width:640px) { .author-bio { flex-direction: row; gap: 32px; padding: 40px; } }
.author-avatar-large {
    width: 100px; height: 100px;
    background: var(--cyan-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0B0D10;
    font-size: 2.5rem;
    font-weight: 700;
    flex-shrink: 0;
}
.author-bio h3 { margin: 0 0 8px; color: #E9EEF5; transition: color 0.3s ease; }
.author-bio p { margin-bottom: 12px; color: #C0C8D2; transition: color 0.3s ease; }
.author-bio a { color: #40E0FF; text-decoration: none; font-weight: 600; }

/* ============ RELATED GUIDES ============ */
.related-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin: 24px 0;
}
@media (min-width:640px) { .related-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; } }
@media (min-width:1024px) { .related-grid { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.related-card {
    background: #1E2630;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    text-decoration: none;
    transition: var(--transition);
    display: block;
}
.related-card:hover {
    border-color: #40E0FF;
    transform: translateY(-4px);
}
.related-card h4 { color: #E9EEF5; margin-bottom: 8px; font-size: 1rem; font-weight: 700; transition: color 0.3s ease; }
.related-card p { color: #9AA5B5; font-size: 0.85rem; margin-bottom: 12px; transition: color 0.3s ease; }
.related-card span { color: #40E0FF; font-size: 0.85rem; font-weight: 600; }

/* ============ NEWSLETTER SECTION ============ */
.newsletter-section {
    max-width: 800px;
    margin: 40px auto;
    background: var(--surface-1);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border);
    padding: 40px 32px;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}
@media (max-width: 768px) {
    .newsletter-section { margin: 30px 16px; padding: 32px 24px; }
}
@media (max-width: 480px) {
    .newsletter-section { padding: 28px 20px; margin: 30px 16px; }
}
.newsletter-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(64,224,255,0.08), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.newsletter-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(64,224,255,0.05), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.newsletter-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--cyan-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    z-index: 1;
}
@media (max-width: 768px) { .newsletter-title { font-size: 1.2rem; } }
.newsletter-title i {
    -webkit-text-fill-color: #40E0FF;
    color: #40E0FF;
    background: none;
}
.newsletter-description {
    color: var(--text-tertiary);
    font-size: 0.95rem;
    margin-bottom: 28px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
    position: relative;
    z-index: 1;
    transition: color 0.3s ease;
}
@media (max-width: 768px) { .newsletter-description { font-size: 0.85rem; margin-bottom: 24px; } }
.newsletter-description strong { color: var(--primary); font-weight: 600; }
.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
}
@media (min-width: 600px) { .newsletter-form { flex-direction: row; gap: 12px; } }
.newsletter-input {
    flex: 1;
    max-width: 320px;
    padding: 14px 20px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 60px;
    font-size: 0.95rem;
    color: var(--text-primary);
    transition: var(--transition);
    min-width: 240px;
}
@media (max-width: 600px) {
    .newsletter-input { width: 100%; max-width: 100%; padding: 12px 18px; font-size: 0.9rem; }
}
.newsletter-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(64,224,255,0.2);
}
.newsletter-input::placeholder { color: var(--text-muted); }
.newsletter-button {
    padding: 14px 28px;
    background: var(--cyan-gradient);
    border: none;
    border-radius: 60px;
    font-weight: 600;
    font-size: 0.95rem;
    color: #0B0D10;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    min-width: 140px;
    justify-content: center;
}
@media (max-width: 600px) {
    .newsletter-button { width: 100%; padding: 12px 20px; font-size: 0.9rem; }
}
.newsletter-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(64,224,255,0.3);
    gap: 12px;
}
.newsletter-button:active { transform: translateY(0); }

/* ============ FOOTER STYLES ============ */
#footer-container footer, .modern-footer {
    background: var(--surface-0);
    padding: 60px 20px 40px;
    margin-top: 60px;
    border-top: 1px solid var(--border);
    transition: background-color 0.3s ease, border-top-color 0.3s ease;
}
#footer-container .footer-bottom, .modern-footer .footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 30px;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    text-align: center;
}
@media (min-width: 768px) {
    #footer-container .footer-bottom, .modern-footer .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
    }
}
#footer-container .footer-copyright, .modern-footer .footer-copyright {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}
@media (min-width: 768px) {
    #footer-container .footer-copyright, .modern-footer .footer-copyright {
        flex-direction: row;
        gap: 20px;
    }
}
#footer-container .footer-copyright span, .modern-footer .footer-copyright span {
    color: var(--text-muted);
    font-size: 0.8rem;
    transition: color 0.3s ease;
}
#footer-container .free-badge, .modern-footer .free-badge {
    background: var(--cyan-gradient);
    color: #0B0D10;
    padding: 4px 10px;
    border-radius: 30px;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
}
#footer-container .footer-bottom-links, .modern-footer .footer-bottom-links {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}
#footer-container .footer-bottom-links a, .modern-footer .footer-bottom-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.8rem;
    transition: var(--transition);
}
#footer-container .footer-bottom-links a:hover, .modern-footer .footer-bottom-links a:hover {
    color: var(--primary);
}

/* ============ TOUCH OPTIMIZATIONS ============ */
@media (max-width: 767px) {
    .mobile-nav-link, .kofi-link, .mobile-menu-btn, .guides-link,
    .checker-btn, .back-link {
        min-height: 48px;
    }
    .license-category h4 {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ============ FOCUS INDICATORS ============ */
a:focus-visible, button:focus-visible, .filter-tab:focus-visible {
    outline: 3px solid #40E0FF;
    outline-offset: 2px;
}

/* ============ HIDDEN SEO H1 ============ */
.seo-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    border: 0;
}