/* ==========================================================================
   YWI — shared design system
   Rose-red brand, modern serif display + clean sans body, photo-led layouts.
   Linked by every page except ywi-success.html (which has its own small sheet).
   ========================================================================== */

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

:root {
  /* Brand palette */
  --rose:        #C8124B;   /* primary: red rose */
  --rose-deep:   #8F0B36;   /* hover / pressed */
  --rose-bright: #EC3B70;   /* glows, accents on dark */
  --blush:       #FDEEF2;   /* soft section backgrounds */
  --blush-2:     #F8D7E1;   /* borders on blush, tints */
  --ink:         #17111A;   /* near-black, cool (not brown) */
  --ink-2:       #2A2130;
  --muted:       #6E6370;
  --line:        #EEDFE4;
  --paper:       #FFFBFA;
  --white:       #FFFFFF;
  --success:     #1F7A55;

  /* Legacy aliases — keep page-level inline styles (e.g. register.html) on-brand */
  --red: var(--rose);
  --red-dark: var(--rose-deep);
  --red-deep: var(--ink);
  --cream: var(--blush);
  --cream-mid: var(--blush-2);
  --tan: #E7C9D3;
  --tan-dark: var(--muted);
  --black: var(--ink);
  --green: var(--success);

  /* Type */
  --font-display: 'Instrument Serif', 'Times New Roman', serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-editorial: var(--font-body);
  --font-script: var(--font-display);

  /* Shape & motion */
  --radius-sm: 12px;
  --radius: 20px;
  --radius-lg: 28px;
  --shadow: 0 1px 2px rgba(23,17,26,0.04), 0 8px 24px rgba(23,17,26,0.06);
  --shadow-lg: 0 24px 60px rgba(23,17,26,0.14);
  --ease: cubic-bezier(.22,1,.36,1);
  --header-h: 72px;
}

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

:focus-visible { outline: 2px solid var(--rose); outline-offset: 3px; border-radius: 6px; }

/* ── HEADER / NAV ─────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(255,251,250,0.82);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
  transition: background 0.3s, border-color 0.3s, color 0.3s;
}

.site-header__inner {
  max-width: 1240px;
  height: 100%;
  margin: 0 auto;
  padding: 0 clamp(1rem, 3vw, 2rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: var(--ink);
}
.brand__mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--rose);
  color: var(--white);
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}
.brand__name {
  font-weight: 700;
  font-size: 0.92rem;
  letter-spacing: -0.01em;
  line-height: 1.15;
  max-width: 13ch;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 2rem);
}
.site-nav a {
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--ink-2);
  position: relative;
  transition: color 0.2s;
}
.site-nav a:not(.btn)::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 2px;
  border-radius: 2px;
  background: var(--rose);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.site-nav a:not(.btn):hover::after,
.site-nav a[aria-current="page"]:not(.btn)::after { transform: scaleX(1); }
.site-nav a[aria-current="page"]:not(.btn) { color: var(--rose); }
.site-nav .btn--rose { color: var(--white); }

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  position: relative;
  color: inherit;
}
.nav-toggle span:not(.sr-only) {
  position: absolute;
  left: 12px; right: 12px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.3s var(--ease), top 0.3s var(--ease);
}
.nav-toggle span:nth-child(1) { top: 17px; }
.nav-toggle span:nth-child(2) { top: 25px; }
.nav-open .nav-toggle span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.nav-open .nav-toggle span:nth-child(2) { top: 21px; transform: rotate(-45deg); }

/* Transparent header over a full-bleed photo hero (home page) */
.site-header--overlay {
  position: fixed;
  left: 0; right: 0;
  background: transparent;
  border-color: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: var(--white);
}
.site-header--overlay .brand,
.site-header--overlay .site-nav a:not(.btn) { color: var(--white); }
.site-header--overlay .site-nav a:not(.btn)::after { background: var(--white); }
.site-header--overlay.is-scrolled {
  background: rgba(255,251,250,0.86);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-color: var(--line);
  color: var(--ink);
}
.site-header--overlay.is-scrolled .brand,
.site-header--overlay.is-scrolled .site-nav a:not(.btn) { color: var(--ink-2); }
.site-header--overlay.is-scrolled .site-nav a:not(.btn)::after { background: var(--rose); }

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed;
    top: var(--header-h);
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.5rem clamp(1rem, 3vw, 2rem) 1.5rem;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s, transform 0.3s var(--ease), visibility 0.25s;
  }
  .nav-open .site-nav { opacity: 1; transform: none; visibility: visible; }
  .site-nav a:not(.btn) {
    padding: 0.95rem 0;
    font-size: 1.05rem;
    border-bottom: 1px solid var(--line);
    color: var(--ink) !important;
  }
  .site-nav a:not(.btn)::after { display: none; }
  .site-nav .btn { margin-top: 1rem; justify-content: center; }
  .nav-open.site-header--overlay {
    background: var(--paper);
    color: var(--ink);
  }
  .nav-open.site-header--overlay .brand { color: var(--ink); }
}

