/* ==========================================================================
   Generator Robot — generatorrobot.com — Design System
   Professional, clean, modern design. No emojis. Premium feel.
   ========================================================================== */

/* ---------- CSS Custom Properties ---------- */
:root {
    /* Colors - Light Mode */
    --color-bg: #ffffff;
    --color-bg-alt: #f8f9fb;
    --color-bg-card: #ffffff;
    --color-bg-input: #ffffff;
    --color-bg-code: #f1f3f5;
    --color-border: #e2e5e9;
    --color-border-light: #eef0f2;
    --color-text: #1a1d23;
    --color-text-secondary: #5a6270;
    --color-text-muted: #6b7280;
    --color-primary: #2563eb;
    --color-primary-hover: #1d4ed8;
    --color-primary-light: #dbeafe;
    --color-success: #16a34a;
    --color-error: #dc2626;
    --color-warning: #d97706;
    --color-header-bg: #ffffff;
    --color-header-border: #e2e5e9;
    --color-footer-bg: #111318;
    --color-footer-text: #a0a4ab;
    --color-shadow: rgba(0, 0, 0, 0.06);
    --color-shadow-md: rgba(0, 0, 0, 0.1);
    --color-overlay: rgba(0, 0, 0, 0.4);

    /* Typography - Native system font stack for fastest render (no web fonts) */
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;
    --leading-tight: 1.25;
    --leading-normal: 1.6;
    --leading-relaxed: 1.75;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;

    /* Layout */
    --container-max: 1200px;
    --container-narrow: 800px;
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms ease;
}

/* ---------- Dark Mode ---------- */
[data-theme="dark"] {
    --color-bg: #0f1117;
    --color-bg-alt: #161922;
    --color-bg-card: #1a1d27;
    --color-bg-input: #1e212c;
    --color-bg-code: #1e212c;
    --color-border: #2a2e3a;
    --color-border-light: #232730;
    --color-text: #e8eaed;
    --color-text-secondary: #a0a4af;
    --color-text-muted: #6b7080;
    --color-primary: #3b82f6;
    --color-primary-hover: #60a5fa;
    --color-primary-light: #1e3a5f;
    --color-success: #22c55e;
    --color-error: #ef4444;
    --color-warning: #f59e0b;
    --color-header-bg: #0f1117;
    --color-header-border: #2a2e3a;
    --color-footer-bg: #080a0f;
    --color-footer-text: #6b7080;
    --color-shadow: rgba(0, 0, 0, 0.2);
    --color-shadow-md: rgba(0, 0, 0, 0.3);
    --color-overlay: rgba(0, 0, 0, 0.6);
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: var(--leading-normal);
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-main {
    flex: 1;
}

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

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

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

h1, h2, h3, h4, h5, h6 {
    line-height: var(--leading-tight);
    font-weight: 600;
    color: var(--color-text);
}

h1 { font-size: var(--text-3xl); margin-bottom: var(--space-4); }
h2 { font-size: var(--text-2xl); margin-bottom: var(--space-3); }
h3 { font-size: var(--text-xl); margin-bottom: var(--space-2); }

p { margin-bottom: var(--space-4); }

ul, ol {
    padding-left: var(--space-6);
    margin-bottom: var(--space-4);
}

li { margin-bottom: var(--space-2); }

/* ---------- Container ---------- */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-6);
}

/* ---------- Header ---------- */
.site-header {
    background: var(--color-header-bg);
    border-bottom: 1px solid var(--color-header-border);
    position: sticky;
    top: 0;
    z-index: 100;
    /* backdrop-filter kaldırıldı: fixed-position nav'ın containing block'unu bozuyordu */
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    gap: var(--space-6);
}

.logo {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: var(--color-text);
    flex-shrink: 0;
    line-height: 0;
}

.logo:hover { color: var(--color-text); }

.logo-img {
    width: 270px;
    height: 80px;
    display: block;
    max-width: 100%;
}

/* Navigation */
.main-nav {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: var(--space-1);
    padding: 0;
    margin: 0;
}

.nav-list a,
.nav-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    padding: var(--space-2) var(--space-3);
    color: var(--color-text-secondary);
    font-size: var(--text-sm);
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    white-space: nowrap;
    border: none;
    background: none;
    cursor: pointer;
    font-family: var(--font-sans);
}

.nav-list a:hover,
.nav-list a.active,
.nav-dropdown-toggle:hover {
    color: var(--color-text);
    background: var(--color-bg-alt);
}

/* Reset animated entrance & mobile-specific styles on desktop */
@media (min-width: 769px) {
    .nav-list > li {
        opacity: 1;
        transform: none;
        animation: none;
    }
    .main-nav::before,
    .main-nav::after {
        display: none;
    }
    /* Hide mobile close button on desktop */
    .mobile-close {
        display: none !important;
    }
    /* Reset mobile-specific link styles for desktop */
    .nav-list a,
    .nav-dropdown-toggle {
        background: none;
        border: none;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
    .nav-list a::after,
    .nav-dropdown-toggle::after {
        display: none;
    }
    .nav-list a::before,
    .nav-dropdown-toggle::before {
        display: none;
    }
    .nav-list a:hover,
    .nav-list a.active,
    .nav-dropdown-toggle:hover {
        transform: none;
        background: var(--color-bg-alt);
        color: var(--color-text);
        border-color: transparent;
        box-shadow: none;
    }
}

.has-dropdown {
    position: relative;
}

.nav-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px var(--color-shadow-md);
    padding: var(--space-2);
    min-width: 180px;
    display: none;
    list-style: none;
    z-index: 50;
}


.has-dropdown:hover .nav-dropdown,
.has-dropdown.open .nav-dropdown {
    display: block;
}

.nav-dropdown a {
    display: block;
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-sm);
}

.nav-dropdown-toggle svg {
    transition: transform var(--transition-fast);
}

.has-dropdown:hover .nav-dropdown-toggle svg,
.has-dropdown.open .nav-dropdown-toggle svg {
    transform: rotate(180deg);
}

/* Desktop Tools Dropdown - hidden on mobile */
.desktop-tools-dropdown {
    display: none;
}

/* Categories that are in Tools dropdown - hidden on desktop, visible on mobile */
.mobile-nav-item {
    display: block;
}

@media (min-width: 769px) {
    .desktop-tools-dropdown {
        display: block;
    }
    .mobile-nav-item {
        display: none;
    }
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    flex-shrink: 0;
}

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg);
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.theme-toggle:hover {
    color: var(--color-text);
    border-color: var(--color-text-muted);
}

.icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }
[data-theme="dark"] .icon-moon { display: block; }

.mobile-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    border: 1px solid var(--color-border);
    border-radius: 10px;
    background: #ffffff;
    cursor: pointer;
    padding: 0;
    transition: all var(--transition-fast);
}

[data-theme="dark"] .mobile-toggle {
    background: var(--color-bg-card);
    border-color: var(--color-border);
}

