/* ============================================
   BestTools - Professional CSS Styles
   Modern Dark/Light Mode Design
   ============================================ */

/* CSS Variables - Dark Mode (Default) */
:root {
    /* Colors */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: #1a1a24;
    --bg-card-hover: #22222e;
    --accent-primary: #6366f1;
    --accent-secondary: #818cf8;
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: #2d2d3a;
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;

    /* Shadows */
    --card-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
    --card-hover-shadow: 0 8px 32px rgba(99, 102, 241, 0.2);
    --glow: 0 0 20px rgba(99, 102, 241, 0.3);

    /* Typography */
    --font-heading: 'Sora', sans-serif;
    --font-body: 'DM Sans', sans-serif;

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-full: 50%;
}

/* Light Mode Variables */
[data-theme="light"] {
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-card: #ffffff;
    --bg-card-hover: #f1f5f9;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --border-color: #e2e8f0;
    --card-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    --card-hover-shadow: 0 8px 32px rgba(99, 102, 241, 0.15);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

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

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

/* Ad Banner Placeholder */
.ad-banner {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 90px;
}

.ad-placeholder {
    color: var(--text-muted);
    font-size: 0.875rem;
    padding: var(--space-md);
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-sm);
}

.top-ad {
    position: sticky;
    top: 0;
    z-index: 100;
}

.middle-ad {
    margin: var(--space-2xl) 0;
}

.footer-ad {
    margin-bottom: var(--space-lg);
    min-height: 60px;
}

/* ============================================
   Navigation
   ============================================ */
.navbar {
    position: fixed;
    top: 90px;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

[data-theme="light"] .navbar {
    background: rgba(255, 255, 255, 0.8);
}

.navbar.scrolled {
    top: 0;
    box-shadow: var(--card-shadow);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: var(--space-md) var(--space-lg);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.5rem;
}

.logo-icon {
    font-size: 1.75rem;
}

.logo-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: var(--space-xl);
}

.nav-link {
    font-weight: 500;
    color: var(--text-secondary);
    transition: color 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.theme-toggle {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: var(--space-sm) var(--space-md);
    cursor: pointer;
    font-size: 1.25rem;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background: var(--bg-card-hover);
    transform: scale(1.05);
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--space-sm);
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: var(--glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    filter: brightness(1.1);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--accent-primary);
    color: var(--accent-primary);
}

.btn-outline:hover {
    background: var(--accent-primary);
    color: white;
}

.btn-large {
    padding: var(--space-md) var(--space-2xl);
    font-size: 1.125rem;
}

.nav-cta {
    padding: var(--space-sm) var(--space-lg);
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    padding: calc(140px + var(--space-3xl)) 0 var(--space-3xl);
    position: relative;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: -1;
}

.hero-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    animation: float 20s ease-in-out infinite;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: var(--accent-primary);
    top: -100px;
    right: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: #a855f7;
    bottom: -50px;
    left: 20%;
    animation-delay: -5s;
}

.shape-3 {
    width: 250px;
    height: 250px;
    background: #06b6d4;
    top: 50%;
    right: 30%;
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -30px) scale(1.05); }
    50% { transform: translate(-20px, 20px) scale(0.95); }
    75% { transform: translate(20px, 30px) scale(1.02); }
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-3xl);
    align-items: center;
}

.hero-content {
    animation: fadeInUp 0.8s ease-out;
}

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

.hero-title {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--space-lg);
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-desc {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-xl);
    max-width: 500px;
}

.hero-search {
    display: flex;
    gap: var(--space-sm);
    margin-bottom: var(--space-xl);
}

.search-input {
    flex: 1;
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-sm);
    border: 2px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: border-color 0.3s ease;
}

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

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

.search-btn {
    padding: var(--space-md) var(--space-lg);
    background: var(--accent-gradient);
    border: none;
    border-radius: var(--radius-sm);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-btn:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.hero-stats {
    display: flex;
    gap: var(--space-2xl);
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.hero-visual {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-card {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
    padding: var(--space-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all 0.3s ease;
    cursor: pointer;
}

.hero-card:hover {
    transform: translateX(-10px);
    border-color: var(--accent-primary);
    box-shadow: var(--card-hover-shadow);
}

.hero-card-icon {
    font-size: 2.5rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
}

.hero-card-text h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: var(--space-xs);
}

.hero-card-text p {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.card-2 { margin-right: var(--space-2xl); }
.card-3 { margin-right: var(--space-xl); }

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

.section-header {
    text-align: center;
    margin-bottom: var(--space-2xl);
}

.section-tag {
    display: inline-block;
    padding: var(--space-sm) var(--space-md);
    background: var(--accent-gradient);
    color: white;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-md);
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--space-md);
}

.section-desc {
    color: var(--text-secondary);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

.section-cta {
    text-align: center;
    margin-top: var(--space-2xl);
}

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

.tool-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.tool-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--accent-gradient);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.tool-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-primary);
    box-shadow: var(--card-hover-shadow);
}

.tool-card:hover::before {
    opacity: 0.05;
}

.tool-card-image {
    height: 180px;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
    overflow: hidden;
    padding: 20px;
}

.tool-card-image img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.tool-card:hover .tool-card-image img {
    transform: scale(1.05);
}

.tool-card-icon {
    font-size: 4rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-card-content {
    padding: var(--space-lg);
    position: relative;
    z-index: 1;
}

.tool-card-category {
    display: inline-block;
    padding: var(--space-xs) var(--space-sm);
    background: var(--bg-secondary);
    color: var(--accent-secondary);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-sm);
}

.tool-card-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
}

.tool-card-desc {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: var(--space-md);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tool-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tool-card-rating {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}

.stars {
    color: #fbbf24;
    font-size: 0.875rem;
}

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

.rating-count {
    color: var(--text-muted);
    font-size: 0.75rem;
}

.tool-card-btn {
    padding: var(--space-sm) var(--space-lg);
    background: var(--accent-gradient);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tool-card-btn:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* ============================================
   Categories Section
   ============================================ */
.categories-section {
    background: var(--bg-secondary);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--space-lg);
}

.category-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.category-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-primary);
    box-shadow: var(--card-hover-shadow);
}

.category-icon {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
}

.category-card h3 {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    margin-bottom: var(--space-sm);
}

.category-count {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* ============================================
   Why Section
   ============================================ */
.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
}

.why-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    transition: all 0.3s ease;
}

.why-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-primary);
}

.why-icon {
    font-size: 3rem;
    margin-bottom: var(--space-md);
}

.why-card h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: var(--space-sm);
}

.why-card p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* ============================================
   Newsletter
   ============================================ */
