/**
 * TradeTechSolutions Design - cryptopropfirm.net
 * Dark SaaS B2B theme: black bg, blue (#3760FF) + purple (#944DF6) accents
 */

/* ============================================================
   FONTS
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* Geist Mono via CSS - fallback to monospace */
@font-face {
    font-family: 'GeistMono';
    src: local('Geist Mono'), local('GeistMono');
    font-weight: normal;
}

/* ============================================================
   BASE OVERRIDES
   ============================================================ */
body {
    background-color: #111111;
    color: #ffffff;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: 700;
    color: #ffffff;
}

a { color: #3760FF; }
a:hover { color: #944DF6; }

/* ============================================================
   HEADER - TTS Style
   ============================================================ */
.header {
    background-color: #111111;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-fixed);
    height: var(--header-height);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2rem;
}

.header-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.header-logo img {
    width: 36px;
    height: 36px;
}

.header-logo-text {
    font-size: 1rem;
    font-weight: 700;
    color: #ffffff;
    font-family: 'Inter', sans-serif;
    letter-spacing: -0.02em;
}

.nav-main {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0.5rem 0.85rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
    background: rgba(255,255,255,0.06);
}

.nav-link svg {
    width: 14px;
    height: 14px;
    opacity: 0.6;
}

/* Dropdown */
.nav-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    padding: 0.5rem;
    min-width: 220px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    z-index: var(--z-dropdown);
}

.nav-item:hover .nav-dropdown {
    display: block;
}

.nav-dropdown-link {
    display: block;
    padding: 0.6rem 0.75rem;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
}

.nav-dropdown-link:hover {
    color: #ffffff;
    background: rgba(55,96,255,0.15);
}

.nav-dropdown-link small {
    font-size: 0.75rem;
    opacity: 0.5;
    margin-left: 4px;
}

/* CTA button in header */
.header-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.55rem 1.2rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #ffffff !important;
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    border-radius: 8px;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.2s;
    white-space: nowrap;
}

.header-cta:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    color: #ffffff !important;
}

/* Mobile toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.mobile-menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #ffffff;
    border-radius: 2px;
}

/* ============================================================
   MOBILE NAV
   ============================================================ */
.mobile-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    z-index: 998;
}

.mobile-overlay.active { display: block; }

.mobile-nav {
    position: fixed;
    top: 0;
    right: -320px;
    width: 300px;
    height: 100vh;
    background: #1a1a1a;
    border-left: 1px solid rgba(255,255,255,0.1);
    z-index: 999;
    transition: right 0.3s ease;
    overflow-y: auto;
    padding: 1rem;
}

.mobile-nav.active { right: 0; }

.mobile-nav-header {
    display: flex;
    justify-content: flex-end;
    padding: 0.5rem 0 1rem;
}

.mobile-nav-close {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 4px;
}

.mobile-nav-close svg { width: 20px; height: 20px; fill: currentColor; }

.mobile-nav-links { display: flex; flex-direction: column; gap: 2px; }

.mobile-nav-item { border-radius: 8px; overflow: hidden; }

.mobile-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: background 0.2s;
}

.mobile-nav-link:hover, .mobile-nav-link.active {
    color: #fff;
    background: rgba(55,96,255,0.15);
}

.mobile-nav-link svg { width: 14px; height: 14px; transition: transform 0.2s; }

.mobile-nav-item.open .mobile-nav-link svg { transform: rotate(180deg); }

.mobile-nav-dropdown {
    display: none;
    padding: 0 0 0.5rem 1rem;
}

.mobile-nav-item.open .mobile-nav-dropdown { display: block; }

.mobile-nav-dropdown a {
    display: block;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    border-radius: 6px;
}