.mobile-toggle:hover {
    border-color: #2563eb;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
}

.mobile-toggle span {
    display: block;
    width: 18px;
    height: 2.5px;
    background: #2563eb;
    border-radius: 2px;
}

/* Hamburger stays as hamburger always — no X animation needed */

/* Mobile menu backdrop overlay */
.mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 250ms ease, visibility 250ms ease;
    z-index: 98;
}

.mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Body lock when menu is open */
body.menu-open {
    overflow: hidden;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    font-weight: 500;
    line-height: 1;
    border-radius: var(--radius-md);
    border: 1.5px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: all var(--transition-fast);
    white-space: nowrap;
    outline: none;
    -webkit-font-smoothing: antialiased;
}

.btn:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Primary */
.btn-primary {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #ffffff;
}

.btn-primary:hover {
    background: var(--color-primary-hover);
    border-color: var(--color-primary-hover);
    color: #ffffff;
}

/* Outline / Ghost */
.btn-outline {
    background: transparent;
    border-color: var(--color-border);
    color: var(--color-text-secondary);
}

.btn-outline:hover {
    border-color: var(--color-text-muted);
    color: var(--color-text);
    background: var(--color-bg-alt);
}

/* Sizes */
.btn-sm {
    padding: 6px 14px;
    font-size: 0.8125rem;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: var(--space-3) var(--space-6);
    font-size: var(--text-base);
}

/* Icon-only */
.btn-icon {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: var(--radius-sm);
}

/* Secondary / muted */
.btn-secondary {
    background: var(--color-bg-alt);
    border-color: var(--color-border);
    color: var(--color-text-secondary);
}

.btn-secondary:hover {
    background: var(--color-border);
    color: var(--color-text);
}

/* Danger */
.btn-danger {
    background: var(--color-error);
    border-color: var(--color-error);
    color: #ffffff;
}

.btn-danger:hover {
    opacity: 0.88;
}

/* ---------- Hero Section ---------- */
.hero {
    padding: var(--space-20) 0 var(--space-16);
    text-align: center;
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border-light);
}

.hero h1 {
    font-size: var(--text-4xl);
    font-weight: 700;
    margin-bottom: var(--space-4);
    letter-spacing: -0.02em;
    color: #0167da;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hero-sub {
    font-size: var(--text-lg);
    color: var(--color-text-secondary);
    max-width: 600px;
    margin: 0 auto var(--space-8);
    line-height: var(--leading-relaxed);
}

.hero-search {
    max-width: 560px;
    margin: 0 auto;
    position: relative;
}

.search-input {
    width: 100%;
    padding: var(--space-4) var(--space-5);
    font-size: var(--text-base);
    font-family: var(--font-sans);
    border: 2px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
    transition: border-color var(--transition-fast);
}

.search-input:focus {
    border-color: var(--color-primary);
}

.search-input::placeholder {
    color: var(--color-text-muted);
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: 0 12px 32px var(--color-shadow-md);
    max-height: 360px;
    overflow-y: auto;
    z-index: 50;
    display: none;
    margin-top: var(--space-2);
}

.search-results.active {
    display: block;
}

.search-result-item {
    display: block;
    padding: var(--space-3) var(--space-4);
    color: var(--color-text);
    border-bottom: 1px solid var(--color-border-light);
    transition: background var(--transition-fast);
}

.search-result-item:hover {
    background: var(--color-bg-alt);
    color: var(--color-text);
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item .result-name {
    font-weight: 500;
}

.search-result-item .result-category {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    margin-top: 2px;
}

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

.section-title {
    font-size: var(--text-2xl);
    text-align: center;
    margin-bottom: var(--space-3);
}

.section-desc {
    text-align: center;
    color: var(--color-text-secondary);
    max-width: 600px;
    margin: 0 auto var(--space-10);
}

/* ---------- Category Intro Card ---------- */
.category-intro-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: var(--space-6);
    padding: var(--space-6) var(--space-8);
    background: linear-gradient(135deg, #0167da 0%, #024ea8 50%, #012f6b 100%);
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-10);
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(1, 103, 218, 0.3);
}

.category-intro-icon {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-lg);
    color: #ffffff;
    backdrop-filter: blur(8px);
}

.category-intro-content {
    flex: 1;
    position: relative;
    z-index: 1;
}

.category-intro-title {
    font-size: var(--text-2xl);
    font-weight: 700;
    color: #ffffff;
    margin-bottom: var(--space-2);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.category-intro-desc {
    font-size: var(--text-base);
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    line-height: var(--leading-relaxed);
}

.category-intro-accent {
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.category-intro-card::before {
    content: '';
    position: absolute;
    bottom: -30%;
    left: 20%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

@media (max-width: 768px) {
    .category-intro-card {
        flex-direction: column;
        text-align: center;
        padding: var(--space-6);
        gap: var(--space-4);
    }

    .category-intro-icon {
        width: 56px;
        height: 56px;
    }

    .category-intro-title {
        font-size: var(--text-xl);
    }

    .category-intro-desc {
        font-size: var(--text-sm);
    }
}

/* ---------- Category Grid ---------- */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: var(--space-5);
}

.category-grid-sm {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-4);
}

.category-card {
    display: block;
    padding: var(--space-6);
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
    text-decoration: none;
    color: var(--color-text);
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--cat-color, var(--color-primary));
    opacity: 0;
    transition: opacity var(--transition-base);
}

.category-card:hover {
    border-color: var(--cat-color, var(--color-primary));
    box-shadow: 0 4px 16px var(--color-shadow);
    color: var(--color-text);
    transform: translateY(-2px);
}

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

.category-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: var(--color-bg-alt);
    color: var(--cat-color, var(--color-primary));
    border-radius: var(--radius-md);
    font-size: var(--text-xl);
    font-weight: 700;
    margin-bottom: var(--space-3);
    font-family: var(--font-mono);
}

.category-card h3 {
    font-size: var(--text-lg);
    margin-bottom: var(--space-2);
}

.category-card p {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    margin-bottom: var(--space-3);
    line-height: var(--leading-normal);
}

.category-count {
    font-size: var(--text-xs);
    color: var(--color-text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ---------- Tools Grid ---------- */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-4);
}

.tool-card {
    display: block;
    padding: var(--space-5);
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    color: var(--color-text);
    text-decoration: none;
    position: relative;
}

.tool-card:hover {
    border-color: var(--cat-color, var(--color-primary));
    box-shadow: 0 4px 12px var(--color-shadow);
    color: var(--color-text);
    transform: translateY(-1px);
}

.tool-card h3 {
    font-size: var(--text-base);
    margin-bottom: var(--space-2);
}

.tool-card p {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    margin-bottom: 0;
    line-height: var(--leading-normal);
}

