/* =========================================================
   Variables
   ========================================================= */
:root {
  /* Colors */
  --color-bg: #060608; /* deep cinematic charcoal */
  --color-bg-elevated: #101018;
  --color-bg-soft: #171821;
  --color-text: #f6f1e9; /* warm cream */
  --color-text-muted: #b1a79a;
  --color-primary: #c9a25a; /* antique gold */
  --color-primary-soft: rgba(201, 162, 90, 0.18);
  --color-success: #2f7b5a; /* dark emerald green */
  --color-warning: #e0a847;
  --color-danger: #a32634; /* rich burgundy */

  --color-border-subtle: rgba(255, 255, 255, 0.06);
  --color-border-strong: rgba(255, 255, 255, 0.16);

  --color-neutral-50: #f7f7f8;
  --color-neutral-100: #e3e4e6;
  --color-neutral-200: #c7c9cc;
  --color-neutral-300: #a0a3a8;
  --color-neutral-400: #7b7f86;
  --color-neutral-500: #5a5e66;
  --color-neutral-600: #41444b;
  --color-neutral-700: #2f3238;
  --color-neutral-800: #212328;
  --color-neutral-900: #14151a;

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-heading: "Playfair Display", "Times New Roman", serif;
  --font-alt: "Cormorant Garamond", Georgia, serif;

  --font-size-xs: 0.75rem;   /* 12px */
  --font-size-sm: 0.875rem;  /* 14px */
  --font-size-base: 1rem;    /* 16px */
  --font-size-md: 1.0625rem; /* 17px */
  --font-size-lg: 1.125rem;  /* 18px */
  --font-size-xl: 1.25rem;   /* 20px */
  --font-size-2xl: 1.5rem;   /* 24px */
  --font-size-3xl: 2rem;     /* 32px */
  --font-size-4xl: 2.5rem;   /* 40px */
  --font-size-5xl: 3.25rem;  /* 52px hero */

  --line-height-tight: 1.1;
  --line-height-snug: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.75;

  /* Spacing scale (0–96px) */
  --space-0: 0;
  --space-1: 0.125rem; /* 2px */
  --space-2: 0.25rem;  /* 4px */
  --space-3: 0.375rem; /* 6px */
  --space-4: 0.5rem;   /* 8px */
  --space-5: 0.625rem; /* 10px */
  --space-6: 0.75rem;  /* 12px */
  --space-8: 1rem;     /* 16px */
  --space-10: 1.25rem; /* 20px */
  --space-12: 1.5rem;  /* 24px */
  --space-16: 2rem;    /* 32px */
  --space-20: 2.5rem;  /* 40px */
  --space-24: 3rem;    /* 48px */
  --space-32: 4rem;    /* 64px */
  --space-40: 5rem;    /* 80px */
  --space-48: 6rem;    /* 96px */

  /* Radius */
  --radius-none: 0;
  --radius-xs: 2px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --radius-xl: 24px;
  --radius-pill: 999px;

  /* Shadows (subtle cinematic) */
  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.35);
  --shadow-elevated: 0 26px 80px rgba(0, 0, 0, 0.65);
  --shadow-soft-inner: inset 0 0 0 1px rgba(255, 255, 255, 0.02);

  /* Transitions */
  --transition-fast: 120ms ease-out;
  --transition-normal: 200ms ease-out;
  --transition-slow: 320ms ease;

  /* Layout */
  --container-max-width: 1200px;
  --container-wide-width: 1440px;
}

@media (min-width: 768px) {
  :root {
    --font-size-3xl: 2.4rem;
    --font-size-4xl: 3rem;
    --font-size-5xl: 3.75rem;
  }
}

/* Respect prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
  :root {
    --transition-fast: 0ms;
    --transition-normal: 0ms;
    --transition-slow: 0ms;
  }

  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* =========================================================
   Reset / Normalize
   ========================================================= */
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  min-height: 100vh;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

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

button {
  border: none;
  background: none;
  padding: 0;
}

ul[role="list"],
ol[role="list"] {
  list-style: none;
  padding: 0;
}

/* Remove default link styles while keeping accessibility */
a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

/* =========================================================
   Base
   ========================================================= */
