/* ============================================
   T6 TECH — Main Stylesheet
   Brand Kit Compliant | Dark-First Design
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
  /* Colors */
  --t6-dark: #111418;
  --t6-dark-alt: #181C22;
  --t6-slate: #1E2228;
  --t6-gunmetal: #2A2F38;
  --t6-steel: #3D4450;
  --t6-silver: #C9CCD1;
  --t6-silver-dim: #8A8F96;
  --t6-ice: #E5E7EA;
  --t6-white: #FFFFFF;
  --t6-blue: #2456FF;
  --t6-blue-dim: #6B8CFF;
  --t6-blue-glow: rgba(36, 86, 255, 0.15);
  --t6-gradient: linear-gradient(135deg, #2456FF 0%, #6B8CFF 100%);
  --t6-metallic: linear-gradient(135deg, #BFC3C8 0%, #E5E7EA 100%);
  --t6-error: #FF3B3B;
  --t6-success: #00D68F;

  /* Typography */
  --t6-font-display: 'Montserrat', sans-serif;
  --t6-font-body: 'Poppins', sans-serif;
  --t6-font-mono: 'IBM Plex Mono', monospace;

  /* Type Scale */
  --t6-text-display: 44px;
  --t6-text-h1: 30px;
  --t6-text-h2: 22px;
  --t6-text-h3: 17px;
  --t6-text-body: 15px;
  --t6-text-small: 13px;
  --t6-text-overline: 10px;

  /* Spacing (base 4px) */
  --t6-space-xs: 4px;
  --t6-space-sm: 8px;
  --t6-space-md: 16px;
  --t6-space-lg: 24px;
  --t6-space-xl: 32px;
  --t6-space-2xl: 48px;
  --t6-space-3xl: 64px;

  /* Borders & Radius */
  --t6-radius: 8px;
  --t6-radius-sm: 6px;
  --t6-radius-lg: 14px;

  /* Shadows */
  --t6-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --t6-shadow-lg: 0 8px 28px rgba(0, 0, 0, 0.15);
  --t6-shadow-card: 0 4px 16px rgba(0, 0, 0, 0.12);

  /* Transitions */
  --t6-transition: 200ms ease;
  --t6-transition-slow: 300ms ease;

  /* Layout */
  --t6-max-width: 1200px;
  --t6-content-width: 960px;
  --t6-header-height: 72px;
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--t6-font-body);
  font-size: var(--t6-text-body);
  font-weight: 300;
  line-height: 1.7;
  color: var(--t6-silver);
  background-color: var(--t6-dark);
  overflow-x: hidden;
}

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

a {
  color: var(--t6-blue);
  text-decoration: none;
  transition: color var(--t6-transition);
}

a:hover {
  color: var(--t6-blue-dim);
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--t6-font-display);
  color: var(--t6-white);
  line-height: 1.2;
  letter-spacing: -0.5px;
}

h1 { font-size: var(--t6-text-h1); font-weight: 600; }
h2 { font-size: var(--t6-text-h2); font-weight: 600; }
h3 { font-size: var(--t6-text-h3); font-weight: 500; }

.t6-display {
  font-size: var(--t6-text-display);
  font-weight: 700;
  letter-spacing: -2px;
  line-height: 1.1;
}

.t6-overline {
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-overline);
  font-weight: 600;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--t6-blue);
}

.t6-mono {
  font-family: var(--t6-font-mono);
  font-weight: 400;
}

.t6-gradient-text {
  background: var(--t6-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Layout --- */
.t6-container {
  max-width: var(--t6-max-width);
  margin: 0 auto;
  padding: 0 var(--t6-space-lg);
}

.t6-container--narrow {
  max-width: var(--t6-content-width);
}

.t6-section {
  padding: 80px 0;
  position: relative;
}

.t6-section--dark {
  background-color: var(--t6-dark);
}

.t6-section--dark-alt {
  background-color: var(--t6-dark-alt);
}

.t6-section--light {
  background-color: var(--t6-white);
  color: var(--t6-steel);
}

.t6-section--light h1,
.t6-section--light h2,
.t6-section--light h3 {
  color: var(--t6-dark);
}

.t6-section__header {
  margin-bottom: var(--t6-space-2xl);
}

.t6-section__subtitle {
  font-size: var(--t6-text-small);
  font-weight: 300;
  color: var(--t6-silver-dim);
  margin-top: var(--t6-space-sm);
  line-height: 1.6;
}

/* --- Grid System --- */
.t6-grid {
  display: grid;
  gap: var(--t6-space-lg);
}

.t6-grid--2 { grid-template-columns: repeat(2, 1fr); }
.t6-grid--3 { grid-template-columns: repeat(3, 1fr); }
.t6-grid--4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
  .t6-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .t6-grid--3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .t6-grid--4,
  .t6-grid--3,
  .t6-grid--2 { grid-template-columns: 1fr; }

  .t6-section { padding: 56px 0; }
  .t6-container { padding: 0 var(--t6-space-md); }

  :root {
    --t6-text-display: 32px;
    --t6-text-h1: 24px;
    --t6-text-h2: 20px;
  }
}

/* --- Buttons --- */
.t6-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--t6-space-sm);
  padding: 12px 28px;
  border-radius: var(--t6-radius-sm);
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-small);
  font-weight: 600;
  letter-spacing: 0.5px;
  border: none;
  cursor: pointer;
  transition: all var(--t6-transition);
  text-decoration: none;
  line-height: 1;
}