.tool-card-arrow {
    position: absolute;
    right: var(--space-4);
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-muted);
    font-size: var(--text-lg);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.tool-card:hover .tool-card-arrow {
    opacity: 1;
}

.tool-category-badge {
    display: inline-block;
    font-size: var(--text-xs);
    color: var(--color-text-secondary);
    background: var(--color-bg-alt);
    border: 1px solid var(--cat-color, var(--color-border));
    padding: 2px 8px;
    border-radius: var(--radius-sm);
    margin-bottom: var(--space-2);
    font-weight: 600;
}

/* ---------- Tools List Compact ---------- */
.tools-list-compact {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
    margin-bottom: var(--space-6);
}

.tool-list-item {
    display: inline-block;
    padding: var(--space-2) var(--space-3);
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-size: var(--text-sm);
    color: var(--color-text);
    transition: all var(--transition-fast);
}

.tool-list-item:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

/* Home category blocks */
.home-category-block {
    margin-bottom: var(--space-8);
    padding-bottom: var(--space-8);
    border-bottom: 1px solid var(--color-border-light);
}

.home-category-block:last-child {
    border-bottom: none;
}

.home-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-4);
}

.home-category-header h3 {
    margin-bottom: 0;
}

.home-category-header h3 a {
    color: var(--color-text);
}

.home-category-header h3 a:hover {
    color: var(--color-primary);
}

.view-all-link {
    font-size: var(--text-sm);
    font-weight: 500;
}

/* ---------- Features Grid ---------- */
.about-content {
    max-width: var(--container-narrow);
    margin: 0 auto;
}

.about-content h2 {
    text-align: center;
    margin-bottom: var(--space-8);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-6);
}

.feature {
    padding: var(--space-6);
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
}

.feature h3 {
    font-size: var(--text-base);
    margin-bottom: var(--space-2);
}

.feature p {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    margin-bottom: 0;
}

/* ---------- Breadcrumbs ---------- */
.breadcrumbs {
    padding: var(--space-4) 0;
}

.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: var(--space-1);
}

.breadcrumbs li {
    display: flex;
    align-items: center;
    margin: 0;
    font-size: var(--text-sm);
    color: var(--color-text-muted);
}

.breadcrumbs li + li::before {
    content: '/';
    margin-right: var(--space-1);
    color: var(--color-text-muted);
}

.breadcrumbs a {
    color: var(--color-text-secondary);
}

.breadcrumbs a:hover {
    color: var(--color-primary);
}

/* ---------- Category Header ---------- */
.category-header {
    padding: var(--space-8) 0;
    margin-bottom: var(--space-6);
    border-bottom: 1px solid var(--color-border-light);
}

.category-header h1 {
    font-size: var(--text-3xl);
    position: relative;
    display: inline-block;
}

.category-header h1::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 48px;
    height: 3px;
    background: var(--cat-color, var(--color-primary));
    border-radius: 2px;
}

.category-desc {
    color: var(--color-text-secondary);
    max-width: 640px;
    margin-bottom: var(--space-2);
}

.category-meta {
    font-size: var(--text-sm);
    color: var(--color-text-muted);
    margin-bottom: 0;
}

.category-filter {
    margin-bottom: var(--space-6);
}

.related-categories {
    margin-top: var(--space-12);
    padding-top: var(--space-8);
    border-top: 1px solid var(--color-border-light);
}

/* ---------- Tool Page ---------- */
.tool-page {
    padding-bottom: var(--space-12);
}

.tool-header {
    padding: var(--space-6) 0 var(--space-4);
}

.tool-header h1 {
    font-size: var(--text-3xl);
    margin-bottom: var(--space-3);
}

.tool-subtitle {
    color: var(--color-text-secondary);
    font-size: var(--text-lg);
    margin-bottom: 0;
}

/* Tool Widget */
.tool-widget {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--space-6);
    margin-bottom: var(--space-10);
}

.tool-layout-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-6);
}

.tool-layout-center {
    max-width: 640px;
    margin: 0 auto;
}

.tool-textarea {
    width: 100%;
    padding: var(--space-3) var(--space-4);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-bg-input);
    color: var(--color-text);
    resize: vertical;
    outline: none;
    transition: border-color var(--transition-fast);
    line-height: var(--leading-normal);
}

.tool-textarea:focus {
    border-color: var(--color-primary);
}

.tool-textarea.tool-code {
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    tab-size: 2;
}

.tool-textarea[readonly] {
    background: var(--color-bg-code);
}

.tool-input-area label,
.tool-output-area label {
    display: block;
    font-weight: 500;
    font-size: var(--text-sm);
    margin-bottom: var(--space-2);
    color: var(--color-text);
}

.tool-options {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
    margin: var(--space-3) 0;
}

.tool-option {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    cursor: pointer;
}

.tool-actions {
    display: flex;
    gap: var(--space-2);
    margin-top: var(--space-3);
    flex-wrap: wrap;
}

.tool-actions-center {
    text-align: center;
    margin: var(--space-6) 0;
}

/* Tool Stats (word counter etc.) */
.tool-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: var(--space-3);
    margin-bottom: var(--space-4);
}

.stat-item {
    padding: var(--space-3);
    background: var(--color-bg-alt);
    border-radius: var(--radius-sm);
    text-align: center;
}

.stat-value {
    display: block;
    font-size: var(--text-2xl);
    font-weight: 700;
    color: var(--color-text);
}

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

/* ---------- Calculator Styles ---------- */
.calc-form {
    background: var(--color-bg-alt);
    padding: var(--space-6);
    border-radius: var(--radius-md);
}

.calc-field {
    margin-bottom: var(--space-4);
}

.calc-field label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
}

.calc-field input,
.calc-field select {
    width: 100%;
    padding: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
    transition: border-color var(--transition-fast);
}

.calc-field input:focus,
.calc-field select:focus {
    border-color: var(--color-primary);
}

.field-hint {
    display: block;
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    margin-top: var(--space-1);
}

.calc-result {
    margin-top: var(--space-6);
    padding: var(--space-6);
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
}

.calc-result h3 {
    margin-bottom: var(--space-4);
}

.result-display {
    font-size: var(--text-lg);
    font-weight: 600;
    padding: var(--space-4);
    background: var(--color-bg-card);
    border-radius: var(--radius-sm);
    text-align: center;
}

.result-item {
    display: flex;
    justify-content: space-between;
    padding: var(--space-3) 0;
    border-bottom: 1px solid var(--color-border-light);
    font-size: var(--text-sm);
}

.result-item:last-child {
    border-bottom: none;
}

.result-label {
    color: var(--color-text-secondary);
}

.result-value {
    font-weight: 600;
}

/* ---------- Converter Styles ---------- */
.converter-row {
    display: flex;
    align-items: flex-end;
    gap: var(--space-3);
    flex-wrap: wrap;
}

.converter-field {
    flex: 1;
    min-width: 140px;
}

.converter-field label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
}