body {
  font-family: var(--font-sans);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  background-color: var(--color-bg);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main {
  display: block;
}

p {
  margin-bottom: var(--space-8);
  color: var(--color-text-muted);
}

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--color-text);
  line-height: var(--line-height-tight);
  margin-bottom: var(--space-6);
}

h1 {
  font-size: var(--font-size-4xl);
}

h2 {
  font-size: var(--font-size-3xl);
}

h3 {
  font-size: var(--font-size-2xl);
}

h4 {
  font-size: var(--font-size-xl);
}

h5 {
  font-size: var(--font-size-lg);
}

h6 {
  font-size: var(--font-size-base);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

@media (min-width: 768px) {
  h1 {
    font-size: var(--font-size-5xl);
  }

  h2 {
    font-size: var(--font-size-4xl);
  }

  h3 {
    font-size: calc(var(--font-size-2xl) + 0.1rem);
  }
}

strong, b {
  font-weight: 600;
}

em, i {
  font-style: italic;
}

small {
  font-size: var(--font-size-sm);
}

code, kbd, samp, pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

hr {
  border: none;
  border-top: 1px solid var(--color-border-subtle);
  margin: var(--space-16) 0;
}

/* Links with subtle luxury accent */
a,
.link {
  color: var(--color-primary);
  text-decoration: none;
  position: relative;
  transition: color var(--transition-fast), opacity var(--transition-fast);
}

a::after,
.link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.15em;
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(201, 162, 90, 0.7), rgba(201, 162, 90, 0));
  transition: width var(--transition-normal);
}

a:hover::after,
.link:hover::after {
  width: 100%;
}

a:hover,
.link:hover {
  color: #f8e3b7;
}

/* =========================================================
   Accessibility & Focus
   ========================================================= */
:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

/* Screen reader only */
.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;
}

/* =========================================================
   Utilities
   ========================================================= */

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

.container-wide {
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-16);
  padding-right: var(--space-16);
  max-width: var(--container-wide-width);
}

.section {
  padding-top: var(--space-32);
  padding-bottom: var(--space-32);
}

@media (min-width: 768px) {
  .section {
    padding-top: var(--space-40);
    padding-bottom: var(--space-40);
  }
}

/* Flex utilities */
.flex {
  display: flex;
}

.inline-flex {
  display: inline-flex;
}

.flex-col {
  flex-direction: column;
}

.flex-row {
  flex-direction: row;
}

.items-center {
  align-items: center;
}

.items-start {
  align-items: flex-start;
}

.items-end {
  align-items: flex-end;
}

.justify-center {
  justify-content: center;
}

.justify-between {
  justify-content: space-between;
}

.justify-end {
  justify-content: flex-end;
}

.flex-wrap {
  flex-wrap: wrap;
}

.gap-4 {
  gap: var(--space-4);
}

.gap-8 {
  gap: var(--space-8);
}

.gap-12 {
  gap: var(--space-12);
}

.gap-16 {
  gap: var(--space-16);
}

/* Grid utilities */
.grid {
  display: grid;
}

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

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

.grid-gap-8 {
  gap: var(--space-8);
}

.grid-gap-16 {
  gap: var(--space-16);
}

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

/* Text alignment */
.text-left {
  text-align: left;
}

.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

/* Spacing utilities (common ones) */
.mt-0 { margin-top: 0; }
.mt-8 { margin-top: var(--space-8); }
.mt-16 { margin-top: var(--space-16); }
.mt-24 { margin-top: var(--space-24); }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: var(--space-8); }
.mb-16 { margin-bottom: var(--space-16); }
.mb-24 { margin-bottom: var(--space-24); }

.pt-16 { padding-top: var(--space-16); }
.pb-16 { padding-bottom: var(--space-16); }
.pt-24 { padding-top: var(--space-24); }
.pb-24 { padding-bottom: var(--space-24); }

/* Width helpers */
.w-full {
  width: 100%;
}

/* Background helpers */
.bg-elevated {
  background-color: var(--color-bg-elevated);
}

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

/* =========================================================
   Components
   ========================================================= */

/* Buttons */
.button,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  padding: 0.7rem 1.6rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: radial-gradient(circle at 0 0, rgba(248, 227, 183, 0.22), transparent 55%),
              linear-gradient(135deg, rgba(201, 162, 90, 0.85), rgba(115, 81, 33, 0.9));
  color: #1b1407;
  font-size: var(--font-size-sm);
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  cursor: pointer;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
  transition:
    transform var(--transition-fast),
    box-shadow var(--transition-fast),
    background var(--transition-slow),
    opacity var(--transition-fast);
}

