/* ============================================
   Last Minute Joy — Design System
   ============================================ */

:root {
  /* Base */
  --color-bg: #FFFFFF;
  --color-bg-soft: #FAFAF8;
  --color-text: #1A1A1A;
  --color-text-muted: #6B6B68;
  --color-border: #ECEAE4;

  /* Confetti accent palette */
  --confetti-coral: #E8694A;
  --confetti-pink: #E15B86;
  --confetti-amber: #F2A93B;
  --confetti-teal: #2BA88A;
  --confetti-periwinkle: #6C7AE0;

  /* Semantic */
  --color-success-bg: #E9F6F0;
  --color-success-text: #1E7A5C;
  --color-warning-bg: #FDF1DE;
  --color-warning-text: #9C6B16;

  /* Type */
  --font-display: 'Poppins', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Layout */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;
  --max-width: 1140px;

  --shadow-soft: 0 4px 20px rgba(26, 26, 26, 0.06);
  --shadow-lift: 0 10px 30px rgba(26, 26, 26, 0.10);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  margin: 0;
}

h1 { font-size: clamp(2.2rem, 4.5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
h3 { font-size: 1.3rem; }

p { margin: 0; }

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

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

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 72px 0; }

@media (max-width: 640px) {
  section { padding: 48px 0; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 14px 28px;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:focus-visible {
  outline: 3px solid var(--confetti-periwinkle);
  outline-offset: 2px;
}

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

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lift);
}

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

.btn-outline:hover {
  background: var(--color-text);
  color: #fff;
}

.btn-block { width: 100%; justify-content: center; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.3rem;
  white-space: nowrap;
}

.logo-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.logo span:nth-child(1) { color: var(--confetti-coral); }
.logo .word-last { color: var(--confetti-coral); }
.logo .word-minute { color: var(--confetti-pink); }
.logo .word-joy { color: var(--confetti-amber); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  font-weight: 500;
  font-size: 0.95rem;
}

.nav-links a {
  transition: color 0.15s ease;
}

.nav-links a:hover { color: var(--confetti-coral); }

.nav-cart {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    inset: 64px 0 0 0;
    background: #fff;
    flex-direction: column;
    justify-content: flex-start;
    padding: 32px 24px;
    gap: 24px;
    transform: translateY(-110%);
    transition: transform 0.25s ease;
  }
  .nav-links.open { transform: translateY(0); }
  .nav-toggle { display: block; }
}

/* ---------- Confetti dots (signature motif) ---------- */
.confetti-dot {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.confetti-field {
  position: relative;
  overflow: visible;
}

/* ---------- Badge ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--color-warning-bg);
  color: var(--color-warning-text);
}

.badge svg { width: 16px; height: 16px; flex-shrink: 0; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-bg-soft);
  border-top: 1px solid var(--color-border);
  padding: 56px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 40px;
}

.footer-grid h4 {
  font-size: 0.9rem;
  margin-bottom: 14px;
  font-family: var(--font-body);
  font-weight: 700;
}

.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-grid a { color: var(--color-text-muted); font-size: 0.9rem; }
.footer-grid a:hover { color: var(--color-text); }

.footer-bottom {
  border-top: 1px solid var(--color-border);
  padding-top: 24px;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

/* ---------- Utility ---------- */
.text-muted { color: var(--color-text-muted); }
.text-center { text-align: center; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 40px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.sr-only-skip {
  position: absolute;
  left: -9999px;
}
.sr-only-skip:focus {
  left: 24px;
  top: 12px;
  background: #fff;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  z-index: 100;
}
