/*
Theme Name: calculator.net
Theme URI: https://calculator.net
Author: calculator.net
Author URI: https://google.com
Description: A modern, high-density calculator theme . Featuring a premium interactive calculator and streamlined editorial layout.
Version: 1.0.0
Text Domain: calculator2-net
*/

:root {
    --primary: #22c55e;
    --primary-light: #4ade80;
    --primary-dark: #16a34a;
    --primary-vibrant: #10b981;
    --bg-body: #f8fafc;
    --bg-card: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --accent: #e11d48;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -1px rgba(0,0,0,0.04);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -2px rgba(0,0,0,0.03);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
    --glass: rgba(255, 255, 255, 0.85);
    --glass-green: rgba(34, 197, 94, 0.05);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --premium-gradient: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Inter', system-ui, -apple-system, sans-serif; background: var(--bg-body); color: var(--text-main); font-size: 15px; -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4, h5, h6, .logo-text, .nav-btn, .classic-calc-header, .classic-calc-btn, .result-title, .summary-label { font-family: 'Outfit', sans-serif; }
a { text-decoration: none; color: inherit; }

/* TOP BAR */
.topbar { 
    background: var(--glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0,0,0,0.06); 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    padding: 12px 24px; 
    gap: 20px; 
    position: relative;
    top: 0;
    z-index: 1000;
}
.logo { display: flex; align-items: center; gap: 12px; }
.logo-icon { 
    width: 42px; 
    height: 42px; 
    border-radius: 12px; 
    background: linear-gradient(135deg, #22c55e, #4ade80); 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    color: #fff; 
    font-size: 22px; 
    font-weight: 900; 
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3); 
    transition: transform 0.2s;
}
.logo:hover .logo-icon { transform: rotate(-5deg) scale(1.05); }
.logo-text { font-size: 22px; font-weight: 800; color: #0f172a; letter-spacing: -0.8px; }

.header-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.theme-toggle {
    background: #f1f5f9 !important;
    color: #334155 !important;
    width: 40px;
    height: 40px;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    font-size: 18px !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.04) !important;
    border: 1px solid #e2e8f0 !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.theme-toggle:hover {
    background: #e2e8f0 !important;
    transform: translateY(-1px);
}

.topbar-search-container { 
    display: flex; 
    align-items: center; 
    flex: 1; 
    max-width: 450px; 
}

.topbar-search { 
    display: flex; 
    align-items: center; 
    background: #f1f5f9;
    border: 1px solid #e2e8f0; 
    border-radius: 50px; 
    overflow: hidden; 
    flex: 1; 
    max-width: 450px; 
    transition: all 0.2s;
}
.topbar-search:focus-within {
    background: #fff;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}
.topbar-search input { 
    border: none; 
    outline: none; 
    padding: 10px 20px; 
    font-size: 14px; 
    width: 100%; 
    font-family: inherit;
    background: transparent;
}
.topbar-search button { 
    background: var(--primary); 
    border: none; 
    color: #fff; 
    padding: 10px 22px; 
    cursor: pointer; 
    font-size: 13px; 
    text-transform: uppercase; 
    font-weight: 800; 
    border-radius: 0 50px 50px 0;
    transition: background 0.2s;
}
.topbar-search button:hover { background: var(--primary-dark); }

.lang-dropdown { position: relative; display: inline-block; }
.lang-content { 
    display: none; 
    position: absolute; 
    right: 0; 
    top: 100%; 
    background: #fff; 
    box-shadow: var(--shadow-xl); 
    min-width: 150px; 
    z-index: 9999; 
    border-radius: var(--radius-md); 
    border: 1px solid #e2e8f0; 
    margin-top: 10px;
}
.lang-dropdown:hover .lang-content { display: block; animation: slideUp 0.2s ease; }
@keyframes slideUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.lang-content a { color: #334155; padding: 12px 18px; display: block; text-decoration: none; font-size: 14px; font-weight: 700; border-bottom: 1px solid #f1f5f9; }
.lang-content a:last-child { border-bottom: none; }
.lang-content a:hover { background: #f8fafc; color: var(--primary); }
.lang-btn { 
    display: flex; 
    align-items: center; 
    gap: 8px; 
    background: #fff; 
    border: 1px solid #e2e8f0; 
    border-radius: 8px; 
    padding: 8px 16px; 
    cursor: pointer; 
    font-size: 13px; 
    font-weight: 700; 
    white-space: nowrap;
    transition: all 0.2s;
}
.lang-btn:hover { background: #f1f5f9; border-color: #cbd5e1; }

/* NAV SECTIONS (Standard Grid Rows) */
.nav-section { background: #fff; padding: 12px 10px; border-bottom: 2px solid #ddd; }
.nav-row { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-bottom: 6px; }
.nav-row:last-child { margin-bottom: 0; }

.nav-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 6px; font-size: 13px; font-weight: 700; color: #fff; cursor: pointer; border: none; transition: filter 0.2s, transform 0.1s; box-shadow: 0 2px 4px rgba(0,0,0,0.1); }
.nav-btn:hover { filter: brightness(1.2); transform: translateY(-1px); }
.nav-btn .icon { font-size: 15px; }

/* COLORS */
.c-teal { background: #00897B; }
.c-green { background: #43A047; }
.c-lime { background: #7CB342; }
.c-orange { background: #FB8C00; }
.c-red { background: #E53935; }
.c-pink { background: #D81B60; }
.c-purple { background: #8E24AA; }
.c-blue { background: #1E88E5; }
.c-navy { background: #1565C0; }
.c-cyan { background: #00ACC1; }
.c-amber { background: #FFB300; color: #333; }
.c-brown { background: #6D4C41; }
.c-indigo { background: #3949AB; }
.c-deep { background: #0277BD; }

/* HERO BANNER */
.hero { background: linear-gradient(135deg, #1565C0 0%, #1976D2 60%, #0D47A1 100%); color: #fff; text-align: center; padding: 20px 20px; box-shadow: inset 0 -5px 15px rgba(0,0,0,0.1); }
.hero h1 { font-size: 22px; font-weight: 800; margin-bottom: 6px; line-height: 1.2; }
.hero p { font-size: 14px; opacity: 0.95; line-height: 1.5; max-width: 800px; margin: 0 auto; }

/* CALCULATOR SECTION */
.calc-main-row { background: #fff; display: flex; align-items: flex-start; justify-content: center; gap: 20px; padding: 10px 20px; border-bottom: 2px solid #eee; }
.calc-side-ad { flex: 1; max-width: 300px; display: flex; flex-direction: column; gap: 10px; padding-top: 10px; }
.ad-placeholder { background: #f0f0f0; border: 1px dashed #ccc; color: #999; height: 400px; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; border-radius: 6px; }

.calc-wrap { padding: 10px 0; text-align: center; flex: 0 0 auto; }
.calc-container { display: inline-block; background: #e0e0e0; border-radius: 12px; padding: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.15); max-width: 360px; width: 100%; border: 3px solid #ccc; }
.calc-display { background: #fff; border: 2px solid #aaa; border-radius: 6px; padding: 8px 12px; text-align: right; margin-bottom: 10px; box-shadow: inset 0 2px 5px rgba(0,0,0,0.05); }
.calc-expr { font-size: 13px; color: #888; min-height: 18px; font-weight: 600; }
.calc-res { font-size: 32px; font-weight: 700; color: #1565C0; min-height: 36px; word-break: break-all; }

.calc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.cb { padding: 10px 0; border: 1px solid rgba(0,0,0,0.1); border-radius: 6px; font-size: 18px; font-weight: 700; cursor: pointer; transition: all 0.1s; font-family: 'Outfit', sans-serif; }
.cb:active { transform: scale(0.94); }
.cb.num { background: #fdfdfd; color: #333; box-shadow: 0 2px 0 #ddd; }
.cb.num:hover { background: #f5f5f5; }
.cb.op { background: #E3F2FD; color: #1565C0; border-color: #BBDEFB; }
.cb.op:hover { background: #BBDEFB; }
.cb.eq { background: #E53935; color: #fff; grid-column: span 2; box-shadow: 0 2px 0 #c62828; }
.cb.eq:hover { background: #d32f2f; }
.cb.fn { background: #F1F8E9; color: #43A047; border-color: #DCEDC8; }
.cb.clr { background: #FFF3E0; color: #FB8C00; border-color: #FFE0B2; }
.cb.back { background: #FAFAFA; color: #666; }

.fs-link { display: block; margin-top: 15px; font-size: 13px; color: #1565C0; font-weight: 800; cursor: pointer; text-decoration: underline; }

/* NAV 2 SECTION (Blue BG) */
.nav2 { background: #1565C0; padding: 15px 10px; }
.nav2 .nav-btn { background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2); }
.nav2 .nav-btn:hover { background: rgba(255,255,255,0.2); }

/* SUBNAV */
.subnav { background: #0D47A1; padding: 10px; text-align: center; }
.subnav .nav-row { gap: 10px; }
.subnav .tag { color: #fff; font-size: 12px; font-weight: 700; opacity: 0.8; cursor: pointer; }
.subnav .tag:hover { opacity: 1; text-decoration: underline; }

/* FEATURED TOOLS */
.featured { padding: 40px 20px; background: #fff; }
.featured-header { text-align: center; margin-bottom: 30px; }
.featured-header h2 { font-size: 26px; font-weight: 800; color: #222; }
.featured-header p { font-size: 14px; color: #666; margin-top: 5px; }

.tools-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 24px; max-width: 1200px; margin: 0 auto; }
.tool-card { border: 1px solid #e2e8f0; border-radius: var(--radius-lg); overflow: hidden; background: #fff; display: flex; flex-direction: column; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); box-shadow: var(--shadow-md); }
.tool-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-xl); border-color: var(--primary-light); }

.tool-body { display: flex; padding: 24px; gap: 20px; flex: 1; }
.tool-icon { 
    width: 64px; 
    height: 64px; 
    border-radius: 16px; 
    background: #f8fafc; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 32px; 
    flex-shrink: 0; 
    border: 1px solid #f1f5f9;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}
.tool-info h3 { font-size: 19px; font-weight: 800; color: #0f172a; margin-bottom: 10px; transition: color 0.2s; }
.tool-card:hover .tool-info h3 { color: var(--primary); }
.tool-info p { font-size: 14px; color: #64748b; line-height: 1.6; }
.tool-footer { 
    background: #f8fafc; 
    color: #1e40af; 
    text-align: center; 
    padding: 16px; 
    font-weight: 800; 
    font-size: 14px; 
    cursor: pointer; 
    border-top: 1px solid #f1f5f9;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.tool-card:hover .tool-footer { background: var(--primary); color: #fff; }

/* TOOL CARD COLOR VARIANTS */
.tool-card.tc-amber { border: 2px solid #FF8F00; }
.tool-card.tc-amber .tool-footer { background: #FF8F00; }
.tool-card.tc-amber .tool-info h3 { color: #FF8F00; }
.tool-card.tc-amber:hover { box-shadow: 0 12px 25px rgba(255,143,0,0.2); }

.tool-card.tc-green { border: 2px solid #2E7D32; }
.tool-card.tc-green .tool-footer { background: #2E7D32; }
.tool-card.tc-green .tool-info h3 { color: #2E7D32; }
.tool-card.tc-green:hover { box-shadow: 0 12px 25px rgba(46,125,50,0.2); }

.tool-card.tc-blue { border: 2px solid #1E88E5; }
.tool-card.tc-blue .tool-footer { background: #1E88E5; }
.tool-card.tc-blue .tool-info h3 { color: #1E88E5; }
.tool-card.tc-blue:hover { box-shadow: 0 12px 25px rgba(30,136,229,0.2); }

.tool-card.tc-purple { border: 2px solid #8E24AA; }
.tool-card.tc-purple .tool-footer { background: #8E24AA; }
.tool-card.tc-purple .tool-info h3 { color: #8E24AA; }
.tool-card.tc-purple:hover { box-shadow: 0 12px 25px rgba(142,36,170,0.2); }

.tool-card.tc-red { border: 2px solid #D32F2F; }
.tool-card.tc-red .tool-footer { background: #D32F2F; }
.tool-card.tc-red .tool-info h3 { color: #D32F2F; }
.tool-card.tc-red:hover { box-shadow: 0 12px 25px rgba(211,47,47,0.2); }

.tool-card.tc-teal { border: 2px solid #00897B; }
.tool-card.tc-teal .tool-footer { background: #00897B; }
.tool-card.tc-teal .tool-info h3 { color: #00897B; }
.tool-card.tc-teal:hover { box-shadow: 0 12px 25px rgba(0,137,123,0.2); }

/* PREMIUM SIGNUP BUTTON */
.signup-btn {
    background: linear-gradient(135deg, #22c55e, #4ade80) !important;
    color: #fff !important;
    padding: 10px 24px !important;
    border-radius: 50px !important;
    font-weight: 800 !important;
    font-size: 14px !important;
    text-transform: capitalize !important;
    box-shadow: 0 4px 15px rgba(21, 101, 192, 0.4);
    transition: all 0.3s ease !important;
    border: none !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.signup-btn:hover {
    box-shadow: 0 8px 25px rgba(21, 101, 192, 0.6);
    transform: translateY(-2px);
    background: linear-gradient(135deg, #4ade80, #86efac) !important;
}

/* COLOR SECTIONS */
.banner-red { background: #C62828; color: #fff; padding: 40px 20px; text-align: center; }
.banner-green { background: #43A047; color: #fff; padding: 40px 20px; text-align: center; }

.banner-content { max-width: 900px; margin: 0 auto; }
.banner-title { display: flex; align-items: center; justify-content: center; gap: 10px; font-size: 18px; font-weight: 800; margin-bottom: 15px; }
.banner-text { font-size: 15px; line-height: 1.7; opacity: 0.9; margin-bottom: 25px; }

.grid-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.link-tag { padding: 8px 16px; border-radius: 4px; font-size: 13px; font-weight: 700; cursor: pointer; transition: background 0.2s; box-shadow: 0 2px 4px rgba(0,0,0,0.1); border: 1px solid rgba(255,255,255,0.1); }
.link-tag:not([class*="c-"]) { background: rgba(0,0,0,0.2); }
.link-tag:hover { background: rgba(0,0,0,0.4); }

/* FOOTER */
footer { background: #222; color: #aaa; padding: 40px 20px; text-align: center; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; margin-bottom: 20px; border-bottom: 1px solid #333; padding-bottom: 20px; }
.footer-links a { font-size: 13px; font-weight: 600; }
.footer-links a:hover { color: #fff; }
.footer-copy { font-size: 12px; opacity: 0.6; }


/* TOOL PAGE LAYOUT */
.page-with-sidebar-layout { display: flex; gap: 30px; padding: 30px 20px; max-width: 1200px; margin: 0 auto; }
.page-main-content { flex: 1; min-width: 0; }
.site-sidebar { width: 320px; flex-shrink: 0; }

@media(max-width: 992px) {
    .page-with-sidebar-layout { flex-direction: column !important; }
    .page-main-content { order: 1; }
    .site-sidebar { order: 2; position: static !important; margin-top: 30px; width: 100% !important; }

}

/* BREADCRUMBS */
.breadcrumb-nav { 
    font-size: 13px; 
    margin-bottom: 30px; 
    padding: 12px 18px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-md);
    color: var(--text-muted); 
    font-weight: 600; 
    display: inline-flex; 
    align-items: center; 
    gap: 10px; 
    box-shadow: var(--shadow-sm);
}
.breadcrumb-nav a { color: var(--primary); transition: color 0.2s; }
.breadcrumb-nav a:hover { color: var(--primary-light); text-decoration: none; }
.breadcrumb-separator { opacity: 0.3; font-weight: 400; }
.breadcrumb-current { color: var(--text-main); font-weight: 700; }

/* MAIN CONTENT TYPOGRAPHY */
h1.main-seo-h1 { 
    font-size: 34px; 
    font-weight: 900; 
    color: #0f172a; 
    margin-bottom: 20px; 
    line-height: 1.2;
    letter-spacing: -0.5px;
}
.page-main-content p { 
    font-size: 17px; 
    line-height: 1.8; 
    color: #475569; 
    margin-bottom: 25px; 
}

/* CLASSIC CALCULATOR WRAPPER (Premium Card) */
.classic-calc-wrapper { background: #fff; border: 2px solid #e0e0e0; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); margin-bottom: 40px; }
.classic-calc-header { background: #f8f9fa; border-bottom: 2px solid #e0e0e0; padding: 10px 16px; font-size: 18px; font-weight: 800; color: var(--primary); display: flex; align-items: center; }
.classic-calc-body { padding: 30px 25px; background: #fff; }

.calculator-input-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.calculator-input-item label, .age-input-group label { display: block; font-weight: 700; font-size: 14px; margin-bottom: 8px; color: #000; }
.calculator-input-item input, .calculator-input-item select, .age-input-group input, .age-input-group select { width: 100%; padding: 12px; border: 2px solid #eee; border-radius: 8px; font-family: inherit; font-size: 15px; transition: border-color 0.2s; color: #000; }
.calculator-input-item input:focus, .calculator-input-item select:focus, .age-input-group input:focus, .age-input-group select:focus { border-color: var(--primary); outline: none; color: #000; }

.classic-calc-btns-container {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    width: 100%;
    grid-column: 1 / -1; /* For cases where it's inside a grid */
}

.classic-calc-btn { 
    background: var(--premium-gradient); 
    color: #fff; 
    border: none; 
    padding: 12px 28px; 
    font-size: 15px; 
    font-weight: 800; 
    border-radius: 12px; 
    cursor: pointer; 
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); 
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.25); 
    text-transform: uppercase; 
    letter-spacing: 0.5px; 
    display: inline-flex; 
    align-items: center; 
    justify-content: center;
    gap: 8px; 
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
    min-width: 170px; /* Slightly smaller */
}
.classic-calc-btn:hover { 
    background: linear-gradient(135deg, #16a34a, #22c55e); 
    box-shadow: 0 8px 20px rgba(34, 197, 94, 0.4); 
    transform: translateY(-2px) scale(1.02); 
}
.classic-calc-btn:hover span {
    transform: rotate(360deg);
}
.classic-calc-btn span { 
    font-size: 14px; 
    opacity: 0.9; 
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
}

/* SECONDARY BUTTON (Reset) */
.classic-calc-btn-secondary {
    background: #f8f9fa;
    color: #555;
    border: 1px solid #ddd;
    padding: 8px 18px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.classic-calc-btn-secondary:hover {
    background: #e9ecef;
    border-color: #ced4da;
    color: #212529;
}

/* ARTICLE CONTENT */
.article-content h2 { font-size: 26px; font-weight: 800; color: #222; margin: 40px 0 20px; position: relative; padding-left: 15px; }
.article-content h2::before { content: ''; position: absolute; left: 0; top: 5px; bottom: 5px; width: 5px; background: var(--primary); border-radius: 2px; }
.article-content h3 { font-size: 18px; font-weight: 800; color: #333; margin: 30px 0 15px; }
.article-content ul, .article-content ol { margin-bottom: 25px; padding-left: 20px; }
.article-content li { margin-bottom: 10px; line-height: 1.6; color: #555; }

/* TABLES */
.comparison-table { width: 100%; border-radius: 10px; overflow: hidden; border: 2px solid #eee; margin: 30px 0; }
.comparison-table th { background: #2c3e50; color: #fff; padding: 15px; text-align: left; font-size: 14px; text-transform: uppercase; }
.comparison-table td { padding: 15px; border-bottom: 1px solid #eee; vertical-align: top; font-size: 14px; color: #444; }
.comparison-table tr:last-child td { border-bottom: none; }
.comparison-table tr:nth-child(even) { background: #fcfcfc; }

/* BOXES */
.example-box { background: #f1f8e9; border-left: 5px solid #43a047; padding: 25px; border-radius: 0 10px 10px 0; margin: 30px 0; font-size: 15px; color: #2E7D32; line-height: 1.6; }
.rule-box div { background: #fff; padding: 25px; border-radius: 12px; border: 1px solid #eee; box-shadow: 0 4px 10px rgba(0,0,0,0.03); }
.rule-box h5 { font-size: 16px; font-weight: 800; color: var(--primary); margin-bottom: 10px; }

/* FAQ */
.faq-section { background: #fff; border-radius: 12px; border: 2px solid #eee; padding: 30px; margin: 40px 0; }
.faq-item { margin-bottom: 25px; border-bottom: 1px solid #f0f0f0; padding-bottom: 20px; }
.faq-item:last-child { margin-bottom: 0; border-bottom: none; }
.faq-item h4 { font-size: 18px; font-weight: 800; color: #222; margin-bottom: 10px; }
.faq-item p { margin-bottom: 0 !important; font-size: 15px; color: #666; }

/* RESULTS CARD */
.result-card { background: #f8f9fa; border: 2px dashed var(--primary); border-radius: 12px; padding: 30px; margin-top: 30px; }
.result-title { font-size: 22px; font-weight: 800; color: var(--primary); margin-bottom: 20px; text-align: center; }
.result-summary-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 20px; margin-bottom: 30px; }
.summary-item { background: #fff; padding: 20px; border-radius: 10px; text-align: center; border: 1px solid #eee; }
.summary-val { font-size: 18px; font-weight: 800; color: #222; }
.summary-label { font-size: 12px; color: #888; text-transform: uppercase; margin-top: 5px; }

.result-charts-container { display: flex; gap: 20px; flex-wrap: wrap; }
.chart-card { flex: 1; min-width: 300px; background: #fff; padding: 20px; border-radius: 10px; border: 1px solid #eee; }

/* SIDEBAR STYLES */
.sidebar, .site-sidebar { position: -webkit-sticky; position: relative; top: 90px; height: fit-content; align-self: flex-start; }

.sidebar-section { background: #fff; border: 2px solid #eee; border-radius: 12px; padding: 20px; margin-bottom: 25px; box-shadow: 0 4px 10px rgba(0,0,0,0.02); }
.sidebar-title { font-size: 18px; font-weight: 800; color: #222; margin-bottom: 20px; display: flex; align-items: center; gap: 10px; border-bottom: 2px solid #f0f0f0; padding-bottom: 15px; }
.title-icon { font-size: 16px; background: #fff; width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 5px rgba(0,0,0,0.1); }

.sidebar-calculator-list { list-style: none; }
.sidebar-calculator-list li { margin-bottom: 12px; }
.sidebar-calculator-list a { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; color: #000; transition: color 0.1s; }
.sidebar-calculator-list a:hover { color: var(--primary); }
.sidebar-calculator-list .dot { width: 6px; height: 6px; border-radius: 50%; background: #ccc; }
.sidebar-calculator-list a:hover .dot { background: var(--primary); transform: scale(1.5); }

/* SIDEBAR SEARCH */
.sidebar-search-form .search-wrap { display: flex; border: 2px solid #eee; border-radius: 8px; overflow: hidden; }
.sidebar-search-form input { border: none; outline: none; padding: 10px 15px; font-size: 14px; width: 100%; font-family: inherit; }
.sidebar-search-form button { background: var(--primary); border: none; color: #fff; padding: 10px 15px; cursor: pointer; }

/* CATEGORY GRID BOXES (Premium Grid) */
.cat-grid-wrapper { padding: 40px 20px; background: #fdfdfd; }
.cat-container-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; max-width: 1200px; margin: 0 auto; }

.cat-card { background: #fff; border: 2px solid #ddd; border-radius: 6px; overflow: hidden; display: flex; flex-direction: column; transition: transform 0.2s; }
.cat-card:hover { transform: scale(1.02); z-index: 10; box-shadow: 0 10px 25px rgba(0,0,0,0.1); }

/* The color classes (c-navy, c-red, etc.) will apply to the category HEADER */
.cat-header { padding: 12px; text-align: center; color: #fff; font-size: 16px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px; border-bottom: 2px solid rgba(0,0,0,0.1); }
.cat-card.c-navy .cat-header { background: #1565C0; }
.cat-card.c-red .cat-header { background: #E53935; }
.cat-card.c-green .cat-header { background: #43A047; }
.cat-card.c-orange .cat-header { background: #FB8C00; }

.cat-list { list-style: none; padding: 0; margin: 0; flex: 1; }
.cat-list li { border-bottom: 1px solid #f0f0f0; }
.cat-list li:last-child { border-bottom: none; }
.cat-list a { display: block; padding: 10px 15px; font-size: 14px; font-weight: 700; color: #333; transition: background 0.1s; }
.cat-list a:hover { background: #f5f5f5; color: var(--primary); text-decoration: underline; }

.cat-more { display: block; padding: 10px; text-align: center; font-size: 12px; font-weight: 800; color: #fff; text-transform: uppercase; background: #444; }
.cat-card.c-navy .cat-more { background: #0D47A1; }
.cat-card.c-red .cat-more { background: #C62828; }
.cat-card.c-green .cat-more { background: #2E7D32; }
.cat-card.c-orange .cat-more { background: #E65100; }
.cat-more:hover { filter: brightness(1.2); }

/* === PREMIUM RESULT SUMMARY CARDS === */
.result-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); /* slightly smaller minimum width */
    gap: 12px;
    margin-bottom: 24px;
}
.summary-item {
    background: #ffffff;
    border-radius: 10px;
    padding: 14px 16px;
    border: 1px solid #cbd5e1; 
    box-shadow: 0 4px 6px rgba(0,0,0,0.05); 
    text-align: center;
}
.summary-item.highlight {
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    border: none;
}
.summary-label { 
    font-size: 11px; /* Smaller label */
    font-weight: 800; 
    color: #000; 
    text-transform: uppercase; 
    letter-spacing: 0.5px; 
    margin-bottom: 6px; 
    font-family: 'Inter', sans-serif;
}
.summary-item.highlight .summary-label { color: rgba(255,255,255,0.9); }
.summary-value { 
    font-size: 18px; /* Slightly smaller value */
    font-weight: 900; 
    color: #000; 
    font-family: 'Inter', sans-serif;
}
/* Fix: Text was white on white background. Now it is a strong blue instead, unless the whole card is highlighted */
.summary-value.highlight { color: #1e40af; }
.summary-item.highlight .summary-value { color: #ffffff; }

/* === PREMIUM RESULT TABLES === */
.modern-result-table { 
    width: 100%; 
    border-collapse: collapse; 
    margin-top: 20px; 
    border-radius: 10px; 
    overflow: hidden; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
    border: 1px solid #e2e8f0;
}
.modern-result-table thead tr { 
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%); 
    color: #fff; 
}
.modern-result-table th { 
    padding: 12px 16px; 
    text-align: left; 
    font-size: 12px; 
    font-weight: 700; 
    letter-spacing: 0.5px; 
    text-transform: uppercase;
}
.modern-result-table td { 
    padding: 12px 16px; 
    font-size: 14px; 
    border-bottom: 1px solid #f1f5f9; 
    color: #334155;
    font-weight: 500;
}
.modern-result-table tbody tr:nth-child(even) td { 
    background: #f8fafc; 
}
.modern-result-table tbody tr:hover td {
    background: #f1f5f9;
}

/* === SEO ARTICLE Premium Styling === */
.dynamic-seo-guide {
    margin-top: 50px; 
    padding: 40px; 
    font-family: 'Inter', sans-serif; 
    line-height: 1.9; 
    color: #334155; 
    background: #ffffff; 
    border-radius: 16px;
    box-shadow: 0 4px 30px rgba(0,0,0,0.02);
    border: 1px solid #e2e8f0;
}
.rank-math-toc-container {
    background: #f8fafc; 
    padding: 25px; 
    border-radius: 10px; 
    margin-bottom: 35px; 
    border-left: 5px solid #1e40af;
}
.rank-math-toc-container h4 { margin-top: 0; color: #0f172a; font-weight: 800; font-size: 18px; }
.toc-list { list-style: none; padding-left: 0; font-size: 15px; columns: 2; margin: 0; }
.toc-list li { margin-bottom: 8px; }
.toc-list a { color: #1e40af; text-decoration: none; font-weight: 600; transition: color 0.2s; }
.toc-list a:hover { color: #1d4ed8; text-decoration: underline; }

.seo-section { margin-top: 40px; }
.seo-section h2, .seo-section h3, .seo-section h4 {
    color: #0f172a; 
    font-weight: 800; 
    margin-bottom: 16px;
    line-height: 1.3;
}
.seo-section h2 { font-size: 26px; }
.seo-section h3 { font-size: 22px; }
.seo-section p { font-size: 16px; color: #475569; margin-bottom: 16px; }
.seo-section strong { color: #1e293b; }

.seo-img-wrapper { text-align: center; margin-bottom: 25px; }
.seo-img-wrapper img { max-width: 100%; height: auto; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.08); }

.seo-steps-list {
    background: #f8fafc; 
    padding: 20px 20px 20px 40px; 
    border-radius: 8px; 
    border: 1px solid #e2e8f0;
    margin-bottom: 20px;
}
.seo-steps-list li { margin-bottom: 10px; color: #475569; font-size: 15px; padding-left: 5px;}

.seo-table-wrapper {
    overflow-x: auto; 
    border-radius: 10px; 
    border: 1px solid #e2e8f0; 
    background: #fff; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    margin-bottom: 15px;
}
.seo-table { width: 100%; border-collapse: collapse; font-size: 15px; text-align: left; }
.seo-table thead { background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%); color: #fff; }
.seo-table th { padding: 15px; font-weight: 700; letter-spacing: 0.5px; }
.seo-table td { padding: 12px 15px; border-bottom: 1px solid #f1f5f9; }
.seo-table td.bad { color: #64748b; }
.seo-table td.good { color: #1565C0; font-weight: 800; }

.seo-caption { font-size: 13px !important; color: #94a3b8 !important; font-style: italic; text-align: center; }

.seo-faq { border-top: 1px solid #e2e8f0; padding-top: 35px; }
.faq-item { margin-bottom: 20px; }
.faq-item strong { display: block; font-size: 16px; color: #1e293b; margin-bottom: 5px; }

.seo-conclusion { padding: 25px; background: #fffbeb; border-radius: 12px; border: 1px solid #fde68a; }
.seo-conclusion h4 { margin-top: 0; color: #b45309; }

/* RESPONSIVE OVERRIDES (Moved to end for top-level specificity) */
@media(max-width: 600px) {
    /* MOBILE SEO BLOCK FULL WIDTH EDGE-TO-EDGE */
    .dynamic-seo-guide { 
        margin-left: -15px !important; 
        margin-right: -15px !important; 
        width: calc(100% + 30px) !important; 
        border-radius: 0 !important; 
        border-left: none !important; 
        border-right: none !important; 
        padding: 25px 15px !important; 
    }
    .toc-list { columns: 1; }

    body { font-size: 13px; }
    .hero h1 { font-size: 19px; }
    .hero p { font-size: 13px; }
    /* MOBILE HEADER: LOGO + DARK MODE + SIGNUP ONLY */
    .topbar { 
        flex-wrap: nowrap !important;
        flex-direction: row !important; 
        justify-content: space-between !important; 
        align-items: center !important; 
        padding: 0 15px !important; 
        height: 60px !important; 
        position: relative !important; 
        top: 0 !important; 
        background: #ffffff !important; 
        box-shadow: 0 2px 12px rgba(0,0,0,0.08) !important;
        gap: 10px !important;
        border-bottom: 1px solid #f1f5f9 !important;
    }
    /* Hide search on mobile */
    .topbar-search-container { 
        display: none !important; 
    }
    .logo { 
        display: flex !important;
        align-items: center !important;
        gap: 10px !important;
        width: auto !important; 
    }
    .logo-text { 
        display: block !important; 
        font-size: 16px !important; 
        font-weight: 800 !important;
        color: #0f172a !important;
        letter-spacing: -0.3px !important;
    }
    .logo-icon {
        width: 36px !important;
        height: 36px !important;
        font-size: 18px !important;
        border-radius: 10px !important;
    }
    .header-controls { 
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        margin-left: auto !important;
    }
    .theme-toggle {
        width: 36px !important;
        height: 36px !important;
        border-radius: 10px !important;
        font-size: 16px !important;
        background: #f1f5f9 !important;
        border: 1px solid #e2e8f0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 !important;
    }
    .signup-btn {
        padding: 0 16px !important;
        font-size: 13px !important;
        font-weight: 800 !important;
        white-space: nowrap !important;
        border-radius: 50px !important;
        height: 36px !important;
        display: flex !important;
        align-items: center !important;
        box-shadow: 0 4px 12px rgba(21, 101, 192, 0.35) !important;
    }

    /* NAV SECTION MOBILE */
    .nav-section { padding: 8px 4px; }
    .nav-btn { padding: 6px 10px; font-size: 12px; flex: 1 1 calc(50% - 6px); justify-content: center; min-width: 140px; }
    /* CRITICAL FIX: Header control buttons must NOT stretch like nav buttons */
    .header-controls .nav-btn {
        flex: 0 0 auto !important;
        min-width: unset !important;
        width: auto !important;
        padding: unset !important;
    }

    .hero { padding: 25px 10px; }
    .calc-main-row { display: block; padding: 10px 0; }
    .calc-side-ad { display: none; }
    .calc-wrap { padding: 10px 0; }
    .calc-container { padding: 12px; width: 100%; max-width: none; border-radius: 0; border-left: none; border-right: none; }

    .page-with-sidebar-layout { padding: 15px 0; gap: 15px; }
    .page-main-content { padding: 0; }
    .page-main-content > .breadcrumb-nav, 
    .page-main-content > .main-seo-h1, 
    .page-main-content > p:not(.article-content p),
    .article-content { padding: 0 15px; }

    .classic-calc-wrapper { border-left: none; border-right: none; border-radius: 0; margin-bottom: 25px; box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
    .classic-calc-body { padding: 20px 15px; }
    
    .featured { padding: 30px 10px; }
    .tools-grid { grid-template-columns: 1fr; gap: 15px; }
    
    .banner-red, .banner-green { padding: 30px 12px; }
    .link-tag { font-size: 12px; padding: 6px 12px; }
    
    .sidebar-section { border-left: none; border-right: none; border-radius: 0; padding: 15px; }

    /* MOBILE RESULTS FULL WIDTH */
    .result-card { border-left: none !important; border-right: none !important; border-radius: 0 !important; padding: 20px 10px !important; margin-left: -15px !important; margin-right: -15px !important; width: calc(100% + 30px) !important; border-style: solid !important; border-width: 1px 0 !important; }
    .result-summary-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 10px !important; }
    .result-charts-container { flex-direction: column !important; }
    .chart-card { min-width: 0 !important; width: 100% !important; border-radius: 0 !important; border-left: none !important; border-right: none !important; padding: 15px 10px !important; }
    
    /* MOBILE SEO BLOCK FULL WIDTH */
    .dynamic-seo-guide { 
        margin-left: -15px !important; 
        margin-right: -15px !important; 
        width: calc(100% + 30px) !important; 
        border-radius: 0 !important; 
        padding: 25px 15px !important; 
        border-left: none !important; 
        border-right: none !important; 
    }
    /* MOBILE AUTO-SLIDER */
    .sv-mobile-slider {
        display: flex !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        gap: 12px !important;
        padding: 10px 5px 20px !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Hide scrollbar Firefox */
        scroll-behavior: smooth;
    }
    .sv-mobile-slider::-webkit-scrollbar { display: none; } /* Hide scrollbar Chrome/Safari */
    .sv-mobile-slider .link-tag {
        flex: 0 0 auto !important;
        white-space: nowrap !important;
        box-shadow: 0 4px 10px rgba(0,0,0,0.1) !important;
    }
}

/* === FRONT PAGE ARTICLE STYLING (STYLISH & COLORFUL) === */
.front-page-article {
    max-width: 1100px;
    margin: 60px auto;
    padding: 0 20px;
    font-family: 'Inter', sans-serif;
    color: #334155;
    line-height: 1.8;
}

.article-header {
    text-align: center;
    margin-bottom: 40px;
}

.article-main-title {
    font-size: 32px;
    font-weight: 900;
    color: #1e293b;
    margin-bottom: 10px;
    background: linear-gradient(90deg, #1565C0, #0D47A1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.article-subtitle {
    font-size: 16px;
    color: #64748b;
    font-weight: 700;
}

.article-grid {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.article-card {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    border: 1px solid #e2e8f0;
}

.article-card h2 {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.article-card.intro-card {
    font-size: 16px;
    line-height: 1.8;
    background: #f8fafc;
}

.accent-blue h2 { color: #1565C0; }
.accent-navy { border-top: 5px solid #0D47A1 !important; }

.pillar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.pillar-item {
    background: #fff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.04);
    transition: transform 0.2s;
}

.pillar-item:hover { transform: translateY(-5px); }

.pillar-item h3 {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 12px;
}

.accent-teal h3 { color: #00897B; border-bottom: 2px solid #00897B; padding-bottom: 8px; }
.accent-red h3 { color: #E53935; border-bottom: 2px solid #E53935; padding-bottom: 8px; }
.accent-green h3 { color: #43A047; border-bottom: 2px solid #43A047; padding-bottom: 8px; }

.comparison-table-wrap { margin-top: 20px; border-radius: 8px; overflow: hidden; border: 1px solid #cbd5e1; }
.comparison-table { width: 100%; border-collapse: collapse; background: #fff; }
.comparison-table th { background: #1565C0; color: #fff; padding: 15px; text-align: left; font-weight: 800; }
.comparison-table td { padding: 15px; border-bottom: 1px solid #e2e8f0; font-size: 14px; }
.comparison-table tr:last-child td { border-bottom: none; }

.tool-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.t-tag { background: #f1f5f9; padding: 3px 10px; border-radius: 4px; font-weight: 700; font-size: 12px; color: #1565C0; border: 1px solid #e2e8f0; }

.pro-tip-banner {
    display: flex;
    align-items: center;
    gap: 20px;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: #fff;
    padding: 25px;
    border-radius: 12px;
}

.tip-icon { font-size: 30px; }

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.faq-item h4 {
    font-size: 16px;
    font-weight: 800;
    color: #1565C0;
    margin-bottom: 8px;
}

.article-footer-box {
    background: #f1f5f9;
    padding: 40px;
    text-align: center;
    border-radius: 12px;
}

.article-footer-box h2 {
    font-size: 18px;
    font-weight: 900;
    color: #1e293b;
    margin-bottom: 15px;
}

/* --- MODERN GLASS SPINNER --- */
.sv-glass-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 99999;
    display: none;
    align-items: center; justify-content: center;
    flex-direction: column;
}

.sv-glass-spinner {
    width: 50px; height: 50px;
    border: 4px solid rgba(21, 101, 192, 0.08);
    border-top: 4px solid #1565C0;
    border-radius: 50%;
    animation: sv-spin 0.8s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.sv-glass-text {
    margin-top: 15px;
    font-family: 'Inter', sans-serif;
    color: #1565C0;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 13px;
}

@keyframes sv-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.sv-glass-overlay.active { display: flex; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

@media(max-width: 768px) {
    .article-main-title { font-size: 26px; }
    .pillar-grid { grid-template-columns: 1fr; }
    .pro-tip-banner { flex-direction: column; text-align: center; }
}

/* --- FULL PAGE PRELOADER (2S PREMIUM ANIMATION) --- */
.sv-preloader {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: #ffffff;
    z-index: 1000000;
    display: flex;
    align-items: center; justify-content: center;
    flex-direction: column;
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.6s;
}

.sv-preloader-container {
    display: flex;
    gap: 10px;
}

.sv-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    animation: sv-dot-bounce 1s infinite alternate;
}

.sv-dot:nth-child(1) { background: #1565C0; animation-delay: 0s; }
.sv-dot:nth-child(2) { background: #43A047; animation-delay: 0.2s; }
.sv-dot:nth-child(3) { background: #E53935; animation-delay: 0.4s; }

@keyframes sv-dot-bounce {
    0% { transform: translateY(0); opacity: 0.3; }
    100% { transform: translateY(-20px); opacity: 1; }
}

.sv-preloader-text {
    margin-top: 40px;
    font-size: 14px;
    font-weight: 800;
    color: #1e293b;
    letter-spacing: 3px;
    text-transform: uppercase;
    animation: pulse 1.5s infinite;
}

@keyframes sv-pre-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes pulse {
    0% { opacity: 0.5; }
    50% { opacity: 1; }
    100% { opacity: 0.5; }
}

.sv-preloader.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* MODERN FOOTER STYLES */
.site-footer {
    background: #0f172a;
    color: #f8fafc;
    padding: 80px 20px 40px;
    border-top: 4px solid #1565C0;
    font-family: 'Inter', sans-serif;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.footer-logo {
    background: #fff;
    color: #1565C0;
    width: 35px;
    height: 35px;
    font-size: 18px;
}

.footer-brand-name {
    font-size: 18px;
    font-weight: 800;
    color: #fff;
}

.footer-about {
    font-size: 14px;
    line-height: 1.7;
    color: #94a3b8;
    margin-bottom: 25px;
}

.social-row {
    display: flex;
    gap: 12px;
}

.social-icon {
    width: 32px;
    height: 32px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    transition: all 0.3s;
}

.social-icon:hover {
    background: #1565C0;
    transform: translateY(-3px);
}

.footer-title {
    font-size: 18px;
    font-weight: 800;
    color: #fff;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

.footer-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 30px;
    height: 3px;
    background: #1565C0;
    border-radius: 2px;
}

.footer-nav-list {
    list-style: none;
}

.footer-nav-list li {
    margin-bottom: 15px;
}

.footer-nav-list a {
    font-size: 14px;
    color: #94a3b8;
    transition: color 0.2s;
}

.footer-nav-list a:hover {
    color: #fff;
    padding-left: 5px;
}

.footer-bottom {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-copy {
    font-size: 13px;
    color: #64748b;
}

.back-to-top {
    background: #1565C0;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 800;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(21, 101, 192, 0.2);
}

.back-to-top:hover {
    background: #1E88E5;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(21, 101, 192, 0.3);
}

@media(max-width: 992px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media(max-width: 576px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

/* --- DARK MODE THEME --- */
body[data-theme="dark"] {
    --bg-body: #0f172a;
    --text-main: #f1f5f9;
    background: #0f172a;
}

body[data-theme="dark"] .topbar,
body[data-theme="dark"] .nav-section,
body[data-theme="dark"] .calc-main-row,
body[data-theme="dark"] .featured,
body[data-theme="dark"] .cat-grid-wrapper {
    background: #1e293b !important;
    border-color: #334155 !important;
}

body[data-theme="dark"] .topbar-search input {
    background: #334155;
    color: #fff;
    border-color: #475569;
}

body[data-theme="dark"] .tool-card,
body[data-theme="dark"] .cat-card,
body[data-theme="dark"] .article-card,
body[data-theme="dark"] .classic-calc-wrapper {
    background: #0f172a !important;
    border-color: #334155 !important;
    color: #fff;
}

body[data-theme="dark"] .tool-info p,
body[data-theme="dark"] .article-card p,
body[data-theme="dark"] .cat-list li a {
    color: #94a3b8;
}

body[data-theme="dark"] .hero {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-bottom: 2px solid #334155;
}

body[data-theme="dark"] .calc-container {
    background: #334155;
    border-color: #475569;
}

body[data-theme="dark"] .calc-display {
    background: #0f172a;
    border-color: #1e293b;
}

body[data-theme="dark"] .cb.num {
    background: #1e293b;
    color: #fff;
    box-shadow: 0 2px 0 #0f172a;
}

body[data-theme="dark"] .lang-btn {
    background: #334155;
    color: #fff;
    border-color: #475569;
}

body[data-theme="dark"] .lang-content {
    background: #1e293b;
    border-color: #334155;
}

body[data-theme="dark"] .lang-content a {
    color: #fff;
    border-color: #334155;
}

body[data-theme="dark"] .article-main-title {
    color: #fff;
}

body[data-theme="dark"] .site-footer {
    background: #020617;
}

body[data-theme="dark"] ::-webkit-scrollbar-track { background: #0f172a; }
body[data-theme="dark"] ::-webkit-scrollbar-thumb { background: #334155; }

/* --- PREMIUM AJAX SEARCH STYLES --- */
.topbar-search-container {
    position: relative;
    flex: 1;
    max-width: 450px;
    margin: 0 20px;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.theme-toggle {
    background: #f1f5f9 !important;
    color: #334155 !important;
    width: 40px;
    height: 40px;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    font-size: 18px !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.04) !important;
    border: 1px solid #e2e8f0 !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.theme-toggle:hover {
    background: #e2e8f0 !important;
    transform: translateY(-1px);
}

.topbar-search-container { 
    display: flex; 
    align-items: center; 
    flex: 1; 
    max-width: 450px; 
}

.topbar-search {
    display: flex;
    align-items: center;
    background: #f1f5f9;
    border-radius: 8px;
    padding: 2px;
    border: 1.5px solid #e2e8f0;
    transition: all 0.3s;
}

.topbar-search:focus-within {
    border-color: #1565C0;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(21, 101, 192, 0.1);
}

.top-search-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 8px 15px;
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    outline: none;
}

#top-search-btn {
    background: #22c55e;
    color: #fff;
    border: none;
    padding: 8px 18px;
    border-radius: 6px;
    font-weight: 800;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s;
}

#top-search-btn:hover { background: #16a34a; }

/* --- PREMIUM AJAX SEARCH STYLES (MODERN GLASSMORPHISM) --- */
.search-suggestions {
    position: absolute;
    top: calc(100% + 15px);
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 16px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.5);
    display: none;
    animation: svScaleFade 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes svScaleFade {
    from { opacity: 0; transform: translateY(-15px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.search-loading { padding: 20px; text-align: center; color: #64748b; font-size: 14px; font-weight: 700; letter-spacing: 0.5px; animation: pulse 1.5s infinite; }
@keyframes pulse { 0%, 100% { opacity: 0.8; } 50% { opacity: 0.4; } }

.suggestions-header { font-size: 10px; font-weight: 900; color: #94a3b8; padding: 12px 20px 8px; text-transform: uppercase; letter-spacing: 1.5px; border-bottom: 1px solid #f1f5f9; }
.suggestions-footer { background: #f8fafc; padding: 10px 20px; font-size: 11px; font-weight: 700; color: #64748b; text-align: center; }

.search-suggestions ul { list-style: none; padding: 0; margin: 0; }
.search-suggestions li a {
    display: flex;
    align-items: center;
    padding: 14px 20px;
    color: #1e293b;
    text-decoration: none;
    transition: all 0.2s;
    gap: 15px;
}

.search-suggestions li a:hover {
    background: rgba(21, 101, 192, 0.05);
    padding-left: 25px;
}

.s-icon { font-size: 18px; flex-shrink: 0; }
.s-text { flex: 1; font-weight: 700; font-size: 14px; color: #334155; }
.s-arrow { font-size: 11px; color: #cbd5e1; opacity: 0; transition: opacity 0.2s; }
.search-suggestions li a:hover .s-arrow { opacity: 1; color: #1565C0; }

.no-results-suggestion { padding: 30px 20px; text-align: center; color: #64748b; font-family: 'Inter', sans-serif;}

/* DARK MODE OVERRIDES */
body[data-theme="dark"] .search-suggestions {
    background: rgba(15, 23, 42, 0.98);
    border-color: rgba(255, 255, 255, 0.05);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.6);
}
body[data-theme="dark"] .s-text { color: #e2e8f0; }
body[data-theme="dark"] .suggestions-header { color: #475569; }
body[data-theme="dark"] .suggestions-footer { background: rgba(0,0,0,0.2); }
body[data-theme="dark"] .search-suggestions li a:hover { background: rgba(0, 210, 255, 0.1); }


/* HERO SEARCH */
.hero-search-wrap {
    max-width: 650px;
    margin: 30px auto 0;
    position: relative;
}

.hero-search-form {
    display: flex;
    background: #fff;
    padding: 6px;
    border-radius: 50px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    border: 3px solid rgba(255,255,255,0.1);
    position: relative;
}

.hero-search-input {
    flex: 1;
    border: none;
    padding: 15px 25px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 50px;
    outline: none;
}

.hero-search-btn {
    background: #E53935;
    color: #fff;
    border: none;
    padding: 0 35px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 900;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

.hero-search-btn:hover { background: #D32F2F; transform: scale(1.02); }

@media(max-width: 768px) {
    .topbar-search-container { display: none; }
    .hero-search-btn { padding: 0 20px; font-size: 14px; }
    .hero-search-input { padding: 12px 18px; font-size: 14px; }
}


/* --- ARCHIVE & CATEGORY STYLES --- */
.sv-archive-header { background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%); padding: 50px 20px; text-align: center; color: #fff; }
.sv-archive-title { font-size: 32px; font-weight: 900; text-transform: uppercase; margin-bottom: 12px; letter-spacing: 1px; }
.sv-archive-desc { color: rgba(255,255,255,0.9); font-size: 16px; max-width: 800px; margin: 0 auto; line-height: 1.6; }
.sv-archive-main { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.sv-archive-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; margin: 30px 0; }
.sv-tool-card { background: #fff; border-radius: 12px; border: 1px solid #e2e8f0; overflow: hidden; transition: all 0.3s; box-shadow: var(--shadow-sm); text-decoration: none; display: block; }
.sv-tool-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: var(--primary-light); }
.sv-tool-body { padding: 20px; display: flex; align-items: center; gap: 15px; }
.sv-tool-icon { width: 56px; height: 56px; border-radius: 12px; background: #f8fafc; display: flex; align-items: center; justify-content: center; font-size: 28px; border: 1px solid #f1f5f9; }
.sv-tool-info h3 { font-size: 16px; font-weight: 800; color: #0f172a; margin-bottom: 4px; }
.sv-tool-info p { font-size: 12px; color: #64748b; font-weight: 600; margin:0; }
.sv-archive-section { margin-bottom: 50px; }
.sv-archive-section-title { font-size: 22px; font-weight: 900; border-bottom: 4px solid var(--primary); padding-bottom: 10px; margin-bottom: 25px; text-transform: uppercase; color: #0f172a; }
.sv-archive-empty { text-align: center; padding: 80px 20px; color: #94a3b8; font-size: 18px; font-weight: 700; grid-column: 1 / -1; }

@media(max-width: 600px) {
    .sv-archive-header { padding: 35px 15px; }
    .sv-archive-title { font-size: 18px; }
    .sv-archive-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .sv-tool-body { padding: 15px; flex-direction: column; text-align: center; }
    .sv-tool-info p { display: none; }
}

/* RESPONSIVE TABLE FOR MOBILE */
@media (max-width: 768px) {
    .comparison-table thead { display: none !important; }
    .comparison-table tr { display: block !important; margin-bottom: 20px !important; border: 1px solid #e2e8f0 !important; border-radius: 12px !important; background: #fff !important; overflow: hidden !important; box-shadow: 0 4px 12px rgba(0,0,0,0.06) !important; }
    .comparison-table td { display: block !important; text-align: left !important; padding: 12px 15px !important; border-bottom: 1px solid #f1f5f9 !important; position: relative !important; }
    .comparison-table td:last-child { border-bottom: none !important; }
    .comparison-table td::before { content: attr(data-label); display: block !important; font-size: 11px !important; font-weight: 800 !important; text-transform: uppercase !important; color: #64748b !important; margin-bottom: 4px !important; letter-spacing: 0.5px !important; }
    .comparison-table td[data-label='Category'] { background: #f8fafc !important; font-weight: 700 !important; color: #1565C0 !important; font-size: 18px !important; border-bottom: 1px solid #cbd5e1 !important; }
    .tool-tags { display: flex !important; flex-wrap: wrap !important; gap: 8px !important; margin-top: 5px !important; justify-content: flex-start !important; }
}

/* GLOBAL DARK MODE OVERRIDES */
body[data-theme='dark'] { --border-main: #334155 !important; color: #f1f5f9 !important; }
body[data-theme='dark'] th, body[data-theme='dark'] td { border-color: #334155 !important; color: #f1f5f9 !important; }
body[data-theme='dark'] input[type='number'], body[data-theme='dark'] input[type='text'], body[data-theme='dark'] select { background: #334155 !important; color: #fff !important; border-color: #475569 !important; }
body[data-theme='dark'] .result-card { background: #1e293b !important; border-color: #334155 !important; box-shadow: 0 4px 20px rgba(0,0,0,0.5) !important; }
body[data-theme='dark'] .result-item { background: rgba(15, 23, 42, 0.4) !important; border-color: #334155 !important; }
body[data-theme='dark'] .result-title, body[data-theme='dark'] .result-item-label { color: #cbd5e1 !important; }
body[data-theme='dark'] .breadcrumb-nav { opacity: 0.8; }
body[data-theme='dark'] .breadcrumb-nav a { color: #38bdf8 !important; }
body[data-theme='dark'] .sv-sidebar-box { background: #1e293b !important; border-color: #334155 !important; }
body[data-theme='dark'] .comparison-table-wrap { border-color: #475569 !important; }
body[data-theme='dark'] .t-tag { background: #334155 !important; border-color: #475569 !important; color: #38bdf8 !important; }
body[data-theme='dark'] .quick-access-middle { background: #0f172a !important; border-top: 1px solid #334155 !important; border-bottom: 1px solid #334155 !important; }
body[data-theme='dark'] .pro-tip-banner { background: linear-gradient(135deg, #020617 0%, #0f172a 100%) !important; border: 1px solid #1e293b !important; }
body[data-theme='dark'] .tip-content { color: #94a3b8 !important; }
body[data-theme='dark'] label { color: #94a3b8 !important; }
body[data-theme='dark'] .sidebar-search-container { background: #0f172a !important; }


/* PREMIUM RESULT ANIMATIONS */
.summary-item { opacity: 0; transform: scale(0.9); transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
#result-card[style*='display: block'] .summary-item { opacity: 1; transform: scale(1); }
.summary-item:nth-child(1) { transition-delay: 0.1s; }
.summary-item:nth-child(2) { transition-delay: 0.2s; }
.summary-item:nth-child(3) { transition-delay: 0.3s; }
.summary-item:nth-child(4) { transition-delay: 0.4s; }
.summary-item:nth-child(5) { transition-delay: 0.5s; }
.summary-item:nth-child(6) { transition-delay: 0.6s; }

.result-card { border: 1px solid #e2e8f0; box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1); }
body[data-theme='dark'] .result-card { box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5); }


/* RESULT ACTION BUTTONS */
.result-actions { display: flex; gap: 10px; margin-bottom: 20px; flex-wrap: wrap; }
.action-btn { border: none; padding: 10px 18px; border-radius: 8px; color: #fff; font-weight: 700; font-size: 13px; cursor: pointer; transition: all 0.3s ease; display: flex; align-items: center; gap: 6px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); }
.action-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 15px rgba(0,0,0,0.15); opacity: 0.9; }

/* GLASS LOOK FOR RESULT CARD */
.result-card { background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(5px); border: 1px solid rgba(255, 255, 255, 0.3); }
body[data-theme='dark'] .result-card { background: rgba(30, 41, 59, 0.9); }


/* GPAS ANIMATIONS */
@keyframes gpasFadeIn {
    0% { opacity: 0; transform: translateY(12px); filter: blur(4px); }
    100% { opacity: 1; transform: translateY(0); filter: blur(0); }
}
.nav-btn, .tool-card { animation: gpasFadeIn 0.6s backwards; }
.nav-btn:nth-child(2) { animation-delay: 0.1s; }
.nav-btn:nth-child(3) { animation-delay: 0.2s; }
.nav-btn:nth-child(4) { animation-delay: 0.3s; }

/* MOBILE SPEED OPTIMIZATION (GREEN SCORE 90+) */
@media(max-width: 600px) {
    .hero h1 { font-size: 18px !important; }
    .hero p { display: none; }
    .nav-btn { padding: 4px 10px !important; font-size: 11px !important; }
    .nav-section { padding: 5px !important; }
    .nav-row { gap: 8px !important; flex-wrap: nowrap !important; overflow-x: auto !important; justify-content: flex-start !important; padding: 5px 0 !important; -webkit-overflow-scrolling: touch; } .nav-row::-webkit-scrollbar { display: none; } .nav-row .nav-btn { flex-shrink: 0; }
    .calc-side-ad { display: none !important; }
    .tools-grid { grid-template-columns: 1fr !important; gap: 15px !important; }
    .tool-body { padding: 12px !important; gap: 10px !important; }
    .tool-icon { width: 40px !important; height: 40px !important; font-size: 18px !important; }
    .tool-info h3 { font-size: 15px !important; }
    .tool-info p { font-size: 12px !important; line-height: 1.4 !important; }
    .tool-footer { padding: 10px !important; font-size: 11px !important; }
    .topbar { padding: 15px 16px !important; height: auto !important; position: relative !important; top: 0 !important; z-index: 1000 !important; background: #fff !important; box-shadow: 0 2px 10px rgba(0,0,0,0.05) !important; }
    .logo-text { display: block !important; font-size: 19px !important; }
    .logo-icon { width: 36px !important; height: 36px !important; font-size: 18px !important; }
    .logo-accent { color: #22c55e !important; }
    .header-controls { gap: 8px !important; }
    .signup-btn { padding: 6px 12px !important; font-size: 11px !important; }
    .theme-toggle { width: 34px !important; height: 34px !important; font-size: 16px !important; }
    .top-search-input { height: 36px !important; }
    .sv-preloader { display: none !important; }
}

/* ARCHIVE IMPROVEMENTS: LIVE WORDPRESS STYLE */
.sv-archive-inner { max-width: 1100px; margin: 0 auto; position: relative; z-index: 2; }
.sv-archive-header { position: relative; background: linear-gradient(135deg, #1565C0 0%, #0D47A1 100%); overflow: hidden; }
.sv-archive-header::before { content: ''; position: absolute; top: -50%; left: -20%; width: 140%; height: 200%; background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%); pointer-events: none; }

.sv-stat-badge { background: rgba(255,255,255,0.15); backdrop-filter: blur(8px); padding: 8px 20px; border-radius: 50px; display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; border: 1px solid rgba(255,255,255,0.2); margin-top: 15px; }

.sv-archive-grid .sv-tool-card { border: 1px solid #e0e0e0; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); animation: gpasFadeIn 0.5s backwards; }
.sv-archive-grid .sv-tool-card:hover { transform: translateY(-8px) scale(1.02); border-color: #1565C0; box-shadow: 0 15px 35px rgba(21, 101, 192, 0.15); }

.sv-tool-card:nth-child(1) { animation-delay: 0.1s; }
.sv-tool-card:nth-child(2) { animation-delay: 0.15s; }
.sv-tool-card:nth-child(3) { animation-delay: 0.2s; }
.sv-tool-card:nth-child(4) { animation-delay: 0.25s; }
.sv-tool-card:nth-child(5) { animation-delay: 0.3s; }

.sv-tool-icon { background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%); border: 1px solid #dee2e6; color: #1565C0; }
.sv-archive-grid .sv-tool-card:hover .sv-tool-icon { background: #1565C0; color: #fff; border-color: #1565C0; transform: rotate(10deg); }

body[data-theme='dark'] .sv-archive-header { background: #0f172a; border-bottom: 1px solid #1e293b; }
body[data-theme='dark'] .sv-tool-card { background: #1e293b; border-color: #334155; }
body[data-theme='dark'] .sv-tool-icon { background: #334155; border-color: #475569; }
body[data-theme='dark'] .sv-tool-info h3 { color: #f1f5f9; }


/* SIMPLE ARCHIVE STYLE */
.archive-header-simple { border-bottom: 2px solid #eee; padding-bottom: 20px; margin-bottom: 25px; }
.archive-title-simple { font-size: 28px; font-weight: 800; color: #1e3a8a; }
.archive-desc-simple { font-size: 15px; color: #666; margin-top: 10px; line-height: 1.5; }
.sv-tool-list-simple { display: flex; flex-direction: column; gap: 10px; }
.sv-simple-row { background: #fff; border: 1px solid #eee; border-radius: 8px; transition: all 0.2s; }
.sv-simple-row:hover { border-color: #1565C0; background: #f8faff; transform: translateX(5px); }
.sv-simple-link { display: flex; align-items: center; padding: 10px 16px; text-decoration: none; color: inherit; }
.sv-simple-icon { font-size: 18px; margin-right: 15px; }
.sv-simple-name { font-size: 17px; font-weight: 700; color: #333; flex: 1; }
.sv-simple-tag { font-size: 13px; font-weight: 700; color: #1565C0; opacity: 0.8; }
.sv-simple-archive { padding: 40px 20px; max-width: 1000px; margin: 0 auto; }


/* SCREENSHOT STYLE CATEGORY PAGE */
.archive-header-pro-modern { margin-bottom: 30px; }
.archive-title-pro-modern { font-size: 32px; font-weight: 800; color: #0f172a; margin-bottom: 5px; }
.archive-desc-pro-modern { font-size: 15px; color: #64748b; }

.sv-tool-list-modern-v2 { display: flex; flex-direction: column; gap: 8px; }
.sv-modern-v2-row { border-bottom: 1px solid transparent; }
.sv-modern-v2-link { display: flex; align-items: center; gap: 12px; text-decoration: none; color: #475569; font-size: 16px; transition: color 0.2s; padding: 5px 0; }
.sv-modern-v2-bullet { color: #cbd5e1; font-size: 18px; }
.sv-modern-v2-link:hover { color: #1565C0; }

.sidebar-box-modern { background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 25px; margin-bottom: 25px; box-shadow: var(--shadow-sm); }
.sidebar-search-modern { background: #fff; display: flex; align-items: center; border: 1px solid #e2e8f0; border-radius: 8px; overflow: hidden; }
.sidebar-search-modern input { border: none; padding: 12px 15px; outline: none; width: 100%; font-size: 14px; }
.sidebar-search-modern button { background: #1e3a8a; color: #fff; border: none; padding: 12px 20px; cursor: pointer; }

.sidebar-box-title { font-size: 18px; font-weight: 800; color: #1e293b; margin-bottom: 20px; border-bottom: 2px solid #f1f5f9; padding-bottom: 12px; }
.sidebar-tool-list { list-style: none; padding: 0; }
.sidebar-tool-list li { margin-bottom: 12px; }
.sidebar-tool-list a { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; color: #64748b; text-decoration: none; transition: color 0.1s; }
.sidebar-tool-list a::before { content: 'Ã¢â‚¬Â¢'; color: #cbd5e1; font-size: 18px; }
.sidebar-tool-list a:hover { color: #1565C0; }

body[data-theme='dark'] .sidebar-box-modern { background: #1e293b; border-color: #334155; }


/* MODERN V2 STYLISH REFINEMENTS */
.sv-modern-v2-row { margin-bottom: 5px; }
.sv-modern-v2-link { background: transparent; border-left: 3px solid transparent; border-radius: 4px; padding: 12px 20px; transition: all 0.3s; color: #334155; font-weight: 600; display: block; text-decoration: none; }
.sv-modern-v2-link:hover { background: #f1f5f9; border-left-color: #1e3a8a; padding-left: 25px; color: #1e3a8a; }

.sidebar-box-modern { border: 1px solid #f1f5f9; box-shadow: 0 4px 12px rgba(0,0,0,0.03); }
.sidebar-box-title { color: #1e3a8a; font-size: 19px; position: relative; }
.sidebar-box-title::after { content: ''; position: absolute; bottom: 0; left: 0; width: 40px; height: 3px; background: #1e3a8a; border-radius: 2px; }

.sidebar-search-modern { border-color: #e2e8f0; transition: border-color 0.3s; }
.sidebar-search-modern:focus-within { border-color: #1e3a8a; }
.sidebar-search-modern button { background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%); transition: opacity 0.3s; }
.sidebar-search-modern button:hover { opacity: 0.9; }

/* EMPTY STATE TEXT */
.sv-no-tools { background: #f8fafc; border: 1px dashed #cbd5e1; padding: 40px; text-align: center; border-radius: 12px; color: #94a3b8; font-weight: 600; }


/* COLORFUL & PREMIUM CATEGORY LIST STYLE */
.sv-modern-v2-row { border-bottom: 1px solid #f1f5f9; }
.sv-modern-v2-link { padding: 18px 25px; display: flex; align-items: center; border-left: 4px solid #1e3a8a; background: #fff; margin-bottom: 2px; }
.sv-modern-v2-link:hover { background: linear-gradient(90deg, #f8faff 0%, #ffffff 100%); border-left-color: #3b82f6; padding-left: 35px; box-shadow: 0 4px 15px rgba(0,0,0,0.03); }

.sv-modern-v2-name { color: #1e293b; font-size: 18px; font-weight: 700; }
.sv-modern-v2-link:hover .sv-modern-v2-name { color: #2563eb; }

/* SIDEBAR COLORFUL ENHANCEMENT */
.sidebar-box-title { color: #1e3a8a; border-left: 4px solid #3b82f6; padding-left: 15px; border-bottom: none; }
.sidebar-tool-list a::before { color: #3b82f6; transition: all 0.3s; }
.sidebar-tool-list a:hover::before { transform: scale(1.5) rotate(20deg); }

/* MODERN BUTTON FOR SEARCH */
.sidebar-search-modern button { background: #1e3a8a; border-radius: 0 6px 6px 0; font-size: 18px; }


/* VIVID COLORFUL CATEGORY LIST REFINEMENTS */
.sv-modern-v2-row:nth-child(4n+1) .sv-modern-v2-link { border-left-color: #f59e0b; } /* Orange */
.sv-modern-v2-row:nth-child(4n+2) .sv-modern-v2-link { border-left-color: #10b981; } /* Green */
.sv-modern-v2-row:nth-child(4n+3) .sv-modern-v2-link { border-left-color: #8b5cf6; } /* Purple */
.sv-modern-v2-row:nth-child(4n+4) .sv-modern-v2-link { border-left-color: #ec4899; } /* Pink */

.sv-modern-v2-link { background: #fff; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05); border-radius: 8px; margin-bottom: 12px; }
.sv-modern-v2-link:hover { transform: scale(1.02); filter: drop-shadow(0 0 10px rgba(0,0,0,0.05)); }

.sv-modern-v2-name { color: #1e293b; font-size: 19px; }
.sv-modern-v2-row:nth-child(4n+1) .sv-modern-v2-link:hover .sv-modern-v2-name { color: #d97706; }
.sv-modern-v2-row:nth-child(4n+2) .sv-modern-v2-link:hover .sv-modern-v2-name { color: #059669; }
.sv-modern-v2-row:nth-child(4n+3) .sv-modern-v2-link:hover .sv-modern-v2-name { color: #7c3aed; }
.sv-modern-v2-row:nth-child(4n+4) .sv-modern-v2-link:hover .sv-modern-v2-name { color: #db2777; }


/* LAPTOP 2-COLUMN GRID FOR CATEGORY LIST */
@media (min-width: 992px) {
    .sv-tool-list-modern-v2 {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 15px !important;
        align-items: flex-start !important;
    }
    .sv-modern-v2-row { border: none !important; }
    .sv-modern-v2-link { margin-bottom: 0px !important; }
}


/* FINAL CLEAN ARCHIVE REBOOT */
.sv-archive-reboot { padding: 80px 20px; background: #f8fafc; min-height: 100vh; }
.reboot-header { text-align: center; margin-bottom: 60px; }
.reboot-title { font-size: 42px; font-weight: 900; color: #0f172a; margin-bottom: 20px; }

.reboot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 30px; max-width: 1200px; margin: 0 auto; }
.reboot-card { background: #fff; padding: 35px; border-radius: 20px; border: 1px solid #e2e8f0; text-decoration: none; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); display: flex; flex-direction: column; align-items: center; text-align: center; box-shadow: 0 10px 30px -10px rgba(0,0,0,0.05); }
.reboot-card:hover { transform: translateY(-15px); box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.15); border-color: #3b82f6; }
.reboot-icon { width: 70px; height: 70px; display: flex; align-items: center; justify-content: center; background: #eff6ff; border-radius: 50%; font-size: 32px; margin-bottom: 25px; transition: transform 0.4s; }
.reboot-card:hover .reboot-icon { transform: rotateY(180deg); background: #3b82f6; color: #fff; }
.reboot-name { font-size: 18px; font-weight: 800; color: #1e293b; margin-bottom: 12px; }
.btn-reboot { background: #3b82f6; color: #fff; padding: 10px 25px; border-radius: 50px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; transition: background 0.3s; margin-top: 15px; }
.reboot-card:hover .btn-reboot { background: #1d4ed8; }

/* =======================================================
   UNIVERSAL MOBILE & TABLET HEADER FIX (Consolidated)
   ======================================================= */
@media (max-width: 991px) {
    .topbar { 
        padding: 12px 16px !important; 
        height: auto !important; 
        min-height: 65px !important;
        position: relative !important; 
        top: 0 !important; 
        z-index: 1000 !important; 
        background: #ffffff !important; 
        box-shadow: 0 4px 15px rgba(0,0,0,0.08) !important;
        flex-wrap: nowrap !important;
        display: flex !important;
        justify-content: space-between !important;
    }
    
    .logo {
        flex: 0 0 auto !important;
        display: flex !important;
        align-items: center !important;
    }

    .logo-text { 
        display: block !important; 
        font-size: 18px !important; 
        font-weight: 800 !important;
        margin-left: 8px !important;
    }

    .logo-icon { 
        width: 42px !important; 
        height: 42px !important; 
        font-size: 22px !important;
        border-radius: 12px !important;
    }

    .header-controls { 
        display: flex !important;
        gap: 10px !important; 
        flex: 0 0 auto !important;
    }

    .signup-btn { 
        padding: 8px 15px !important; 
        font-size: 12px !important; 
        background: #22c55e !important;
        border-radius: 50px !important;
        font-weight: 800 !important;
        white-space: nowrap !important;
    }

    .theme-toggle { 
        width: 38px !important; 
        height: 38px !important; 
        font-size: 18px !important;
        border-radius: 10px !important;
    }

    .topbar-search-container { 
        display: none !important; /* Keep clean on small headers */
    }
}

@media (max-width: 480px) {
    .logo-text { font-size: 16px !important; }
    .signup-btn { padding: 6px 10px !important; font-size: 11px !important; }
    .topbar { padding: 10px 12px !important; }
}
/* REMOVED CONFLICTING MOBILE OVERRIDES TO ALLOW HEADER.PHP TO CONTROL PREMIUM LOOK */


/* LOGO CUT FIX & HEIGHT REFINEMENT */
.topbar {
    overflow: visible !important;
    min-height: 75px !important;
}

.logo {
    display: flex !important;
    align-items: center !important;
    text-decoration: none !important;
    padding: 5px 0 !important;
}

.logo-icon {
    width: 45px !important;
    height: 45px !important;
    margin: 5px 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}


/* UNIVERSAL SIDEBAR LAYOUT FIX */
.page-with-sidebar-layout {
    display: flex !important;
    max-width: 1250px !important;
    margin: 40px auto !important;
    padding: 0 20px !important;
    gap: 30px !important;
}

.page-main-content {
    flex: 1 !important;
    min-width: 0 !important;
}

.site-sidebar {
    width: 320px !important;
    flex-shrink: 0 !important;
}

@media (max-width: 991px) {
    .page-with-sidebar-layout {
        flex-direction: column !important;
    }
    .site-sidebar {
        width: 100% !important;
    }
}


/* RELATED CALCULATORS SECTION */
.related-calculators { margin-top: 40px; padding: 25px; background: rgba(255,255,255,0.05); border-radius: 12px; border: 1px solid rgba(255,255,255,0.1); }
.related-calculators h3 { margin-bottom: 20px; color: var(--primary-color, #1565C0); font-size: 1.4rem; }
.related-calculators ul { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 15px; list-style: none; padding: 0; }
.related-calculators li a { display: block; padding: 12px; background: #fff; color: #333; text-decoration: none; border-radius: 8px; text-align: center; font-weight: 500; transition: transform 0.2s, box-shadow 0.2s; border: 1px solid #ddd; }
.related-calculators li a:hover { transform: translateY(-3px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); border-color: var(--primary-color, #1565C0); color: var(--primary-color, #1565C0); }
[data-theme="dark"] .related-calculators li a { background: #222; color: #eee; border-color: #444; }

/* === PREMIUM OLED TRUE BLACK DARK MODE (GLOBAL REPAIR) === */
body[data-theme="dark"] {
    background: #000000 !important;
    color: #e2e8f0 !important;
}

/* Global Dark Wrappers */
body[data-theme="dark"] .topbar,
body[data-theme="dark"] .nav-section,
body[data-theme="dark"] .hero,
body[data-theme="dark"] .site-footer,
body[data-theme="dark"] .page-main-content,
body[data-theme="dark"] .dynamic-seo-guide,
body[data-theme="dark"] .article-content,
body[data-theme="dark"] .sidebar-section,
body[data-theme="dark"] .breadcrumb-nav {
    background: #000000 !important;
    border-color: #1a1a1a !important;
    color: #e2e8f0 !important;
}

/* Fix for the white articles blocks in screenshot */
body[data-theme="dark"] .dynamic-seo-guide, 
body[data-theme="dark"] .rank-math-toc-container,
body[data-theme="dark"] .article-card,
body[data-theme="dark"] .sidebar-box-modern {
    background: #0a0a0a !important;
    border-color: #1a1a1a !important;
}

/* Typography */
body[data-theme="dark"] h1, 
body[data-theme="dark"] h2, 
body[data-theme="dark"] h3, 
body[data-theme="dark"] h4,
body[data-theme="dark"] .main-seo-h1,
body[data-theme="dark"] .article-main-title {
    color: #ffffff !important;
}

body[data-theme="dark"] p, 
body[data-theme="dark"] li, 
body[data-theme="dark"] span {
    color: #94a3b8 !important;
}

/* Premium Calculator Card */
body[data-theme="dark"] .classic-calc-wrapper {
    background: #080808 !important;
    border-color: #1a1a1a !important;
}
body[data-theme="dark"] .classic-calc-header {
    background: #000 !important;
    border-bottom: 2px solid #1a1a1a !important;
    color: #3b82f6 !important;
}
body[data-theme="dark"] .classic-calc-body {
    background: transparent !important;
}

/* Inputs & Forms */
body[data-theme="dark"] input, 
body[data-theme="dark"] select, 
body[data-theme="dark"] textarea {
    background: #000000 !important;
    border-color: #262626 !important;
    color: #ffffff !important;
}

/* Tables & FAQ */
body[data-theme="dark"] .comparison-table,
body[data-theme="dark"] .modern-result-table,
body[data-theme="dark"] .seo-table,
body[data-theme="dark"] table {
    background: #0a0a0a !important;
    border-color: #1a1a1a !important;
}
body[data-theme="dark"] th {
    background: #111 !important;
    color: #3b82f6 !important;
}
body[data-theme="dark"] td {
    background: #000 !important;
    border-bottom-color: #111 !important;
    color: #cbd5e1 !important;
}
body[data-theme="dark"] tr:nth-child(even) td {
    background: #050505 !important;
}

/* FAQ Items */
body[data-theme="dark"] .faq-item {
    border-bottom-color: #1a1a1a !important;
}
body[data-theme="dark"] .faq-item strong,
body[data-theme="dark"] .faq-item h4 {
    color: #fff !important;
}

/* Table of Contents Look */
body[data-theme="dark"] .rank-math-toc-container {
    border-left-color: #3b82f6 !important;
}
body[data-theme="dark"] .toc-list a {
    color: #3b82f6 !important;
}

/* Breadcrumbs Links */
body[data-theme="dark"] .breadcrumb-nav a {
    color: #3b82f6 !important;
}

/* Summary Items */
body[data-theme="dark"] .summary-item:not(.highlight) {
    background: #050505 !important;
    border-color: #1a1a1a !important;
}
body[data-theme="dark"] .summary-value:not(.highlight) {
    color: #fff !important;
}

/* LOGO FIX */
body[data-theme="dark"] .logo-text { color: #fff !important; }

/* Scrollbar */
body[data-theme="dark"]::-webkit-scrollbar { width: 10px; background: #000; }
body[data-theme="dark"]::-webkit-scrollbar-thumb { background: #333; border-radius: 10px; border: 2px solid #000; }

/* === NAV BUTTON REPAIR === */
.nav-row {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 10px !important;
    padding: 10px !important;
}

.nav-btn {
    padding: 10px 20px !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #fff !important;
    cursor: pointer !important;
    transition: all 0.2s !important;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1) !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: auto !important;
    height: auto !important;
}

@media screen and (max-width: 768px) {
    .nav-row {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
    }
    .nav-btn {
        width: 100% !important;
        padding: 12px 10px !important;
        justify-content: center !important;
        font-size: 13px !important;
    }
}


/* FINAL PREMIUM HEADER REPAIR (FORCE LARGE SIZE) */
@media screen and (max-width: 991px) {
    .topbar {
        min-height: 65px !important;
        height: auto !important;
        padding: 10px 16px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        background: #fff !important;
        box-shadow: 0 4px 20px rgba(0,0,0,0.1) !important;
    }
    .logo-text {
        display: block !important;
        font-size: 18px !important;
        font-weight: 800 !important;
        color: #0f172a !important;
        margin-left: 10px !important;
    }
    .logo-icon {
        width: 36px !important;
        height: 36px !important;
        font-size: 18px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: linear-gradient(135deg, #22c55e, #16a34a) !important;
        color: #fff !important;
        border-radius: 12px !important;
    }
    .header-controls {
        gap: 12px !important;
    }
    .signup-btn {
        padding: 10px 18px !important;
        font-size: 13px !important;
        border-radius: 50px !important;
    }
}

/* --- GLOBAL CALCULATOR PREMIUM REBRAND (GREEN THEME) --- */
.calculator-container, .calculator-card, .calc-wrapper, .tool-container { background: #fff; padding: 30px; border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,0.05); margin: 20px 0; border: 1px solid #f0f0f0; }
.calculator-container input[type='number'], .calculator-container input[type='text'], .calculator-container select { padding: 12px 15px !important; border: 2px solid #e2e8f0 !important; border-radius: 10px !important; font-size: 16px !important; width: 100%; margin-bottom: 15px; outline: none !important; }
.calculator-container button, .calculator-container input[type='button'], .calc-wrapper button, .tool-container button { background: linear-gradient(135deg, #22c55e, #16a34a) !important; color: #fff !important; padding: 14px 30px !important; border: none !important; border-radius: 12px !important; font-weight: 800 !important; font-size: 16px !important; cursor: pointer !important; box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3) !important; text-transform: uppercase; }

/* SITEMAP / DIRECTORY STYLES */
.sitemap-hero {
    background: var(--premium-gradient);
    color: #fff;
    padding: 60px 20px;
    text-align: center;
    border-radius: 0 0 40px 40px;
    margin-bottom: 50px;
    box-shadow: var(--shadow-lg);
}
.sitemap-hero h1 { font-size: 42px; font-weight: 900; margin-bottom: 15px; }
.sitemap-hero p { font-size: 18px; opacity: 0.9; max-width: 700px; margin: 0 auto; }

.sitemap-container { max-width: 1200px; margin: 0 auto; padding: 0 20px 80px; }

.sitemap-section { margin-bottom: 60px; }
.sitemap-cat-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}
.sitemap-cat-header h2 { font-size: 28px; font-weight: 800; color: #0f172a; }
.sitemap-cat-icon {
    width: 45px;
    height: 45px;
    background: var(--glass-green);
    border: 1px solid var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 22px;
}

.sitemap-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.sitemap-item {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-md);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
}
.sitemap-item:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
    background: var(--glass-green);
}
.sitemap-item-icon {
    font-size: 24px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    border-radius: 8px;
    transition: transform 0.3s;
}
.sitemap-item:hover .sitemap-item-icon { transform: scale(1.1) rotate(5deg); background: #fff; }
.sitemap-item-name {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    transition: color 0.2s;
}
.sitemap-item:hover .sitemap-item-name { color: var(--primary-dark); }

@media (max-width: 768px) {
    .sitemap-hero h1 { font-size: 32px; }
    .sitemap-grid { grid-template-columns: 1fr; }
}
