/* =============================================================
   DASTARKHAN DELIGHTS — Base Styles
   Modern CSS reset + typography foundation
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,300;0,9..144,400;0,9..144,600;0,9..144,700;1,9..144,400&family=Nunito:wght@300;400;500;600;700&display=swap');

/* ---- Modern Reset ---- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--charcoal);
  background-color: var(--cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}

input, button, textarea, select {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  background: none;
  border: none;
  cursor: pointer;
}

/* ---- Skip Link (Accessibility) ---- */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  background: var(--forest);
  color: var(--warm-white);
  font-family: var(--font-body);
  font-weight: 600;
  border-radius: 0 0 var(--radius-button) var(--radius-button);
  z-index: var(--z-toast);
  transition: top 0.2s ease;
}
.skip-link:focus {
  top: 0;
}

/* ---- Typography Scale ---- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--forest);
}

h1 { font-size: clamp(var(--text-4xl), 6vw, var(--text-7xl)); }
h2 { font-size: clamp(var(--text-3xl), 4vw, var(--text-5xl)); }
h3 { font-size: clamp(var(--text-2xl), 3vw, var(--text-4xl)); }
h4 { font-size: clamp(var(--text-xl), 2.5vw, var(--text-3xl)); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

p {
  font-size: var(--text-base);
  line-height: 1.7;
  color: var(--charcoal);
  max-width: 65ch;
}

strong { font-weight: 700; }
em { font-style: italic; }

small {
  font-size: var(--text-sm);
  color: var(--muted);
}

/* ---- Focus States (Accessibility) ---- */
*:focus-visible {
  outline: 2px solid var(--saffron);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---- Selection ---- */
::selection {
  background: var(--saffron-pale);
  color: var(--forest);
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--cream); }
::-webkit-scrollbar-thumb {
  background: var(--gold-border);
  border-radius: var(--radius-pill);
}
::-webkit-scrollbar-thumb:hover { background: var(--saffron); }

/* ---- Utility Classes ---- */
.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;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

.text-center { text-align: center; }
.text-left   { text-align: left; }
.text-right  { text-align: right; }

.text-saffron  { color: var(--saffron); }
.text-forest   { color: var(--forest); }
.text-muted    { color: var(--muted); }
.text-white    { color: var(--warm-white); }

.font-display { font-family: var(--font-display); }
.font-body    { font-family: var(--font-body); }

.font-light   { font-weight: 300; }
.font-regular { font-weight: 400; }
.font-medium  { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold    { font-weight: 700; }

.italic { font-style: italic; }

/* ---- Decorative Divider ---- */
.divider-gold {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin: var(--space-lg) 0;
}
.divider-gold::before,
.divider-gold::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gold-border);
}
.divider-gold__diamond {
  width: 8px;
  height: 8px;
  background: var(--gold-border);
  transform: rotate(45deg);
  flex-shrink: 0;
}

/* ---- Section Spacing ---- */
.section {
  padding: var(--space-4xl) 0;
}
.section--sm {
  padding: var(--space-3xl) 0;
}
.section--lg {
  padding: var(--space-5xl) 0;
}

/* ---- Prefers Reduced Motion ---- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