.converter-field input,
.converter-field select {
    width: 100%;
    padding: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
}

.converter-field input:focus,
.converter-field select:focus {
    border-color: var(--color-primary);
}

.converter-result {
    margin-top: var(--space-6);
}

/* ---------- CSS Generator Styles ---------- */
.tool-controls-area {
    padding-right: var(--space-4);
    border-right: 1px solid var(--color-border-light);
}

.tool-controls-area h3 {
    margin-bottom: var(--space-4);
}

.css-control {
    margin-bottom: var(--space-4);
}

.css-control label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
}

.range-group {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.range-group input[type="range"] {
    flex: 1;
    accent-color: var(--color-primary);
}

.range-value {
    font-size: var(--text-sm);
    font-weight: 500;
    min-width: 48px;
    text-align: right;
    font-family: var(--font-mono);
}

.css-preview {
    background-color: #1a1a2e;
    background-image:
        radial-gradient(circle at 50% 50%, rgba(99, 102, 241, 0.06) 0%, transparent 70%),
        linear-gradient(45deg, rgba(255,255,255,0.02) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.02) 75%),
        linear-gradient(45deg, rgba(255,255,255,0.02) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.02) 75%);
    background-size: 100% 100%, 24px 24px, 24px 24px;
    background-position: center, 0 0, 12px 12px;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    margin-bottom: var(--space-6);
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 24px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.05);
}

.css-preview-element {
    width: 250px;
    height: 250px;
    padding: var(--space-4);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: #fff;
    font-weight: 600;
    font-size: 1.25rem;
    transition: all 0.15s ease-out;
    position: relative;
    z-index: 10;
}

/* ---- Tool-Specific Preview Inner Styles ---- */
.preview-card {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
    box-sizing: border-box;
}
.preview-card .preview-icon {
    font-size: 2.5rem;
    line-height: 1;
}
.preview-card h4 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}
.preview-card p {
    margin: 0;
    font-size: 0.8rem;
    opacity: 0.75;
    line-height: 1.4;
}

.preview-text-display {
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.2;
    text-align: center;
    font-family: Georgia, 'Times New Roman', serif;
}

.preview-image-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
.preview-image-placeholder .landscape {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, #87CEEB 0%, #87CEEB 55%, #228B22 55%, #228B22 75%, #8B4513 75%);
}
.preview-image-placeholder .sun {
    position: absolute;
    top: 18%;
    left: 25%;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #FFD700;
    box-shadow: 0 0 20px rgba(255,215,0,0.6);
}
.preview-image-placeholder .cloud {
    position: absolute;
    top: 12%;
    right: 20%;
    width: 60px;
    height: 25px;
    background: rgba(255,255,255,0.9);
    border-radius: 20px;
}

.preview-flex-child {
    min-width: 48px;
    min-height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    color: #fff;
    flex-shrink: 0;
}

.preview-grid-cell {
    background: rgba(99, 102, 241, 0.3);
    border: 1px solid rgba(99, 102, 241, 0.5);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.8rem;
    color: #e0e0ff;
    min-height: 40px;
    transition: background 0.2s;
}

.preview-glass-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f857a6 100%);
    z-index: 1;
}
.css-preview-element.glass-mode {
    z-index: 10;
    position: relative;
}

.preview-knob {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
}

.preview-playing-card {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-size: 2.5rem;
    background: white;
    color: #1a1a2e;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.preview-playing-card span {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.5;
}

.preview-notification {
    width: 100%;
    padding: 16px 20px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.85rem;
    box-shadow: 0 4px 16px rgba(99,102,241,0.4);
}
.preview-notification .notif-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}
.preview-notification .notif-body h5 {
    margin: 0 0 2px;
    font-size: 0.9rem;
    font-weight: 700;
}
.preview-notification .notif-body p {
    margin: 0;
    font-size: 0.75rem;
    opacity: 0.8;
}

.preview-swatch-label {
    font-size: 0.65rem;
    font-weight: 600;
    text-align: center;
    padding: 4px 0;
    color: rgba(255,255,255,0.9);
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    position: absolute;
    bottom: 4px;
    left: 0;
    right: 0;
}
.preview-swatch {
    position: relative;
    flex: 1;
    height: 100%;
}

.preview-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    flex-shrink: 0;
}

.code-output {
    background: var(--color-bg-code);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    overflow-x: auto;
    margin-bottom: var(--space-3);
}

.code-output code {
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    color: var(--color-text);
    white-space: pre;
}

/* ---------- Random Generator Styles ---------- */
.generator-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-4);
    padding: var(--space-6);
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-4);
}

.gen-control label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
}

.gen-control input[type="number"],
.gen-control select {
    width: 100%;
    padding: var(--space-2) var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
}

.generator-result {
    margin-top: var(--space-4);
    padding: var(--space-6);
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    text-align: center;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    cursor: pointer;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--color-border);
    border-radius: 24px;
    transition: var(--transition-fast);
}

.toggle-slider::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: var(--transition-fast);
}

.toggle-switch input:checked + .toggle-slider {
    background: var(--color-primary);
}

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(20px);
}

/* ---------- Toast Notification ---------- */
.toast {
    position: fixed;
    bottom: var(--space-6);
    right: var(--space-6);
    padding: var(--space-3) var(--space-5);
    background: var(--color-text);
    color: var(--color-bg);
    border-radius: var(--radius-md);
    font-size: var(--text-sm);
    font-weight: 500;
    z-index: 300;
    opacity: 0;
    transform: translateY(10px);
    transition: all var(--transition-base);
    pointer-events: none;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- Footer ---------- */
.site-footer {
    background: var(--color-footer-bg);
    color: var(--color-footer-text);
    padding: var(--space-12) 0 var(--space-6);
    margin-top: auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: var(--space-8);
    margin-bottom: var(--space-8);
    padding-bottom: var(--space-8);
    border-bottom: 1px solid #1f232e;
}

.footer-brand .logo {
    margin-bottom: var(--space-4);
}

.footer-brand .logo-text {
    color: #e8eaed;
}

.footer-desc {
    font-size: var(--text-sm);
    line-height: var(--leading-relaxed);
    color: var(--color-footer-text);
    margin: 0;
}

.footer-links h4 {
    color: #e8eaed;
    font-size: var(--text-sm);
    font-weight: 600;
    margin-bottom: var(--space-4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-links ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: var(--space-2);
}

.footer-links a {
    color: var(--color-footer-text);
    font-size: var(--text-sm);
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: #e8eaed;
}

/* ---------- Footer Bottom ---------- */
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-3);
    padding-top: var(--space-2);
}

.footer-bottom > p {
    font-size: 0.75rem;
    color: var(--color-footer-text);
    margin: 0;
    flex: 1;
    min-width: 0;
}

/* Right side: links + hosted-by, all inline and same size */
.footer-bottom-right {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    flex-shrink: 0;
    flex-wrap: nowrap;
    white-space: nowrap;
}

