/* Adrienne & Nick | wedding site */

:root {
  --cream: #f3f1e8;
  --ink: #3a3d2e;
  --olive: #63703a;
  --olive-dark: #4b562b;
  --sage: #5d614d;
  --lilac: #d6bdd1;
  --plum: #4f2638;
  --chartreuse: #e6f09c;

  --font-heading: "BIZ UDPMincho", "Hiragino Mincho ProN", Georgia, serif;
  --font-body: "Futura PT", "futura-pt", "Jost", "Futura", "Century Gothic", system-ui, sans-serif;

  --header-h: 96px;
  --gutter: clamp(20px, 4vw, 56px);
  --content: 1280px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-padding-top: var(--header-h); }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main { flex: 1 0 auto; }

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

a { color: inherit; }

::selection { background: var(--lilac); color: var(--plum); }

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

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

.skip-link {
  position: absolute;
  left: 12px; top: -100px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--cream);
  color: var(--olive);
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 100px;
  height: 40px;
  padding: 0 26px;
  border: 0;
  border-radius: 0;
  background: var(--olive);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 13px;
  letter-spacing: 0.06em;
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.btn:hover { background: var(--olive-dark); }

.btn--light { background: var(--cream); color: var(--olive); }
.btn--light:hover { background: #e4e1d3; color: var(--olive-dark); }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: var(--olive);
  color: var(--cream);
}

.site-header__inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 clamp(20px, 2.2vw, 32px);
}

.site-header__logo { display: block; flex-shrink: 0; }
.site-header__logo img { width: auto; height: 60px; }

.site-nav { display: flex; align-items: center; gap: clamp(28px, 4.5vw, 64px); }

.site-nav__list {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2vw, 28px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav__link {
  position: relative;
  font-size: 15px;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: var(--cream);
  padding: 6px 0;
}
.site-nav__link::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--chartreuse);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}
.site-nav__link:hover::after,
.site-nav__link[aria-current="page"]::after { transform: scaleX(1); }

.site-header__actions { display: none; align-items: center; gap: 16px; }

.menu-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 0 6px;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.menu-toggle span {
  display: block;
  height: 1px;
  background: var(--cream);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* Mobile menu panel */
.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 0 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 36px;
  padding: 48px var(--gutter) 40px;
  background: var(--cream);
  overflow-y: auto;
}
.mobile-menu[hidden] { display: none; }

.mobile-menu__wordmark { width: 170px; }

.mobile-menu__list {
  margin: 0;
  padding: 0;
  list-style: none;
  text-align: center;
}
.mobile-menu__list li + li { border-top: 1px solid rgba(99, 112, 58, 0.25); }
.mobile-menu__list a {
  display: block;
  min-width: 220px;
  padding: 16px 0;
  font-family: var(--font-heading);
  font-size: 22px;
  color: var(--olive);
  text-decoration: none;
}
.mobile-menu__list a[aria-current="page"] { color: var(--plum); }

body.menu-open { overflow: hidden; }

/* ---------- Home ---------- */

.hero {
  position: relative;
  height: clamp(380px, 41.6vw, 760px);
  overflow: hidden;
  background: var(--sage);
}
.hero picture,
.hero img {
  width: 100%;
  height: 100%;
}
.hero img {
  object-fit: cover;
  object-position: 50% 38%;
}

.intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: clamp(56px, 6vw, 84px) var(--gutter) clamp(72px, 8vw, 110px);
}

.intro__wordmark {
  width: min(466px, 82vw);
  margin: 0 0 22px;
}
.intro__wordmark img { width: 100%; }

.intro__details {
  margin: 0;
  font-size: 17px;
  letter-spacing: 0.01em;
}
.intro__details p { margin: 0; }
.intro__details p + p { margin-top: 18px; }
.intro__details .sep { padding: 0 0.35em; }

.intro__cta { margin-top: 26px; }

.portrait {
  margin: clamp(64px, 6vw, 84px) 0 0;
  width: min(304px, 78vw);
  padding: 3px;
  background: var(--cream);
  box-shadow: 0 2px 4px rgba(58, 61, 46, 0.14), 0 8px 22px rgba(58, 61, 46, 0.18);
}
.portrait img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }

.rsvp-note {
  margin: 36px 0 0;
  font-size: 16px;
  letter-spacing: 0.02em;
  color: var(--sage);
}

/* ---------- Inner pages ---------- */

.page {
  width: 100%;
  max-width: 920px;
  margin: 0 auto;
  padding: clamp(64px, 8vw, 112px) var(--gutter) clamp(72px, 9vw, 120px);
}

.page-head { text-align: center; margin-bottom: clamp(48px, 6vw, 72px); }

.eyebrow {
  display: block;
  margin: 0 0 14px;
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sage);
}

.page-title {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.2;
  color: var(--olive);
}

.page-lede {
  max-width: 620px;
  margin: 22px auto 0;
  font-size: 17px;
}

.h2 {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: clamp(22px, 2.6vw, 28px);
  line-height: 1.3;
  color: var(--olive);
}

.ornament {
  display: block;
  width: 44px;
  height: auto;
  margin: 0 auto 26px;
}

.rule {
  border: 0;
  border-top: 1px solid var(--olive);
  margin: 0;
}

.page-cta {
  margin-top: clamp(56px, 7vw, 88px);
  text-align: center;
}
.page-cta p { margin: 0 0 20px; color: var(--sage); }

/* Schedule */
.timeline { margin: 0; padding: 0; list-style: none; }
.timeline__item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 32px;
  padding: 34px 0;
  border-top: 1px solid rgba(99, 112, 58, 0.35);
}
.timeline__item:last-child { border-bottom: 1px solid rgba(99, 112, 58, 0.35); }
.timeline__time {
  font-family: var(--font-heading);
  font-size: clamp(26px, 3vw, 32px);
  line-height: 1.1;
  color: var(--olive);
  white-space: nowrap;
}
.timeline__date {
  display: block;
  margin-top: 8px;
  font-family: var(--font-body);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
}
.timeline__body p { margin: 6px 0 0; }
.timeline__venue { color: var(--sage); }

/* Attire */
.dress-code {
  text-align: center;
  padding: clamp(36px, 5vw, 56px) clamp(20px, 4vw, 48px);
  border-top: 1px solid var(--olive);
  border-bottom: 1px solid var(--olive);
}
.dress-code__name {
  margin: 0;
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: clamp(30px, 4.4vw, 44px);
  color: var(--plum);
}
.dress-code p { max-width: 600px; margin: 18px auto 0; }

.attire-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  margin-top: clamp(48px, 6vw, 72px);
}
.attire-grid p { margin: 12px 0 0; }

.swatches { display: flex; gap: 18px; margin: 20px 0 0; padding: 0; list-style: none; }
.swatch { text-align: center; font-size: 13px; color: var(--sage); }
.swatch__chip {
  position: relative;
  display: block;
  width: 52px;
  height: 52px;
  margin: 0 auto 8px;
  border: 1px solid rgba(58, 61, 46, 0.3);
  border-radius: 50%;
  overflow: hidden;
}
.swatch__chip::after {
  content: "";
  position: absolute;
  left: 50%; top: -10%;
  width: 1px; height: 120%;
  background: var(--plum);
  transform: rotate(45deg);
}

.palette {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}
.palette__chip {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(58, 61, 46, 0.18);
}
.palette__label {
  display: block;
  margin-top: 26px;
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--sage);
}
.palette__label + .swatches { margin-top: 12px; }

/* Registry */
.gift-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(20px, 4vw, 40px);
  max-width: 720px;
  margin: 0 auto;
}
.gift-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(28px, 4vw, 44px) clamp(20px, 3vw, 32px);
  border: 1px solid var(--olive);
  text-align: center;
}
.gift-card__qr {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 220px;
  aspect-ratio: 1;
  margin-top: 22px;
  padding: 16px;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage);
  border: 1px dashed rgba(99, 112, 58, 0.55);
  background: rgba(214, 189, 209, 0.18);
}
.gift-card__qr img { width: 100%; height: 100%; object-fit: contain; }
.gift-card__qr:has(img) { padding: 0; border: 0; background: none; }
.gift-card__handle { margin: 16px 0 0; font-size: 15px; color: var(--sage); }
.gift-card__handle:empty { display: none; }

