@layer base, utilities, components;

@layer base {
  :root {
    --color-bg: #121212;
    --color-bg-elevated: #1c1c1c;
    --color-bg-subtle: #181818;
    --color-text: #f5f5f5;
    --color-muted: #a3a3a3;
    --color-border: #1a1a1a;
    --color-primary: #f97316;
    --color-primary-soft: rgba(249, 115, 22, 0.1);
    --color-success: #22c55e;
    --color-warning: #eab308;
    --color-danger: #ef4444;
    --color-neutral-50: #fafafa;
    --color-neutral-100: #e5e5e5;
    --color-neutral-200: #d4d4d4;
    --color-neutral-300: #a3a3a3;
    --color-neutral-400: #737373;
    --color-neutral-500: #525252;
    --color-neutral-600: #404040;
    --color-neutral-700: #262626;
    --color-neutral-800: #171717;
    --color-neutral-900: #0a0a0a;

    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", sans-serif;
    --font-display: "Oswald", "Impact", system-ui, sans-serif;
    --font-mono: "JetBrains Mono", "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 1.875rem;
    --text-4xl: 2.25rem;
    --text-5xl: 3rem;

    --leading-tight: 1.1;
    --leading-snug: 1.25;
    --leading-normal: 1.5;
    --leading-relaxed: 1.7;

    --space-0: 0px;
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    --space-16: 64px;
    --space-20: 80px;
    --space-24: 96px;

    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 18px;
    --radius-full: 999px;

    --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.65);
    --shadow-hard: 0 0 0 1px #000000, 0 0 55px rgba(0, 0, 0, 0.9);
    --shadow-glow-primary: 0 0 0 1px rgba(249, 115, 22, 0.35), 0 0 30px rgba(249, 115, 22, 0.45);

    --transition-fast: 120ms ease-out;
    --transition-base: 180ms ease-out;
    --transition-slow: 260ms ease-out;
  }

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

  html,
  body {
    margin: 0;
    padding: 0;
  }

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

  body {
    min-height: 100vh;
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: var(--leading-normal);
    background-color: var(--color-bg);
    color: var(--color-text);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }

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

  input,
  button,
  textarea,
  select {
    font: inherit;
    color: inherit;
    background-color: transparent;
    border-radius: 0;
  }

  p,
  h1,
  h2,
  h3,
  h4,
  h5,
  h6,
  figure,
  blockquote,
  dl,
  dd {
    margin: 0;
  }

  ul,
  ol {
    margin: 0;
    padding: 0;
  }

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

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

  table {
    border-collapse: collapse;
    border-spacing: 0;
  }

  h1,
  h2,
  h3,
  h4,
  h5,
  h6 {
    font-family: var(--font-display);
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    line-height: var(--leading-tight);
    color: var(--color-text);
  }

  h1 {
    font-size: clamp(2.5rem, 4vw, 3.25rem);
    margin-bottom: var(--space-4);
  }

  h2 {
    font-size: clamp(2rem, 3vw, 2.5rem);
    margin-bottom: var(--space-3);
  }

  h3 {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    margin-bottom: var(--space-3);
  }

  h4 {
    font-size: 1.25rem;
    margin-bottom: var(--space-2);
  }

  h5 {
    font-size: 1.125rem;
    margin-bottom: var(--space-2);
  }

  h6 {
    font-size: 1rem;
    margin-bottom: var(--space-2);
  }

  p {
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
    color: var(--color-neutral-200);
    margin-bottom: var(--space-4);
  }

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

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

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