.footer-bottom-links {
    display: flex;
    gap: var(--space-4);
}

.footer-bottom-links a {
    font-size: 0.75rem;
    color: var(--color-footer-text);
    transition: color var(--transition-fast);
}

.footer-bottom-links a:hover {
    color: #e8eaed;
}

.footer-hosted-divider {
    font-size: 0.75rem;
    color: var(--color-footer-text);
    opacity: 0.4;
    user-select: none;
}

.footer-hosted-label {
    font-size: 0.75rem;
    color: var(--color-footer-text);
    white-space: nowrap;
    line-height: 1;
}

.footer-alastyr-link {
    display: inline-flex;
    align-items: center;
    opacity: 0.75;
    transition: opacity var(--transition-fast);
    text-decoration: none;
    line-height: 0;
}

.footer-alastyr-link:hover {
    opacity: 1;
}

.alastyr-logo-img {
    display: block;
    height: 13px;
    width: auto;
}

/* ---------- Empty State ---------- */
.empty-state {
    text-align: center;
    padding: var(--space-12);
    color: var(--color-text-secondary);
}

.empty-state h3 {
    margin-bottom: var(--space-2);
}

/* ---------- FAQ ---------- */
.faq-list {
    margin-top: var(--space-6);
}

.faq-item {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-3);
    overflow: hidden;
}

.faq-item summary {
    padding: var(--space-4) var(--space-5);
    font-weight: 500;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background var(--transition-fast);
}

.faq-item summary:hover {
    background: var(--color-bg-alt);
}

.faq-answer {
    padding: 0 var(--space-5) var(--space-4);
    color: var(--color-text-secondary);
    line-height: var(--leading-relaxed);
    font-size: var(--text-sm);
}

/* ---------- Related Tools ---------- */
.related-tools {
    padding-top: var(--space-8);
    border-top: 1px solid var(--color-border-light);
}

.related-tools h2 {
    margin-bottom: var(--space-6);
}

/* ---------- Static Pages ---------- */
.static-page {
    max-width: var(--container-narrow);
    margin: 0 auto;
    padding: var(--space-6) 0 var(--space-16);
}

.static-page h1 {
    font-size: var(--text-3xl);
    margin-bottom: var(--space-2);
}

.page-updated {
    color: var(--color-text-muted);
    font-size: var(--text-sm);
    margin-bottom: var(--space-8);
}

.page-content h2 {
    font-size: var(--text-xl);
    margin-top: var(--space-8);
    margin-bottom: var(--space-3);
}

.page-content h3 {
    font-size: var(--text-lg);
    margin-top: var(--space-6);
    margin-bottom: var(--space-3);
}

.page-content p,
.page-content li {
    color: var(--color-text-secondary);
    line-height: var(--leading-relaxed);
}

.page-content a {
    text-decoration: underline;
}

/* Contact Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    max-width: 520px;
}

.form-group label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--color-primary);
}

/* Alerts */
.alert {
    padding: var(--space-4);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-6);
    font-size: var(--text-sm);
}

.alert-success {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

.alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

[data-theme="dark"] .alert-success {
    background: #052e16;
    border-color: #166534;
    color: #a7f3d0;
}

[data-theme="dark"] .alert-error {
    background: #450a0a;
    border-color: #991b1b;
    color: #fecaca;
}

/* ---------- Error Page ---------- */
.error-page {
    text-align: center;
    padding: var(--space-16) 0;
}

.error-code {
    font-size: 6rem;
    font-weight: 800;
    color: var(--color-border);
    line-height: 1;
    margin-bottom: var(--space-4);
}

.error-page h1 {
    margin-bottom: var(--space-4);
}

.error-page p {
    color: var(--color-text-secondary);
    max-width: 480px;
    margin: 0 auto var(--space-8);
}

.error-actions {
    margin-bottom: var(--space-12);
}

.error-categories h2 {
    margin-bottom: var(--space-6);
}

/* ---------- Cookie Banner ---------- */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    background: var(--color-bg-card);
    border-top: 1px solid var(--color-border);
    box-shadow: 0 -4px 16px var(--color-shadow);
    z-index: 200;
    padding: var(--space-4) 0;
    box-sizing: border-box;
    overflow: hidden;
}

.cookie-inner {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-6);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
}

.cookie-inner p {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    margin: 0;
}

.cookie-buttons {
    display: flex;
    gap: var(--space-2);
    flex-shrink: 0;
}

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