.newsletter-section {
    background: var(--bg-secondary);
}

.newsletter-box {
    background: var(--accent-gradient);
    border-radius: var(--radius-lg);
    padding: var(--space-2xl);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-xl);
}

.newsletter-content h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    margin-bottom: var(--space-sm);
}

.newsletter-content p {
    opacity: 0.9;
}

.newsletter-form {
    display: flex;
    gap: var(--space-sm);
}

.newsletter-form input {
    padding: var(--space-md) var(--space-lg);
    border: none;
    border-radius: var(--radius-sm);
    background: white;
    color: var(--text-primary);
    font-size: 1rem;
    min-width: 250px;
}

.newsletter-form .btn-primary {
    background: var(--bg-primary);
    color: var(--text-primary);
}

/* ============================================
   Footer
   ============================================ */
.footer {
    background: var(--bg-secondary);
    padding: var(--space-3xl) 0 var(--space-lg);
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: var(--space-2xl);
    margin-bottom: var(--space-2xl);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.5rem;
    margin-bottom: var(--space-md);
}

.footer-desc {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: var(--space-lg);
}

.social-links {
    display: flex;
    gap: var(--space-sm);
}

.social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

.footer-col h4 {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    margin-bottom: var(--space-lg);
}

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

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.875rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent-primary);
}

.footer-newsletter {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: var(--space-md);
}

.footer-form {
    display: flex;
    gap: var(--space-sm);
}

.footer-form input {
    flex: 1;
    padding: var(--space-sm) var(--space-md);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.875rem;
}

.footer-form button {
    padding: var(--space-sm) var(--space-md);
    background: var(--accent-gradient);
    border: none;
    border-radius: var(--radius-sm);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.footer-form button:hover {
    transform: scale(1.05);
}

.footer-bottom {
    text-align: center;
    padding-top: var(--space-lg);
    border-top: 1px solid var(--border-color);
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* ============================================
   Page Header
   ============================================ */
.page-header-section {
    padding: calc(140px + var(--space-2xl)) 0 var(--space-2xl);
    text-align: center;
    background: var(--bg-secondary);
}

.page-title {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: var(--space-md);
}

.page-desc {
    color: var(--text-secondary);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ============================================
   Tools Page
   ============================================ */
.tools-page-section {
    padding: var(--space-2xl) 0;
}

.tools-filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-lg);
    margin-bottom: var(--space-xl);
    flex-wrap: wrap;
}

.category-tabs {
    display: flex;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

.category-tab {
    padding: var(--space-sm) var(--space-md);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
}

.category-tab:hover,
.category-tab.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: white;
}

.search-box {
    display: flex;
    gap: var(--space-sm);
}

.search-box .search-input {
    min-width: 250px;
}

.tools-count {
    margin-bottom: var(--space-lg);
    color: var(--text-muted);
    font-size: 0.875rem;
}

.load-more-container {
    text-align: center;
    margin-top: var(--space-2xl);
}

/* ============================================
   Tool Detail Page
   ============================================ */
.tool-detail-page {
    padding: calc(120px + var(--space-xl)) 0 var(--space-2xl);
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-xl);
    font-size: 0.875rem;
}

.breadcrumb a {
    color: var(--text-muted);
    transition: color 0.3s ease;
}

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

.breadcrumb span {
    color: var(--text-muted);
}

.breadcrumb .current {
    color: var(--text-primary);
}

.tool-hero {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: var(--space-2xl);
    align-items: center;
    margin-bottom: var(--space-2xl);
}

.tool-logo-section {
    text-align: center;
}

.tool-logo {
    width: 150px;
    height: 150px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-md);
    padding: var(--space-lg);
}

.tool-logo img {
    width: 100px;
    height: 100px;
    object-fit: contain;
}

.tool-category-tag {
    display: inline-block;
    padding: var(--space-sm) var(--space-md);
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    font-size: 0.875rem;
}

.tool-info .tool-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--space-md);
}

.tool-short-desc {
    color: var(--text-secondary);
    font-size: 1.125rem;
    margin-bottom: var(--space-lg);
}

.tool-meta {
    display: flex;
    gap: var(--space-xl);
    align-items: center;
    margin-bottom: var(--space-xl);
}

.tool-rating {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.rating-value {
    font-weight: 700;
    font-size: 1.125rem;
}

.tool-pricing {
    display: flex;
    gap: var(--space-md);
}

.price-free {
    color: var(--success);
    font-weight: 600;
}

.price-pro {
    color: var(--accent-primary);
    font-weight: 600;
}

.tool-cta {
    display: inline-flex;
    gap: var(--space-sm);
}

.tool-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: var(--space-2xl);
}

.content-main section {
    margin-bottom: var(--space-2xl);
}

.content-main h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    margin-bottom: var(--space-lg);
}

.content-main p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: var(--space-md);
}

.features-list,
.cons-list {
    display: grid;
    gap: var(--space-md);
}

.features-list li,
.cons-list li {
    padding: var(--space-md);
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    font-size: 1rem;
}

.pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--space-lg);
}

.pricing-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    position: relative;
}

.pricing-card.featured {
    border-color: var(--accent-primary);
    transform: scale(1.05);
}

.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: var(--space-xs) var(--space-md);
    background: var(--accent-gradient);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-xl);
}

.pricing-card h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: var(--space-md);
}

.pricing-card .price {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: var(--space-md);
}

.pricing-card .price span {
    font-size: 1rem;
    color: var(--text-muted);
}

.pricing-card ul {
    margin-bottom: var(--space-lg);
}

.pricing-card li {
    color: var(--text-secondary);
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--border-color);
}

.content-sidebar {
    position: sticky;
    top: 140px;
    height: fit-content;
}

.sidebar-widget {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    margin-bottom: var(--space-lg);
}

.sidebar-widget h4 {
    font-family: var(--font-heading);
    font-size: 1rem;
    margin-bottom: var(--space-md);
}

.quick-info li {
    display: flex;
    justify-content: space-between;
    padding: var(--space-sm) 0;
    border-bottom: 1px solid var(--border-color);
}

