/* ==========================================================================
   STELLAR PIPES - BASE STYLES & RESET
   File: css/base.css
   ========================================================================== */

/* Modern CSS Reset */
*, *::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;
  max-width: 100%;
  width: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--ink);
  background-color: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  max-width: 100%;
  width: 100%;
  position: relative;
  padding-bottom: 0;
}

body.tamil-lang {
  font-family: var(--font-tamil);
}

/* Accessibility: Skip to Content */
.skip-link {
  position: absolute;
  top: -100px;
  left: 20px;
  background: var(--safety);
  color: #000;
  padding: 10px 18px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  z-index: 99999;
  transition: top 0.2s ease;
  text-decoration: none;
}

.skip-link:focus {
  top: 15px;
  outline: 3px solid var(--navy);
}

/* Focus Visibility (WCAG AA Compliance) */
:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

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

h1 { font-size: clamp(2.1rem, 4.2vw, 3.4rem); font-weight: 800; }
h2 { font-size: clamp(1.75rem, 3.2vw, 2.5rem); }
h3 { font-size: clamp(1.3rem, 2.2vw, 1.75rem); }
h4 { font-size: 1.2rem; }
p { margin-bottom: 1rem; color: var(--muted); }
p:last-child { margin-bottom: 0; }

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

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

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

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
  max-width: 100%;
}

iframe {
  max-width: 100%;
}

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

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

.container-narrow {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.section {
  padding: var(--section-pad-desktop);
  position: relative;
}

.section-soft {
  background-color: var(--bg-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-dark {
  background-color: var(--navy);
  color: #FFFFFF;
}

.section-dark h2, 
.section-dark h3, 
.section-dark p {
  color: #FFFFFF;
}

.section-dark p {
  color: rgba(255, 255, 255, 0.85);
}

/* Header Text Blocks */
.section-header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 54px;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--aqua-soft);
  color: var(--blue);
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 14px;
}

.section-dark .section-tag {
  background: rgba(25, 181, 232, 0.2);
  color: var(--aqua);
}

.section-title {
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.12rem;
  color: var(--muted);
}

/* Visually Hidden for screen readers */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Respect Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Responsive Grid Utilities */
.responsive-split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.responsive-split-grid-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: flex-start;
}

.rfq-layout-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 40px;
  align-items: flex-start;
}

.about-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 24px;
}

.responsive-auto-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

