/* ═══════════════════════════════════════════════════
   Traffic Builders — Main Styles
   ═══════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    font-family: var(--tb-font-sans);
    color: var(--tb-text);
    background: var(--tb-bg);
    line-height: var(--tb-leading-normal);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a { color: var(--tb-primary); text-decoration: none; transition: color var(--tb-t); }
a:hover { color: var(--tb-primary-hover); }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--tb-font-sans);
    line-height: var(--tb-leading-tight);
    letter-spacing: -0.02em;
    margin: 0;
    color: var(--tb-text);
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); font-weight: 700; }
h2 { font-size: clamp(1.875rem, 3.5vw, 2.75rem); font-weight: 700; }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.5rem); font-weight: 600; }

p { margin: 0 0 var(--tb-s-4); line-height: var(--tb-leading-relaxed); }

/* ─── Layout ─── */
.tb-container {
    width: 100%;
    max-width: var(--tb-container);
    margin: 0 auto;
    padding: 0 var(--tb-s-6);
}

.tb-section {
    padding: var(--tb-s-24) 0;
}

.tb-section-head {
    text-align: center;
    max-width: 720px;
    margin: 0 auto var(--tb-s-16);
}

.tb-section-head h2 {
    margin: var(--tb-s-3) 0 var(--tb-s-4);
}

.tb-eyebrow {
    display: inline-block;
    font-size: var(--tb-text-xs);
    font-weight: 600;
    color: var(--tb-primary);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: var(--tb-s-1) var(--tb-s-3);
    background: var(--tb-primary-soft);
    border-radius: var(--tb-r-full);
}

/* ─── Topbar ─── */
.tb-topbar {
    background: var(--tb-dark);
    color: var(--tb-dark-text);
    text-align: center;
    font-size: var(--tb-text-sm);
    padding: var(--tb-s-2) 0;
}
.tb-topbar a {
    color: var(--tb-dark-text);
    display: inline-flex;
    align-items: center;
    gap: var(--tb-s-2);
}
.tb-topbar a:hover { color: #fff; }
.tb-topbar span { transition: transform var(--tb-t); }
.tb-topbar a:hover span { transform: translateX(3px); }

/* ─── Header ─── */
.tb-header {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: saturate(180%) blur(12px);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--tb-border-subtle);
    z-index: 100;
}
.tb-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
    gap: var(--tb-s-8);
}
.tb-logo {
    display: flex;
    align-items: center;
    gap: var(--tb-s-2);
    font-weight: 700;
    font-size: var(--tb-text-lg);
    color: var(--tb-text);
}
.tb-logo-mark {
    width: 28px; height: 28px;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--tb-primary), var(--tb-accent));
    position: relative;
}
.tb-logo-mark::after {
    content: '';
    position: absolute;
    inset: 6px;
    border-radius: 2px;
    background: #fff;
    opacity: 0.9;
}
.tb-logo--light { color: var(--tb-text); }

.tb-nav { flex: 1; }
.tb-nav-list {
    list-style: none;
    display: flex;
    gap: var(--tb-s-6);
    margin: 0;
    padding: 0;
    justify-content: center;
}
.tb-nav-list a, .tb-nav-link {
    color: var(--tb-text-muted);
    font-size: var(--tb-text-sm);
    font-weight: 500;
    transition: color var(--tb-t);
}
.tb-nav-list a:hover, .tb-nav-link:hover { color: var(--tb-text); }

.tb-header-ctas {
    display: flex;
    align-items: center;
    gap: var(--tb-s-4);
}

.tb-mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
}
.tb-mobile-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--tb-text);
    border-radius: 1px;
}

/* ─── Buttons ─── */
.tb-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--tb-s-2);
    padding: 10px 20px;
    border-radius: var(--tb-r);
    font-weight: 600;
    font-size: var(--tb-text-sm);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--tb-t);
    white-space: nowrap;
}
.tb-btn-sm { padding: 7px 14px; font-size: var(--tb-text-xs); }
.tb-btn-lg { padding: 14px 28px; font-size: var(--tb-text-base); }

.tb-btn-primary {
    background: var(--tb-text);
    color: #fff;
    box-shadow: var(--tb-shadow);
}
.tb-btn-primary:hover {
    background: var(--tb-dark);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: var(--tb-shadow-md);
}

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

.tb-btn-ghost {
    background: transparent;
    color: var(--tb-dark-text);
    border-color: rgba(255, 255, 255, 0.15);
}
.tb-btn-ghost:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.tb-arrow {
    transition: transform var(--tb-t);
    display: inline-block;
}
.tb-btn:hover .tb-arrow { transform: translateX(3px); }

/* ─── Hero ─── */
.tb-hero {
    position: relative;
    overflow: hidden;
    padding: var(--tb-s-20) 0 var(--tb-s-16);
    background: var(--tb-bg);
}
.tb-hero--mini {
    padding: var(--tb-s-16) 0 var(--tb-s-12);
}