@media (max-width: 768px) {
    :root {
        --text-3xl: 1.5rem;
        --text-4xl: 1.875rem;
    }

    .hero h1 {
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
        font-size: 1.75rem;
    }

    .mobile-toggle {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: min(88vw, 380px);
        background: var(--color-bg);
        border-left: 1px solid var(--color-border);
        padding: calc(64px + var(--space-5)) var(--space-4) var(--space-6);
        transform: translateX(100%);
        transition: transform 280ms ease-out;
        overflow-y: auto;
        overflow-x: hidden;
        z-index: 99;
        box-shadow: -4px 0 16px rgba(0, 0, 0, 0.12);
        -webkit-overflow-scrolling: touch;
        visibility: hidden;
        will-change: transform;
    }

    .main-nav.open {
        transform: translateX(0);
        visibility: visible;
    }

    /* Close button inside the panel */
    .mobile-close {
        position: absolute;
        top: 16px;
        right: 16px;
        width: 40px;
        height: 40px;
        border: 1px solid var(--color-border);
        border-radius: 10px;
        background: var(--color-bg-card);
        color: var(--color-text);
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 10;
        transition: border-color var(--transition-fast), color var(--transition-fast);
    }

    .mobile-close:hover {
        border-color: #2563eb;
        color: #2563eb;
    }

    .nav-list {
        flex-direction: column;
        gap: 4px;
        position: relative;
        z-index: 2;
    }

    .nav-list > li {
        opacity: 0;
        transform: translateX(12px);
        animation: navItemIn 280ms ease-out forwards;
    }

    .main-nav.open .nav-list > li:nth-child(1) { animation-delay: 60ms; }
    .main-nav.open .nav-list > li:nth-child(2) { animation-delay: 80ms; }
    .main-nav.open .nav-list > li:nth-child(3) { animation-delay: 100ms; }
    .main-nav.open .nav-list > li:nth-child(4) { animation-delay: 120ms; }
    .main-nav.open .nav-list > li:nth-child(5) { animation-delay: 140ms; }
    .main-nav.open .nav-list > li:nth-child(6) { animation-delay: 160ms; }
    .main-nav.open .nav-list > li:nth-child(7) { animation-delay: 180ms; }
    .main-nav.open .nav-list > li:nth-child(8) { animation-delay: 200ms; }
    .main-nav.open .nav-list > li:nth-child(n+9) { animation-delay: 220ms; }

    @keyframes navItemIn {
        to {
            opacity: 1;
            transform: translateX(0);
        }
    }

    .nav-list a,
    .nav-dropdown-toggle {
        padding: var(--space-3) var(--space-4);
        width: 100%;
        justify-content: flex-start;
        font-size: var(--text-base);
        border-radius: var(--radius-md);
        color: var(--color-text);
        font-weight: 500;
        position: relative;
        background: var(--color-bg-card);
        border: 1px solid var(--color-border);
        transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
    }

    /* Colorful accent bar on left */
    .nav-list a::before,
    .nav-dropdown-toggle::before {
        content: '';
        position: absolute;
        left: 0;
        top: 50%;
        transform: translateY(-50%) scaleY(0);
        width: 3px;
        height: 60%;
        background: #2563eb;
        border-radius: 0 3px 3px 0;
        transition: transform var(--transition-fast);
    }

    /* Hide shimmer effect on mobile for performance */
    .nav-list a::after,
    .nav-dropdown-toggle::after {
        display: none;
    }

    .nav-list a:hover,
    .nav-list a.active,
    .nav-dropdown-toggle:hover {
        background: var(--color-bg-alt);
        color: var(--color-primary);
        border-color: var(--color-primary);
    }

    .nav-list a:hover::before,
    .nav-list a.active::before,
    .nav-dropdown-toggle:hover::before {
        transform: translateY(-50%) scaleY(1);
    }

    .hero {
        padding: var(--space-10) 0 var(--space-8);
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .tool-layout-split {
        grid-template-columns: 1fr;
    }

    .tool-controls-area {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid var(--color-border-light);
        padding-bottom: var(--space-4);
    }

    .converter-row {
        flex-direction: column;
    }

    .btn-icon {
        align-self: center;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--space-6);
    }

    .footer-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-3);
    }

    .footer-bottom-right {
        flex-wrap: wrap;
        gap: var(--space-2);
    }

    .footer-hosted-divider {
        display: none;
    }

    .cookie-inner {
        flex-direction: column;
        text-align: center;
        padding: 0 var(--space-4);
        gap: var(--space-3);
    }

    .cookie-inner p {
        font-size: var(--text-xs);
        word-break: break-word;
        overflow-wrap: break-word;
    }

    .cookie-buttons {
        justify-content: center;
        width: 100%;
    }

    .cookie-buttons .btn {
        flex: 1;
        max-width: 140px;
    }

    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }

    .tools-grid {
        grid-template-columns: 1fr;
    }

    .qr-options {
        flex-direction: column;
    }

    .home-category-header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-2);
    }

    .generator-options {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 var(--space-4);
    }

    .hero {
        padding: var(--space-8) 0 var(--space-6);
    }

    .section {
        padding: var(--space-10) 0;
    }

    .tool-widget {
        padding: var(--space-4);
    }

    .category-grid {
        grid-template-columns: 1fr;
    }

    .error-code {
        font-size: 4rem;
    }
}

/* ---------- Tables ---------- */
.static-page table, .tool-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: var(--space-6);
    background: var(--color-bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 1px 3px var(--color-shadow);
}

.static-page th, .tool-content th,
.static-page td, .tool-content td {
    padding: var(--space-3) var(--space-4);
    text-align: left;
    border-bottom: 1px solid var(--color-border-light);
}

.static-page th, .tool-content th {
    background: var(--color-bg-alt);
    font-weight: 600;
    color: var(--color-text);
}

.static-page tr:last-child td, .tool-content tr:last-child td {
    border-bottom: none;
}

.static-page tr:hover td, .tool-content tr:hover td {
    background: var(--color-bg-alt);
}

@media (max-width: 768px) {
    .static-page table, .tool-content table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

/* ---------- Print Styles ---------- */
@media print {
    .site-header,
    .site-footer,
    .cookie-banner,
    .toast,
    .tool-widget,
    .tool-actions,
    .related-tools,
    .related-categories {
        display: none;
    }

    body {
        color: #000;
        background: #fff;
    }

    .tool-content,
    .static-page {
        max-width: none;
    }
}

/* ---------- QR Generator Field Styles ---------- */
.qr-field {
    margin-bottom: var(--space-4);
}

.qr-field label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
    color: var(--color-text);
}

.qr-field input,
.qr-field select,
.qr-field textarea {
    width: 100%;
    padding: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
    transition: border-color var(--transition-fast);
    -webkit-appearance: auto;
    appearance: auto;
}

.qr-field input:focus,
.qr-field select:focus,
.qr-field textarea:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-light);
}

.qr-field input[type="color"] {
    height: 40px;
    padding: var(--space-1) var(--space-2);
    cursor: pointer;
}

.qr-options {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
    margin-top: var(--space-3);
    padding: var(--space-4);
    background: var(--color-bg-alt);
    border-radius: var(--radius-sm);
    border: 1px solid var(--color-border-light);
}

.qr-options .qr-field {
    flex: 1;
    min-width: 110px;
    margin-bottom: 0;
}

.qr-preview {
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    padding: var(--space-4);
}

.qr-placeholder {
    color: var(--color-text-muted);
    font-size: var(--text-sm);
    text-align: center;
}

/* ---------- Unit Converter Result Styles ---------- */
.unit-converter-form {
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-5);
    margin-bottom: var(--space-5);
}

.unit-input-row {
    display: flex;
    gap: var(--space-4);
    flex-wrap: wrap;
    align-items: flex-end;
}

.unit-input-field {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.unit-input-value {
    flex: 2;
    min-width: 160px;
}

.unit-input-from {
    flex: 3;
    min-width: 200px;
}

.unit-input-field label {
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--color-text);
}

.unit-input-field input,
.unit-input-field select {
    width: 100%;
    padding: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
    transition: border-color var(--transition-fast);
}

.unit-input-field input:focus,
.unit-input-field select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-light);
}

.unit-results {
    margin-top: var(--space-4);
}

.unit-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: var(--space-3);
}

.unit-result-item {
    padding: var(--space-4);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: border-color var(--transition-fast);
}

.unit-result-item.unit-result-active {
    background: var(--color-primary-light);
    border-color: var(--color-primary);
}

.unit-result-value {
    display: block;
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--color-text);
    font-family: var(--font-mono);
    margin-bottom: var(--space-1);
    word-break: break-all;
}

/* ---------- SERP Preview / SERP Simulator Tool ---------- */
.serp-page {
    padding: var(--space-6) 0 var(--space-10);
}

.serp-page-header {
    text-align: center;
    margin-bottom: var(--space-8);
}

.serp-page-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    font-size: var(--text-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 50px;
    margin-bottom: var(--space-4);
    animation: serp-badge-pulse 3s ease-in-out infinite;
}

@keyframes serp-badge-pulse {
    0%, 100% { box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3); }
    50% { box-shadow: 0 4px 25px rgba(102, 126, 234, 0.5); }
}

