/* ==========================================================================
   TERNOVA TECHNOLOGIES — DESIGN SYSTEM & STYLESHEET
   Monochrome Architecture: Deep Obsidian Black, Slate Grays, Crisp White
   ========================================================================== */

:root {
  /* Surface Colors */
  --bg-deep: #07080b;
  --bg-main: #0b0d12;
  --bg-surface: #11141b;
  --bg-card: rgba(18, 22, 31, 0.75);
  --bg-card-hover: rgba(26, 31, 44, 0.85);
  --bg-glass: rgba(255, 255, 255, 0.03);
  --bg-glass-active: rgba(255, 255, 255, 0.08);

  /* Borders & Dividers */
  --border-ultra-subtle: rgba(255, 255, 255, 0.05);
  --border-subtle: rgba(255, 255, 255, 0.1);
  --border-medium: rgba(255, 255, 255, 0.2);
  --border-high: rgba(255, 255, 255, 0.4);

  /* Typography / Monochromatic Scale */
  --text-pure: #ffffff;
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #8492a6;
  --text-faint: #4b5563;

  /* Accent & Status (Monochromatic with functional accents) */
  --accent-white: #ffffff;
  --accent-light-gray: #e2e8f0;
  --accent-gray: #94a3b8;
  --accent-dark-gray: #334155;
  --live-emerald: #10b981;
  --live-emerald-glow: rgba(16, 185, 129, 0.2);
  --soon-amber: #eab308;
  --soon-amber-glow: rgba(234, 179, 8, 0.2);

  /* Elevation Shadows */
  --shadow-subtle: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-card: 0 12px 35px -10px rgba(0, 0, 0, 0.6), 0 0 0 1px var(--border-subtle);
  --shadow-card-hover: 0 20px 45px -10px rgba(0, 0, 0, 0.8), 0 0 0 1px var(--border-medium);
  --shadow-glow: 0 0 35px rgba(255, 255, 255, 0.07);

  /* Radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-pill: 9999px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Inter", "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg-deep);
  color: var(--text-secondary);
  line-height: 1.65;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Background Atmospheric Grid & Radial Glow */
.bg-ambient {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.05) 0%, transparent 60%),
    radial-gradient(circle at 10% 50%, rgba(255, 255, 255, 0.02) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(255, 255, 255, 0.02) 0%, transparent 40%);
}

.bg-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-size: 40px 40px;
  background-image: 
    linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  mask-image: radial-gradient(ellipse at center, black 40%, transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 85%);
}

/* Content Container wrapper */
.page-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container-narrow {
  max-width: 860px;
}

.container-wide {
  max-width: 1360px;
}

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-pure);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.025em;
}

h1 { font-size: clamp(2.35rem, 5vw, 3.8rem); font-weight: 800; letter-spacing: -0.035em; }
h2 { font-size: clamp(1.85rem, 3.5vw, 2.6rem); font-weight: 750; letter-spacing: -0.03em; }
h3 { font-size: clamp(1.35rem, 2.5vw, 1.75rem); }
h4 { font-size: 1.2rem; }

p {
  margin-bottom: 1.25rem;
  color: var(--text-secondary);
}

p.lead {
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 740px;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast), opacity var(--transition-fast);
}

.text-white { color: var(--text-pure) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-center { text-align: center; }
.text-gradient {
  background: linear-gradient(180deg, #FFFFFF 30%, #8892a4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ==========================================================================
   NAVIGATION BAR
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 13, 18, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--transition-normal);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
}

.brand-link img {
  height: 38px;
  width: auto;
  display: block;
}

.brand-title {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--text-pure);
  line-height: 1.1;
}

.brand-tagline {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-item a {
  color: var(--text-muted);
  font-size: 0.925rem;
  font-weight: 500;
  padding: 0.4rem 0.6rem;
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background var(--transition-fast);
}

.nav-item a:hover,
.nav-item.active a {
  color: var(--text-pure);
}

.nav-item.active a {
  font-weight: 600;
  background: rgba(255, 255, 255, 0.05);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.mobile-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-pure);
  padding: 0.5rem;
  border-radius: var(--radius-md);
  cursor: pointer;
}

/* ==========================================================================
   BUTTONS & BADGES
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  font-size: 0.925rem;
  font-weight: 600;
  padding: 0.65rem 1.35rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
  white-space: nowrap;
  text-decoration: none;
}

.btn-sm {
  padding: 0.45rem 0.95rem;
  font-size: 0.825rem;
}

.btn-lg {
  padding: 0.9rem 1.85rem;
  font-size: 1rem;
  border-radius: var(--radius-lg);
}

.btn-primary {
  background: #ffffff;
  color: #07080b;
  border-color: #ffffff;
  box-shadow: 0 4px 14px rgba(255, 255, 255, 0.12);
}

.btn-primary:hover {
  background: #e2e8f0;
  border-color: #e2e8f0;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(255, 255, 255, 0.2);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-pure);
  border-color: var(--border-medium);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--border-high);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-pure);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-pill);
  font-size: 0.775rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.badge-live {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.08);
  color: #34d399;
}

.badge-live .dot {
  width: 7px;
  height: 7px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 8px #10b981;
  animation: pulse-dot 2s infinite ease-in-out;
}

.badge-soon {
  border-color: rgba(234, 179, 8, 0.35);
  background: rgba(234, 179, 8, 0.08);
  color: #facc15;
}

.badge-soon .dot {
  width: 7px;
  height: 7px;
  background: #eab308;
  border-radius: 50%;
  box-shadow: 0 0 8px #eab308;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* ==========================================================================
   CARDS & SECTIONS
   ========================================================================== */
