/* ==========================================================================
   HolidayClash — stylesheet
   Aesthetic: editorial / refined / confident — warm cream + clash red
   ========================================================================== */

:root {
  --cream:        #F4EFE6;
  --cream-deep:   #ECE4D5;
  --ink:          #1B1A17;
  --ink-soft:     #4A4842;
  --ink-mute:     #87837A;
  --rule:         #D9D2C2;

  --clash:        #E63946;   /* primary accent */
  --clash-deep:   #B5202C;
  --gold:         #D4A949;   /* secondary accent for long weekends */
  --teal:         #1D6E6E;   /* tertiary, for clean weeks */

  --shadow-sm: 0 2px 0 rgba(27,26,23,0.05);
  --shadow-md: 0 8px 24px -8px rgba(27,26,23,0.18);
  --shadow-lg: 0 24px 48px -16px rgba(27,26,23,0.22);

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1180px;
}

/* ---------- reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--clash-deep); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: inherit; cursor: pointer; }

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

.muted   { color: var(--ink-mute); }
.small   { font-size: 14px; }

/* subtle film grain texture overlay */
.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.45'/></svg>");
  opacity: 0.06;
  mix-blend-mode: multiply;
}

/* ---------- typography ---------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--ink);
  margin: 0 0 .4em;
}
h1 em, h2 em, h3 em {
  font-style: italic;
  font-weight: 800;
  color: var(--clash);
  font-feature-settings: "ss01";
}

.section-title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: .3em;
}
.section-sub {
  font-size: 1.1rem;
  color: var(--ink-soft);
  max-width: 640px;
  margin: 0 0 2.5rem;
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--cream);
  border-bottom: 1px solid var(--rule);
  backdrop-filter: blur(8px);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px;
}
.logo {
  display: inline-flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--ink);
}
.logo:hover { text-decoration: none; }
.logo-mark {
  display: inline-flex;
  color: var(--clash);
}
.logo-text {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.4rem;
  letter-spacing: -0.02em;
}
.logo-text em {
  font-style: italic;
  color: var(--clash);
}
.site-nav { display: flex; gap: 28px; }
.site-nav a {
  color: var(--ink-soft);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  position: relative;
}
.site-nav a:hover { color: var(--clash); text-decoration: none; }
.site-nav a:hover::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px;
  height: 2px; background: var(--clash);
}

@media (max-width: 700px) {
  .site-nav { display: none; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 6px;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: transform .15s ease, background .15s ease, color .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary {
  background: var(--ink);
  color: var(--cream);
}
.btn-primary:hover { background: var(--clash); color: white; }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}
.btn-ghost:hover { background: var(--ink); color: var(--cream); }
.btn-small { padding: 10px 18px; font-size: 14px; }

.link-btn {
  background: none; border: none; padding: 0;
  color: var(--clash-deep); text-decoration: underline; cursor: pointer;
  font: inherit;
}
.link-btn:hover { color: var(--clash); }

/* ---------- hero ---------- */
.hero {
  position: relative; z-index: 1;
  padding: 80px 0 60px;
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; right: -120px; top: 40px;
  width: 420px; height: 420px;
  background: radial-gradient(circle at center, var(--clash) 0%, transparent 65%);
  opacity: 0.10; border-radius: 50%;
  pointer-events: none;
}
.hero-eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: var(--cream-deep);
  border: 1px solid var(--rule);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 24px;
}
.hero-title {
  font-size: clamp(2.5rem, 7vw, 5.2rem);
  font-weight: 900;
  line-height: 0.98;
  margin: 0 0 28px;
  max-width: 14ch;
}
.hero-lede {
  font-size: clamp(1.05rem, 1.5vw, 1.25rem);
  color: var(--ink-soft);
  max-width: 56ch;
  margin: 0 0 36px;
  line-height: 1.55;
}
.hero-cta {
  display: flex; gap: 14px; flex-wrap: wrap;
  margin-bottom: 60px;
}
.hero-stats {
  display: flex; gap: 48px; flex-wrap: wrap;
  padding-top: 32px;
  border-top: 1px solid var(--rule);
}
.hero-stats > div {
  display: flex; flex-direction: column;
}
.hero-stats strong {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.hero-stats span {
  font-size: 13px;
  color: var(--ink-mute);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------- tool ---------- */
.tool-section {
  position: relative; z-index: 1;
  padding: 60px 0 80px;
  background: var(--cream-deep);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.tool-header { margin-bottom: 32px; }

.tool-card {
  background: var(--cream);
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.picker {
  padding: 28px;
  border-bottom: 1px solid var(--rule);
  background:
    linear-gradient(to bottom, rgba(255,255,255,0.5), transparent);
}
.picker-row {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.picker-label {
  font-weight: 600;
  font-size: 14px;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  min-width: 110px;
}
.picker-controls { display: flex; gap: 8px; flex: 1; min-width: 240px; }
select {
  font-family: inherit;
  font-size: 15px;
  padding: 10px 14px;
  border: 1.5px solid var(--rule);
  border-radius: var(--radius-sm);
  background: white;
  color: var(--ink);
  flex: 1;
  min-width: 200px;
  cursor: pointer;
}
select:focus {
  outline: none;
  border-color: var(--clash);
}

.selected-countries {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-top: 16px;
  min-height: 32px;
}
.country-chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ink);
  color: var(--cream);
  padding: 6px 8px 6px 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
}
.country-chip button {
  background: rgba(255,255,255,0.15);
  border: none;
  color: var(--cream);
  width: 22px; height: 22px;
  border-radius: 50%;
  font-size: 14px;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0;
  line-height: 1;
}
.country-chip button:hover { background: var(--clash); }

/* ---------- results ---------- */
.results {
  padding: 28px;
  min-height: 240px;
}
.results-empty {
  text-align: center;
  padding: 48px 24px;
  color: var(--ink-mute);
}
.results-empty-icon {
  font-size: 2.4rem;
  margin-bottom: 16px;
}

.results-summary {
  display: flex; gap: 24px; flex-wrap: wrap;
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px dashed var(--rule);
}
.summary-pill {
  display: flex; flex-direction: column; gap: 2px;
}
.summary-pill strong {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
}
.summary-pill span {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-mute);
}
.summary-pill.clash strong { color: var(--clash); }
.summary-pill.gold  strong { color: var(--gold); }
.summary-pill.teal  strong { color: var(--teal); }

/* month grid */
.year-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}
.month-card {
  background: white;
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: 16px;
}
.month-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
  display: flex; align-items: center; justify-content: space-between;
}
.month-tag {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 999px;
}
.month-tag.clean { background: rgba(29,110,110,0.12); color: var(--teal); }
.month-tag.busy  { background: rgba(230,57,70,0.12);  color: var(--clash-deep); }