.quick-info .label {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.quick-info .value {
    font-weight: 600;
    font-size: 0.875rem;
}

.ad-widget {
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.tag {
    padding: var(--space-xs) var(--space-sm);
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.related-tools {
    margin-top: var(--space-2xl);
}

.related-tools h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    margin-bottom: var(--space-lg);
}

/* ============================================
   Top 10 Page
   ============================================ */
.top10-header {
    background: var(--bg-secondary);
    position: relative;
}

.top10-badge {
    font-size: 4rem;
    margin-bottom: var(--space-md);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.top10-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.top10-item {
    display: grid;
    grid-template-columns: 80px auto 1fr auto;
    gap: var(--space-xl);
    align-items: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    transition: all 0.3s ease;
    cursor: pointer;
}

.top10-item:hover {
    border-color: var(--accent-primary);
    transform: translateX(10px);
    box-shadow: var(--card-hover-shadow);
}

.top10-item.gold {
    border-color: #fbbf24;
    background: linear-gradient(135deg, var(--bg-card) 0%, rgba(251, 191, 36, 0.1) 100%);
}

.top10-item.silver {
    border-color: #94a3b8;
}

.top10-item.bronze {
    border-color: #cd7f32;
}

.top10-rank {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
}

.gold .top10-rank { color: #fbbf24; }
.silver .top10-rank { color: #94a3b8; }
.bronze .top10-rank { color: #cd7f32; }

.top10-logo {
    width: 80px;
    height: 80px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.top10-info h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: var(--space-sm);
}

.top10-info p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.top10-meta {
    display: flex;
    gap: var(--space-lg);
    align-items: center;
}

.top10-rating {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.top10-cta {
    padding: var(--space-md) var(--space-xl);
}

/* ============================================
   About Page
   ============================================ */
.about-hero {
    padding: calc(120px + var(--space-2xl)) 0 var(--space-2xl);
    text-align: center;
    background: var(--bg-secondary);
}

.about-mission {
    padding: var(--space-3xl) 0;
}

.mission-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-3xl);
    align-items: center;
}

.mission-text h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: var(--space-lg);
}

.mission-text p {
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
    line-height: 1.8;
}

.mission-visual {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-md);
}

.mission-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    text-align: center;
    transition: all 0.3s ease;
}

.mission-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-primary);
}

.mission-icon {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
}

.mission-card h3 {
    font-family: var(--font-heading);
    margin-bottom: var(--space-sm);
}

.mission-card p {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.about-stats {
    padding: var(--space-3xl) 0;
    background: var(--bg-secondary);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-5px);
}

.stat-card .stat-number {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: var(--space-sm);
}

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

.about-how,
.about-values {
    padding: var(--space-3xl) 0;
}

.how-grid,
.values-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
}

.how-card,
.value-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    transition: all 0.3s ease;
}

.how-card:hover,
.value-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-5px);
}

.step-number {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
    margin-bottom: var(--space-md);
}

.how-card h3,
.value-card h3 {
    font-family: var(--font-heading);
    margin-bottom: var(--space-sm);
}

.how-card p,
.value-card p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.value-icon {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
}

/* ============================================
   Contact Page
   ============================================ */
.contact-content {
    padding: var(--space-2xl) 0;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--space-2xl);
    margin-bottom: var(--space-3xl);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    text-align: center;
    transition: all 0.3s ease;
}

.contact-card:hover {
    border-color: var(--accent-primary);
}

.contact-icon {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
}

.contact-card h3 {
    font-family: var(--font-heading);
    margin-bottom: var(--space-sm);
}

.contact-card p {
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
}

.contact-card a {
    color: var(--accent-primary);
    font-weight: 600;
}

.contact-card .social-links {
    justify-content: center;
}

.contact-form-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
}

.contact-form .form-group {
    margin-bottom: var(--space-lg);
}

.contact-form label {
    display: block;
    font-weight: 600;
    margin-bottom: var(--space-sm);
    color: var(--text-primary);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: var(--space-md);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: border-color 0.3s ease;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.contact-form textarea {
    resize: vertical;
    min-height: 120px;
}

.faq-section {
    margin-top: var(--space-2xl);
}

.faq-section h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-bottom: var(--space-xl);
    text-align: center;
}

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

.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: var(--accent-primary);
}

.faq-item h3 {
    font-family: var(--font-heading);
    font-size: 1.125rem;
    margin-bottom: var(--space-sm);
}

.faq-item p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* ============================================
   Animations
   ============================================ */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

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

    .hero-visual {
        display: none;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .content-sidebar {
        position: static;
    }

    .mission-content {
        grid-template-columns: 1fr;
    }

    .mission-visual {
        grid-template-columns: repeat(3, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .how-grid,
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-primary);
        flex-direction: column;
        padding: var(--space-lg);
        border-bottom: 1px solid var(--border-color);
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-stats {
        flex-wrap: wrap;
        justify-content: center;
    }

    .newsletter-box {
        flex-direction: column;
        text-align: center;
    }

    .newsletter-form {
        flex-direction: column;
        width: 100%;
    }

    .newsletter-form input {
        min-width: auto;
    }

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

    .tools-filter-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .category-tabs {
        justify-content: center;
    }

    .search-box {
        width: 100%;
    }

    .search-box .search-input {
        flex: 1;
        min-width: auto;
    }

    .tool-hero {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .tool-meta {
        flex-direction: column;
        gap: var(--space-md);
    }

    .top10-item {
        grid-template-columns: 60px 1fr;
    }

    .top10-logo,
    .top10-meta {
        display: none;
    }

    .pricing-cards {
        grid-template-columns: 1fr;
    }

    .pricing-card.featured {
        transform: scale(1);
    }

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

    .how-grid,
    .values-grid {
        grid-template-columns: 1fr;
    }

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

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

    .hero-title {
        font-size: 2rem;
    }

    .page-title {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.75rem;
    }

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

    .category-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        justify-content: flex-start;
        padding-bottom: var(--space-sm);
    }

    .category-tab {
        white-space: nowrap;
    }
}

/* ============================================
   Comprehensive Multi-Device Support
   ============================================ */

/* --- Extra Small Phones (iPhone SE, Galaxy Mini) --- */
@media only screen and (max-width: 320px) {
    :root {
        --space-md: 10px;
        --space-lg: 16px;
        --space-xl: 20px;
    }

    .hero-title {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }

    .hero-search input {
        font-size: 14px;
        padding: 10px;
    }

    .tool-card-title {
        font-size: 0.95rem;
    }

    .btn {
        padding: 10px 16px;
        font-size: 0.85rem;
    }
}

/* --- Small Phones --- */
@media only screen and (min-width: 321px) and (max-width: 375px) {
    .hero-title {
        font-size: 1.65rem;
    }

    .tool-card-title {
        font-size: 1rem;
    }
}

/* --- Medium Phones --- */
@media only screen and (min-width: 376px) and (max-width: 425px) {
    .hero-title {
        font-size: 1.85rem;
    }

    .section-title {
        font-size: 1.5rem;
    }
}

/* --- Large Phones / Small Tablets --- */
@media only screen and (min-width: 426px) and (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

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

/* --- Tablets Portrait (iPad, Galaxy Tab) --- */
@media only screen and (min-width: 481px) and (max-width: 767px) {
    .container {
        padding: 0 20px;
        max-width: 100%;
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .hero .container {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero-visual {
        display: none;
    }

    .hero-stats {
        gap: 30px;
    }

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

    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 15px;
    }

    .tool-card-image {
        height: 160px;
    }

    .tool-card-content {
        padding: 15px;
    }

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

/* --- Tablets Landscape (iPad Pro, Surface) --- */
@media only screen and (min-width: 768px) and (max-width: 1024px) {
    .container {
        max-width: 100%;
        padding: 0 30px;
    }

    .hero-title {
        font-size: 2.75rem;
    }

    .hero .container {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }

    .hero-visual {
        display: flex;
    }

    .hero-visual .hero-card {
        transform: scale(0.9);
    }

    .tools-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }

    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .why-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .section {
        padding: 60px 0;
    }

    .tool-content {
        grid-template-columns: 1fr 280px;
        gap: 30px;
    }

    .content-sidebar {
        position: static;
    }

    .newsletter-box {
        flex-direction: row;
        align-items: center;
        gap: 30px;
    }

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

    .top10-item {
        grid-template-columns: 80px auto auto;
    }

    .top10-logo {
        display: none;
    }

    .top10-meta {
        display: flex;
        align-items: center;
    }
}

/* --- Small Laptops / Large Tablets --- */
@media only screen and (min-width: 1025px) and (max-width: 1280px) {
    .container {
        max-width: 1200px;
        padding: 0 20px;
    }

    .hero-title {
        font-size: 3rem;
    }

    .section-title {
        font-size: 2.25rem;
    }

    .tools-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 25px;
    }

    .tool-card-image {
        height: 180px;
    }

    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr 1fr;
        gap: 30px;
    }
}

/* --- Standard Laptops / Desktops --- */
@media only screen and (min-width: 1281px) and (max-width: 1440px) {
    .container {
        max-width: 1300px;
    }

    .hero-title {
        font-size: 3.25rem;
    }

    .section-title {
        font-size: 2.5rem;
    }

    .tools-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px;
    }
}