.button:hover,
.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-elevated);
  opacity: 0.96;
}

.button:active,
.btn:active {
  transform: translateY(0);
  box-shadow: var(--shadow-soft);
}

.button:disabled,
.btn:disabled,
.button[aria-disabled="true"],
.btn[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.5;
  box-shadow: none;
}

.button--outline,
.btn--outline {
  background: transparent;
  color: var(--color-text);
  border-color: rgba(201, 162, 90, 0.7);
  box-shadow: none;
}

.button--outline:hover,
.btn--outline:hover {
  background: rgba(201, 162, 90, 0.12);
}

.button--ghost,
.btn--ghost {
  background: rgba(0, 0, 0, 0.3);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--color-text);
}

.button--ghost:hover,
.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.05);
}

/* Form elements */
.input,
textarea,
select {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border-strong);
  background-color: rgba(10, 10, 16, 0.85);
  color: var(--color-text);
  font-size: var(--font-size-sm);
  line-height: var(--line-height-normal);
  transition:
    border-color var(--transition-fast),
    box-shadow var(--transition-fast),
    background-color var(--transition-fast);
}

.input::placeholder,
textarea::placeholder {
  color: var(--color-text-muted);
}

.input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px rgba(201, 162, 90, 0.65);
  background-color: rgba(10, 10, 16, 0.95);
}

textarea {
  min-height: 120px;
  resize: vertical;
}

label {
  display: block;
  margin-bottom: var(--space-4);
  font-size: var(--font-size-sm);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.form-field {
  margin-bottom: var(--space-12);
}

.input--error {
  border-color: var(--color-danger);
}

.input-error-message {
  margin-top: var(--space-4);
  font-size: var(--font-size-xs);
  color: var(--color-danger);
}

/* Card component (menu items, events, stories) */
.card {
  position: relative;
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top left, rgba(201, 162, 90, 0.08), transparent 55%),
              radial-gradient(circle at bottom right, rgba(36, 78, 60, 0.22), transparent 55%),
              var(--color-bg-elevated);
  border: 1px solid var(--color-border-subtle);
  box-shadow: var(--shadow-soft);
  padding: var(--space-16);
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.02);
  pointer-events: none;
}

.card--soft {
  background: rgba(11, 11, 18, 0.9);
  box-shadow: var(--shadow-soft-inner);
}

.card-header {
  margin-bottom: var(--space-8);
}

.card-title {
  font-family: var(--font-heading);
  font-size: var(--font-size-xl);
  margin-bottom: var(--space-4);
}

.card-subtitle {
  font-size: var(--font-size-sm);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.card-body {
  font-size: var(--font-size-sm);
  color: var(--color-text-muted);
}

/* Hero media helpers (cinematic full-bleed sections) */
.hero-full {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  color: var(--color-text);
  overflow: hidden;
}

.hero-full::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top, rgba(0, 0, 0, 0.35), transparent 55%),
              linear-gradient(to bottom, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.95));
  pointer-events: none;
}

.hero-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-content {
  position: relative;
  z-index: 1;
}

/* Tag / pill (e.g. VIP, Chef's Choice, Poker Night) */
.pill {
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(201, 162, 90, 0.55);
  padding: 0.15rem 0.7rem;
  font-size: var(--font-size-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-primary);
  background: rgba(12, 12, 18, 0.92);
}

/* Status tokens for poker evenings, availability, etc. */
.badge {
  display: inline-block;
  padding: 0.1rem 0.5rem;
  border-radius: var(--radius-pill);
  font-size: var(--font-size-xs);
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.badge--success {
  background-color: rgba(47, 123, 90, 0.15);
  color: #b4e3c9;
}

.badge--warning {
  background-color: rgba(224, 168, 71, 0.15);
  color: #f4d5a2;
}

.badge--danger {
  background-color: rgba(163, 38, 52, 0.18);
  color: #f3b5be;
}

/* Media framing for gallery / dishes */
.frame-cinematic {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-elevated);
}

.frame-cinematic img,
.frame-cinematic video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.frame-cinematic::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent 45%);
  pointer-events: none;
}
