/* ==========================================================================
   JALO GROUP - Base Styles, Typography & Resets
   ========================================================================== */

/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Alexandria:wght@400;500;600;700;800&family=Cairo:wght@400;500;600;700;800;900&family=Inter:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
}

body {
  min-height: 100vh;
  font-family: var(--font-family);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-canvas);
  transition: background-color var(--transition-base), color var(--transition-base);
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html.drawer-open,
body.drawer-open {
  overflow: hidden !important;
  touch-action: none;
}

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

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

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

ul, ol {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

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

h1 { font-size: clamp(2.25rem, 4vw + 1rem, 3.75rem); }
h2 { font-size: clamp(1.85rem, 3vw + 0.5rem, 2.75rem); }
h3 { font-size: clamp(1.35rem, 2vw + 0.25rem, 1.85rem); }
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 {
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

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

.text-muted {
  color: var(--text-muted);
}

.text-brand {
  color: var(--brand-orange);
}

.text-navy {
  color: var(--brand-navy);
}

/* --------------------------------------------------------------------------
   Layout Containers & Wrappers
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--container-padding);
  padding-right: var(--container-padding);
}

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

.section {
  padding-top: 5rem;
  padding-bottom: 5rem;
  position: relative;
}

.section-sm {
  padding-top: 3.5rem;
  padding-bottom: 3.5rem;
}

.section-bg-surface {
  background-color: var(--bg-surface);
}

.section-bg-elevated {
  background-color: var(--bg-surface-elevated);
}

.section-bg-dark {
  background-color: var(--bg-hero);
  color: var(--bg-hero-text);
}

.section-bg-dark h1,
.section-bg-dark h2,
.section-bg-dark h3,
.section-bg-dark h4 {
  color: #FFFFFF;
}

.section-bg-dark p {
  color: #CBD5E1;
}

/* Section Header */
.section-header {
  text-align: center;
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 3.5rem;
}

.section-header.text-start {
  text-align: start;
  margin-left: 0;
  margin-right: 0;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-orange);
  background-color: rgba(255, 122, 0, 0.1);
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full);
  margin-bottom: 1rem;
  border: 1px solid rgba(255, 122, 0, 0.2);
}

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

.section-subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Grid Utilities */
.grid {
  display: grid;
  gap: 2rem;
}

.grid > * {
  min-width: 0;
}

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

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

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

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

@media (max-width: 768px) {
  .section { padding-top: 3.5rem; padding-bottom: 3.5rem; }
  .grid-cols-4, .grid-cols-3, .grid-cols-2 { grid-template-columns: 1fr; }
}

/* Accessibility & Utilities */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