.serp-page-badge svg {
    width: 14px;
    height: 14px;
}

.serp-page-title {
    font-size: var(--text-3xl);
    font-weight: 800;
    background: linear-gradient(135deg, #1a1d23 0%, #2563eb 50%, #7c3aed 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--space-3);
    line-height: 1.2;
}

[data-theme="dark"] .serp-page-title {
    background: linear-gradient(135deg, #e8eaed 0%, #60a5fa 50%, #a78bfa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.serp-page-subtitle {
    font-size: var(--text-base);
    color: var(--color-text-secondary);
    max-width: 560px;
    margin: 0 auto;
    line-height: var(--leading-relaxed);
}

/* Main tool card */
.serp-tool-card {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: 0 4px 24px var(--color-shadow);
    max-width: 720px;
    margin: 0 auto;
}

/* Preview Section */
.serp-preview-section {
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    border-bottom: 1px solid var(--color-border-light);
    padding: var(--space-6);
}

[data-theme="dark"] .serp-preview-section {
    background: linear-gradient(180deg, #1a1d27 0%, #0f1117 100%);
    border-bottom-color: #2a2e3a;
}

.serp-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-5);
}

.serp-preview-label {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
}

.serp-preview-label svg {
    color: #667eea;
    animation: serp-icon-spin 8s linear infinite;
}

@keyframes serp-icon-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.serp-device-tabs {
    display: flex;
    background: var(--color-bg-alt);
    border-radius: var(--radius-md);
    padding: 3px;
    gap: 2px;
}

.serp-device-tab {
    display: flex;
    align-items: center;
    gap: var(--space-1);
    padding: var(--space-1) var(--space-3);
    font-size: var(--text-xs);
    font-weight: 500;
    color: var(--color-text-secondary);
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.serp-device-tab svg {
    width: 14px;
    height: 14px;
}

.serp-device-tab:hover {
    color: var(--color-text);
}

.serp-device-tab.active {
    background: var(--color-bg-card);
    color: #667eea;
    box-shadow: 0 2px 8px var(--color-shadow);
}

/* SERP Preview Card */
.serp-preview-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    cursor: default;
    position: relative;
}

.serp-preview-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2, #f093fb);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.serp-preview-card:hover::before {
    opacity: 1;
}

.serp-preview-card:hover {
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

[data-theme="dark"] .serp-preview-card {
    background: #1e212c;
}

.serp-preview-content {
    padding: 20px 24px;
    transition: all var(--transition-base);
}

.serp-preview-title {
    font-size: 22px;
    line-height: 1.35;
    color: #1a0dab;
    margin-bottom: 4px;
    word-break: break-word;
    overflow-wrap: break-word;
    font-family: Arial, sans-serif;
    transition: color var(--transition-fast);
}

.serp-preview-title:hover {
    text-decoration: underline;
    cursor: pointer;
}

[data-theme="dark"] .serp-preview-title {
    color: #8ab4f8;
}

.serp-preview-title.length-short {
    color: #d97706;
}

.serp-preview-title.length-perfect {
    color: #1a0dab;
}

[data-theme="dark"] .serp-preview-title.length-short {
    color: #fbbf24;
}

[data-theme="dark"] .serp-preview-title.length-perfect {
    color: #8ab4f8;
}

.serp-preview-breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #006621;
    margin-bottom: 6px;
    line-height: 1.5;
    font-family: Arial, sans-serif;
    min-height: 20px;
}

[data-theme="dark"] .serp-preview-breadcrumb {
    color: #81c995;
}

.serp-preview-favicon {
    width: 16px;
    height: 16px;
    background: linear-gradient(135deg, #ea4335, #fbbc05, #34a853, #4885ed);
    border-radius: 3px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.serp-preview-favicon::after {
    content: '';
    width: 6px;
    height: 6px;
    background: white;
    border-radius: 50%;
}

.serp-preview-url {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 450px;
}

.serp-preview-caret {
    display: inline-block;
    width: 0;
    height: 0;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 5px solid #006621;
    flex-shrink: 0;
}

[data-theme="dark"] .serp-preview-caret {
    border-left-color: #81c995;
}

.serp-preview-description {
    font-size: 14px;
    line-height: 1.58;
    color: #3c4043;
    font-family: Arial, sans-serif;
    word-break: break-word;
    overflow-wrap: break-word;
}

[data-theme="dark"] .serp-preview-description {
    color: #bdc1c6;
}

/* Mobile preview variant */
.serp-preview-card.serp-mobile .serp-preview-content {
    padding: 16px 18px;
}

.serp-preview-card.serp-mobile .serp-preview-title {
    font-size: 18px;
}

.serp-preview-card.serp-mobile .serp-preview-url {
    max-width: 280px;
}

.serp-preview-card.serp-mobile .serp-preview-description {
    font-size: 13px;
    line-height: 1.5;
}

/* Counter Section in Preview */
.serp-preview-counters {
    display: flex;
    gap: var(--space-4);
    margin-top: var(--space-4);
    padding-top: var(--space-4);
    border-top: 1px dashed var(--color-border-light);
}

[data-theme="dark"] .serp-preview-counters {
    border-top-color: #2a2e3a;
}

.serp-counter-item {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.serp-counter-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-base);
}

.serp-counter-icon svg {
    width: 16px;
    height: 16px;
}

.serp-counter-icon.icon-optimal {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.serp-counter-icon.icon-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
    animation: serp-warning-pulse 1.5s ease-in-out infinite;
}

.serp-counter-icon.icon-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
    animation: serp-danger-pulse 1s ease-in-out infinite;
}

@keyframes serp-warning-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes serp-danger-pulse {
    0%, 100% { transform: scale(1); box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3); }
    50% { transform: scale(1.08); box-shadow: 0 2px 16px rgba(239, 68, 68, 0.5); }
}

.serp-counter-info {
    display: flex;
    flex-direction: column;
}

.serp-counter-value {
    font-size: var(--text-lg);
    font-weight: 700;
    font-family: var(--font-mono);
    line-height: 1.2;
}

.serp-counter-value.counter-optimal {
    color: #10b981;
}

.serp-counter-value.counter-warning {
    color: #f59e0b;
}

.serp-counter-value.counter-danger {
    color: #ef4444;
}

.serp-counter-label {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    font-weight: 500;
}

/* Input Section */
.serp-input-section {
    padding: var(--space-6);
}

.serp-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
}

.serp-input-group {
    position: relative;
}

.serp-input-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-2);
}

.serp-input-label {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
}

.serp-input-label svg {
    width: 16px;
    height: 16px;
    color: #667eea;
}

.serp-char-counter {
    display: flex;
    align-items: center;
    gap: var(--space-1);
    font-size: var(--text-xs);
    font-weight: 600;
    font-family: var(--font-mono);
    padding: 3px 10px;
    border-radius: 50px;
    transition: all var(--transition-base);
}