@layer utilities {
  .container {
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--space-4);
    padding-right: var(--space-4);
    max-width: 1200px;
  }

  @media (min-width: 1440px) {
    .container {
      max-width: 1320px;
    }
  }

  .flex {
    display: flex;
  }

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

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

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

  .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;
  }

  .grid {
    display: grid;
  }

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

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

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

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

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

  .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;
  }

  .hero-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    gap: var(--space-8);
    align-items: stretch;
    padding-top: var(--space-16);
    padding-bottom: var(--space-16);
  }

  .hero-shell-main {
    position: relative;
    padding: var(--space-8);
    background: radial-gradient(circle at top left, rgba(249, 115, 22, 0.14), transparent 60%), var(--color-bg-elevated);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
  }

  .hero-shell-main::before {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid rgba(249, 115, 22, 0.12);
    border-radius: inherit;
    pointer-events: none;
  }

  .hero-shell-tagline {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: 2px 10px 2px 4px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(249, 115, 22, 0.5);
    background: rgba(0, 0, 0, 0.7);
    box-shadow: 0 0 22px rgba(0, 0, 0, 0.9);
    margin-bottom: var(--space-4);
  }

  .hero-shell-tagline-dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: var(--color-primary);
    box-shadow: 0 0 12px rgba(249, 115, 22, 0.9);
  }

  .hero-shell-tagline-text {
    font-size: var(--text-xs);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--color-neutral-100);
  }

  .hero-shell-heading {
    max-width: 24ch;
    margin-bottom: var(--space-4);
  }

  .hero-shell-heading span {
    display: block;
  }

  .hero-shell-heading-ember {
    color: var(--color-primary);
  }

  .hero-shell-subcopy {
    max-width: 46ch;
    font-size: var(--text-sm);
    color: var(--color-neutral-200);
  }

  .hero-shell-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-4);
    align-items: center;
    margin-top: var(--space-6);
  }

  .hero-shell-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-6);
    margin-top: var(--space-6);
    padding-top: var(--space-6);
    border-top: 1px solid rgba(250, 250, 250, 0.04);
  }

  .hero-shell-meta-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .hero-shell-meta-label {
    font-size: var(--text-xs);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-neutral-400);
  }

  .hero-shell-meta-value {
    font-size: var(--text-sm);
    color: var(--color-neutral-100);
  }

  .hero-shell-side {
    display: grid;
    grid-template-rows: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: var(--space-4);
  }

  .hero-shell-media-primary {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl);
    border: 1px solid var(--color-border);
    background: linear-gradient(145deg, #000000 0%, #1c1c1c 40%, #34170a 100%);
    box-shadow: var(--shadow-hard);
  }

  .hero-shell-media-primary::after {
    content: "Woodfired Charcoal Grill";
    position: absolute;
    left: 16px;
    bottom: 14px;
    padding: 3px 10px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    background: rgba(0, 0, 0, 0.85);
    border-radius: 999px;
    border: 1px solid rgba(249, 115, 22, 0.7);
    color: var(--color-neutral-100);
  }

  .hero-shell-media-primary-photo {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    mix-blend-mode: lighten;
    opacity: 0.9;
  }

  .hero-shell-media-secondary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-3);
  }

  .hero-shell-media-card {
    position: relative;
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    background: radial-gradient(circle at top, rgba(249, 115, 22, 0.16), transparent 55%), var(--color-bg-subtle);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.75);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: var(--space-3);
  }

  .hero-shell-media-card-label {
    font-size: var(--text-xs);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-neutral-400);
  }

  .hero-shell-media-card-value {
    font-family: var(--font-display);
    font-size: 1.1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--color-neutral-50);
  }

  .hero-shell-media-card-tag {
    align-self: flex-start;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    padding: 3px 10px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--color-neutral-200);
  }

  .hero-shell-media-card-photo {
    position: absolute;
    inset: 0;
    opacity: 0.25;
    mix-blend-mode: screen;
    background-size: cover;
    background-position: center;
    pointer-events: none;
  }

  @media (max-width: 1024px) {
    .hero-shell {
      grid-template-columns: minmax(0, 1fr);
    }

    .hero-shell-main {
      order: 2;
    }

    .hero-shell-side {
      order: 1;
    }
  }

  @media (max-width: 768px) {
    .hero-shell {
      padding-top: var(--space-12);
      padding-bottom: var(--space-12);
    }

    .hero-shell-main {
      padding: var(--space-6);
    }

    .hero-shell-cta-row {
      flex-direction: column;
      align-items: stretch;
    }

    .hero-shell-side {
      grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    }
  }
}

@layer components {
  .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 0.7rem 1.7rem;
    border-radius: 999px;
    font-family: var(--font-display);
    font-size: var(--text-sm);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    border: 1px solid var(--color-border);
    background: linear-gradient(135deg, #2a1204 0%, #f97316 40%, #fb923c 100%);
    color: #111111;
    box-shadow: var(--shadow-glow-primary);
    transition: transform var(--transition-base), box-shadow var(--transition-base), background var(--transition-base), border-color var(--transition-base), color var(--transition-base);
    white-space: nowrap;
  }

  .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 0 0 1px rgba(249, 115, 22, 0.7), 0 0 42px rgba(249, 115, 22, 0.8);
    background: linear-gradient(135deg, #f97316 0%, #fb923c 35%, #fed7aa 100%);
  }

  .btn:active {
    transform: translateY(0px) scale(0.99);
    box-shadow: 0 0 0 1px rgba(249, 115, 22, 0.4), 0 12px 32px rgba(0, 0, 0, 0.9);
  }

  .btn:disabled,
  .btn[aria-disabled="true"] {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
    background: linear-gradient(135deg, #262626 0%, #1c1c1c 100%);
    color: var(--color-neutral-400);
  }

  .btn-outline {
    background: rgba(0, 0, 0, 0.7);
    color: var(--color-neutral-50);
    border-color: rgba(249, 115, 22, 0.6);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.9);
  }

  .btn-outline:hover {
    background: var(--color-primary-soft);
    box-shadow: 0 0 0 1px rgba(249, 115, 22, 0.6), 0 0 24px rgba(249, 115, 22, 0.5);
  }

  .input,
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="number"],
  input[type="date"],
  input[type="time"],
  input[type="password"],
  select,
  textarea {
    width: 100%;
    padding: 0.75rem 0.9rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    background-color: var(--color-bg-subtle);
    color: var(--color-text);
    font-size: var(--text-sm);
    line-height: 1.4;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.7);
    transition: border-color var(--transition-base), box-shadow var(--transition-base), background-color var(--transition-base);
  }

  .input::placeholder,
  input::placeholder,
  textarea::placeholder {
    color: var(--color-neutral-500);
  }

  .input:focus-visible,
  input:focus-visible,
  select:focus-visible,
  textarea:focus-visible {
    outline: none;
    border-color: rgba(249, 115, 22, 0.9);
    box-shadow: 0 0 0 1px rgba(249, 115, 22, 0.9), 0 0 30px rgba(249, 115, 22, 0.45);
  }

  .input[disabled],
  input[disabled],
  select[disabled],
  textarea[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
  }

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

  .card {
    position: relative;
    padding: var(--space-6);
    border-radius: var(--radius-xl);
    background: radial-gradient(circle at top left, rgba(249, 115, 22, 0.18), transparent 55%), var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-soft);
    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-header {
    margin-bottom: var(--space-4);
  }

  .card-title {
    margin-bottom: var(--space-1);
  }

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

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

  .badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.15rem 0.65rem;
    border-radius: 999px;
    border: 1px solid rgba(249, 115, 22, 0.7);
    font-size: 0.65rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--color-primary);
    background: rgba(0, 0, 0, 0.65);
  }
}

ul {
  list-style: none !important;
}

.nav-toggle {
  flex-direction: column;
}
html, body {
  overflow-x: clip;
  max-width: 100%;
}

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