/* --- Large Laptops / Small Desktop Monitors --- */
@media only screen and (min-width: 1441px) and (max-width: 1680px) {
    .container {
        max-width: 1400px;
    }

    .hero .container {
        gap: 60px;
    }

    .hero-title {
        font-size: 3.5rem;
    }

    .section-title {
        font-size: 2.75rem;
    }

    .tools-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* --- Standard Desktop Monitors (1080p) --- */
@media only screen and (min-width: 1681px) and (max-width: 1920px) {
    .container {
        max-width: 1500px;
    }

    .hero-title {
        font-size: 3.75rem;
    }

    .hero-desc {
        font-size: 1.25rem;
        max-width: 600px;
    }

    .section-title {
        font-size: 3rem;
    }

    .page-title {
        font-size: 3.5rem;
    }

    .tools-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 30px;
    }

    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px;
    }
}

/* --- Large Desktop Monitors (1440p, 4K ready) --- */
@media only screen and (min-width: 1921px) and (max-width: 2560px) {
    .container {
        max-width: 1800px;
        padding: 0 40px;
    }

    .hero-title {
        font-size: 4rem;
    }

    .hero-desc {
        font-size: 1.35rem;
        max-width: 700px;
    }

    .section-title {
        font-size: 3.25rem;
    }

    .page-title {
        font-size: 4rem;
    }

    .tools-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 35px;
    }

    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .tool-card {
        min-height: 400px;
    }

    .tool-card-title {
        font-size: 1.4rem;
    }

    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr 1.5fr;
        gap: 60px;
    }
}

/* --- 4K Monitors and Large TVs --- */
@media only screen and (min-width: 2561px) and (max-width: 3840px) {
    .container {
        max-width: 2200px;
        padding: 0 60px;
    }

    :root {
        --space-lg: 32px;
        --space-xl: 48px;
        --space-2xl: 64px;
        --space-3xl: 96px;
    }

    .hero-title {
        font-size: 5rem;
        line-height: 1.1;
    }

    .hero-desc {
        font-size: 1.5rem;
        max-width: 800px;
    }

    .section-title {
        font-size: 3.75rem;
    }

    .page-title {
        font-size: 4.5rem;
    }

    .tools-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 40px;
    }

    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 40px;
    }

    .tool-card {
        min-height: 450px;
        border-radius: 24px;
    }

    .tool-card-image {
        height: 220px;
    }

    .tool-card-title {
        font-size: 1.6rem;
    }

    .tool-card-desc {
        font-size: 1.1rem;
    }

    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 80px;
    }

    .footer-col {
        min-width: 250px;
    }

    .section {
        padding: 100px 0;
    }
}

/* --- 8K Monitors and Very Large Screens --- */
@media only screen and (min-width: 3841px) {
    .container {
        max-width: 2800px;
        padding: 0 80px;
    }

    .hero-title {
        font-size: 6rem;
    }

    .hero-desc {
        font-size: 1.75rem;
    }

    .section-title {
        font-size: 4.5rem;
    }

    .page-title {
        font-size: 5.5rem;
    }

    .tools-grid {
        grid-template-columns: repeat(8, 1fr);
    }

    .categories-grid {
        grid-template-columns: repeat(5, 1fr);
    }

    .tool-card {
        min-height: 500px;
    }
}

/* ============================================
   Device-Specific Optimizations
   ============================================ */

/* --- iOS Specific --- */
@supports (-webkit-touch-callout: none) {
    .navbar {
        -webkit-backdrop-filter: blur(12px);
        backdrop-filter: blur(12px);
    }

    .tool-card:active {
        transform: scale(0.98);
    }
}

/* --- Android Specific --- */
@media screen and (max-width: 767px) {
    .tool-card-btn {
        -webkit-tap-highlight-color: transparent;
    }

    .search-input {
        font-size: 16px; /* Prevent zoom on focus */
    }
}

/* --- Samsung DeX / Desktop Mode --- */
@media (max-width: 767px) and (hover: hover) {
    .tool-card:hover {
        transform: translateY(-8px);
    }
}