.tb-hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}
.tb-hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(59, 130, 246, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59, 130, 246, 0.04) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 60% 50% at 50% 30%, #000 40%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse 60% 50% at 50% 30%, #000 40%, transparent 80%);
}
.tb-hero-orb {
    position: absolute;
    width: 500px; height: 500px;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
}
.tb-hero-orb-1 {
    top: -100px; left: 10%;
    background: radial-gradient(circle, var(--tb-primary) 0%, transparent 60%);
}
.tb-hero-orb-2 {
    top: 40%; right: 10%;
    background: radial-gradient(circle, var(--tb-accent) 0%, transparent 60%);
}

.tb-hero-inner {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 920px;
    margin: 0 auto;
}

.tb-hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1.05;
    margin: var(--tb-s-4) 0 var(--tb-s-6);
}

.tb-hero-subtitle {
    font-size: clamp(1rem, 1.8vw, 1.25rem);
    color: var(--tb-text-muted);
    max-width: 680px;
    margin: 0 auto var(--tb-s-8);
    line-height: 1.6;
}

.tb-hero-ctas {
    display: flex;
    gap: var(--tb-s-3);
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: var(--tb-s-8);
}

.tb-hero-badges {
    display: flex;
    gap: var(--tb-s-3);
    justify-content: center;
    flex-wrap: wrap;
    margin-top: var(--tb-s-6);
}

.tb-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--tb-s-2);
    font-size: var(--tb-text-xs);
    color: var(--tb-text-muted);
    background: var(--tb-surface);
    padding: 6px 12px;
    border: 1px solid var(--tb-border);
    border-radius: var(--tb-r-full);
}
.tb-badge::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--tb-green);
}

/* ─── Product Preview ─── */
.tb-preview {
    margin-top: var(--tb-s-16);
    position: relative;
}
.tb-preview-frame {
    background: var(--tb-dark);
    border-radius: var(--tb-r-xl);
    padding: var(--tb-s-1);
    box-shadow: 0 30px 80px rgba(10, 14, 26, 0.2), 0 12px 30px rgba(10, 14, 26, 0.1);
    overflow: hidden;
    border: 1px solid var(--tb-dark-border);
}
.tb-preview-chrome {
    height: 32px;
    display: flex;
    align-items: center;
    padding: 0 var(--tb-s-3);
    gap: var(--tb-s-2);
    background: var(--tb-dark);
}
.tb-preview-chrome span {
    width: 10px; height: 10px;
    border-radius: 50%;
    background: var(--tb-dark-border);
}
.tb-preview-chrome span:nth-child(1) { background: #FF5F57; }
.tb-preview-chrome span:nth-child(2) { background: #FEBC2E; }
.tb-preview-chrome span:nth-child(3) { background: #28C840; }
.tb-preview-url {
    flex: 1;
    text-align: center;
    background: #0A0D12;
    color: var(--tb-dark-text-muted);
    font-size: var(--tb-text-xs);
    font-family: var(--tb-font-mono);
    padding: 4px 10px;
    border-radius: 4px;
    max-width: 340px;
    margin: 0 auto;
}
.tb-preview-content {
    display: flex;
    background: var(--tb-dark-surface);
    height: 380px;
    border-radius: 0 0 var(--tb-r-lg) var(--tb-r-lg);
}
.tb-preview-sidebar {
    width: 180px;
    padding: var(--tb-s-4);
    border-right: 1px solid var(--tb-dark-border);
}
.tb-preview-logo {
    width: 24px; height: 24px;
    border-radius: 6px;
    background: linear-gradient(135deg, var(--tb-primary), var(--tb-accent));
    margin-bottom: var(--tb-s-4);
}
.tb-preview-nav-item {
    padding: 6px 10px;
    font-size: 11px;
    color: var(--tb-dark-text-muted);
    border-radius: 6px;
    margin-bottom: 2px;
}
.tb-preview-nav-item.active {
    background: rgba(59, 130, 246, 0.15);
    color: var(--tb-primary);
}
.tb-preview-main { flex: 1; padding: var(--tb-s-4); }
.tb-preview-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--tb-s-3);
    margin-bottom: var(--tb-s-4);
}
.tb-preview-card {
    background: #0E121B;
    border: 1px solid var(--tb-dark-border);
    border-radius: 10px;
    padding: var(--tb-s-3);
}
.tb-preview-score {
    font-size: 28px;
    font-weight: 700;
    color: var(--tb-primary);
    line-height: 1;
}
.tb-preview-metric {
    font-size: 22px;
    font-weight: 700;
    color: var(--tb-dark-text);
    line-height: 1;
}
.tb-preview-metric.tb-purple { color: var(--tb-purple); }
.tb-preview-label {
    font-size: 10px;
    color: var(--tb-dark-text-muted);
    margin-top: var(--tb-s-2);
}
.tb-preview-label .up {
    color: var(--tb-green);
    font-weight: 600;
    margin-left: 4px;
}
.tb-preview-chart {
    background: #0E121B;
    border: 1px solid var(--tb-dark-border);
    border-radius: 10px;
    padding: var(--tb-s-3);
    height: 140px;
}
.tb-preview-chart svg { width: 100%; height: 100%; }

/* ─── Logos ─── */
.tb-logos {
    padding: var(--tb-s-12) 0;
    border-top: 1px solid var(--tb-border-subtle);
    border-bottom: 1px solid var(--tb-border-subtle);
}
.tb-logos-label {
    text-align: center;
    font-size: var(--tb-text-xs);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--tb-text-dim);
    margin-bottom: var(--tb-s-6);
    font-weight: 600;
}
.tb-logos-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: var(--tb-s-6);
    align-items: center;
    justify-items: center;
}
.tb-logo-item {
    font-size: var(--tb-text-lg);
    font-weight: 700;
    color: var(--tb-text-dim);
    font-family: var(--tb-font-sans);
    letter-spacing: -0.02em;
    opacity: 0.7;
    transition: opacity var(--tb-t);
}
.tb-logo-item:hover { opacity: 1; }

