/* =============================================================
   The Complex Bytes — Theme CSS v1.1.0
   Brand: #0A1628 navy | #4FC3F7 electric blue | #F5A623 amber
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700;800&family=Barlow+Condensed:wght@600;700;800&display=swap');

:root {
  --navy:       #0A1628;
  --navy-mid:   #0d1f38;
  --navy-light: #1e3a5f;
  --blue:       #4FC3F7;
  --blue-dark:  #378ADD;
  --amber:      #F5A623;
  --white:      #ffffff;
  --gray-100:   #f1f5f9;
  --gray-200:   #e2e8f0;
  --gray-400:   #94a3b8;
  --gray-600:   #475569;
  --gray-700:   #334155;
  --text-dark:  #0f172a;
  --font-main:  'Barlow', sans-serif;
  --font-cond:  'Barlow Condensed', sans-serif;
}

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

html { font-size: 16px; }

body {
  font-family: var(--font-main);
  background: var(--gray-100);
  color: var(--text-dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }

/* =============================================================
   MASTHEAD BANNER
   ============================================================= */

.tcb-masthead {
  position: relative;
  width: 100%;
  height: 108px;
  overflow: hidden;
  background: var(--navy);
}

.tcb-masthead-bg {
  position: absolute;
  inset: 0;
  background-image: url('../images/tcb-banner.png');
  background-size: cover;
  background-position: center;
  z-index: 0;
}

.tcb-masthead-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(10,22,40,0.72) 0%,
    rgba(10,22,40,0.0) 35%,
    rgba(10,22,40,0.0) 55%,
    rgba(10,22,40,0.82) 100%
  );
  z-index: 1;
}

.tcb-masthead-fade {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 48px;
  background: linear-gradient(to bottom, transparent, var(--navy));
  z-index: 2;
}

.tcb-masthead-inner {
  position: relative;
  z-index: 3;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.tcb-masthead-tagline {
  font-family: var(--font-cond);
  font-size: 20px;
  font-weight: 800;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.15;
  text-shadow: 0 2px 8px rgba(0,0,0,0.5);
  max-width: 220px;
}

.tcb-masthead-right {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.tcb-masthead-logo {
  height: 52px;
  width: auto;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.4));
}

.tcb-subscribe-btn {
  background: var(--amber);
  color: var(--navy);
  font-family: var(--font-main);
  font-size: 13px;
  font-weight: 700;
  padding: 9px 20px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  transition: background 0.15s ease;
  white-space: nowrap;
}

.tcb-subscribe-btn:hover { background: #e8941a; }

/* =============================================================
   HERO SECTION
   ============================================================= */

.tcb-hero {
  background: var(--navy);
  padding: 2.5rem 2rem 3rem;
  position: relative;
  overflow: hidden;
}

.tcb-hero-circuits {
  position: absolute;
  inset: 0;
  opacity: 0.07;
  pointer-events: none;
}

.tcb-hero-fade-bottom {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 48px;
  background: linear-gradient(to bottom, transparent, var(--gray-100));
  z-index: 1;
}

.tcb-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  max-width: 600px;
}

.tcb-hero-h1 {
  font-family: var(--font-cond);
  font-size: 48px;
  font-weight: 800;
  color: var(--white);
  line-height: 1.05;
  letter-spacing: 0.01em;
  margin-bottom: 0;
}

.tcb-hero-h2 {
  font-family: var(--font-cond);
  font-size: 48px;
  font-weight: 800;
  color: var(--blue);
  line-height: 1.05;
  letter-spacing: 0.01em;
  margin-bottom: 1.25rem;
}

.tcb-hero-sub {
  color: var(--gray-400);
  font-size: 15px;
  line-height: 1.65;
  margin-bottom: 1.75rem;
  max-width: 440px;
}

.tcb-hero-cta {
  display: inline-block;
  background: var(--amber);
  color: var(--navy);
  font-size: 14px;
  font-weight: 700;
  padding: 11px 26px;
  border-radius: 4px;
  letter-spacing: 0.04em;
  transition: background 0.15s ease;
}