/* --- Foldable Devices --- */
@media screen and (aspect-ratio: 0.7/1) and (max-width: 767px) {
    .hero-title {
        font-size: 1.75rem;
    }

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

/* --- Smart TV Remote Navigation (Focus States) --- */
@media (hover: none) and (pointer: coarse) {
    *:focus {
        outline: 2px solid var(--accent-primary);
        outline-offset: 2px;
    }

    .btn:focus {
        box-shadow: var(--glow);
    }
}

/* ============================================
   Performance Optimizations
   ============================================ */

/* Reduce Motion for Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .hero-shape {
        animation: none;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --border-color: #ffffff;
    }

    .tool-card {
        border: 2px solid var(--accent-primary);
    }
}

/* Dark Mode Preference Override (if user prefers dark) */
@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;
    }
}

/* Light Mode Preference Override (if user prefers light) */
@media (prefers-color-scheme: light) {
    :root {
        color-scheme: light;
    }
}

/* ============================================
   Safe Area Insets (Notch Devices)
   ============================================ */
@supports (padding: max(0px)) {
    .navbar {
        padding-top: max(env(safe-area-inset-top), 10px);
    }

    .hero {
        padding-top: max(calc(140px + env(safe-area-inset-top)), 100px);
    }
}

/* ============================================
   Zoom Levels
   ============================================ */
@media screen and (zoom: 125%) {
    .container {
        max-width: 95%;
    }
}

@media screen and (zoom: 150%) {
    :root {
        --space-xl: 24px;
        --space-2xl: 32px;
    }

    .hero-title {
        font-size: 2rem;
    }
}

/* ============================================
   Orientation Considerations
   ============================================ */
@media (orientation: landscape) and (max-height: 600px) {
    .hero {
        padding-top: 100px;
        padding-bottom: 50px;
    }

    .hero-visual {
        display: none;
    }

    .navbar {
        position: relative;
    }
}

@media (orientation: portrait) {
    .hero-visual .hero-card:nth-child(2) {
        margin-right: 0;
    }

    .hero-visual .hero-card:nth-child(3) {
        margin-right: 0;
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    .navbar,
    .hero,
    .footer,
    .ad-banner,
    .newsletter-section,
    .search-box,
    .mobile-menu-btn,
    .theme-toggle {
        display: none !important;
    }

    body {
        background: white;
        color: black;
        font-size: 12pt;
    }

    .tool-card {
        break-inside: avoid;
        border: 1px solid #ccc;
        margin-bottom: 1rem;
        box-shadow: none;
    }

    .container {
        max-width: 100%;
    }

    a[href]::after {
        content: " (" attr(href) ")";
        font-size: 0.8em;
        color: #666;
    }
}

/* ============================================
   Extra Large Screens (Big TVs and Monitors)
   ============================================ */
@media (min-width: 1921px) {
    .container {
        max-width: 1600px;
    }

    .hero-title {
        font-size: 4.5rem;
    }

    .hero-desc {
        font-size: 1.5rem;
        max-width: 800px;
    }

    .section-title {
        font-size: 3rem;
    }

    .page-title {
        font-size: 4rem;
    }

    .hero-visual {
        transform: scale(1.2);
    }

    .tool-card {
        min-height: 380px;
    }

    .tool-card-title {
        font-size: 1.5rem;
    }

    .tool-card-desc {
        font-size: 1rem;
    }
}

/* ============================================
   Tablet Landscape and Small Laptops
   ============================================ */
@media (min-width: 1024px) and (max-width: 1280px) {
    .container {
        max-width: 1100px;
    }

    .hero-title {
        font-size: 3rem;
    }

    .section-title {
        font-size: 2.25rem;
    }

    .tools-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-xl);
    }
}

/* ============================================
   Tablet Portrait
   ============================================ */