.serp-char-counter.counter-optimal {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    color: #047857;
}

[data-theme="dark"] .serp-char-counter.counter-optimal {
    background: linear-gradient(135deg, #064e3b, #065f46);
    color: #6ee7b7;
}

.serp-char-counter.counter-warning {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #b45309;
    animation: serp-counter-warning 2s ease-in-out infinite;
}

[data-theme="dark"] .serp-char-counter.counter-warning {
    background: linear-gradient(135deg, #78350f, #92400e);
    color: #fcd34d;
}

.serp-char-counter.counter-danger {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    color: #b91c1c;
    animation: serp-counter-danger 1s ease-in-out infinite;
}

[data-theme="dark"] .serp-char-counter.counter-danger {
    background: linear-gradient(135deg, #7f1d1d, #991b1b);
    color: #fca5a5;
}

@keyframes serp-counter-warning {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

@keyframes serp-counter-danger {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.06); }
}

.serp-char-counter .counter-icon {
    width: 12px;
    height: 12px;
}

.serp-char-counter .counter-icon.icon-check {
    color: #10b981;
}

.serp-char-counter .counter-icon.icon-warning {
    color: #f59e0b;
}

.serp-char-counter .counter-icon.icon-x {
    color: #ef4444;
}

.serp-input-field {
    width: 100%;
    padding: var(--space-4);
    font-family: var(--font-sans);
    font-size: var(--text-base);
    border: 2px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: var(--color-bg-input);
    color: var(--color-text);
    outline: none;
    transition: all var(--transition-fast);
    line-height: var(--leading-normal);
}

.serp-input-field:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.15);
}

.serp-input-field:hover:not(:focus) {
    border-color: var(--color-text-muted);
}

.serp-input-field::placeholder {
    color: var(--color-text-muted);
}

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

.serp-input-hint {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    margin-top: var(--space-1);
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

.serp-input-hint svg {
    width: 12px;
    height: 12px;
}

/* Action Buttons */
.serp-actions {
    display: flex;
    gap: var(--space-3);
    margin-top: var(--space-2);
}

.serp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    font-family: var(--font-sans);
    font-size: var(--text-sm);
    font-weight: 600;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-fast);
    outline: none;
}

.serp-btn svg {
    width: 16px;
    height: 16px;
}

.serp-btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(102, 126, 234, 0.35);
}

.serp-btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd6 0%, #6a4190 100%);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.45);
    transform: translateY(-1px);
}

.serp-btn-primary:active {
    transform: translateY(0);
}

.serp-btn-outline {
    background: transparent;
    border: 2px solid var(--color-border);
    color: var(--color-text-secondary);
}

.serp-btn-outline:hover {
    border-color: #667eea;
    color: #667eea;
    background: rgba(102, 126, 234, 0.05);
}

/* Analysis Section */
.serp-analysis-section {
    padding: var(--space-6);
    border-top: 1px solid var(--color-border-light);
    background: linear-gradient(180deg, transparent, rgba(102, 126, 234, 0.02));
}

[data-theme="dark"] .serp-analysis-section {
    border-top-color: #2a2e3a;
    background: linear-gradient(180deg, transparent, rgba(102, 126, 234, 0.05));
}

.serp-analysis-header {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    margin-bottom: var(--space-5);
}

.serp-analysis-header svg {
    width: 20px;
    height: 20px;
    color: #667eea;
}

.serp-analysis-header h3 {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--color-text);
    margin: 0;
}

.serp-analysis-grid {
    display: grid;
    gap: var(--space-3);
}

.serp-analysis-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-4);
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
}

.serp-analysis-item:hover {
    border-color: #667eea;
    box-shadow: 0 2px 12px rgba(102, 126, 234, 0.1);
}

.serp-analysis-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

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

.serp-analysis-icon.pass {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    color: #047857;
}

.serp-analysis-icon.warning {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #b45309;
}

.serp-analysis-icon.error {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    color: #b91c1c;
}

.serp-analysis-content {
    flex: 1;
    min-width: 0;
}

.serp-analysis-title {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 2px;
}

.serp-analysis-desc {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    line-height: var(--leading-normal);
}

/* Feature Cards */
.serp-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--space-4);
    margin-top: var(--space-8);
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
}

.serp-feature-card {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--space-5);
    text-align: center;
    transition: all var(--transition-fast);
}

.serp-feature-card:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.1);
}

.serp-feature-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #667eea20, #764ba220);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-3);
}

.serp-feature-icon svg {
    width: 24px;
    height: 24px;
    color: #667eea;
}

.serp-feature-card h4 {
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: var(--space-1);
}

.serp-feature-card p {
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    margin: 0;
    line-height: var(--leading-normal);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .serp-page {
        padding: var(--space-4) 0 var(--space-8);
    }

    .serp-page-title {
        font-size: var(--text-2xl);
    }

    .serp-preview-header {
        flex-direction: column;
        gap: var(--space-3);
        align-items: flex-start;
    }

    .serp-preview-counters {
        flex-direction: column;
        gap: var(--space-3);
    }

    .serp-preview-title {
        font-size: 18px;
    }

    .serp-preview-description {
        font-size: 13px;
    }

    .serp-actions {
        flex-direction: column;
    }

    .serp-btn {
        width: 100%;
    }

    .serp-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .serp-tool-card {
        border-radius: var(--radius-lg);
    }

    .serp-preview-content {
        padding: 16px;
    }

    .serp-input-section {
        padding: var(--space-4);
    }

    .serp-analysis-section {
        padding: var(--space-4);
    }

    .serp-char-counter {
        font-size: 10px;
        padding: 2px 8px;
    }
}

.unit-result-label {
    display: block;
    font-size: var(--text-xs);
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

@media (max-width: 480px) {
    .unit-input-row {
        flex-direction: column;
    }
    .unit-input-value,
    .unit-input-from {
        min-width: 0;
        width: 100%;
    }
    .unit-results-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* Truncation warning */
.serp-truncation-warning {
    margin-top: var(--space-3);
    padding: var(--space-3) var(--space-4);
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 1px solid #f59e0b;
    border-radius: var(--radius-md);
    font-size: var(--text-xs);
    color: #92400e;
    line-height: var(--leading-normal);
    animation: serp-truncation-shake 0.5s ease-in-out;
}

[data-theme="dark"] .serp-truncation-warning {
    background: linear-gradient(135deg, #78350f, #92400e);
    border-color: #f59e0b;
    color: #fde047;
}

@keyframes serp-truncation-shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-4px); }
    40%, 80% { transform: translateX(4px); }
}

/* Truncated text style */
.serp-preview-title.serp-truncated,
.serp-preview-description.serp-truncated {
    color: #b45309;
}

[data-theme="dark"] .serp-preview-title.serp-truncated,
[data-theme="dark"] .serp-preview-description.serp-truncated {
    color: #fbbf24;
}