.mobile-nav-dropdown a:hover { color: #fff; background: rgba(55,96,255,0.1); }
.mobile-nav-all { font-weight: 500; }

/* Header spacer */
.header-spacer { height: var(--header-height); }

/* ============================================================
   HERO - TTS Style
   ============================================================ */
.tts-hero {
    position: relative;
    background: #111111;
    padding: 100px 0 80px;
    text-align: center;
    overflow: hidden;
    min-height: min(85vh, 820px);
    display: flex;
    align-items: center;
}

.tts-hero-bg {
    position: absolute;
    inset: 0;
    background-image: url('/images/ref/hero-bg.png');
    background-size: cover;
    background-position: center top;
    opacity: 0.25;
    pointer-events: none;
}

/* Decorative gradient glow */
.tts-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 400px;
    background: radial-gradient(ellipse at center top, rgba(55,96,255,0.25) 0%, transparent 70%);
    pointer-events: none;
}

.tts-hero::after {
    content: '';
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 300px;
    background: radial-gradient(ellipse at center, rgba(148,77,246,0.15) 0%, transparent 70%);
    pointer-events: none;
}

.tts-hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
}

.tts-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.4rem 1rem;
    background: rgba(55,96,255,0.12);
    border: 1px solid rgba(55,96,255,0.3);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
    margin-bottom: 1.5rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.tts-hero-badge span {
    color: #3760FF;
}

.tts-hero h1 {
    font-size: clamp(2.2rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    color: #ffffff;
    margin: 0 auto 1.25rem;
    max-width: 780px;
    letter-spacing: -0.03em;
}

.tts-hero h1 .accent {
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tts-hero-subtitle {
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    color: rgba(255,255,255,0.6);
    max-width: 560px;
    margin: 0 auto 2rem;
    line-height: 1.6;
}

.tts-hero-btns {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.tts-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.75rem 1.75rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: #ffffff !important;
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    border-radius: 8px;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 20px rgba(55,96,255,0.3);
}

.tts-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(55,96,255,0.5);
    color: #ffffff !important;
}

.tts-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.75rem 1.75rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: rgba(255,255,255,0.8) !important;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 8px;
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.tts-btn-secondary:hover {
    border-color: rgba(55,96,255,0.5);
    color: #ffffff !important;
    background: rgba(55,96,255,0.08);
}

/* Hero stats row */
.tts-hero-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    flex-wrap: wrap;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.08);
}

.tts-hero-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.tts-hero-stat-num {
    font-size: 1.5rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.02em;
}

.tts-hero-stat-label {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.5);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 500;
}

/* ============================================================
   SECTION TITLES
   ============================================================ */
.tts-section {
    padding: 80px 0;
    background: #111111;
}

.tts-section-alt {
    background: #0d0d0d;
}

.tts-section-label {
    display: block;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.tts-section-title {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    margin-bottom: 0.75rem;
    letter-spacing: -0.03em;
    line-height: 1.2;
}

.tts-section-title .accent {
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tts-section-subtitle {
    font-size: 1rem;
    color: rgba(255,255,255,0.5);
    text-align: center;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ============================================================
   CATEGORY GRID - TTS Style cards with blue borders
   ============================================================ */
.tts-cat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    max-width: 780px;
    margin: 0 auto;
}

.tts-cat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 1.75rem;
    background: #1a1a1a;
    border: 1px solid rgba(55,96,255,0.25);
    border-radius: 12px;
    text-decoration: none;
    color: #ffffff;
    transition: border-color 0.2s, background 0.2s, transform 0.2s;
}

.tts-cat-card:hover {
    border-color: rgba(55,96,255,0.7);
    background: rgba(55,96,255,0.08);
    transform: translateY(-2px);
    color: #ffffff;
}

.tts-cat-card-icon {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(55,96,255,0.15);
    border-radius: 10px;
}

.tts-cat-card-icon svg {
    width: 22px;
    height: 22px;
    fill: #3760FF;
}

.tts-cat-card-text h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 2px;
}

.tts-cat-card-text p {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.45);
    margin: 0;
}

/* All categories grid (5 cats) */
.tts-cat-grid-5 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

/* ============================================================
   LOGO CAROUSEL (integrations / trusted by)
   ============================================================ */
.tts-logos-section {
    padding: 60px 0;
    background: #0d0d0d;
    overflow: hidden;
}