@media (min-width: 768px) and (max-width: 1023px) {
    .container {
        max-width: 90%;
    }

    .hero {
        padding-top: 160px;
    }

    .hero .container {
        grid-template-columns: 1fr;
    }

    .hero-visual {
        display: none;
    }

    .hero-title {
        font-size: 2.75rem;
    }

    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .why-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

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

    .mission-content {
        grid-template-columns: 1fr;
    }

    .mission-visual {
        grid-template-columns: repeat(3, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .how-grid,
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .top10-item {
        grid-template-columns: 70px 1fr auto;
    }

    .top10-logo {
        display: none;
    }

    .newsletter-box {
        flex-direction: column;
        text-align: center;
        gap: var(--space-lg);
    }

    .newsletter-form {
        width: 100%;
        justify-content: center;
    }
}

/* ============================================
   Mobile Devices (Phones)
   ============================================ */
@media (max-width: 767px) {
    :root {
        --space-xs: 4px;
        --space-sm: 8px;
        --space-md: 12px;
        --space-lg: 20px;
        --space-xl: 28px;
        --space-2xl: 40px;
        --space-3xl: 56px;
    }

    .ad-banner {
        min-height: 60px;
    }

    .navbar {
        top: 60px;
    }

    .navbar.scrolled {
        top: 0;
    }

    .nav-container {
        padding: var(--space-sm) var(--space-md);
    }

    .logo {
        font-size: 1.25rem;
    }

    .logo-icon {
        font-size: 1.5rem;
    }

    .theme-toggle {
        padding: var(--space-xs) var(--space-sm);
    }

    .nav-cta {
        display: none;
    }

    .hero {
        padding-top: 140px;
        padding-bottom: var(--space-2xl);
    }

    .hero-title {
        font-size: 2rem;
        line-height: 1.3;
    }

    .hero-desc {
        font-size: 1rem;
        margin-bottom: var(--space-lg);
    }

    .hero-search {
        flex-direction: column;
        gap: var(--space-sm);
    }

    .search-btn {
        width: 100%;
    }

    .hero-stats {
        flex-wrap: wrap;
        justify-content: center;
        gap: var(--space-lg);
    }

    .stat-number {
        font-size: 1.5rem;
    }

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

    .section-title {
        font-size: 1.75rem;
    }

    .section-desc {
        font-size: 0.95rem;
    }

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

    .category-tabs {
        display: flex;
        overflow-x: auto;
        flex-wrap: nowrap;
        justify-content: flex-start;
        padding-bottom: var(--space-sm);
        -webkit-overflow-scrolling: touch;
    }

    .category-tab {
        flex-shrink: 0;
        font-size: 0.8rem;
        padding: var(--space-xs) var(--space-sm);
    }

    .search-box {
        flex-direction: column;
    }

    .search-box .search-input {
        width: 100%;
    }

    .search-box .search-btn {
        width: 100%;
    }

    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-sm);
    }

    .category-icon {
        font-size: 1.75rem;
    }

    .category-card h3 {
        font-size: 0.9rem;
    }

    .category-count {
        font-size: 0.7rem;
    }

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

    .tool-hero {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .tool-logo-section {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .tool-logo {
        width: 100px;
        height: 100px;
    }

    .tool-info .tool-title {
        font-size: 1.75rem;
    }

    .tool-short-desc {
        font-size: 0.95rem;
    }

    .tool-meta {
        flex-direction: column;
        align-items: center;
        gap: var(--space-sm);
    }

    .tool-cta {
        width: 100%;
        justify-content: center;
    }

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

    .content-sidebar {
        grid-template-columns: 1fr;
    }

    .pricing-cards {
        grid-template-columns: 1fr;
    }

    .pricing-card.featured {
        transform: scale(1);
    }

    .tool-card {
        min-height: auto;
    }

    .tool-card-image {
        height: 150px;
    }

    .tool-card-title {
        font-size: 1.1rem;
    }

    .tool-card-desc {
        font-size: 0.85rem;
        -webkit-line-clamp: 3;
    }

    .tool-card-footer {
        flex-direction: column;
        gap: var(--space-sm);
        align-items: stretch;
    }

    .tool-card-rating {
        justify-content: center;
    }

    .tool-card-btn {
        width: 100%;
    }

    .newsletter-box {
        padding: var(--space-lg);
    }

    .newsletter-content h2 {
        font-size: 1.25rem;
    }

    .newsletter-content p {
        font-size: 0.9rem;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .newsletter-form input {
        min-width: auto;
    }

    .footer {
        padding: var(--space-2xl) 0 var(--space-md);
    }

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

    .footer-col {
        text-align: center;
    }

    .footer-links {
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .footer-form {
        justify-content: center;
    }

    .page-header-section {
        padding-top: 120px;
    }

    .page-title {
        font-size: 2rem;
    }

    .page-desc {
        font-size: 0.95rem;
    }

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

    .top10-list {
        gap: var(--space-md);
    }

    .top10-item {
        grid-template-columns: 50px 1fr;
        padding: var(--space-md);
    }

    .top10-rank {
        font-size: 1.5rem;
    }

    .top10-logo,
    .top10-meta {
        display: none;
    }

    .mission-content {
        grid-template-columns: 1fr;
    }

    .mission-visual {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stat-card {
        padding: var(--space-md);
    }

    .stat-card .stat-number {
        font-size: 1.75rem;
    }

    .how-grid,
    .values-grid {
        grid-template-columns: 1fr;
    }

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

    .contact-card {
        padding: var(--space-md);
    }

    .contact-form .btn-large {
        width: 100%;
    }

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

/* ============================================
   Small Mobile Devices
   ============================================ */
@media (max-width: 380px) {
    .hero-title {
        font-size: 1.75rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

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

    .category-card {
        padding: var(--space-md);
    }

    .hero-stats .stat {
        width: 100%;
        text-align: center;
        padding: var(--space-sm) 0;
    }

    .newsletter-box {
        padding: var(--space-md);
    }

    .footer-bottom p {
        font-size: 0.75rem;
    }
}

/* ============================================
   Touch Devices (Tablets andPhones with touch)
   ============================================ */
@media (hover: none) {
    .btn:hover {
        transform: none;
    }

    .btn-primary:hover {
        filter: none;
    }

    .tool-card:hover {
        transform: none;
    }

    .tool-card:active {
        transform: scale(0.98);
    }

    .category-card:hover {
        transform: none;
    }

    .category-card:active {
        transform: scale(0.98);
    }

    .why-card:hover {
        transform: none;
    }

    .hero-card:hover {
        transform: none;
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    .navbar,
    .hero,
    .footer,
    .ad-banner,
    .newsletter-section,
    .search-box,
    .mobile-menu-btn {
        display: none !important;
    }

    body {
        background: white;
        color: black;
    }

    .tool-card {
        break-inside: avoid;
        border: 1px solid #ccc;
        margin-bottom: var(--space-md);
    }

    .container {
        max-width: 100%;
    }
}

/* ============================================
   Touch & Mobile Optimizations
   ============================================ */

/* Interactive Elements Touch Targets */
button, .btn, .tool-card, .category-card, .nav-link {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

/* Smooth Touch Scrolling */
@media (pointer: coarse) {
    html {
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
    }

    body {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* Prevent Zoom on Input Focus */
@media screen and (max-width: 767px) {
    input, select, textarea {
        font-size: 16px !important;
    }
}

/* Better Touch Targets for Small Screens */
@media (max-width: 767px) {
    .btn {
        min-height: 44px;
        min-width: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .tool-card {
        min-height: 320px;
    }

    .tool-card-btn {
        min-height: 40px;
    }

    .category-card {
        min-height: 120px;
        padding: var(--space-lg);
    }

    .search-input {
        min-height: 44px;
    }

    .nav-link {
        min-height: 44px;
        display: flex;
        align-items: center;
        padding: var(--space-md);
    }
}

/* Hover States for Touch Devices */
@media (hover: hover) {
    .tool-card:hover {
        transform: translateY(-8px);
    }

    .category-card:hover {
        transform: translateY(-5px);
    }

    .btn:hover {
        transform: translateY(-2px);
    }
}

/* Active States for Touch */
@media (hover: none) {
    .tool-card:active {
        transform: scale(0.98);
    }

    .btn:active {
        transform: scale(0.98);
    }

    .category-card:active {
        transform: scale(0.98);
    }
}

/* Improved Tap Highlight Color */
* {
    -webkit-tap-highlight-color: rgba(99, 102, 241, 0.2);
}

/* Prevent Text Selection on Buttons */
button, .btn {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Scroll Optimizations */
@supports (scrollbar-width: thin) {
    ::-webkit-scrollbar {
        width: 8px;
        height: 8px;
    }

    ::-webkit-scrollbar-track {
        background: var(--bg-secondary);
    }

    ::-webkit-scrollbar-thumb {
        background: var(--accent-primary);
        border-radius: 4px;
    }

    ::-webkit-scrollbar-thumb:hover {
        background: var(--accent-secondary);
    }
}

/* Keyboard Focus for Accessibility */
.keyboard-nav *:focus {
    outline: 2px solid var(--accent-primary) !important;
    outline-offset: 2px;
}

/* Skip to Content Link (Accessibility) */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--accent-primary);
    color: white;
    padding: 8px;
    z-index: 9999;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
}

/* Focus Visible Polyfill Support */
:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .hero-shape {
        animation: none !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --border-color: #ffffff;
        --text-secondary: #e0e0e0;
    }

    .tool-card {
        border: 2px solid var(--accent-primary);
    }

    .btn {
        border: 2px solid currentColor;
    }
}

/* Dark Mode System Preference */
@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;
    }
}

@media (prefers-color-scheme: light) {
    :root {
        color-scheme: light;
    }
}

/* Device Pixel Ratio Fixes */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .tool-card-img,
    .tool-logo img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Safe Area Insets for Notched Devices */
@supports (padding: max(0px)) {
    body {
        padding-left: max(env(safe-area-inset-left), 0px);
        padding-right: max(env(safe-area-inset-right), 0px);
    }

    .navbar {
        padding-left: max(env(safe-area-inset-left), var(--space-md));
        padding-right: max(env(safe-area-inset-right), var(--space-md));
    }

    .footer {
        padding-left: max(env(safe-area-inset-left), var(--space-md));
        padding-right: max(env(safe-area-inset-right), var(--space-md));
    }
}

/* Horizontal Overflow Prevention */
html, body {
    overflow-x: hidden;
    max-width: 100vw;
}

img, video, iframe {
    max-width: 100%;
    height: auto;
}

/* Fix for 100vh on mobile browsers */
@supports (height: 100dvh) {
    body, .hero {
        min-height: 100dvh;
    }
}

/* Orientation Changes */
@media (orientation: landscape) and (max-height: 600px) {
    .hero {
        padding-top: 120px;
        padding-bottom: 60px;
    }

    .hero-visual {
        display: none;
    }

    .navbar {
        position: relative;
    }
}

/* Foldable Devices (Galaxy Fold, etc) */
@media screen and (aspect-ratio: 0.7/1) {
    .container {
        max-width: 100% !important;
        padding: 0 16px !important;
    }
}

/* TV & Large Screen Optimizations */
@media tv {
    .btn {
        min-height: 56px;
        min-width: 120px;
        font-size: 1.2rem;
    }

    .tool-card {
        min-height: 400px;
    }

    .hero-title {
        font-size: 3rem;
    }

    * {
        -webkit-font-smoothing: antialiased;
    }
}

/* Focus for TV Remote Navigation */
@media (hover: none) and (pointer: coarse) {
    *:focus {
        outline: 3px solid var(--accent-primary);
        outline-offset: 4px;
    }

    .btn:focus {
        transform: scale(1.05);
        box-shadow: var(--glow);
    }
}

/* Performance: GPU Acceleration */
.tool-card,
.hero-card,
.category-card,
.why-card {
    transform: translateZ(0);
    will-change: transform;
}

/* Font Loading Optimization */
.font-loaded body {
    font-display: swap;
}

/* Will-change for smooth animations */
.fade-in {
    will-change: opacity, transform;
}

/* Containment for better rendering */
.tool-card,
.hero-card {
    contain: layout style paint;
}

/* GPU-accelerated transforms */
@keyframes GPU {
    from { transform: translateY(0); }
    to { transform: translateY(1px); }
}

/*=
   Device Lab - Testing Classes (Remove in production)
   =*/
.dev-debug {
    outline: 2px solid red;
}

/* ============================================
   Scroll Progress Bar
   ============================================ */
.scroll-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    z-index: 10000;
    pointer-events: none;
}

.scroll-progress-bar {
    height: 100%;
    background: var(--accent-gradient);
    width: 0%;
    transition: width 0.1s ease-out;
    border-radius: 0 2px 2px 0;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.6);
}

/* ============================================
   Custom Scrollbar
   ============================================ */
::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 6px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 6px;
    border: 3px solid var(--bg-secondary);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--accent-secondary), var(--accent-primary));
}

::-webkit-scrollbar-corner {
    background: var(--bg-secondary);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--accent-primary) var(--bg-secondary);
}

/* ============================================
   Toast Notifications
   ============================================ */
.toast-container {
    position: fixed;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10001;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 90%;
    width: 350px;
    pointer-events: none;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-md);
    padding: var(--space-md) var(--space-lg);
    box-shadow: var(--card-hover-shadow);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    animation: slideInDown 0.3s ease-out, fadeOut 0.3s ease-in 2.7s forwards;
    pointer-events: auto;
    min-height: 50px;
}

.toast.success {
    border-color: var(--success);
    background: rgba(16, 185, 129, 0.1);
}

.toast.error {
    border-color: var(--error);
    background: rgba(239, 68, 68, 0.1);
}

.toast.info {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

.toast-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.toast-message {
    flex: 1;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    font-size: 1.2rem;
    line-height: 1;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.toast-close:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

@keyframes slideInDown {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(10px);
    }
}

/* ============================================
   Share Buttons
   ============================================ */
.share-buttons {
    display: flex;
    gap: var(--space-sm);
    margin-top: var(--space-lg);
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s ease;
    min-height: 36px;
    min-width: 36px;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--glow);
}

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

.share-btn.whatsapp {
    background: #25D366;
    color: white;
}

.share-btn.facebook {
    background: #1877F2;
    color: white;
}

.share-btn.twitter {
    background: #1DA1F2;
    color: white;
}

.share-btn.linkedin {
    background: #0077B5;
    color: white;
}

.share-btn.telegram {
    background: #0088cc;
    color: white;
}

/* ============================================
   Ad Placeholder Styling
   ============================================ */
.ad-placeholder {
    background: linear-gradient(135deg, var(--bg-secondary), var(--bg-card));
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.9rem;
    min-height: 90px;
    transition: border-color 0.3s ease;
}

.ad-placeholder:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

/* ============================================
   Schema.org JSON-LD (Hidden)
   ============================================ */
.schema-jsonld {
    display: none;
}

/* ============================================
   404 Page Styling
   ============================================ */
.error-404-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-2xl);
    background: var(--bg-primary);
}