/* FAQs */
.faq { margin: 0; padding: 0; list-style: none; }
.faq__item {
  padding: 34px 0;
  border-top: 1px solid rgba(99, 112, 58, 0.35);
}
.faq__item:last-child { border-bottom: 1px solid rgba(99, 112, 58, 0.35); }
.faq__item p { margin: 12px 0 0; }

.hotels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
}
.hotel {
  padding: 20px 20px 22px;
  border: 1px solid rgba(99, 112, 58, 0.4);
  font-size: 15px;
  line-height: 1.5;
}
.hotel__name {
  display: block;
  margin-bottom: 6px;
  font-family: var(--font-heading);
  font-size: 18px;
  color: var(--olive);
}
.hotel--featured {
  border-color: var(--plum);
  background: rgba(214, 189, 209, 0.22);
}
.hotel__tag {
  display: block;
  margin-bottom: 8px;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--plum);
}
.hotel__distance {
  display: block;
  margin-top: 10px;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--plum);
}

/* ---------- Photos ---------- */

.photo-frame {
  margin: 0;
  padding: 3px;
  background: var(--cream);
  box-shadow: 0 2px 4px rgba(58, 61, 46, 0.14), 0 8px 22px rgba(58, 61, 46, 0.18);
}
.photo-frame img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }

.photo-trio {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(14px, 2.4vw, 32px);
  width: 100%;
  max-width: 980px;
  margin: clamp(64px, 7vw, 96px) auto 0;
  padding: 0;
  list-style: none;
}
.photo-trio li:nth-child(2) { transform: translateY(clamp(16px, 3vw, 40px)); }

.page-banner {
  position: relative;
  height: clamp(280px, 38vw, 580px);
  overflow: hidden;
  background: var(--sage);
}
.page-banner picture,
.page-banner img { width: 100%; height: 100%; }
.page-banner img { object-fit: cover; object-position: 50% 62%; }

.photo-feature {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  align-items: center;
  gap: clamp(32px, 6vw, 72px);
}
.photo-feature .photo-frame { max-width: 360px; justify-self: center; width: 100%; }
.photo-feature p { margin: 12px 0 0; }

.photo-center {
  width: min(320px, 78vw);
  margin: 0 auto clamp(44px, 6vw, 64px);
}
.photo-center--tilt-l { transform: rotate(-1.5deg); }
.photo-center--tilt-r { transform: rotate(1.5deg); }

/* Attire inspiration board */
.inspo-board {
  max-width: 640px;
  margin: clamp(56px, 7vw, 88px) auto 0;
  text-align: center;
}
.inspo-board .h2 { margin-bottom: 10px; }
.inspo-board p { max-width: 520px; margin: 0 auto 26px; color: var(--sage); }
.inspo-board__img {
  margin: 0;
  padding: clamp(10px, 2vw, 20px);
  background: #fff;
  border: 1px solid rgba(99, 112, 58, 0.35);
}
.inspo-board__img img { width: 100%; }

/* Named palette chips */
.palette--named { display: grid; grid-template-columns: repeat(3, 72px); gap: 18px 14px; }
.palette--named li {
  width: auto;
  text-align: center;
  font-size: 12px;
  line-height: 1.3;
  color: var(--sage);
}
.palette--named .palette__chip {
  display: block;
  width: 52px;
  height: 52px;
  margin: 0 auto 8px;
}

/* ---------- Password gate ---------- */

html.is-locked,
html.is-locked body { overflow: hidden; }
html.is-locked body > *:not(.gate) { visibility: hidden; }

