/* =========================================================
   Nebula v2 - base.css
   Reset + typography + global utilities
========================================================= */

:root{
  /* Layout tokens */
  --container: 1160px;
  --gutter: 18px;
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 18px;
  --radius-xl: 22px;

  /* Motion */
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --ease-soft: cubic-bezier(.2, .8, .2, 1);
}

/* Base colors driven by theme.css variables */
html{
  background: var(--bg-body, #020617);
  color: var(--text-main, #e5e7eb);
}

body{
  background: transparent;
  color: var(--text-main, #e5e7eb);
}

::selection{
  background: rgba(56,189,248,.22);
}
html[data-theme="light"] ::selection{
  background: rgba(124,58,237,.18);
}

*,
*::before,
*::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

body{
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  line-height: 1.6;
  overflow-x: hidden;
}

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

a{ color: inherit; text-decoration: none; }

button, input, textarea{ font: inherit; }

:focus-visible{
  outline: none;
  box-shadow: 0 0 0 4px rgba(56,189,248,.18);
  border-radius: 12px;
}

.container{
  width: min(var(--container), calc(100% - (var(--gutter) * 2)));
  margin-inline: auto;
}

.section{ padding: 86px 0; position: relative; z-index: 1; }
.section-muted{ background: var(--bg-section-muted); }

@media (max-width: 860px){
  .section{ padding: 64px 0; }
}

.section-header{ margin-bottom: 30px; }
.section-title{
  margin: 0 0 8px;
  font-size: clamp(1.55rem, 2.5vw, 2.15rem);
  letter-spacing: -.02em;
}
.section-subtitle{
  margin: 0;
  max-width: 72ch;
  color: var(--text-muted);
}

.eyebrow{
  margin: 0 0 10px;
  color: var(--text-subtle);
  letter-spacing: .14em;
  text-transform: uppercase;
  font-weight: 850;
  font-size: .78rem;
}

.kicker{
  color: var(--text-subtle);
  letter-spacing: .12em;
  text-transform: uppercase;
  font-weight: 800;
  font-size: .78rem;
}

.highlight{
  background: linear-gradient(135deg, var(--accent-1), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.muted{ color: var(--text-muted); }
.small{ font-size: .92rem; }

/* Grids */
.grid{ display: grid; gap: 22px; }
.grid-2{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4{ grid-template-columns: repeat(4, minmax(0, 1fr)); }

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

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

/* Accessibility skip link (Hindi page) */
.skip-link{
  position: absolute;
  left: -999px;
  top: 12px;
  z-index: 9999;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  backdrop-filter: blur(12px);
}
.skip-link:focus{ left: 12px; }

/* Helpers */
.visually-hidden{
  position: absolute !important;
  height: 1px; width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
  border: 0; padding: 0; margin: -1px;
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}