.holiday-list {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 6px;
}
.holiday-item {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  background: var(--cream);
  border: 1px solid transparent;
}
.holiday-item.clash {
  background: rgba(230,57,70,0.08);
  border-color: rgba(230,57,70,0.18);
}
.holiday-item.long-weekend {
  background: rgba(212,169,73,0.10);
  border-color: rgba(212,169,73,0.25);
}
.holiday-date {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  min-width: 38px;
}
.holiday-name { flex: 1; color: var(--ink-soft); }
.holiday-flags { display: flex; gap: 3px; flex-wrap: wrap; }
.flag-badge {
  font-size: 10px;
  font-weight: 700;
  background: var(--ink);
  color: var(--cream);
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.04em;
}
.holiday-item.long-weekend .holiday-date::after {
  content: " ★";
  color: var(--gold);
}

.month-empty {
  text-align: center;
  padding: 18px 0;
  color: var(--ink-mute);
  font-size: 13px;
  font-style: italic;
}

.legend {
  display: flex; gap: 18px; flex-wrap: wrap;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px dashed var(--rule);
  font-size: 13px;
  color: var(--ink-mute);
}
.legend-item { display: flex; align-items: center; gap: 6px; }
.legend-dot {
  width: 12px; height: 12px; border-radius: 50%;
  display: inline-block;
}
.legend-dot.clash       { background: var(--clash); }
.legend-dot.long-weekend{ background: var(--gold);  }
.legend-dot.clean       { background: var(--teal);  }

/* ---------- HOW section ---------- */
.how-section { padding: 100px 0; }
.how-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 32px;
}
.how-card {
  background: white;
  border: 1px solid var(--rule);
  border-radius: var(--radius-md);
  padding: 32px 28px;
  position: relative;
  transition: transform .25s ease, box-shadow .25s ease;
}
.how-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.how-num {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--clash);
  margin-bottom: 16px;
}
.how-card h3 {
  font-size: 1.4rem;
  margin-bottom: 12px;
}
.how-card p {
  color: var(--ink-soft);
  margin: 0;
  font-size: 15.5px;
}

/* ---------- USE CASES ---------- */
.usecases-section {
  padding: 100px 0;
  background: var(--cream-deep);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.usecases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px 48px;
  margin-top: 32px;
}
.usecase h3 {
  font-size: 1.3rem;
  margin-bottom: 8px;
  color: var(--ink);
}
.usecase h3::before {
  content: "—";
  color: var(--clash);
  margin-right: 8px;
  font-weight: 800;
}
.usecase p {
  color: var(--ink-soft);
  margin: 0;
  font-size: 15.5px;
}

/* ---------- FAQ ---------- */
.faq-section { padding: 100px 0; }
.faq {
  max-width: 760px;
}
.faq details {
  border-bottom: 1px solid var(--rule);
  padding: 18px 0;
}
.faq summary {
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  list-style: none;
  display: flex; justify-content: space-between; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-size: 1.6rem;
  color: var(--clash);
  font-weight: 400;
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p {
  margin: 12px 0 0;
  color: var(--ink-soft);
}

/* ---------- footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--cream);
  padding: 60px 0 40px;
}
.site-footer .logo-text { color: var(--cream); }
.site-footer .logo-text em { color: var(--clash); }
.footer-inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 32px;
  align-items: start;
}
.footer-brand p { margin: 12px 0 0; color: rgba(244,239,230,0.5); }
.footer-nav { display: flex; flex-direction: column; gap: 8px; }
.footer-nav a {
  color: rgba(244,239,230,0.7);
  text-decoration: none;
  font-size: 14px;
}
.footer-nav a:hover { color: var(--cream); text-decoration: underline; }
.footer-meta { text-align: right; }
.footer-meta p { color: rgba(244,239,230,0.5); margin: 0; }

@media (max-width: 720px) {
  .footer-inner { grid-template-columns: 1fr; }
  .footer-meta { text-align: left; }
  .hero-stats { gap: 24px; }
  .hero-stats strong { font-size: 1.6rem; }
  .picker-row { flex-direction: column; align-items: stretch; }
  .picker-label { min-width: 0; }
}

/* ---------- subtle entrance animation ---------- */
@media (prefers-reduced-motion: no-preference) {
  .hero-eyebrow, .hero-title, .hero-lede, .hero-cta, .hero-stats {
    animation: rise .8s ease both;
  }
  .hero-eyebrow { animation-delay: .05s; }
  .hero-title   { animation-delay: .15s; }
  .hero-lede    { animation-delay: .30s; }
  .hero-cta     { animation-delay: .45s; }
  .hero-stats   { animation-delay: .60s; }

  @keyframes rise {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
  }
}