.gate {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 48px var(--gutter);
  background: var(--cream);
  color: var(--ink);
  text-align: center;
  overflow-y: auto;
  animation: gate-in 0.5s ease both;
}
.gate::before {
  content: "";
  position: fixed;
  inset: clamp(12px, 2vw, 24px);
  border: 1px solid rgba(99, 112, 58, 0.35);
  pointer-events: none;
}
.gate__inner {
  position: relative;
  flex-shrink: 0;
  margin-top: auto;
  width: 100%;
  max-width: 560px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.gate__logo { flex-shrink: 0; width: 60px; height: auto; margin-bottom: 22px; }
.gate__title {
  width: min(440px, 100%);
  margin: 14px 0 0;
  line-height: 0;
}
.gate__title img { display: block; width: 100%; height: auto; }
.gate__text { max-width: 420px; margin: 16px 0 0; color: var(--sage); }
.gate__form {
  display: flex;
  width: 100%;
  max-width: 420px;
  margin-top: 32px;
  gap: 10px;
}
.gate__input {
  flex: 1 1 auto;
  min-width: 0;
  height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(99, 112, 58, 0.55);
  border-radius: 0;
  background: #fbfaf5;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  letter-spacing: 0.04em;
  -webkit-appearance: none;
  appearance: none;
}
.gate__input::placeholder { color: rgba(93, 97, 77, 0.7); }
.gate__input:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 1px var(--olive); }
.gate__input[aria-invalid="true"] { border-color: var(--plum); }
.gate__btn { height: 44px; flex: 0 0 auto; }
.gate__error {
  min-height: 1.5em;
  margin: 14px 0 0;
  font-size: 14px;
  color: var(--plum);
}
.gate__dog {
  position: relative;
  width: 62px;
  height: auto;
  flex-shrink: 0;
  margin-top: clamp(32px, 6vh, 56px);
  margin-bottom: auto;
}
.gate--shake .gate__form { animation: gate-shake 0.4s ease; }
.gate--leaving { animation: gate-out 0.45s ease forwards; pointer-events: none; }

@keyframes gate-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes gate-out { to { opacity: 0; visibility: hidden; } }
@keyframes gate-shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}

@media (max-width: 560px) {
  .gate { padding: 40px calc(var(--gutter) + 12px); }
  .gate__logo { width: 48px; margin-bottom: 16px; }
  .gate .eyebrow { margin-bottom: 10px; }
  .gate__title { width: min(190px, 52vw); margin-top: 8px; }
  .gate__text { margin-top: 14px; font-size: 15px; }
  .gate__form { margin-top: 22px; gap: 8px; }
  .gate__btn { min-width: 84px; padding: 0 18px; }
  .gate__error { margin-top: 10px; }
  .gate__dog { width: 54px; margin-top: 24px; }
}
@media (max-width: 560px) and (max-height: 600px) {
  .gate { padding-top: 28px; padding-bottom: 28px; }
  .gate__title { width: min(170px, 50vw); }
  .gate__dog { margin-top: 16px; }
}

/* ---------- Footer ---------- */

.site-footer {
  padding: 0 clamp(20px, 1.6vw, 24px) 32px;
}
.site-footer .rule { margin: 0; }
.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 24px;
  padding-top: 22px;
}
.site-footer__dog { width: 70px; height: auto; }

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  :root { --header-h: 80px; }
  .site-header__logo img { height: 52px; }
  .site-nav { display: none; }
  .site-header__actions { display: flex; }
  .btn--light { height: 36px; min-width: 88px; padding: 0 22px; }

  .hero { height: clamp(420px, 92vw, 620px); }
  .hero img { object-position: 55% 45%; }

  .hotels { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .intro { padding-top: 44px; }
  .intro__wordmark { width: min(300px, 80vw); margin-bottom: 18px; }
  .intro__details { font-size: 15px; }
  .intro__details p + p { margin-top: 14px; }
  .intro__cta { margin-top: 22px; }
  .portrait { margin-top: 44px; }
  .rsvp-note { font-size: 15px; }

  .timeline__item { grid-template-columns: 1fr; gap: 12px; }
  .attire-grid { grid-template-columns: 1fr; }
  .gift-cards { grid-template-columns: 1fr; max-width: 360px; }
  .photo-feature { grid-template-columns: 1fr; }
  .photo-feature .photo-frame { max-width: 300px; }
  .photo-trio { gap: 10px; margin-top: 52px; }
  .photo-trio li:nth-child(2) { transform: translateY(14px); }

  .site-footer { padding: 0 16px 36px; }
  .site-footer__inner {
    justify-content: center;
    padding-top: 26px;
    text-align: center;
  }
  .site-footer__dog { width: 58px; }
}

@media (max-width: 380px) {
  .site-header__actions { gap: 10px; }
  .btn--light { min-width: 76px; padding: 0 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