.tcb-hero-cta:hover { background: #e8941a; }

/* =============================================================
   CATEGORY NAV BAR
   ============================================================= */

.tcb-cat-bar {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  position: sticky;
  top: 0;
  z-index: 100;
}

.tcb-cat-bar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.tcb-cat-bar-inner::-webkit-scrollbar { display: none; }

.tcb-cat-link {
  color: var(--gray-600);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 13px 16px;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

.tcb-cat-link:hover,
.tcb-cat-link.active {
  color: var(--navy);
  border-bottom-color: var(--blue);
}

/* =============================================================
   MAIN CONTENT AREA
   ============================================================= */

.tcb-content {
  max-width: 960px;
  margin: 0 auto;
  padding: 1.75rem 1.5rem;
}

/* BRIEFING STRIP */
.tcb-briefing {
  background: var(--navy-mid);
  border: 0.5px solid var(--navy-light);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.tcb-briefing-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.tcb-briefing-dot {
  width: 8px;
  height: 8px;
  background: var(--blue);
  border-radius: 50%;
  flex-shrink: 0;
}

.tcb-briefing-label {
  color: var(--blue);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: block;
  margin-bottom: 3px;
}

.tcb-briefing-title {
  color: #e2e8f0;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tcb-briefing-cta {
  color: var(--amber);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity 0.15s;
}

.tcb-briefing-cta:hover { opacity: 0.8; }

/* FEATURED GRID */
.tcb-featured {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 1.75rem;
}

.tcb-card {
  background: var(--white);
  border: 0.5px solid var(--gray-200);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.tcb-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(10,22,40,0.10);
}

.tcb-card-thumb {
  height: 150px;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: 1rem;
}

.tcb-card-thumb--amber {
  background: linear-gradient(135deg, #1a1228 0%, #2d1f4a 100%);
}

.tcb-card-thumb svg {
  position: absolute;
  inset: 0;
  opacity: 0.18;
  width: 100%;
  height: 100%;
}

.tcb-card-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
}

.tcb-card-cat {
  position: relative;
  z-index: 1;
  display: inline-block;
  background: var(--blue);
  color: var(--navy);
  font-size: 9px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 3px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tcb-card-cat--amber { background: var(--amber); }
.tcb-card-cat--green { background: #34d399; }

.tcb-card-body { padding: 1rem 1.1rem 1.1rem; }

.tcb-card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.4;
  margin-bottom: 0.4rem;
}

.tcb-card-meta {
  font-size: 11px;
  color: var(--gray-400);
  margin-bottom: 0.5rem;
}

.tcb-card-excerpt {
  font-size: 13px;
  color: var(--gray-600);
  line-height: 1.55;
}

/* POST GRID */
.tcb-section-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray-400);
  margin-bottom: 0.875rem;
  padding-bottom: 0.625rem;
  border-bottom: 0.5px solid var(--gray-200);
}

.tcb-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.75rem;
}

.tcb-card-sm {
  background: var(--white);
  border: 0.5px solid var(--gray-200);
  border-radius: 10px;
  padding: 1rem 1.1rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.tcb-card-sm:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(10,22,40,0.08);
}

.tcb-card-sm-cat {
  font-size: 9px;
  font-weight: 800;
  color: var(--blue);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  display: block;
}

.tcb-card-sm-cat--amber { color: #d97706; }
.tcb-card-sm-cat--green { color: #059669; }

.tcb-card-sm-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.4;
  margin-bottom: 0.4rem;
}

.tcb-card-sm-meta { font-size: 10px; color: var(--gray-400); }

/* NEWSLETTER */
.tcb-newsletter {
  background: var(--navy);
  border-radius: 10px;
  padding: 2rem;
  text-align: center;
  margin-bottom: 1.75rem;
}

.tcb-newsletter h3 {
  font-family: var(--font-cond);
  font-size: 22px;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 0.5rem;
  letter-spacing: 0.02em;
}

.tcb-newsletter p {
  color: var(--gray-400);
  font-size: 13px;
  margin-bottom: 1.25rem;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.tcb-newsletter-form {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
}

.tcb-newsletter-form input {
  background: var(--navy-light);
  border: 0.5px solid #2d5a8e;
  color: var(--white);
  font-family: var(--font-main);
  font-size: 13px;
  padding: 10px 16px;
  border-radius: 4px;
  width: 260px;
  outline: none;
}

.tcb-newsletter-form input::placeholder { color: var(--gray-400); }
.tcb-newsletter-form input:focus { border-color: var(--blue); }

.tcb-newsletter-form button {
  background: var(--amber);
  color: var(--navy);
  font-family: var(--font-main);
  font-size: 13px;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: background 0.15s;
}

.tcb-newsletter-form button:hover { background: #e8941a; }

/* =============================================================
   FOOTER
   ============================================================= */

.tcb-footer {
  background: var(--navy);
  border-top: 0.5px solid var(--navy-light);
  padding: 1.5rem 2rem;
}

.tcb-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.tcb-footer-copy {
  color: var(--gray-600);
  font-size: 12px;
}

.tcb-footer-links {
  display: flex;
  gap: 1.5rem;
}

.tcb-footer-links a {
  color: var(--gray-600);
  font-size: 12px;
  transition: color 0.15s;
}

.tcb-footer-links a:hover { color: var(--blue); }

/* =============================================================
   POST / ARTICLE PAGE
   ============================================================= */

.tcb-post-header {
  background: var(--navy);
  padding: 3rem 2rem 2.5rem;
}

.tcb-post-header-inner {
  max-width: 720px;
  margin: 0 auto;
}

.tcb-post-cat-badge {
  display: inline-block;
  background: var(--blue);
  color: var(--navy);
  font-size: 10px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 3px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.tcb-post-title {
  font-family: var(--font-cond);
  font-size: 36px;
  font-weight: 800;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 1rem;
  letter-spacing: 0.01em;
}

.tcb-post-meta {
  color: var(--gray-400);
  font-size: 13px;
}

.tcb-post-body {
  max-width: 720px;
  margin: 2.5rem auto;
  padding: 0 1.5rem;
  font-size: 16px;
  line-height: 1.75;
  color: var(--gray-700);
}

.tcb-post-body h2 {
  font-family: var(--font-cond);
  font-size: 26px;
  font-weight: 700;
  color: var(--text-dark);
  margin: 2rem 0 0.875rem;
  letter-spacing: 0.01em;
}

.tcb-post-body h3 {
  font-size: 19px;
  font-weight: 700;
  color: var(--text-dark);
  margin: 1.5rem 0 0.625rem;
}

.tcb-post-body p { margin-bottom: 1.25rem; }

.tcb-post-body a { color: var(--blue-dark); text-decoration: underline; }

.tcb-post-body pre,
.tcb-post-body code {
  font-family: 'Courier New', monospace;
  background: var(--navy);
  color: var(--blue);
  border-radius: 6px;
}

.tcb-post-body pre {
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.6;
}

.tcb-post-body code {
  padding: 2px 6px;
  font-size: 14px;
}

.tcb-post-body blockquote {
  border-left: 3px solid var(--blue);
  padding: 0.75rem 1.25rem;
  margin: 1.5rem 0;
  background: #f8fafc;
  color: var(--gray-700);
  font-style: italic;
}

/* =============================================================
   GHOST KOENIG CARD REQUIRED CLASSES
   ============================================================= */

.kg-width-wide {
  position: relative;
  width: 85vw;
  min-width: 100%;
  margin: 1.5rem auto;
}

.kg-width-full {
  position: relative;
  width: 100vw;
  margin: 1.5rem calc(50% - 50vw);
}

.kg-image { max-width: 100%; height: auto; }

/* =============================================================
   RESPONSIVE
   ============================================================= */

@media (max-width: 768px) {
  .tcb-masthead { height: 80px; }
  .tcb-masthead-tagline { font-size: 15px; max-width: 160px; }
  .tcb-masthead-logo { height: 38px; }
  .tcb-hero-h1, .tcb-hero-h2 { font-size: 34px; }
  .tcb-featured { grid-template-columns: 1fr; }
  .tcb-grid { grid-template-columns: 1fr 1fr; }
  .tcb-briefing { flex-direction: column; align-items: flex-start; }
  .tcb-briefing-title { white-space: normal; }
}

@media (max-width: 480px) {
  .tcb-grid { grid-template-columns: 1fr; }
  .tcb-masthead-tagline { font-size: 13px; }
  .tcb-hero-h1, .tcb-hero-h2 { font-size: 28px; }
}