.tts-logos-label {
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255,255,255,0.35);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 2rem;
}

.tts-logo-track {
    display: flex;
    gap: 2rem;
    animation: ttsScrollLeft 30s linear infinite;
    width: max-content;
}

.tts-logo-track-rev {
    animation: ttsScrollRight 35s linear infinite;
}

@keyframes ttsScrollLeft {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@keyframes ttsScrollRight {
    from { transform: translateX(-50%); }
    to { transform: translateX(0); }
}

.tts-logo-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.6rem 1.25rem;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255,255,255,0.6);
    white-space: nowrap;
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s;
}

.tts-logo-pill:hover {
    border-color: rgba(55,96,255,0.4);
    color: #fff;
}

/* ============================================================
   FEATURES GRID - 3 columns
   ============================================================ */
.tts-features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.tts-feature-card {
    padding: 1.75rem;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 14px;
    transition: border-color 0.2s, background 0.2s;
}

.tts-feature-card:hover {
    border-color: rgba(55,96,255,0.3);
    background: rgba(55,96,255,0.04);
}

.tts-feature-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(55,96,255,0.12);
    border-radius: 12px;
}

.tts-feature-icon img {
    width: 28px;
    height: 28px;
    object-fit: contain;
    filter: brightness(0) saturate(100%) invert(43%) sepia(95%) saturate(1337%) hue-rotate(210deg) brightness(103%) contrast(98%);
}

.tts-feature-icon svg {
    width: 28px;
    height: 28px;
    fill: #3760FF;
}

.tts-feature-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 0.6rem;
}

.tts-feature-card p {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.5);
    line-height: 1.6;
    margin: 0;
}

/* ============================================================
   ARTICLES GRID
   ============================================================ */
.tts-articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.tts-article-card {
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 12px;
    overflow: hidden;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    transition: border-color 0.2s, transform 0.2s;
}

.tts-article-card:hover {
    border-color: rgba(55,96,255,0.4);
    transform: translateY(-3px);
}

.tts-article-thumb {
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #222;
}

.tts-article-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.tts-article-card:hover .tts-article-thumb img {
    transform: scale(1.04);
}

.tts-article-body {
    padding: 1.25rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.tts-article-cat {
    font-size: 0.72rem;
    font-weight: 600;
    color: #3760FF;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.tts-article-title {
    font-size: 0.925rem;
    font-weight: 600;
    color: #ffffff;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
.tts-cta {
    padding: 80px 0;
    background: #0d0d0d;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.tts-cta::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    width: 600px;
    height: 300px;
    background: radial-gradient(ellipse, rgba(55,96,255,0.15) 0%, transparent 70%);
    pointer-events: none;
}

.tts-cta-inner { position: relative; z-index: 1; }

.tts-cta h2 {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1rem;
    letter-spacing: -0.03em;
}

.tts-cta h2 .accent {
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tts-cta p {
    font-size: 1rem;
    color: rgba(255,255,255,0.5);
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.tts-cta-btns {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ============================================================
   FOOTER - TTS Style
   ============================================================ */
.footer {
    background: #0a0a0a;
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 60px 0 0;
    color: rgba(255,255,255,0.6);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 3rem;
}

.footer-brand p {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.45);
    line-height: 1.7;
    margin-top: 1rem;
    max-width: 300px;
}

.footer-brand .header-logo-text {
    color: #ffffff !important;
}

.footer-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1.25rem;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.footer-links a {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.45);
    text-decoration: none;
    transition: color 0.2s;
}

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

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.07);
    padding: 1.5rem 0;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.footer-disclaimer {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.3);
    max-width: 600px;
    line-height: 1.6;
    margin: 0;
}

.footer-bottom p:last-child {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.3);
    margin: 0;
    white-space: nowrap;
}

/* ============================================================
   PAGE HERO (internal pages)
   ============================================================ */