.t6-btn--primary {
  background: var(--t6-gradient);
  color: var(--t6-white);
  box-shadow: 0 4px 14px rgba(36, 86, 255, 0.3);
}

.t6-btn--primary:hover {
  color: var(--t6-white);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(36, 86, 255, 0.4);
}

.t6-btn--outline {
  background: transparent;
  color: var(--t6-silver);
  border: 1px solid var(--t6-gunmetal);
}

.t6-btn--outline:hover {
  border-color: var(--t6-blue);
  color: var(--t6-blue);
}

.t6-btn--small {
  padding: 8px 18px;
  font-size: 11px;
}

/* --- Cards --- */
.t6-card {
  background: var(--t6-slate);
  border: 1px solid var(--t6-gunmetal);
  border-radius: var(--t6-radius-lg);
  padding: var(--t6-space-lg);
  transition: all var(--t6-transition);
}

.t6-card:hover {
  transform: translateY(-2px);
  border-color: var(--t6-blue);
  box-shadow: 0 0 20px var(--t6-blue-glow);
}

.t6-card--light {
  background: var(--t6-white);
  border-color: var(--t6-ice);
}

.t6-card--light:hover {
  border-color: var(--t6-blue);
  box-shadow: 0 0 20px var(--t6-blue-glow);
}

.t6-card__title {
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-body);
  font-weight: 600;
  margin-bottom: var(--t6-space-sm);
}

.t6-card__text {
  font-size: 12px;
  font-weight: 300;
  color: var(--t6-silver-dim);
  line-height: 1.6;
}

/* --- Tags --- */
.t6-tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.5px;
  background: rgba(201, 204, 209, 0.12);
  color: var(--t6-silver-dim);
  border: 1px solid transparent;
}

.t6-tag--active {
  background: var(--t6-blue-glow);
  color: var(--t6-blue);
  border-color: rgba(36, 86, 255, 0.2);
}

/* --- Accent Bar --- */
.t6-accent-bar {
  width: 4px;
  background: var(--t6-gradient);
  border-radius: 2px;
}

.t6-accent-bar--horizontal {
  width: 48px;
  height: 4px;
}

.t6-divider {
  height: 1px;
  background: var(--t6-gunmetal);
  border: none;
}

/* --- Hex Pattern Background --- */
.t6-hex-pattern {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.t6-hex-pattern svg {
  width: 100%;
  height: 100%;
}

/* --- Header --- */
.t6-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--t6-header-height);
  background: rgba(17, 20, 24, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--t6-gunmetal);
  z-index: 1000;
  transition: background var(--t6-transition);
}

.t6-header__inner {
  max-width: var(--t6-max-width);
  margin: 0 auto;
  padding: 0 var(--t6-space-lg);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.t6-header__logo {
  flex-shrink: 0;
}

.t6-header__logo a {
  display: flex;
  align-items: center;
}

.t6-header__nav {
  display: flex;
  align-items: center;
  gap: var(--t6-space-xl);
}

.t6-header__menu {
  display: flex;
  align-items: center;
  gap: var(--t6-space-lg);
  list-style: none;
}

.t6-header__menu a {
  font-family: var(--t6-font-display);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--t6-silver-dim);
  transition: color var(--t6-transition);
  position: relative;
}

.t6-header__menu a:hover,
.t6-header__menu .current-menu-item a {
  color: var(--t6-white);
}

.t6-header__menu .current-menu-item a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--t6-gradient);
  border-radius: 1px;
}

.t6-header__cta {
  flex-shrink: 0;
}

/* Mobile Menu Toggle */
.t6-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--t6-space-sm);
}

.t6-menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--t6-silver);
  margin: 5px 0;
  border-radius: 1px;
  transition: all var(--t6-transition);
}

.t6-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.t6-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.t6-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