/* ── BUTTONS ──────────────────────────────────────── */
.btn,
.btn-primary,
.btn-outline-dark,
.btn-outline-light {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  text-decoration: none;
  padding: 0.95rem 1.6rem;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.25s, color 0.25s, border-color 0.25s, transform 0.25s var(--ease), box-shadow 0.25s;
}
.btn .arrow { transition: transform 0.3s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

.btn--rose, .btn-primary {
  background: var(--rose);
  color: var(--white);
  box-shadow: 0 8px 22px rgba(200,18,75,0.28);
}
.btn--rose:hover, .btn-primary:hover {
  background: var(--rose-deep);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(200,18,75,0.34);
}
.btn-primary:disabled {
  background: var(--tan);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

.btn--ghost, .btn-outline-dark {
  background: transparent;
  color: var(--ink);
  border-color: rgba(23,17,26,0.18);
}
.btn--ghost:hover, .btn-outline-dark:hover { border-color: var(--ink); background: var(--ink); color: var(--white); }

.btn--light, .btn-outline-light {
  background: rgba(255,255,255,0.12);
  color: var(--white);
  border-color: rgba(255,255,255,0.55);
  backdrop-filter: blur(6px);
}
.btn--light:hover, .btn-outline-light:hover { background: var(--white); color: var(--ink); border-color: var(--white); }

.btn--white { background: var(--white); color: var(--rose); }
.btn--white:hover { background: var(--ink); color: var(--white); transform: translateY(-2px); }

.btn--sm { padding: 0.65rem 1.15rem; font-size: 0.86rem; }

/* ── LAYOUT & TYPE PRIMITIVES ─────────────────────── */
.container {
  max-width: 1240px;
  margin: 0 auto;
  padding-inline: clamp(1rem, 3vw, 2rem);
}

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: clamp(3.5rem, 7vw, 5.5rem) clamp(1rem, 3vw, 2rem);
}
.wrap--narrow { max-width: 780px; }

.section-label,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 0.9rem;
}
.eyebrow::before,
.section-label::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4.6vw, 3.4rem);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 1.1rem;
}
.section-title em, .display em { font-style: italic; color: var(--rose); }

.section-body {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--ink-2);
}

.lead { font-size: clamp(1.08rem, 1.6vw, 1.22rem); line-height: 1.7; color: var(--ink-2); }

.divider {
  width: 56px;
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--rose), var(--rose-bright));
  margin: 2rem 0 2.4rem;
}

/* ── INNER-PAGE PHOTO HEADER ──────────────────────── */
.page-header {
  position: relative;
  min-height: clamp(380px, 52vh, 520px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding-top: 7rem;
  padding-bottom: clamp(3rem, 6vw, 4.5rem);
  padding-inline: max(clamp(1rem, 3vw, 2rem), calc((100% - 1080px) / 2));
  color: var(--white);
  background-color: var(--ink);
  background-size: cover;
  background-position: center;
  overflow: hidden;
  isolation: isolate;
}
/* Each page sets its photo inline: style="background-image:url(...); background-position:..." */
.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(23,17,26,0.15) 0%, rgba(23,17,26,0.35) 45%, rgba(23,17,26,0.85) 100%);
}
.page-header::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 6px;
  background: linear-gradient(90deg, var(--rose), var(--rose-bright), var(--rose));
}
.page-header__eyebrow {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--rose);
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  margin-bottom: 1.2rem;
}
.page-header__title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 5.6rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.025em;
}
.page-header__title em { font-style: italic; color: #FFC2D3; }
.page-header__sub {
  max-width: 620px;
  margin-top: 1.1rem;
  font-size: clamp(1.02rem, 1.6vw, 1.18rem);
  line-height: 1.65;
  color: rgba(255,255,255,0.88);
}
.page-header__bottom-rule { display: none; }

/* ── CARDS ────────────────────────────────────────── */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem 1.8rem;
  position: relative;
  box-shadow: var(--shadow);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.card-grid { display: grid; gap: 1.25rem; }
.card-grid--2 { grid-template-columns: repeat(2, 1fr); }
.card-grid--3 { grid-template-columns: repeat(3, 1fr); }
.card-grid--4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) {
  .card-grid--3, .card-grid--4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .card-grid--2, .card-grid--3, .card-grid--4 { grid-template-columns: 1fr; }
}