.tts-page-hero {
    background: linear-gradient(135deg, #0d0d0d 0%, #111111 100%);
    padding: 60px 0 40px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    position: relative;
    overflow: hidden;
}

.tts-page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 600px;
    height: 300px;
    background: radial-gradient(ellipse at right top, rgba(55,96,255,0.12) 0%, transparent 70%);
    pointer-events: none;
}

.tts-page-hero-inner { position: relative; z-index: 1; }

.tts-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.tts-breadcrumb a, .tts-breadcrumb span {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.4);
    text-decoration: none;
}

.tts-breadcrumb a:hover { color: #ffffff; }

.tts-breadcrumb .sep {
    color: rgba(255,255,255,0.2);
    font-size: 0.7rem;
}

.tts-breadcrumb .current {
    color: rgba(255,255,255,0.7);
}

.tts-page-hero h1 {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    font-weight: 800;
    color: #ffffff;
    margin: 0;
    letter-spacing: -0.03em;
    max-width: 700px;
}

/* ============================================================
   ARTICLE LAYOUT (article.php)
   ============================================================ */
.tts-article-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 2rem;
    padding: 2rem 0;
}

.tts-article-content {
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 14px;
    padding: 2rem 2.5rem;
}

.tts-article-content h1,
.tts-article-content h2,
.tts-article-content h3,
.tts-article-content h4 {
    color: #ffffff;
}

.tts-article-content p,
.tts-article-content li {
    color: rgba(255,255,255,0.75);
    line-height: 1.75;
}

.tts-article-content a {
    color: #3760FF;
}

.tts-sidebar-card {
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 14px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.tts-sidebar-card h3 {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(255,255,255,0.5);
    margin-bottom: 1rem;
}

.tts-sidebar-link {
    display: block;
    padding: 0.5rem 0;
    font-size: 0.875rem;
    color: rgba(255,255,255,0.65);
    text-decoration: none;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: color 0.2s;
}

.tts-sidebar-link:hover { color: #3760FF; }
.tts-sidebar-link:last-child { border-bottom: none; }

/* ============================================================
   CATEGORY / SUBCATEGORY PAGE
   ============================================================ */
.tts-main-section {
    padding: 2rem 0 3rem;
    background: #111111;
}

/* Sub-categories chips */
.tts-subcat-chips {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.tts-subcat-chip {
    padding: 0.4rem 1rem;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 100px;
    font-size: 0.825rem;
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.tts-subcat-chip:hover, .tts-subcat-chip.active {
    border-color: rgba(55,96,255,0.5);
    color: #ffffff;
    background: rgba(55,96,255,0.1);
}

/* ============================================================
   TAGS PAGE
   ============================================================ */
.tts-tags-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
}

.tts-tag-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 8px;
    text-decoration: none;
    transition: border-color 0.2s, background 0.2s;
}

.tts-tag-card:hover {
    border-color: rgba(55,96,255,0.4);
    background: rgba(55,96,255,0.05);
}

.tts-tag-name {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.75);
}

.tts-tag-count {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.06);
    padding: 2px 7px;
    border-radius: 100px;
}

/* ============================================================
   404 PAGE
   ============================================================ */
.tts-404 {
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 0;
}

.tts-404-code {
    font-size: 7rem;
    font-weight: 900;
    line-height: 1;
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.tts-404 h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.tts-404 p {
    color: rgba(255,255,255,0.5);
    margin-bottom: 2rem;
}

/* ============================================================
   CONTACT PAGE
   ============================================================ */
.tts-contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem 0 3rem;
}

.tts-contact-form {
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 14px;
    padding: 2rem;
}

.tts-contact-info {
    padding: 1rem 0;
}

.tts-contact-info h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.tts-contact-info p {
    color: rgba(255,255,255,0.5);
    font-size: 0.9rem;
    line-height: 1.7;
}

.tts-form-group {
    margin-bottom: 1.25rem;
}

.tts-form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: rgba(255,255,255,0.7);
    margin-bottom: 0.5rem;
}

.tts-form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: #111111;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    font-size: 0.9rem;
    color: #ffffff;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.tts-form-input:focus {
    outline: none;
    border-color: rgba(55,96,255,0.6);
    box-shadow: 0 0 0 3px rgba(55,96,255,0.1);
}