.error-404-content {
    max-width: 600px;
}

.error-404-code {
    font-family: var(--font-heading);
    font-size: 8rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: var(--space-lg);
}

.error-404-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
}

.error-404-desc {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-xl);
}

.error-404-actions {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================
   Rating System Enhancement
   ============================================ */
.rating-stars {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.rating-stars .star {
    font-size: 1rem;
    color: #fbbf24;
}

.rating-stars .star.empty {
    color: var(--text-muted);
    opacity: 0.3;
}

.rating-text {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    margin-right: var(--space-sm);
    font-weight: 600;
}

/* ============================================
   Related Tools Section
   ============================================ */
.related-tools {
    margin-top: var(--space-3xl);
    padding-top: var(--space-2xl);
    border-top: 1px solid var(--border-color);
}

.related-tools h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    margin-bottom: var(--space-xl);
    text-align: center;
}

/* ============================================
   Improved Ad Placeholders
   ============================================ */
.ad-slot {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(168, 85, 247, 0.05));
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.875rem;
    position: relative;
    overflow: hidden;
    min-height: 90px;
}

.ad-slot::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        transparent,
        rgba(255, 255, 255, 0.03),
        transparent
    );
    transform: rotate(45deg);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.ad-label {
    position: absolute;
    top: var(--space-sm);
    left: var(--space-sm);
    background: var(--accent-primary);
    color: white;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    text-transform: uppercase;
}