@media (max-width: 900px) {
  .t6-menu-toggle {
    display: block !important;
  }

  .t6-header__nav {
    display: flex !important;
    position: fixed !important;
    top: var(--t6-header-height) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: calc(100vh - var(--t6-header-height)) !important;
    background: #0a0c0f !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    justify-content: flex-start !important;
    gap: 0 !important;
    padding: 32px 28px !important;
    margin: 0 !important;
    transform: translateX(100%);
    transition: transform 300ms ease;
    border-top: 1px solid var(--t6-gunmetal);
    overflow-y: auto;
    z-index: 999;
  }

  .t6-header__nav.active {
    transform: translateX(0);
  }

  .t6-header__menu {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    width: 100% !important;
    gap: 8px !important;
    list-style: none;
    padding: 0 !important;
    margin: 0 0 24px 0 !important;
  }

  .t6-header__menu li {
    width: 100%;
    display: block;
  }

  .t6-header__menu a {
    display: block;
    width: 100%;
    font-size: 17px !important;
    letter-spacing: 1.5px;
    color: var(--t6-white) !important;
    padding: 14px 4px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }

  .t6-header__menu .current-menu-item a::after {
    display: none !important;
    content: none !important;
  }

  .t6-header__cta {
    width: 100%;
    margin-top: 8px;
  }

  .t6-header__cta .t6-btn {
    width: 100%;
    text-align: center;
  }
}

/* Mobile: center standard section headers */
@media (max-width: 768px) {
  .t6-section__header {
    text-align: center;
  }
  .t6-section__header p {
    margin-left: auto;
    margin-right: auto;
  }
}

/* Mobile: center the IQ Site hero headline block (page-iq-site template) */
@media (max-width: 900px) {
  body.page-template-page-iq-site .t6-hero__content {
    text-align: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
    max-width: 100% !important;
  }
  body.page-template-page-iq-site .t6-hero__content > div {
    justify-content: center !important;
  }
  body.page-template-page-iq-site .t6-hero__content > div,
  body.page-template-page-iq-site .t6-hero__actions {
    justify-content: center !important;
    align-items: center !important;
  }
  body.page-template-page-iq-site .t6-hero__content .t6-hero__subtitle {
    margin-left: auto !important;
    margin-right: auto !important;
    max-width: 100% !important;
  }
  body.page-template-page-iq-site .t6-hero__content h1,
  body.page-template-page-iq-site .t6-hero__content p,
  body.page-template-page-iq-site .t6-hero__content span {
    text-align: center;
  }
}

/* --- Footer --- */
.t6-footer {
  background: var(--t6-dark);
  border-top: 1px solid var(--t6-gunmetal);
  padding: var(--t6-space-3xl) 0 0;
}

.t6-footer__inner {
  max-width: var(--t6-max-width);
  margin: 0 auto;
  padding: 0 var(--t6-space-lg);
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--t6-space-2xl);
}

.t6-footer__brand p {
  font-size: var(--t6-text-small);
  color: var(--t6-silver-dim);
  margin-top: var(--t6-space-md);
  line-height: 1.6;
  max-width: 320px;
}

.t6-footer__heading {
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-overline);
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--t6-blue);
  margin-bottom: var(--t6-space-lg);
}

.t6-footer__links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--t6-space-sm);
}

.t6-footer__links a {
  font-size: var(--t6-text-small);
  color: var(--t6-silver-dim);
  transition: color var(--t6-transition);
}

.t6-footer__links a:hover {
  color: var(--t6-white);
}

.t6-footer__contact {
  display: flex;
  flex-direction: column;
  gap: var(--t6-space-sm);
  font-size: var(--t6-text-small);
  color: var(--t6-silver-dim);
}

.t6-footer__contact a {
  color: var(--t6-silver-dim);
}

.t6-footer__contact a:hover {
  color: var(--t6-blue);
}

.t6-footer__social {
  display: flex;
  gap: var(--t6-space-md);
  margin-top: var(--t6-space-md);
}

.t6-footer__social a {
  width: 36px;
  height: 36px;
  border-radius: var(--t6-radius-sm);
  border: 1px solid var(--t6-gunmetal);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--t6-silver-dim);
  transition: all var(--t6-transition);
}

.t6-footer__social a:hover {
  border-color: var(--t6-blue);
  color: var(--t6-blue);
}

.t6-footer__bottom {
  margin-top: var(--t6-space-2xl);
  padding: var(--t6-space-lg) 0;
  border-top: 1px solid var(--t6-gunmetal);
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--t6-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--t6-space-lg);
  padding-right: var(--t6-space-lg);
}

.t6-footer__bottom p {
  font-size: 11px;
  color: var(--t6-silver-dim);
}

.t6-footer__bottom a {
  font-size: 11px;
  color: var(--t6-silver-dim);
}

@media (max-width: 768px) {
  .t6-footer__inner {
    grid-template-columns: 1fr;
    gap: var(--t6-space-xl);
  }

  .t6-footer__bottom {
    flex-direction: column;
    gap: var(--t6-space-sm);
    text-align: center;
  }
}

/* --- Hero Sections --- */
.t6-hero {
  position: relative;
  padding: 140px 0 100px;
  overflow: hidden;
  min-height: 70vh;
  display: flex;
  align-items: center;
}

