/* ==========================================================================
   CABEX LTD - Modern Corporate Design System: Core & Foundation
   ========================================================================== */

:root {
  /* Brand Primary & Surfaces */
  --bg-dark-deep: #080a0e;
  --bg-dark-base: #0f1218;
  --bg-dark-surface: #151922;
  --bg-dark-card: #1b202c;
  --bg-dark-elevated: #232938;
  
  --bg-light-base: #ffffff;
  --bg-light-subtle: #f8fafc;
  --bg-light-card: #ffffff;
  --bg-light-border: #e2e8f0;

  /* Signature Brand Accents */
  --accent-gold: #FFAA00;
  --accent-gold-hover: #e59900;
  --accent-gold-light: #ffbe33;
  --accent-gold-soft: rgba(255, 170, 0, 0.12);
  --accent-gold-glow: rgba(255, 170, 0, 0.25);
  
  --accent-cyan: #007A99;
  --accent-cyan-hover: #00607a;
  --accent-blue: #0086CD;
  --accent-green: #10b981;
  --accent-red: #ef4444;

  /* Compatibility & Semantic Color Tokens (Guarantees High-Contrast Readability) */
  --color-gold: #FFAA00;
  --color-navy: #0f172a;
  --color-dark-bg: #0f172a;
  --color-light-bg: #f8fafc;
  --color-text-main: #1e293b;
  --color-text-muted: #64748b;
  --color-text-subtle: #94a3b8;
  --color-border: #e2e8f0;
  --color-cyan: #007A99;
  --color-white: #ffffff;
  --color-black: #000000;

  /* Typography Colors */
  --text-dark-primary: #0f172a;
  --text-dark-secondary: #475569;
  --text-dark-muted: #64748b;
  
  --text-light-primary: #ffffff;
  --text-light-secondary: #e2e8f0;
  --text-light-muted: #94a3b8;

  /* Fonts */
  --font-heading: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  --font-accent: 'Archivo', sans-serif;

  /* Transitions & Shadows */
  --transition-fast: 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 0.45s cubic-bezier(0.16, 1, 0.3, 1);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 35px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 4px 25px rgba(255, 170, 0, 0.22);
  --shadow-card-dark: 0 10px 30px rgba(0, 0, 0, 0.35);

  /* Geometry */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-pill: 9999px;
  --container-max: 1200px;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text-dark-primary);
  background-color: var(--bg-light-base);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

input, button, textarea, select {
  font: inherit;
}

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

ul, ol {
  list-style: none;
}

/* Typography Scale */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.25;
  color: inherit;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.2rem, 4vw, 3.4rem); line-height: 1.15; }
h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); line-height: 1.2; }
h3 { font-size: clamp(1.35rem, 2vw, 1.75rem); }
h4 { font-size: 1.25rem; font-weight: 600; }
h5 { font-size: 1.1rem; font-weight: 600; }
h6 { font-size: 0.95rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }

p {
  margin-bottom: 1.25rem;
}

p:last-child {
  margin-bottom: 0;
}

/* Container & Layout Primitives */
.cabex-container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.cabex-container-fluid {
  width: 100%;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.cabex-section {
  padding: 5rem 0;
  position: relative;
}

.cabex-section-sm {
  padding: 3rem 0;
}

.cabex-section-lg {
  padding: 7rem 0;
}

.cabex-section-dark {
  background-color: var(--bg-dark-base);
  color: var(--text-light-primary);
}

.cabex-section-deep {
  background-color: var(--bg-dark-deep);
  color: var(--text-light-primary);
}

.cabex-section-subtle {
  background-color: var(--bg-light-subtle);
}

/* Section Header Component */
.section-header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 3.5rem auto;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-gold);
  margin-bottom: 0.75rem;
}

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

.section-subtitle,
.section-desc {
  font-size: 1.1rem;
  color: var(--text-dark-secondary);
  line-height: 1.65;
}

.section-divider {
  width: 50px;
  height: 3px;
  background-color: var(--accent-gold);
  border-radius: var(--radius-pill);
  margin: 0.75rem auto 1.5rem auto;
}

.cabex-section-dark .section-subtitle,
.cabex-section-dark .section-desc,
.cabex-section-deep .section-subtitle,
.cabex-section-deep .section-desc {
  color: var(--text-light-muted);
}

/* Responsive Grid System */
.cabex-grid {
  display: grid;
  gap: 2rem;
}

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

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

@media (max-width: 768px) {
  .cabex-grid-4,
  .cabex-grid-3,
  .cabex-grid-2 { grid-template-columns: 1fr; gap: 1.5rem; }
  .cabex-section { padding: 3.5rem 0; }
  .section-header { margin-bottom: 2.5rem; }
}

/* Flex Utilities */
.d-flex { display: flex; }
.flex-column { flex-direction: column; }
.align-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }


/* Global Mobile Form & Padding Refinements */
@media (max-width: 640px) {
  .cabex-card {
    padding: 1.5rem !important;
  }
  .nav-container {
    padding: 0 1rem !important;
  }
}