section {
  padding: 5rem 0;
  position: relative;
}

.section-hero {
  padding: 5.5rem 0 4rem;
  text-align: center;
}

.section-header {
  margin-bottom: 3.5rem;
}

.section-tag {
  margin-bottom: 1rem;
}

.card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-card);
}

.card:hover {
  border-color: var(--border-medium);
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
}

/* Grids */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

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

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

/* ==========================================================================
   PRODUCT SHOWCASE
   ========================================================================== */
.product-card {
  position: relative;
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(22, 27, 38, 0.85) 0%, rgba(12, 15, 22, 0.95) 100%);
  border: 1px solid var(--border-subtle);
  padding: 2.75rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  transition: all var(--transition-normal);
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.product-card:hover {
  border-color: var(--border-high);
  transform: translateY(-4px);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.7);
}

.product-card:hover::before {
  opacity: 1;
}

.product-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  gap: 1rem;
}

.product-identity {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.product-icon-wrap {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.product-icon-wrap img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.product-meta-name {
  font-size: 1.6rem;
  font-weight: 750;
  color: var(--text-pure);
  line-height: 1.1;
}

.product-entity-notice {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.product-desc {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1.75rem;
}

.product-features-list {
  list-style: none;
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.product-feature-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.product-feature-item svg {
  color: var(--text-pure);
  flex-shrink: 0;
}

.product-footer {
  margin-top: auto;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-ultra-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tech-pill {
  font-size: 0.75rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  border: 1px solid var(--border-ultra-subtle);
}

/* ==========================================================================
   FEATURE / STAT METRICS
   ========================================================================== */
.stat-box {
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  text-align: center;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--text-pure);
  letter-spacing: -0.03em;
  margin-bottom: 0.25rem;
  line-height: 1.1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ==========================================================================
   LEADERSHIP PROFILE (CEO / CTO)
   ========================================================================== */
.profile-card {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 2.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  align-items: center;
}

.profile-avatar-wrap {
  width: 100%;
  aspect-ratio: 1/1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-medium);
  background: #141720;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.profile-initials {
  font-size: 3.5rem;
  font-weight: 800;
  color: var(--text-pure);
  letter-spacing: -0.05em;
}

.profile-info h3 {
  font-size: 1.75rem;
  margin-bottom: 0.25rem;
}

.profile-role {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.profile-bio {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.profile-socials {
  display: flex;
  gap: 1rem;
  align-items: center;
}

/* ==========================================================================
   FORMS & INPUTS
   ========================================================================== */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.form-control {
  width: 100%;
  background: rgba(14, 17, 24, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  color: var(--text-pure);
  font-family: inherit;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: #ffffff;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.15);
}

.form-control::placeholder {
  color: var(--text-faint);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* ==========================================================================
   DEPARTMENT CONTACT CARDS
   ========================================================================== */
.dept-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: all var(--transition-fast);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  text-decoration: none;
}

.dept-card:hover {
  border-color: var(--border-high);
  transform: translateY(-2px);
  background: var(--bg-card-hover);
}

.dept-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dept-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-pure);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dept-email {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-pure);
  word-break: break-all;
}

.dept-desc {
  font-size: 0.825rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ==========================================================================
   VIPRA / COMING SOON SPECIAL
   ========================================================================== */
.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  max-width: 500px;
  margin: 2.5rem auto;
}

.countdown-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.25rem 0.75rem;
  text-align: center;
}

.countdown-val {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--text-pure);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.countdown-lbl {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  margin-top: auto;
  background: #060709;
  border-top: 1px solid var(--border-subtle);
  padding: 4.5rem 0 2.5rem;
  position: relative;
  z-index: 10;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-top: 1rem;
  max-width: 320px;
}

.footer-heading {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-pure);
  margin-bottom: 1.25rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--text-pure);
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border-ultra-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--text-faint);
}

.footer-copy strong {
  color: var(--text-secondary);
}

/* Toast Component */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: #181b24;
  color: #ffffff;
  border: 1px solid var(--border-high);
  border-radius: var(--radius-md);
  padding: 0.9rem 1.4rem;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  z-index: 1000;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: all 0.3s ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .profile-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .profile-avatar-wrap {
    max-width: 180px;
    margin: 0 auto;
  }
  .profile-socials {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(11, 13, 18, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-medium);
    flex-direction: column;
    padding: 2rem;
    gap: 1.25rem;
    align-items: flex-start;
    display: none;
  }
  .nav-menu.open {
    display: flex;
  }
  .mobile-toggle {
    display: block;
  }
  .nav-actions {
    display: none;
  }
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
  .footer-top {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
  .product-card {
    padding: 1.75rem;
  }
  .countdown-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