.t6-hero--full {
  min-height: 90vh;
}

.t6-hero__content {
  position: relative;
  z-index: 1;
  max-width: 680px;
}

.t6-hero__title {
  font-size: var(--t6-text-display);
  font-weight: 700;
  letter-spacing: -2px;
  line-height: 1.1;
  margin-bottom: var(--t6-space-md);
}

.t6-hero__subtitle {
  font-size: var(--t6-text-body);
  font-weight: 300;
  color: var(--t6-silver);
  line-height: 1.8;
  margin-bottom: var(--t6-space-xl);
}

.t6-hero__actions {
  display: flex;
  gap: var(--t6-space-md);
  flex-wrap: wrap;
}

@media (max-width: 1024px) {
  .t6-hero--full .t6-container > div {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .t6-hero {
    padding: 120px 0 60px;
    min-height: auto;
  }

  .t6-hero__title {
    font-size: 32px;
  }

  .t6-hero--full .t6-container > div {
    flex-direction: column-reverse;
    text-align: center;
    gap: 32px;
  }

  .t6-hero--full .t6-animate[style*="width: 380px"] {
    width: 260px !important;
    height: 300px !important;
    margin: 0 auto;
  }

  .t6-hero__actions {
    justify-content: center;
  }
}

/* --- Timeline --- */
.t6-timeline {
  position: relative;
  padding-left: var(--t6-space-2xl);
}

.t6-timeline::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--t6-gunmetal);
}

.t6-timeline__item {
  position: relative;
  padding-bottom: var(--t6-space-xl);
}

.t6-timeline__item::before {
  content: '';
  position: absolute;
  left: calc(-1 * var(--t6-space-2xl) + 3px);
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--t6-blue);
  box-shadow: 0 0 0 4px var(--t6-dark), 0 0 0 5px var(--t6-gunmetal);
}

.t6-timeline__year {
  font-family: var(--t6-font-mono);
  font-size: 11px;
  color: var(--t6-blue);
  margin-bottom: var(--t6-space-xs);
}

.t6-timeline__title {
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-body);
  font-weight: 600;
  color: var(--t6-white);
  margin-bottom: var(--t6-space-xs);
}

.t6-timeline__desc {
  font-size: var(--t6-text-small);
  color: var(--t6-silver-dim);
  line-height: 1.6;
}

/* --- Quote Block --- */
.t6-quote {
  position: relative;
  padding: var(--t6-space-xl) var(--t6-space-xl) var(--t6-space-xl) var(--t6-space-2xl);
  border-left: 4px solid;
  border-image: var(--t6-gradient) 1;
}

.t6-quote__text {
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-h3);
  font-weight: 300;
  font-style: italic;
  color: var(--t6-silver);
  line-height: 1.7;
}

.t6-quote__attribution {
  margin-top: var(--t6-space-md);
  font-size: var(--t6-text-small);
  color: var(--t6-silver-dim);
}

/* --- Press Strip --- */
.t6-press-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--t6-space-2xl);
  flex-wrap: wrap;
  opacity: 0.5;
}

.t6-press-strip__item {
  font-family: var(--t6-font-display);
  font-size: var(--t6-text-small);
  font-weight: 500;
  color: var(--t6-silver-dim);
  letter-spacing: 1px;
}

/* --- Scroll Animations --- */
.t6-animate {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.t6-animate.visible {
  opacity: 1;
  transform: translateY(0);
}

.t6-animate--delay-1 { transition-delay: 100ms; }
.t6-animate--delay-2 { transition-delay: 200ms; }
.t6-animate--delay-3 { transition-delay: 300ms; }
.t6-animate--delay-4 { transition-delay: 400ms; }

/* --- Utility --- */
.t6-text-center { text-align: center; }
.t6-text-dim { color: var(--t6-silver-dim); }
.t6-mt-sm { margin-top: var(--t6-space-sm); }
.t6-mt-md { margin-top: var(--t6-space-md); }
.t6-mt-lg { margin-top: var(--t6-space-lg); }
.t6-mt-xl { margin-top: var(--t6-space-xl); }
.t6-mb-md { margin-bottom: var(--t6-space-md); }
.t6-mb-lg { margin-bottom: var(--t6-space-lg); }

/* --- WordPress Specific Resets --- */
.wp-block-post-content { max-width: 100%; }
.entry-content { max-width: 100%; }

/* --- Skip to Content (Accessibility) --- */
.t6-skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--t6-blue);
  color: var(--t6-white);
  padding: var(--t6-space-sm) var(--t6-space-md);
  z-index: 9999;
  transition: top var(--t6-transition);
}

.t6-skip-link:focus {
  top: 0;
}

/* Offset for fixed header */
main {
  padding-top: var(--t6-header-height);
}