.card__eyebrow {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 0.7rem;
}
.card__price {
  font-family: var(--font-display);
  font-size: 3rem;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 0.4rem;
}
.card__price span {
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--muted);
  letter-spacing: 0;
}
.card__title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 1.1rem;
}
.card__list {
  list-style: none;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink-2);
}
.card__list li {
  padding-left: 1.7rem;
  position: relative;
  margin-bottom: 0.7rem;
}
.card__list li::before {
  content: '';
  position: absolute;
  left: 0; top: 0.2rem;
  width: 1.1rem; height: 1.1rem;
  border-radius: 50%;
  background: var(--blush) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%23C8124B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/70% no-repeat;
}

.card--featured {
  background: linear-gradient(150deg, var(--rose) 0%, var(--rose-deep) 100%);
  border-color: transparent;
  color: var(--white);
  box-shadow: 0 24px 50px rgba(200,18,75,0.3);
}
.card--featured .card__eyebrow { color: #FFC2D3; }
.card--featured .card__price,
.card--featured .card__title { color: var(--white); }
.card--featured .card__price span,
.card--featured .card__list { color: rgba(255,255,255,0.88); }
.card--featured .card__list li::before {
  background-color: rgba(255,255,255,0.18);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* ── FORMS ────────────────────────────────────────── */
.form-panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.6rem, 4vw, 2.8rem);
  box-shadow: var(--shadow-lg);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 1.2rem;
}
@media (max-width: 700px) { .form-row { grid-template-columns: 1fr; } }

.field { margin-bottom: 1.3rem; }
.field label {
  display: block;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.45rem;
}
.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field input[type="number"],
.field select,
.field textarea {
  width: 100%;
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.field input::placeholder,
.field textarea::placeholder { color: #A59AA6; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  background: var(--white);
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(200,18,75,0.12);
}
.field textarea { min-height: 120px; resize: vertical; }

.checkbox-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
}
@media (max-width: 700px) { .checkbox-group { grid-template-columns: 1fr; } }

.checkbox-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.95rem;
  padding: 0.7rem 0.9rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.checkbox-item:hover { border-color: var(--blush-2); background: var(--blush); }
.checkbox-item input { width: 18px; height: 18px; accent-color: var(--rose); flex-shrink: 0; }

.field-hint {
  font-size: 0.84rem;
  color: var(--muted);
  margin-top: 0.45rem;
}

.form-panel .btn-primary { margin-top: 0.4rem; }

/* ── QUANTITY STEPPER ─────────────────────────────── */
.stepper {
  display: inline-flex;
  align-items: center;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  overflow: hidden;
}
.stepper button {
  width: 44px;
  height: 44px;
  background: var(--blush);
  border: none;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--rose);
  cursor: pointer;
  transition: background 0.2s;
}
.stepper button:hover { background: var(--blush-2); }
.stepper button:disabled { opacity: 0.4; cursor: not-allowed; }
.stepper input {
  width: 54px;
  height: 44px;
  border: none;
  text-align: center;
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 600;
  background: var(--white);
}

/* ── ORDER SUMMARY ────────────────────────────────── */
.summary {
  background: var(--ink);
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 2rem 1.8rem;
  position: sticky;
  top: calc(var(--header-h) + 1.5rem);
  box-shadow: var(--shadow-lg);
}
.summary__row {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.summary__row--total {
  font-family: var(--font-display);
  font-size: 1.8rem;
  border-bottom: none;
  padding-top: 1.1rem;
  margin-top: 0.4rem;
  border-top: 1px solid rgba(255,255,255,0.25);
}
.summary__note {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.7);
  margin-top: 1rem;
  line-height: 1.6;
}

.split {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2.5rem;
  align-items: start;
}
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: var(--white);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 1rem 1.2rem;
  margin-bottom: 1rem;
}

.badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--white);
  background: var(--rose);
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  margin-left: 0.6rem;
}

.success-msg {
  display: none;
  background: #EAF6F0;
  border: 1.5px solid var(--success);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.3rem;
  font-size: 0.95rem;
  color: var(--success);
  margin-top: 1.2rem;
}
.success-msg.is-visible { display: block; }

/* ── FOOTER ───────────────────────────────────────── */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.72);
  padding: clamp(3.5rem, 7vw, 5rem) 0 2rem;
  font-size: 0.95rem;
}
.site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.site-footer__logo { width: 220px; height: auto; margin-bottom: 1.2rem; }
.site-footer__tag { max-width: 34ch; line-height: 1.65; }
.site-footer h4 {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 1rem;
}
.site-footer ul { list-style: none; display: grid; gap: 0.6rem; }
.site-footer a { color: rgba(255,255,255,0.72); text-decoration: none; transition: color 0.2s; }
.site-footer a:hover { color: var(--rose-bright); }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.6rem;
  padding-top: 1.6rem;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.5);
}
@media (max-width: 760px) {
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
  .site-footer__brand { grid-column: 1 / -1; }
}

/* ── SCROLL REVEAL ────────────────────────────────── */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: var(--delay, 0s);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
}