/* ─── Stats ─── */
.tb-stats {
    background: var(--tb-surface);
    padding: var(--tb-s-20) 0;
}
.tb-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--tb-s-8);
}
.tb-stat { text-align: center; }
.tb-stat-number {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    background: linear-gradient(135deg, var(--tb-primary), var(--tb-accent));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    letter-spacing: -0.03em;
    line-height: 1;
}
.tb-stat-label {
    font-size: var(--tb-text-sm);
    color: var(--tb-text-muted);
    margin-top: var(--tb-s-2);
}

/* ─── Footer ─── */
.tb-footer {
    background: var(--tb-dark);
    color: var(--tb-dark-text);
    padding: var(--tb-s-20) 0 var(--tb-s-8);
    margin-top: var(--tb-s-24);
}
.tb-footer-grid {
    display: grid;
    grid-template-columns: 2fr repeat(4, 1fr);
    gap: var(--tb-s-12);
    margin-bottom: var(--tb-s-16);
}
.tb-footer-brand .tb-logo { color: #fff; margin-bottom: var(--tb-s-4); }
.tb-footer-brand .tb-logo-text { color: #fff; }
.tb-footer-tagline {
    color: var(--tb-dark-text-muted);
    font-size: var(--tb-text-sm);
    line-height: 1.6;
    max-width: 280px;
}
.tb-footer-social {
    display: flex;
    gap: var(--tb-s-4);
    margin-top: var(--tb-s-4);
}
.tb-social-link {
    color: var(--tb-dark-text-muted);
    font-size: var(--tb-text-sm);
    font-weight: 500;
}
.tb-social-link:hover { color: #fff; }

.tb-footer-col h4 {
    color: #fff;
    font-size: var(--tb-text-sm);
    margin-bottom: var(--tb-s-4);
    font-weight: 600;
}
.tb-footer-links {
    list-style: none;
    margin: 0; padding: 0;
}
.tb-footer-links li { margin-bottom: var(--tb-s-2); }
.tb-footer-links a {
    color: var(--tb-dark-text-muted);
    font-size: var(--tb-text-sm);
    transition: color var(--tb-t);
}
.tb-footer-links a:hover { color: #fff; }

.tb-footer-bottom {
    border-top: 1px solid var(--tb-dark-border);
    padding-top: var(--tb-s-6);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--tb-s-4);
}
.tb-footer-meta {
    display: flex;
    flex-direction: column;
    gap: var(--tb-s-1);
}
.tb-footer-copyright {
    color: var(--tb-dark-text);
    font-size: var(--tb-text-sm);
}
.tb-footer-company-meta {
    display: flex;
    gap: var(--tb-s-4);
    font-size: var(--tb-text-xs);
    color: var(--tb-dark-text-muted);
    flex-wrap: wrap;
}
.tb-footer-trust {
    display: flex;
    gap: var(--tb-s-4);
    font-size: var(--tb-text-xs);
    color: var(--tb-dark-text-muted);
}

/* ─── Responsive ─── */
@media (max-width: 900px) {
    .tb-nav, .tb-header-ctas { display: none; }
    .tb-mobile-toggle { display: flex; }
    .tb-stats-grid { grid-template-columns: repeat(2, 1fr); gap: var(--tb-s-6); }
    .tb-footer-grid { grid-template-columns: 1fr 1fr; gap: var(--tb-s-8); }
    .tb-preview-content { height: auto; flex-direction: column; }
    .tb-preview-sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--tb-dark-border); }
    .tb-preview-cards { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    .tb-footer-grid { grid-template-columns: 1fr; }
    .tb-hero-ctas .tb-btn { width: 100%; }
    .tb-footer-bottom { flex-direction: column; align-items: flex-start; }
}
