/**
 * Digital Bharat Registration - Global Design System & Core Stylesheet
 * High-Performance, Zero-Dependency Vanilla CSS
 */

:root {
  /* Brand Color Palette — Digital India Theme (Navy, Saffron, Green) */
  --primary: #0a284b;           /* Deep Bharat Navy */
  --primary-hover: #154378;     /* Lighter navy */
  --primary-dark: #06182e;      /* Midnight navy */
  --primary-light: #e8f0fe;     /* Ice navy tint */
  --saffron: #f59e0b;           /* Indian Saffron Gold */
  --saffron-hover: #d97706;     /* Deep Saffron */
  --saffron-dark: #b45309;      /* Dark Amber */
  --green: #138808;             /* India Flag Green */
  --green-hover: #0f6c06;       /* Deep Green */
  --accent: #f59e0b;            /* Primary CTA accent is saffron */
  --accent-hover: #d97706;
  --success: #138808;
  --success-hover: #0f6c06;
  --warning: #f59e0b;
  --danger: #dc3545;
  --info: #0284c7;

  /* Neutrals & Surfaces */
  --text-main: #0a284b;         /* Deep navy for readable primary text */
  --text-secondary: #334155;    /* Slate */
  --text-muted: #64748b;        /* Muted slate */
  --text-light: #94a3b8;
  --text-white: #ffffff;
  --bg-page: #fbfcfe;           /* Crisp clean page background */
  --bg-card: #ffffff;           /* Pure white card */
  --bg-muted: #f4f7fb;          /* Soft cool tint */
  --border: #e2e8f0;            /* Clean light border */
  --border-focus: #f59e0b;

  /* Typography — Matched to Live Site */
  --font-family: 'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Elevation & Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 10px 25px -3px rgba(10, 40, 75, 0.12);
  --shadow-hover: 0 14px 30px rgba(10, 40, 75, 0.16);

  /* Radii */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;

  /* Layout */
  --max-width: 1240px;
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

body {
  font-family: var(--font-family);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-main);
  background-color: var(--bg-page);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

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

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

/* ==========================================================================
   Typography
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--primary);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 0.75rem;
}

/* Hero & Dark Banner text protection */
[class*="-hero"] h1,
[class*="-hero"] h2,
[class*="-hero"] h3,
[class*="-cta"] h1,
[class*="-cta"] h2,
[class*="-cta"] h3,
.section-mission h1,
.section-mission h2,
.section-mission h3 {
  color: #ffffff !important;
}

[class*="-hero"] .text-saffron,
[class*="-cta"] .text-saffron {
  color: #fbbf24 !important;
}

h1 { font-size: 2.35rem; }
h2 { font-size: 1.85rem; }
h3 { font-size: 1.45rem; }
h4 { font-size: 1.2rem; }
h5 { font-size: 1.05rem; }
h6 { font-size: 0.95rem; }

p {
  margin-bottom: 1rem;
}

.text-muted { color: var(--text-muted); }
.text-primary { color: var(--primary); }
.text-success { color: var(--success); }
.text-accent { color: var(--accent); }
.text-center { text-align: center; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

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

.section {
  padding: 4rem 0;
}

.section-sm {
  padding: 2.5rem 0;
}

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

.section-bg-primary {
  background-color: var(--primary);
  color: var(--text-white);
}

.section-bg-primary h1,
.section-bg-primary h2,
.section-bg-primary h3 {
  color: var(--text-white);
}

/* Grid System */
.grid {
  display: grid;
  gap: 1.5rem;
}

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

@media (max-width: 992px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }
}

@media (max-width: 768px) {
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .section { padding: 2.75rem 0; }
  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.4rem; }
}

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

/* ==========================================================================
   Buttons & Interactive Elements
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-family);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1;
  padding: 0.85rem 1.6rem;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--text-white);
}

.btn-primary:hover {
  background-color: var(--primary-dark);
  color: var(--text-white);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-accent {
  background-color: var(--accent);
  color: var(--text-white);
}

.btn-accent:hover {
  background-color: var(--accent-hover);
  color: var(--text-white);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-success {
  background-color: var(--success);
  color: var(--text-white);
}

.btn-success:hover {
  background-color: var(--success-hover);
  color: var(--text-white);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-outline {
  background-color: transparent;
  border-color: var(--primary);
  color: var(--primary);
}

.btn-outline:hover {
  background-color: var(--primary);
  color: var(--text-white);
}

.btn-outline-white {
  background-color: transparent;
  border-color: var(--text-white);
  color: var(--text-white);
}

.btn-outline-white:hover {
  background-color: var(--text-white);
  color: var(--primary);
}

.btn-sm {
  font-size: 0.85rem;
  padding: 0.55rem 1.1rem;
}

.btn-lg {
  font-size: 1.05rem;
  padding: 1rem 2.2rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-block {
  width: 100%;
}

/* ==========================================================================
   Cards & Surface Components
   ========================================================================== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-md);
  border-color: #cbd5e1;
}

.card-clickable {
  cursor: pointer;
}

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

/* Trust Badge / Chip */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: var(--radius-full);
}

.badge-primary { background: rgba(13, 44, 84, 0.1); color: var(--primary); }
.badge-success { background: rgba(40, 167, 69, 0.12); color: var(--success); }
.badge-warning { background: rgba(245, 158, 11, 0.12); color: #b45309; }

/* ==========================================================================
   Forms & Input Controls
   ========================================================================== */
.form-group {
  margin-bottom: 1.25rem;
  text-align: left;
}

.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.4rem;
}

.form-label .required {
  color: var(--danger);
  margin-left: 2px;
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: var(--font-family);
  font-size: 0.95rem;
  color: var(--text-main);
  background-color: var(--bg-card);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(13, 44, 84, 0.15);
}

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

.form-help {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

/* ==========================================================================
   Government Compliance / Advisory Notice
   ========================================================================== */
.compliance-box {
  background-color: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  color: #92400e;
  line-height: 1.5;
  margin: 1.5rem 0;
}

/* Text Utilities */
.text-white {
  color: #ffffff !important;
}

.text-saffron {
  color: #fbbf24 !important;
}

.text-muted-light {
  color: rgba(255, 255, 255, 0.8) !important;
}

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