.tts-form-input::placeholder { color: rgba(255,255,255,0.25); }

textarea.tts-form-input {
    min-height: 130px;
    resize: vertical;
    font-family: inherit;
}

.tts-form-submit {
    width: 100%;
    padding: 0.85rem;
    background: linear-gradient(135deg, #3760FF 0%, #944DF6 100%);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.2s;
}

.tts-form-submit:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* ============================================================
   KEYWORD PILLS (carousel)
   ============================================================ */
.kw-pill {
    padding: 0.45rem 1.1rem;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.09);
    border-radius: 100px;
    font-size: 0.825rem;
    color: rgba(255,255,255,0.65);
    cursor: pointer;
    white-space: nowrap;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.kw-pill:hover {
    border-color: rgba(55,96,255,0.5);
    color: #fff;
    background: rgba(55,96,255,0.08);
}

/* ============================================================
   MODAL
   ============================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    z-index: 1000;
    display: none;
}

.modal-overlay.active { display: block; }

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: 90%;
    max-width: 680px;
    max-height: 80vh;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px;
    z-index: 1001;
    display: none;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.2s, transform 0.2s;
}

.modal.active {
    display: flex;
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.07);
}

.modal-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #ffffff;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.5);
    cursor: pointer;
    padding: 4px;
    line-height: 1;
    transition: color 0.2s;
}

.modal-close:hover { color: #fff; }
.modal-close svg { width: 20px; height: 20px; fill: currentColor; display: block; }

.modal-body {
    overflow-y: auto;
    padding: 1.5rem;
    color: rgba(255,255,255,0.75);
    font-size: 0.9rem;
    line-height: 1.7;
}

.modal-body h1, .modal-body h2, .modal-body h3 { color: #fff; }
.modal-body a { color: #3760FF; }

/* ============================================================
   SECTION LABEL (inline label above section title)
   ============================================================ */
.tts-inline-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* ============================================================
   CAROUSEL (kw-carousel rows)
   ============================================================ */
.carousel-section {
    padding: 40px 0;
    background: #0d0d0d;
    overflow: hidden;
}

.carousel-wrapper { overflow: hidden; }

.carousel-row {
    display: flex;
    gap: 0.75rem;
    animation: scrollLeft var(--carousel-speed-row1, 30s) linear infinite;
    width: max-content;
    margin-bottom: 0.75rem;
}

.carousel-row.reverse { animation: scrollRight var(--carousel-speed-row2, 35s) linear infinite; }
.carousel-row.slow { animation: scrollLeft var(--carousel-speed-row3, 40s) linear infinite; }

@keyframes scrollLeft {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@keyframes scrollRight {
    from { transform: translateX(-50%); }
    to { transform: translateX(0); }
}

.carousel-triple { display: flex; flex-direction: column; gap: 0; }

.carousel-static {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

/* ============================================================
   SEO CONTENT
   ============================================================ */
.seo-content {
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 14px;
    padding: 2rem 2.5rem;
}

.seo-content p {
    color: rgba(255,255,255,0.6);
    line-height: 1.75;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.seo-content p:last-child { margin-bottom: 0; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .tts-features-grid,
    .tts-articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .tts-cat-grid-5 {
        grid-template-columns: repeat(2, 1fr);
    }
    .tts-article-layout {
        grid-template-columns: 1fr;
    }
    .tts-tags-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .mobile-menu-toggle { display: flex; }
    .nav-main { display: none; }
    .header-cta { display: none; }

    .tts-hero { min-height: unset; padding: 60px 0 50px; }
    .tts-hero h1 { font-size: 2rem; }
    .tts-hero-stats { gap: 1.5rem; }

    .tts-section { padding: 50px 0; }
    .tts-cat-grid { grid-template-columns: 1fr; max-width: 100%; }
    .tts-cat-grid-5 { grid-template-columns: 1fr; }
    .tts-features-grid { grid-template-columns: 1fr; }
    .tts-articles-grid { grid-template-columns: 1fr; }
    .tts-contact-grid { grid-template-columns: 1fr; }
    .tts-tags-grid { grid-template-columns: repeat(2, 1fr); }

    .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
    .footer-bottom { flex-direction: column; gap: 0.5rem; }

    .tts-article-layout { grid-template-columns: 1fr; }

    .tts-section-title { font-size: 1.6rem; }
    .header-inner { padding: 0 1rem; }
}

@media (max-width: 480px) {
    .tts-hero h1 { font-size: 1.65rem; }
    .tts-hero-btns { flex-direction: column; align-items: stretch; }
    .tts-hero-btns a { text-align: center; justify-content: center; }
    .tts-hero-stats { gap: 1rem; }
    .tts-hero-stat-num { font-size: 1.25rem; }
    .tts-tags-grid { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   ARTICLE CONTENT TEXT OVERRIDES
   Force white text for all article body content
   ============================================================ */
.tts-article-content .article-content,
.tts-article-content .article-content * {
    color: rgba(255,255,255,0.85) !important;
}

.tts-article-content .article-content h1,
.tts-article-content .article-content h2,
.tts-article-content .article-content h3,
.tts-article-content .article-content h4,
.tts-article-content .article-content h5,
.tts-article-content .article-content h6 {
    color: #ffffff !important;
}

.tts-article-content .article-content a {
    color: #3760FF !important;
}

.tts-article-content .article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1rem 0;
}

/* Prevent old hero/decor styles from appearing */
.page-decor { display: none !important; }

/* Main content spacing reset for dark theme */
.main { padding-top: 0; padding-bottom: 0; }

/* ============================================================
   MOBILE OVERFLOW FIXES
   ============================================================ */
body { overflow-x: hidden; }
.page-wrapper { overflow-x: hidden; }

/* Hero buttons - always stack on small screens */
@media (max-width: 600px) {
    .tts-hero-btns {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
    }
    .tts-hero-btns a {
        justify-content: center;
        text-align: center;
    }
    /* Stats - 2 per row on mobile */
    .tts-hero-stats {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1.25rem;
        text-align: center;
    }
    .tts-hero-stat {
        align-items: center;
    }
    /* Hero title */
    .tts-hero h1 {
        font-size: clamp(1.6rem, 8vw, 2.2rem);
    }
}

/* Very small screens - ensure no overflow */
@media (max-width: 430px) {
    .tts-hero h1 {
        font-size: 1.5rem;
        word-break: break-word;
        overflow-wrap: break-word;
    }
    .tts-hero-subtitle {
        font-size: 0.875rem;
    }
    .tts-hero-badge {
        font-size: 0.7rem;
        padding: 0.35rem 0.75rem;
    }
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    .tts-hero-stats {
        gap: 0.75rem;
    }
    .tts-hero-stat-num {
        font-size: 1.2rem;
    }
    .tts-hero-stat-label {
        font-size: 0.65rem;
        letter-spacing: 0.04em;
    }
}

/* Stat labels - allow wrapping, no overflow */
.tts-hero-stat-label {
    word-break: break-word;
    overflow-wrap: break-word;
    max-width: 100%;
}

/* Stats separator hidden on mobile */
@media (max-width: 600px) {
    .tts-hero-stats {
        border-top: 1px solid rgba(255,255,255,0.08);
        padding-top: 1.5rem;
        width: 100%;
    }
    .tts-hero-stat-label {
        font-size: 0.6rem;
        letter-spacing: 0.02em;
    }
}

/* Ensure hero text never overflows on narrow screens */
@media (max-width: 430px) {
    .tts-hero-inner.container {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }
    .tts-hero h1 {
        font-size: 1.45rem;
        max-width: 100%;
        padding: 0 0.25rem;
    }
    .tts-hero-subtitle {
        padding: 0 0.25rem;
        font-size: 0.85rem;
    }
    .tts-hero-badge {
        max-width: calc(100% - 2rem);
        white-space: normal;
        text-align: center;
    }
}