/* ============================================
   Lazy Load Skeleton
   ============================================ */
.skeleton {
    background: linear-gradient(90deg, 
        var(--bg-card) 25%, 
        var(--bg-secondary) 50%, 
        var(--bg-card) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-image {
    height: 180px;
    width: 100%;
}

.skeleton-text {
    height: 16px;
    margin-bottom: var(--space-sm);
}

.skeleton-text.title {
    height: 24px;
    width: 70%;
}

.skeleton-text.desc {
    height: 14px;
    width: 90%;
}

/* ============================================
   Copy Feedback
   ============================================ */
.copied-feedback {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-primary);
    color: white;
    padding: var(--space-sm) var(--space-lg);
    border-radius: var(--radius-xl);
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: var(--glow);
    z-index: 10002;
    animation: slideUp 0.3s ease-out, fadeOut 0.3s ease-in 2s forwards;
}

@keyframes slideUp {
    from {
        transform: translate(-50%, 20px);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

/* ============================================
   End of Additions
   ============================================ */

/* ============================================
   Scroll Progress Bar
   ============================================ */
.scroll-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    z-index: 10000;
    pointer-events: none;
}

.scroll-progress-bar {
    height: 100%;
    background: var(--accent-gradient);
    width: 0%;
    transition: width 0.1s ease-out;
    border-radius: 0 2px 2px 0;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.6);
}

/* ============================================
   Custom Scrollbar
   ============================================ */
::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 6px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 6px;
    border: 3px solid var(--bg-secondary);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--accent-secondary), var(--accent-primary));
}

::-webkit-scrollbar-corner {
    background: var(--bg-secondary);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--accent-primary) var(--bg-secondary);
}

/* ============================================
   Toast Notifications
   ============================================ */
.toast-container {
    position: fixed;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10001;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 90%;
    width: 350px;
    pointer-events: none;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-md);
    padding: var(--space-md) var(--space-lg);
    box-shadow: var(--card-hover-shadow);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    animation: slideInDown 0.3s ease-out, fadeOut 0.3s ease-in 2.7s forwards;
    pointer-events: auto;
    min-height: 50px;
}

.toast.success {
    border-color: var(--success);
    background: rgba(16, 185, 129, 0.1);
}

.toast.error {
    border-color: var(--error);
    background: rgba(239, 68, 68, 0.1);
}

.toast.info {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

.toast-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.toast-message {
    flex: 1;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    font-size: 1.2rem;
    line-height: 1;
    border-radius: var(--radius-sm);
    transition: all 0.2s ease;
}

.toast-close:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

@keyframes slideInDown {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(10px);
    }
}

/* ============================================
   Share Buttons
   ============================================ */
.share-buttons {
    display: flex;
    gap: var(--space-sm);
    margin-top: var(--space-lg);
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s ease;
    min-height: 36px;
    min-width: 36px;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--glow);
}

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

.share-btn.whatsapp {
    background: #25D366;
    color: white;
}

.share-btn.facebook {
    background: #1877F2;
    color: white;
}

.share-btn.twitter {
    background: #1DA1F2;
    color: white;
}

.share-btn.linkedin {
    background: #0077B5;
    color: white;
}

.share-btn.telegram {
    background: #0088cc;
    color: white;
}

/* ============================================
   Ad Placeholder Styling
   ============================================ */
.ad-placeholder {
    background: linear-gradient(135deg, var(--bg-secondary), var(--bg-card));
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.9rem;
    min-height: 90px;
    transition: border-color 0.3s ease;
}

.ad-placeholder:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

/* ============================================
   Schema.org JSON-LD (Hidden)
   ============================================ */
.schema-jsonld {
    display: none;
}

/* ============================================
   404 Page Styling
   ============================================ */
.error-404-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-2xl);
    background: var(--bg-primary);
}

.error-404-content {
    max-width: 600px;
}

.error-404-code {
    font-family: var(--font-heading);
    font-size: 8rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: var(--space-lg);
}

.error-404-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
}

.error-404-desc {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-xl);
}

.error-404-actions {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================
   Rating System Enhancement
   ============================================ */
.rating-stars {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.rating-stars .star {
    font-size: 1rem;
    color: #fbbf24;
}

.rating-stars .star.empty {
    color: var(--text-muted);
    opacity: 0.3;
}

.rating-text {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    margin-right: var(--space-sm);
    font-weight: 600;
}

/* ============================================
   Related Tools Section
   ============================================ */
.related-tools {
    margin-top: var(--space-3xl);
    padding-top: var(--space-2xl);
    border-top: 1px solid var(--border-color);
}

.related-tools h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    margin-bottom: var(--space-xl);
    text-align: center;
}

/* ============================================
   Improved Ad Placeholders
   ============================================ */
.ad-slot {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(168, 85, 247, 0.05));
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.875rem;
    position: relative;
    overflow: hidden;
    min-height: 90px;
}

.ad-slot::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        transparent,
        rgba(255, 255, 255, 0.03),
        transparent
    );
    transform: rotate(45deg);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.ad-label {
    position: absolute;
    top: var(--space-sm);
    left: var(--space-sm);
    background: var(--accent-primary);
    color: white;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    text-transform: uppercase;
}

/* ============================================
   Lazy Load Skeleton
   ============================================ */
.skeleton {
    background: linear-gradient(90deg, 
        var(--bg-card) 25%, 
        var(--bg-secondary) 50%, 
        var(--bg-card) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-image {
    height: 180px;
    width: 100%;
}

.skeleton-text {
    height: 16px;
    margin-bottom: var(--space-sm);
}

.skeleton-text.title {
    height: 24px;
    width: 70%;
}

.skeleton-text.desc {
    height: 14px;
    width: 90%;
}

/* ============================================
   Copy Feedback
   ============================================ */
.copied-feedback {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-primary);
    color: white;
    padding: var(--space-sm) var(--space-lg);
    border-radius: var(--radius-xl);
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: var(--glow);
    z-index: 10002;
    animation: slideUp 0.3s ease-out, fadeOut 0.3s ease-in 2s forwards;
}

@keyframes slideUp {
    from {
        transform: translate(-50%, 20px);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

/* ============================================
   End of Additions
   ============================================ */

/*=
   End of Comprehensive Multi-Device Styles
   =*/