/* ============================================================
   TechFix Pro — Public theme
   Modern, responsive, dark-mode aware. No external dependencies.
   ============================================================ */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-soft: #dbeafe;
    --accent: #0ea5e9;
    --success: #16a34a;
    --success-soft: #dcfce7;
    --danger: #dc2626;
    --danger-soft: #fee2e2;
    --warning: #d97706;
    --warning-soft: #fef3c7;

    --bg: #f8fafc;
    --surface: #ffffff;
    --surface-2: #f1f5f9;
    --text: #0f172a;
    --muted: #64748b;
    --border: #e2e8f0;
    --shadow: 0 1px 3px rgba(15, 23, 42, .08), 0 8px 24px -12px rgba(15, 23, 42, .12);
    --shadow-lg: 0 12px 40px -12px rgba(15, 23, 42, .25);
    --radius: 14px;
    --radius-sm: 9px;
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --mono: ui-monospace, SFMono-Regular, "Cascadia Code", Consolas, monospace;
    --header-bg: rgba(255, 255, 255, .92);
    --nav-h: 68px;
}

[data-theme="dark"] {
    --bg: #0b1220;
    --surface: #111a2c;
    --surface-2: #182338;
    --text: #e2e8f0;
    --muted: #94a3b8;
    --border: #24314d;
    --shadow: 0 1px 3px rgba(0, 0, 0, .4), 0 8px 24px -12px rgba(0, 0, 0, .5);
    --shadow-lg: 0 12px 40px -12px rgba(0, 0, 0, .6);
    --primary-soft: #1e3a8a;
    --success-soft: #14532d;
    --danger-soft: #7f1d1d;
    --warning-soft: #78350f;
    --header-bg: rgba(11, 18, 32, .92);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
ul, ol { list-style-position: inside; }
h1, h2, h3, h4 { line-height: 1.25; color: var(--text); }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; }
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--primary); color: #fff; padding: 8px 16px; z-index: 999; border-radius: 0 0 8px 0; }
.skip-link:focus { left: 0; color: #fff; text-decoration: none; }

/* ------------------------------ Buttons ------------------------------ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 22px; border-radius: var(--radius-sm); border: 2px solid transparent;
    font: inherit; font-weight: 600; cursor: pointer; transition: all .18s ease;
    text-decoration: none !important; white-space: nowrap; background: none; color: inherit;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { border-color: var(--border); color: var(--text); background: var(--surface); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-light { background: #fff; color: #0f172a; }
.btn-light:hover { background: #e2e8f0; }
.btn-outline-light { border-color: rgba(255,255,255,.5); color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,.12); }
.btn-success { background: var(--success); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-ghost { color: var(--muted); }
.btn-ghost:hover { color: var(--text); background: var(--surface-2); }
.btn-whatsapp { background: #25d366; color: #fff; }
.btn-whatsapp:hover { background: #1eb958; }
.btn-telegram { background: #229ed9; color: #fff; }
.btn-telegram:hover { background: #1c8abd; }
.btn-lg { padding: 14px 28px; font-size: 1.05rem; border-radius: 11px; }
.btn-sm { padding: 7px 14px; font-size: .875rem; }
.btn-block { width: 100%; }

.icon-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: 10px; border: none; cursor: pointer;
    background: none; color: var(--text); transition: background .15s;
}
.icon-btn:hover { background: var(--surface-2); color: var(--primary); }
.icon-btn.danger:hover { background: var(--danger-soft); color: var(--danger); }

/* ------------------------------ Badges ------------------------------ */
.badge {
    display: inline-block; padding: 3px 10px; border-radius: 999px;
    font-size: .75rem; font-weight: 600; letter-spacing: .02em;
    background: var(--surface-2); color: var(--muted); text-decoration: none !important;
}
.badge-blue { background: var(--primary-soft); color: var(--primary); }
.badge-green { background: var(--success-soft); color: var(--success); }
.badge-yellow { background: var(--warning-soft); color: var(--warning); }
.badge-red { background: var(--danger-soft); color: var(--danger); }
.badge-gray { background: var(--surface-2); color: var(--muted); }

/* ------------------------------ Alerts ------------------------------ */
.alert {
    display: flex; align-items: flex-start; gap: 10px;
    padding: 13px 16px; border-radius: var(--radius-sm); margin-bottom: 18px;
    border: 1px solid var(--border); background: var(--surface); font-size: .95rem;
}
.alert-success { border-color: #86efac; background: var(--success-soft); color: var(--success); }
.alert-error { border-color: #fca5a5; background: var(--danger-soft); color: var(--danger); }
.alert-info { border-color: #93c5fd; background: var(--primary-soft); color: var(--primary-dark); }
[data-theme="dark"] .alert-info { color: #bfdbfe; }
[data-theme="dark"] .alert-success { color: #86efac; }
[data-theme="dark"] .alert-error { color: #fca5a5; }
.alert svg { flex-shrink: 0; margin-top: 2px; }

/* ------------------------------ Header ------------------------------ */
.announcement-bar { background: linear-gradient(90deg, var(--primary), var(--accent)); color: #fff; font-size: .9rem; }
.announcement-inner { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px 20px; position: relative; }
.announcement-text { text-align: center; }
.announcement-close { background: none; border: none; color: #fff; cursor: pointer; opacity: .8; display: flex; position: absolute; right: 16px; }
.announcement-close:hover { opacity: 1; }

.topbar { background: #0f172a; color: #cbd5e1; font-size: .82rem; }
[data-theme="dark"] .topbar { background: #060b16; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; min-height: 36px; gap: 12px; flex-wrap: wrap; }
.topbar a { color: #cbd5e1; display: inline-flex; align-items: center; gap: 5px; margin-right: 16px; }
.topbar a:hover { color: #fff; }
.topbar-left, .topbar-right { display: flex; align-items: center; gap: 12px; }
.topbar-status { display: inline-flex; align-items: center; gap: 6px; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-green { background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .25); }
.topbar-social a { margin-right: 8px; }

.site-header { background: var(--header-bg); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 100; border-bottom: 1px solid var(--border); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: var(--nav-h); gap: 16px; }

.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none !important; font-weight: 800; font-size: 1.15rem; }
.brand-mark { display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 10px; background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff; flex-shrink: 0; }
.brand-logo { height: 40px; width: auto; }

.main-nav { margin: 0 auto; }
.nav-list { display: flex; list-style: none; gap: 4px; }
.nav-item { position: relative; }
.nav-link {
    display: inline-flex; align-items: center; gap: 5px; padding: 10px 14px;
    color: var(--text); font-weight: 600; font-size: .95rem; border-radius: 9px;
    text-decoration: none !important; transition: background .15s, color .15s;
}
.nav-link:hover { background: var(--surface-2); color: var(--primary); }
.dropdown-menu {
    position: absolute; top: 100%; left: 0; min-width: 220px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
    box-shadow: var(--shadow-lg); padding: 8px; list-style: none;
    opacity: 0; visibility: hidden; transform: translateY(8px);
    transition: all .18s ease; z-index: 200;
}
.nav-item.has-dropdown:hover .dropdown-menu, .nav-item.has-dropdown:focus-within .dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-link { display: block; padding: 9px 12px; border-radius: 8px; color: var(--text); font-weight: 500; text-decoration: none !important; }
.dropdown-link:hover { background: var(--primary-soft); color: var(--primary); }

.nav-actions { display: flex; align-items: center; gap: 6px; }
.nav-cta { margin-left: 4px; }
.nav-burger { display: none; }

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

/* Search panel */
.search-panel { border-top: 1px solid var(--border); background: var(--surface); padding: 18px 0; position: relative; }
.search-form { display: flex; gap: 10px; align-items: center; position: relative; }
.search-form-icon { position: absolute; left: 14px; color: var(--muted); display: flex; }
.search-form input[type="search"] {
    flex: 1; padding: 13px 14px 13px 44px; border-radius: 11px;
    border: 2px solid var(--border); font: inherit; background: var(--bg); color: var(--text);
}
.search-form input:focus { outline: none; border-color: var(--primary); }
.search-suggest { margin-top: 8px; }
.search-suggest a { display: flex; gap: 8px; align-items: center; padding: 9px 12px; border-radius: 8px; color: var(--text); text-decoration: none !important; }
.search-suggest a:hover, .search-suggest a.hover { background: var(--surface-2); }
.search-suggest .ss-cat { margin-left: auto; font-size: .78rem; color: var(--muted); }

/* ------------------------------ Hero ------------------------------ */
.hero { position: relative; overflow: hidden; background: var(--surface); border-bottom: 1px solid var(--border); }
.hero-bg {
    position: absolute; inset: 0;
    background:
        radial-gradient(900px 400px at 85% -10%, rgba(37, 99, 235, .14), transparent 60%),
        radial-gradient(700px 380px at 10% 110%, rgba(14, 165, 233, .12), transparent 60%);
    pointer-events: none;
}
.hero-inner { display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center; padding: 70px 20px; position: relative; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--primary-soft); color: var(--primary);
    padding: 6px 14px; border-radius: 999px; font-size: .85rem; font-weight: 600; margin-bottom: 18px;
}
.hero h1 { font-size: clamp(1.9rem, 4vw, 3rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: 14px; }
.hero-sub { font-size: 1.12rem; color: var(--muted); max-width: 560px; margin-bottom: 26px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 30px; }
.hero-search form {
    display: flex; align-items: center; gap: 4px; background: var(--bg);
    border: 2px solid var(--border); border-radius: 14px; padding: 6px 6px 6px 16px;
    max-width: 560px; color: var(--muted); transition: border-color .15s;
}
.hero-search form:focus-within { border-color: var(--primary); }
.hero-search input { flex: 1; border: none; background: none; font: inherit; padding: 10px 8px; color: var(--text); min-width: 0; }
.hero-search input:focus { outline: none; }
.hero-stats { display: flex; gap: 34px; margin-top: 34px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; }
.stat strong { font-size: 1.35rem; color: var(--primary); }
.stat span { font-size: .82rem; color: var(--muted); }

.hero-visual { position: relative; min-height: 320px; }
.hero-card {
    background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
    box-shadow: var(--shadow-lg); padding: 22px; position: absolute;
}
.hero-card-main { width: 78%; left: 0; top: 30px; }
.hero-card-icon { color: var(--primary); margin-bottom: 14px; }
.hero-card-icon.green { color: var(--success); }
.hero-card-line { height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--primary-soft), var(--primary)); margin-bottom: 16px; }
.hero-card-row { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.hero-card-row span { height: 8px; border-radius: 4px; background: var(--surface-2); }
.hero-card-row span:nth-child(2) { width: 70%; }
.hero-card-row span:nth-child(3) { width: 40%; }
.hero-card-ok { display: inline-flex; align-items: center; gap: 8px; background: var(--success-soft); color: var(--success); padding: 7px 12px; border-radius: 8px; font-weight: 600; font-size: .85rem; }
.hero-card-float { display: flex; align-items: center; gap: 12px; right: 0; bottom: 30px; width: 60%; }
.hero-card-float small { display: block; color: var(--muted); }

/* ------------------------------ Sections ------------------------------ */
.section { padding: 64px 0; }
.section-alt { background: var(--surface); border-block: 1px solid var(--border); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 30px; flex-wrap: wrap; }
.section-title { font-size: 1.65rem; font-weight: 800; letter-spacing: -.01em; }
.section-sub { color: var(--muted); margin-top: 4px; }
.section-subtitle { display: flex; align-items: center; gap: 8px; font-size: 1.2rem; font-weight: 700; margin: 36px 0 18px; }
.link-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: .92rem; text-decoration: none !important; }
.link-more:hover { text-decoration: underline !important; }

.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-3-tight { gap: 16px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Cards */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; transition: transform .18s ease, box-shadow .18s ease; }
.article-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.article-thumb { position: relative; display: block; aspect-ratio: 16/9; background: var(--surface-2); overflow: hidden; }
.article-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.article-card:hover .article-thumb img { transform: scale(1.05); }
.article-thumb-placeholder { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--muted); }
.thumb-badge { position: absolute; top: 12px; left: 12px; background: rgba(15, 23, 42, .78); color: #fff; font-size: .75rem; font-weight: 600; padding: 4px 11px; border-radius: 999px; }
.card-body { padding: 18px; }
.card-title { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.card-title a { color: var(--text); text-decoration: none !important; }
.card-title a:hover { color: var(--primary); }
.card-desc { color: var(--muted); font-size: .9rem; margin-bottom: 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { display: flex; gap: 14px; color: var(--muted); font-size: .78rem; flex-wrap: wrap; }
.card-meta span { display: inline-flex; align-items: center; gap: 5px; }

/* Service cards */
.service-card {
    display: flex; flex-direction: column; gap: 10px;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 24px; box-shadow: var(--shadow); color: var(--text); text-decoration: none !important;
    transition: transform .18s, box-shadow .18s, border-color .18s;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary); }
.service-card-static:hover { transform: none; box-shadow: var(--shadow); border-color: var(--border); }
.service-icon { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 13px; background: var(--primary-soft); color: var(--primary); margin-bottom: 4px; }
.service-icon-lg { width: 64px; height: 64px; }
.service-card h3 { font-size: 1.08rem; }
.service-card p { color: var(--muted); font-size: .9rem; }
.service-price { font-weight: 700; color: var(--primary); }
.service-price small { color: var(--muted); font-weight: 500; }
.service-meta-row { display: flex; justify-content: space-between; align-items: center; }
.service-card-actions { display: flex; gap: 10px; margin-top: auto; padding-top: 6px; }

/* Category cards */
.category-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; color: var(--text); text-decoration: none !important; box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s; display: flex; flex-direction: column; }
.category-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.category-card-img { position: relative; aspect-ratio: 16/8; background: var(--surface-2); }
.category-card-img img { width: 100%; height: 100%; object-fit: cover; }
.count-badge { background: rgba(15, 23, 42, .8); color: #fff; font-size: .72rem; padding: 2px 9px; border-radius: 999px; }
.count-badge-lg { position: absolute; bottom: 10px; left: 10px; padding: 5px 12px; font-size: .78rem; font-weight: 600; }
.category-card-body { padding: 16px; }
.category-card-body h3 { font-size: 1.02rem; margin-bottom: 4px; }
.category-card-body p { color: var(--muted); font-size: .85rem; }

/* Steps */
.steps { counter-reset: step; }
.step { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; position: relative; box-shadow: var(--shadow); }
.step-num { position: absolute; top: -14px; left: 22px; width: 30px; height: 30px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .9rem; }
.step h3 { display: flex; align-items: center; gap: 8px; font-size: 1rem; margin-bottom: 8px; color: var(--primary); }
.step p { color: var(--muted); font-size: .88rem; }

/* CTA */
.cta-section { background: linear-gradient(120deg, var(--primary), var(--accent)); }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.cta-inner h2 { color: #fff; font-size: 1.6rem; margin-bottom: 6px; }
.cta-inner p { color: rgba(255, 255, 255, .85); }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ------------------------------ Layout pages ------------------------------ */
.breadcrumbs { background: var(--surface); border-bottom: 1px solid var(--border); padding: 12px 0; font-size: .85rem; }
.breadcrumbs ol { display: flex; list-style: none; gap: 8px; flex-wrap: wrap; align-items: center; }
.breadcrumbs a { color: var(--muted); display: inline-flex; align-items: center; gap: 5px; text-decoration: none; }
.breadcrumbs a:hover { color: var(--primary); }
.breadcrumbs .sep { color: var(--border); }
.breadcrumbs [aria-current] { color: var(--text); font-weight: 600; }

.page-layout { display: grid; grid-template-columns: 1fr 320px; gap: 40px; padding-top: 34px; padding-bottom: 60px; }
.page-main { min-width: 0; }
.page-head { margin-bottom: 26px; }
.page-title { font-size: 1.9rem; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.page-desc { color: var(--muted); font-size: 1.02rem; }
.page-hero-sm { background: var(--surface); border-bottom: 1px solid var(--border); padding: 46px 0; margin-bottom: 20px; }
.page-hero-sm .page-title { margin-bottom: 8px; }
.page-hero-sm .page-desc { margin: 0; }

.filter-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px 16px; margin-bottom: 24px; }
.filter-label { font-size: .85rem; font-weight: 600; color: var(--muted); }
.filter-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { display: inline-block; padding: 6px 14px; border-radius: 999px; background: var(--surface-2); color: var(--text); font-size: .85rem; font-weight: 500; text-decoration: none !important; border: 1px solid transparent; }
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip.active { background: var(--primary); color: #fff; }
.chip small { opacity: .7; }

.empty-state { text-align: center; padding: 60px 20px; color: var(--muted); }
.empty-state svg { color: var(--border); margin-bottom: 14px; }
.empty-state h1, .empty-state h3 { margin-bottom: 8px; }
.empty-state p { margin-bottom: 20px; }
.error-code { font-size: 5rem; font-weight: 800; color: var(--primary); opacity: .25; line-height: 1; }
.error-page { padding: 40px 0 70px; }
.status-page { padding: 70px 0; }

/* ------------------------------ Pagination ------------------------------ */
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 36px; flex-wrap: wrap; }
.page-link { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); color: var(--text); font-weight: 600; font-size: .9rem; text-decoration: none !important; }
.page-link:hover { border-color: var(--primary); color: var(--primary); }
.page-link.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.page-link.disabled { opacity: .45; pointer-events: none; }
.page-ellipsis { display: inline-flex; align-items: center; color: var(--muted); }

/* ------------------------------ Sidebar ------------------------------ */
.sidebar { display: flex; flex-direction: column; gap: 20px; }
.widget { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.widget-title { display: flex; align-items: center; gap: 8px; font-size: .95rem; font-weight: 700; margin-bottom: 14px; }
.widget-list { list-style: none; }
.widget-list li { padding: 9px 0; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.widget-list li:last-child { border-bottom: none; padding-bottom: 0; }
.widget-list a { color: var(--text); text-decoration: none; font-size: .9rem; font-weight: 500; }
.widget-list a:hover, .widget-list a.active { color: var(--primary); }
.widget-meta { color: var(--muted); font-size: .75rem; white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; }
.widget-cats a { flex: 1; }
.check-list li { border: none; padding: 6px 0; color: var(--muted); font-size: .9rem; display: flex; gap: 8px; align-items: center; }
.check-list svg { color: var(--success); flex-shrink: 0; }
.widget-help { background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff; border: none; }
.widget-help .widget-title, .widget-help p { color: #fff; }
.widget-help p { font-size: .9rem; margin-bottom: 14px; }
.widget-help .btn { margin-bottom: 10px; }
.widget-help .btn-whatsapp { margin-bottom: 0; }

/* ------------------------------ Forms ------------------------------ */
.form-group { margin-bottom: 18px; }
.form-label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.form-control {
    width: 100%; padding: 11px 14px; border-radius: var(--radius-sm);
    border: 2px solid var(--border); background: var(--surface); color: var(--text);
    font: inherit; transition: border-color .15s;
}
.form-control:focus { outline: none; border-color: var(--primary); }
.form-control-sm { padding: 7px 10px; font-size: .88rem; }
.form-control-lg { font-size: 1.05rem; padding: 13px 16px; }
textarea.form-control { resize: vertical; min-height: 90px; }
select.form-control { appearance: auto; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.form-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.form-inline-card { display: flex; gap: 12px; max-width: 560px; margin-bottom: 28px; }
.form-inline-card .form-control { flex: 1; }
.form-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.form-status { font-size: .88rem; margin-top: 8px; }
.form-status.ok { color: var(--success); }
.form-status.err { color: var(--danger); }
.captcha-row { background: var(--surface-2); padding: 14px; border-radius: var(--radius-sm); }
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

/* Newsletter box */
.newsletter-box { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 18px; }
.newsletter-box h4 { display: flex; align-items: center; gap: 8px; font-size: .95rem; margin-bottom: 4px; }
.newsletter-box p { color: var(--muted); font-size: .85rem; margin-bottom: 12px; }
.newsletter-row { display: flex; gap: 8px; }
.newsletter-row .form-control { flex: 1; min-width: 0; }
.newsletter-captcha { margin-top: 10px; font-size: .85rem; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.newsletter-captcha .form-control { max-width: 90px; }

/* ------------------------------ Article page ------------------------------ */
.article-hero-img { border-radius: var(--radius); overflow: hidden; margin-bottom: 22px; border: 1px solid var(--border); }
.article-hero-img img { width: 100%; aspect-ratio: 21/9; object-fit: cover; }
.article-badges { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.article-title { font-size: clamp(1.6rem, 3.4vw, 2.3rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: 16px; }
.article-meta { display: flex; align-items: center; gap: 18px; color: var(--muted); font-size: .87rem; flex-wrap: wrap; margin-bottom: 22px; }
.article-meta span { display: inline-flex; align-items: center; gap: 6px; }
.meta-author { font-weight: 600; color: var(--text); }
.avatar { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-weight: 700; font-size: .85rem; }

.article-actions { display: flex; align-items: center; gap: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px 18px; margin-bottom: 26px; flex-wrap: wrap; }
.vote-widget { display: flex; align-items: center; gap: 8px; }
.vote-btn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 16px; border-radius: 10px; border: 2px solid var(--border); background: var(--surface); color: var(--muted); cursor: pointer; font: inherit; font-weight: 600; transition: all .15s; }
.vote-btn:hover { border-color: var(--success); color: var(--success); }
.vote-btn[data-direction="down"]:hover { border-color: var(--danger); color: var(--danger); }
.vote-btn.voted[data-direction="up"] { background: var(--success-soft); border-color: var(--success); color: var(--success); }
.vote-btn.voted[data-direction="down"] { background: var(--danger-soft); border-color: var(--danger); color: var(--danger); }
.vote-status { font-size: .85rem; color: var(--muted); }
.vote-ratio { display: inline-flex; align-items: center; gap: 8px; font-size: .87rem; color: var(--muted); }
.vote-ratio-bar { width: 110px; height: 7px; border-radius: 99px; background: var(--danger-soft); overflow: hidden; display: inline-block; }
.vote-ratio-bar span { display: block; height: 100%; background: var(--success); border-radius: 99px; }

/* Prose (article content) */
.prose { font-size: 1.02rem; line-height: 1.75; }
.prose h2 { font-size: 1.45rem; margin: 34px 0 14px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.prose h3 { font-size: 1.18rem; margin: 26px 0 10px; }
.prose p { margin-bottom: 16px; }
.prose ul, .prose ol { margin: 0 0 16px 22px; }
.prose li { margin-bottom: 7px; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose code { font-family: var(--mono); font-size: .88em; background: var(--surface-2); border: 1px solid var(--border); border-radius: 5px; padding: 2px 6px; }
.prose pre { background: #0f172a; color: #e2e8f0; padding: 16px 18px; border-radius: 10px; overflow-x: auto; margin-bottom: 18px; }
.prose pre code { background: none; border: none; padding: 0; color: inherit; }
.prose kbd { font-family: var(--mono); font-size: .82em; background: var(--surface); border: 1px solid var(--border); border-bottom-width: 3px; border-radius: 6px; padding: 2px 7px; }
.prose img { border-radius: 10px; margin: 10px 0; }
.prose blockquote { border-left: 4px solid var(--primary); padding: 8px 18px; margin-bottom: 16px; background: var(--surface-2); border-radius: 0 8px 8px 0; color: var(--muted); }
.tip, .warn, .note { padding: 14px 18px; border-radius: 10px; margin-bottom: 18px; font-size: .95rem; border: 1px solid; }
.tip { background: var(--success-soft); border-color: #86efac; }
[data-theme="dark"] .tip { border-color: #166534; }
.warn { background: var(--danger-soft); border-color: #fca5a5; }
[data-theme="dark"] .warn { border-color: #991b1b; }
.note { background: var(--primary-soft); border-color: #93c5fd; }
[data-theme="dark"] .note { border-color: #1e40af; }

.styled-table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); margin: 20px 0; }
.styled-table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.styled-table th { text-align: left; padding: 13px 16px; background: var(--surface-2); font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); white-space: nowrap; }
.styled-table td { padding: 13px 16px; border-top: 1px solid var(--border); vertical-align: top; }
.styled-table tbody tr:hover { background: var(--surface-2); }

.article-footer-actions { text-align: center; background: var(--surface); border: 1px dashed var(--border); border-radius: var(--radius); padding: 22px; margin: 36px 0; }
.article-footer-actions .vote-widget { justify-content: center; }
.related-section { margin-top: 40px; }

/* Comments */
.comments-section { margin-top: 44px; }
.comment { display: flex; gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--border); }
.comment-avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; }
.comment-body { flex: 1; min-width: 0; }
.comment-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.comment-date { color: var(--muted); font-size: .8rem; }
.comment-subject { margin: 4px 0; font-size: .95rem; }
.comment-text { color: var(--text); font-size: .95rem; }
.comment-form-wrap { margin-top: 26px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); }
.comment-form-wrap h4 { margin-bottom: 18px; }

/* FAQs */
.faq-search { display: flex; gap: 10px; align-items: center; background: var(--surface); border: 2px solid var(--border); border-radius: 12px; padding: 6px 6px 6px 16px; color: var(--muted); margin-bottom: 26px; }
.faq-search input { flex: 1; border: none; background: none; font: inherit; padding: 10px 6px; color: var(--text); }
.faq-search input:focus { outline: none; }
.accordion { display: flex; flex-direction: column; gap: 12px; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.faq-question { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 18px; background: none; border: none; font: inherit; font-weight: 600; font-size: .98rem; color: var(--text); cursor: pointer; text-align: left; }
.faq-question:hover { color: var(--primary); }
.faq-question svg { transition: transform .2s; flex-shrink: 0; color: var(--muted); }
.faq-item.open .faq-question svg { transform: rotate(180deg); }
.faq-answer { padding: 0 18px 18px; color: var(--muted); font-size: .95rem; }
.faq-answer p { margin-top: 10px; }

/* Downloads & videos */
.download-card { display: flex; flex-direction: column; padding: 22px; }
.download-card-head { display: flex; gap: 14px; align-items: center; margin-bottom: 10px; }
.download-card-head h3 { font-size: 1.02rem; }
.download-card-foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 14px; }
.video-card { cursor: pointer; }
.video-thumb { position: relative; aspect-ratio: 16/9; background: #0f172a; overflow: hidden; }
.video-thumb img { width: 100%; height: 100%; object-fit: cover; }
.play-btn { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; background: rgba(15, 23, 42, .35); transition: background .15s; }
.video-card:hover .play-btn { background: rgba(15, 23, 42, .55); }
.duration-badge { position: absolute; bottom: 10px; right: 10px; background: rgba(15, 23, 42, .85); color: #fff; font-size: .75rem; padding: 3px 9px; border-radius: 6px; }
.video-embed { position: relative; padding-top: 56.25%; margin-top: 16px; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; border-radius: 10px; }

/* Search results */
.search-results { display: flex; flex-direction: column; gap: 18px; }
.search-results .article-card { display: grid; grid-template-columns: 260px 1fr; }
.search-results .article-thumb { aspect-ratio: 16/9; height: 100%; }

/* Service show */
.service-head { display: flex; flex-direction: column; gap: 14px; }
.service-pricing { display: flex; align-items: baseline; gap: 12px; }
.service-pricing .price { font-size: 1.7rem; font-weight: 800; color: var(--primary); }
.service-pricing .price-note { color: var(--muted); }
.service-book-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }

/* ------------------------------ Footer ------------------------------ */
.site-footer { background: #0f172a; color: #94a3b8; margin-top: 60px; }
[data-theme="dark"] .site-footer { background: #060b16; border-top: 1px solid var(--border); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 36px; padding: 56px 0 40px; }
.footer-brand { color: #fff; margin-bottom: 14px; }
.footer-about p { font-size: .9rem; line-height: 1.7; margin-bottom: 18px; }
.footer-social { display: flex; gap: 10px; }
.footer-social a { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 9px; background: rgba(255, 255, 255, .08); color: #cbd5e1; transition: all .15s; }
.footer-social a:hover { background: var(--primary); color: #fff; }
.footer-heading { color: #fff; font-size: .95rem; margin-bottom: 16px; text-transform: uppercase; letter-spacing: .06em; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: #94a3b8; font-size: .9rem; text-decoration: none; }
.footer-links a:hover { color: #fff; }
.footer-contact-list { list-style: none; }
.footer-contact-list li { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; font-size: .9rem; }
.footer-contact-list svg { color: var(--accent); flex-shrink: 0; margin-top: 3px; }
.footer-contact-list a { color: #94a3b8; }
.footer-contact-list a:hover { color: #fff; }
.footer-messengers { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: 22px 0; display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; font-size: .85rem; }
.footer-legal-links { display: flex; gap: 18px; list-style: none; flex-wrap: wrap; }
.footer-legal-links a { color: #94a3b8; }
.footer-legal-links a:hover { color: #fff; }

.whatsapp-float {
    position: fixed; right: 22px; bottom: 22px; z-index: 300;
    width: 56px; height: 56px; border-radius: 50%;
    background: #25d366; color: #fff; display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 24px rgba(37, 211, 102, .45); transition: transform .15s;
}
.whatsapp-float:hover { transform: scale(1.08); color: #fff; }

/* ------------------------------ Auth ------------------------------ */
.blank-body { background: var(--bg); min-height: 100vh; }
.blank-main { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.auth-wrap { width: 100%; max-width: 420px; }
.auth-card { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 34px; box-shadow: var(--shadow-lg); }
.auth-brand { justify-content: center; margin-bottom: 22px; }
.auth-card h1 { font-size: 1.4rem; text-align: center; margin-bottom: 6px; }
.auth-card > p { text-align: center; margin-bottom: 22px; }
.auth-hint { margin-top: 22px; padding: 12px; background: var(--surface-2); border-radius: 10px; }
.auth-icon { display: flex; justify-content: center; color: var(--primary); margin-bottom: 14px; }
.code-input { text-align: center; font-size: 1.6rem; letter-spacing: .5em; font-family: var(--mono); }

/* ------------------------------ Responsive ------------------------------ */
@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
    .hero-inner { grid-template-columns: 1fr; padding: 48px 20px; }
    .hero-visual { display: none; }
    .page-layout { grid-template-columns: 1fr; }
    .sidebar { order: 2; }
    .nav-burger { display: inline-flex; }
    .nav-cta { display: none; }
    .main-nav {
        position: fixed; inset: var(--nav-h) 0 auto 0; background: var(--surface);
        border-bottom: 1px solid var(--border); max-height: 0; overflow: auto;
        transition: max-height .25s ease; box-shadow: var(--shadow-lg);
    }
    .main-nav.open { max-height: 70vh; }
    .nav-list { flex-direction: column; padding: 14px 20px 22px; }
    .nav-link { width: 100%; justify-content: space-between; }
    .dropdown-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: none; padding-left: 18px; }
    .nav-item.has-dropdown .dropdown-menu { display: none; }
    .nav-item.has-dropdown.open .dropdown-menu { display: block; }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .search-results .article-card { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .grid-3, .grid-2, .grid-4 { grid-template-columns: 1fr; }
    .form-grid { grid-template-columns: 1fr; }
    .topbar-inner { justify-content: center; }
    .topbar-right { display: none; }
    .footer-grid { grid-template-columns: 1fr; }
    .hero-stats { gap: 20px; }
    .section { padding: 44px 0; }
    .article-meta { gap: 12px; }
    .footer-bottom { flex-direction: column; }
    .newsletter-row { flex-direction: column; }
}

/* Global flash messages */
.flash-wrap { padding-top: 22px; margin-bottom: -22px; }

/* ------------------------------ AI Assistant ------------------------------ */
.assistant-fab {
    position: fixed; left: 22px; bottom: 22px; z-index: 300;
    width: 56px; height: 56px; border-radius: 50%; cursor: pointer;
    background: linear-gradient(135deg, #7c3aed, #2563eb); color: #fff;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 24px rgba(124, 58, 237, .4); transition: transform .15s;
}
.assistant-fab:hover { transform: scale(1.08); }
.assistant-pulse { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(124, 58, 237, .5); animation: pulse 2.2s infinite; }
@keyframes pulse { 0% { transform: scale(1); opacity: 1; } 70% { transform: scale(1.45); opacity: 0; } 100% { opacity: 0; } }
.assistant-panel {
    position: fixed; left: 22px; bottom: 90px; z-index: 301; width: 360px; max-width: calc(100vw - 44px);
    background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
    box-shadow: var(--shadow-lg); display: flex; flex-direction: column; overflow: hidden;
}
.assistant-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: linear-gradient(120deg, #7c3aed, #2563eb); color: #fff; }
.assistant-head small { display: block; opacity: .85; }
.assistant-head-icon { display: flex; }
.assistant-head .icon-btn { color: #fff; margin-left: auto; }
.assistant-head .icon-btn:hover { background: rgba(255,255,255,.15); color: #fff; }
.assistant-chat { padding: 14px; max-height: 280px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.assistant-msg { padding: 10px 13px; border-radius: 12px; font-size: .9rem; line-height: 1.5; max-width: 85%; }
.assistant-msg.bot { background: var(--surface-2); border-bottom-left-radius: 4px; align-self: flex-start; }
.assistant-msg.user { background: var(--primary); color: #fff; border-bottom-right-radius: 4px; align-self: flex-end; }
.assistant-link { display: inline-block; margin-top: 8px; font-weight: 600; text-decoration: none; }
.assistant-msg.bot .assistant-link { color: var(--primary); }
.assistant-quick { display: flex; flex-wrap: wrap; gap: 7px; padding: 0 14px 12px; }
.assistant-quick button { border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; font-size: .8rem; padding: 6px 11px; border-radius: 999px; cursor: pointer; }
.assistant-quick button:hover { border-color: var(--primary); color: var(--primary); }
.assistant-input { display: flex; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--border); background: var(--bg); }
.assistant-input input { flex: 1; min-width: 0; }
@media (max-width: 640px) {
    .assistant-fab { left: 16px; bottom: 88px; }
    .assistant-panel { left: 16px; bottom: 152px; }
}

/* Homepage newsletter band */
.newsletter-band { background: var(--surface); border-top: 1px solid var(--border); padding: 46px 0; }
.newsletter-band-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; align-items: center; }
.newsletter-band h2 { display: flex; align-items: center; gap: 10px; font-size: 1.4rem; margin-bottom: 6px; }
.newsletter-band p { color: var(--muted); }
.newsletter-band .newsletter-box { margin: 0; }
@media (max-width: 800px) { .newsletter-band-inner { grid-template-columns: 1fr; } }

/* ---------- Utility: the hidden attribute must always win ---------- */
[hidden] { display: none !important; }

/* ------------------------------ Pricing page ------------------------------ */
.guarantee-strip {
    display: flex; gap: 26px; flex-wrap: wrap; align-items: center;
    background: var(--success-soft); border: 1px solid #86efac; border-radius: var(--radius);
    padding: 14px 22px; margin-bottom: 26px; font-weight: 600; font-size: .92rem; color: var(--success);
}
[data-theme="dark"] .guarantee-strip { border-color: #166534; color: #86efac; }
.guarantee-strip div { display: flex; align-items: center; gap: 8px; }
.pricing-table td { vertical-align: middle; }
.pricing-table .service-icon { margin: 0; }
.price-nowrap { color: var(--primary); white-space: nowrap; }

/* Footer single-link columns (e.g. About Us) */
a.footer-heading-link { display: block; margin-bottom: 16px; color: #fff; text-decoration: none; }
a.footer-heading-link:hover { color: var(--accent); }
