/*
 * Copyright (c) 2026, cmaholidayparty
 * All rights reserved.
 *
 * PROPRIETARY AND CONFIDENTIAL
 *
 * Unauthorized copying, modification, distribution, disclosure,
 * or use of this software is strictly prohibited without prior
 * written permission from the copyright holder.
 *
 * THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO WARRANTIES OF
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND
 * NONINFRINGEMENT.
 *
 * TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THE COPYRIGHT
 * HOLDER SHALL NOT BE LIABLE FOR ANY CLAIM, DAMAGES, OR OTHER
 * LIABILITY, WHETHER IN CONTRACT, TORT, OR OTHERWISE, ARISING
 * FROM, OUT OF, OR IN CONNECTION WITH THE SOFTWARE OR ITS USE.
 */

/* Reusable pieces. */
.party-hero { padding: 3rem 0; background: #244537; color: #fff8eb; }
.party-hero.hero-banner { position: relative; isolation: isolate; overflow: hidden; background: #17392e; min-height: 34rem; display: flex; align-items: center; }
.party-hero.hero-banner::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, rgb(10 28 23 / .9), rgb(10 28 23 / .76) 60%, rgb(10 28 23 / .4)); }
.party-hero-inner { position: relative; z-index: 2; display: grid; gap: 2rem; align-items: center; }
.party-intro .eyebrow { color: #f4d498; }
.party-intro h1 { font-size: clamp(2.9rem, 6vw, 5.6rem); font-weight: 400; letter-spacing: -.04em; line-height: 1.02; }
.hero-theme { font-family: var(--font-heading); font-size: 1.65rem; font-style: italic; color: #f4d498; }
.hero-date { font-size: 1.05rem; margin: 1.5rem 0; }
.party-image { margin: 0; }
.party-image img { display: block; width: 100%; border: 1px solid #d8b574; border-radius: .4rem; }
.hero-banner .party-image { position: absolute; inset: 0; z-index: 0; margin: 0; }
.hero-banner .party-image img { display: block; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 65% center; border: 0; border-radius: 0; box-shadow: none; }
.hero-banner .party-intro { position: relative; z-index: 2; max-width: 38rem; }
.hero-qr { position: absolute; top: 1rem; right: 1rem; z-index: 3; width: 8.5rem; padding: .55rem; border-radius: .5rem; background: #fff; color: #17392e; text-align: center; box-shadow: 0 .4rem 1.5rem rgb(0 0 0 / .25); }
.hero-qr[hidden] { display: none; }
.hero-qr img { display: block; width: 100%; height: auto; }
.hero-qr p { margin: .35rem 0 0; font-size: .75rem; font-weight: 700; line-height: 1.2; }
.qr-enlarge { display: block; width: 100%; padding: 0; border: 0; background: #fff; cursor: zoom-in; }
.qr-dialog { width: min(36rem, calc(100% - 2rem)); max-height: calc(100dvh - 2rem); overflow: auto; padding: 1.25rem; border: 1px solid #b58a46; border-radius: .75rem; background: #fff; color: #17392e; text-align: center; }
.qr-dialog:not([open]) { visibility: hidden; }
.qr-dialog::backdrop { background: rgb(0 0 0 / .7); }
.qr-dialog h2 { font-size: 1.5rem; }
.qr-dialog img { display: block; width: min(100%, 28rem); height: auto; margin: 0 auto 1rem; }
.qr-dialog button { padding: .7rem 1.25rem; cursor: pointer; }
@media (max-width: 47.999rem) { .party-hero.hero-banner { padding-top: 11rem; } .hero-qr { width: 7.5rem; } }
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: scroll()) {
    .hero-banner .party-image { bottom: -35vh; animation: holiday-hero-parallax linear both; animation-timeline: scroll(root); animation-range: 0 100vh; }
  }
}
@keyframes holiday-hero-parallax { to { transform: translateY(50vh); } }
.hero-banner .button { background: #f4d498; color: #17392e; border-color: #f4d498; }
.hero-banner .button:hover { background: #fff0cf; border-color: #fff0cf; }
.holiday-poster-dialog { width: min(22rem, calc(100% - 2rem)); max-height: calc(100dvh - 2rem); overflow: auto; padding: 1.25rem; border: 2px solid #d8b574; border-radius: .6rem; background: #244537; color: #fff8eb; text-align: center; }
.holiday-poster-dialog::backdrop { background: rgb(0 0 0 / .7); }
.holiday-poster-dialog h2 { font-size: 1.4rem; margin: 0 0 .75rem; }
.holiday-poster-dialog .button { margin-top: .75rem; }
.holiday-poster { margin: 0 auto; max-width: 16rem; text-align: center; }
.holiday-poster img { display: block; width: 100%; height: auto; border: 3px solid #f4d498; border-radius: .35rem; }
.holiday-poster figcaption { margin-top: .5rem; color: #fff8eb; font-family: var(--font-heading); font-size: 1.1rem; }
.party-content { padding-top: 2rem; padding-bottom: 4rem; }
.party-tab-nav { display: flex; flex-wrap: wrap; gap: .3rem; border-bottom: 1px solid var(--color-border); }
.party-tab-nav a { display: block; padding: .8rem 1rem; color: var(--color-text); font-weight: 700; text-decoration: none; border-bottom: 3px solid transparent; }
.party-tab-nav a:hover, .party-tab-nav a[aria-selected="true"] { color: var(--color-primary); border-bottom-color: var(--color-primary); }
.party-panels { position: relative; overflow: clip; }
[data-tab-panel][hidden] { display: block; position: absolute; top: 0; left: 0; width: 100%; visibility: hidden; pointer-events: none; }
[data-confirmation][hidden] { display: none; }
[data-registration-open][hidden], [data-registration-closed][hidden], #tab-register[hidden] { display: none; }
.registration-full-notice { display: inline-block; margin: 0; padding: 1rem 1.5rem; border-radius: .4rem; background: #b51f2b; color: #fff; font-size: 1.2rem; font-weight: 700; }
.registration-confirmation { margin-top: 1.25rem; padding: clamp(1.25rem, 4vw, 2rem); border: 2px solid #b58a46; border-radius: .75rem; background: #fff8eb; box-shadow: 0 .75rem 2rem rgb(36 69 55 / .14); }
.registration-confirmation h3 { color: #244537; font-size: clamp(1.6rem, 4vw, 2.2rem); }
.registration-confirmation .bring-dish-cta { display: flex; width: fit-content; min-height: 3.5rem; align-items: center; justify-content: center; gap: .75rem; margin: 1rem 0; padding: .9rem 1.5rem; font-size: 1.2rem; font-weight: 700; }
.registration-confirmation > p:last-child { margin-bottom: 0; }
.party-panel { padding: 2.5rem 0; max-width: 58rem; scroll-margin-top: 5rem; }
.party-panel h2 { font-size: clamp(2.3rem, 4vw, 3.5rem); font-weight: 400; letter-spacing: -.025em; }
.party-panel h3 { font-size: 1.3rem; }
.movie-details { display: grid; gap: 1.5rem; margin-top: 1.5rem; align-items: start; }
.movie-poster { margin: 0; max-width: 16.25rem; }
.movie-poster img { display: block; width: 100%; height: auto; border: 1px solid #b58a46; border-radius: .35rem; }
@media (min-width: 48rem) { .movie-details { grid-template-columns: minmax(0, 16.25rem) minmax(0, 1fr); gap: 2rem; } }
.panel-lead { font-family: var(--font-heading); font-size: 1.4rem; max-width: 40rem; }
.detail-grid { display: grid; gap: 1.5rem; margin: 2rem 0; }
.detail-grid > div { border-top: 2px solid #b58a46; padding-top: 1rem; }
.panel-note { background: #f0e5d1; border-left: 4px solid #b58a46; padding: 1.5rem; margin-top: 2rem; }
.panel-note p:last-child { margin-bottom: 0; }
.party-panel address { font-style: normal; font-size: 1.2rem; margin-bottom: 1rem; }
.party-location-map { margin: 1.5rem 0; }
.party-location-map img { display: block; width: 100%; height: auto; border: 1px solid var(--color-border); border-radius: var(--radius); }
.party-location-map figcaption { margin-top: .5rem; color: var(--color-muted); font-size: .9rem; }
[data-registration-form] form, [data-potluck-form] form { display: grid; gap: .5rem; max-width: 32rem; margin: 1rem 0; }
[data-registration-form] form[hidden], [data-potluck-form] form[hidden] { display: none; }
[data-registration-form] input, [data-potluck-form] input { width: 100%; padding: .65rem; border: 1px solid var(--color-border); border-radius: var(--radius); }
[data-registration-form] button, [data-potluck-form] button { justify-self: start; margin-top: .5rem; cursor: pointer; }
[data-dish-list] { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 1rem; }
[data-dish-list] li { border: 1px solid var(--color-border); border-radius: var(--radius); overflow: hidden; font-weight: 700; overflow-wrap: anywhere; }
[data-dish-list] img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
[data-dish-list] span { display: block; padding: .75rem; }
button:disabled { opacity: .6; cursor: wait; }
.dish-review-dialog { width: min(38rem, calc(100% - 2rem)); max-height: calc(100dvh - 2rem); overflow: auto; padding: 1.25rem; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-surface); color: var(--color-text); }
.dish-review-dialog::backdrop { background: rgb(0 0 0 / .68); }
.dish-review-dialog img { display: block; width: min(100%, 28rem); max-height: 48dvh; object-fit: contain; margin: 1rem auto; border-radius: var(--radius); }
.dish-review-dialog input { width: 100%; padding: .65rem; border: 1px solid var(--color-border); border-radius: var(--radius); }
.dish-review-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1rem; }
.dish-review-actions button { padding: .65rem .85rem; cursor: pointer; }
.dish-review-actions button.is-spinner { position: relative; padding-left: 2.3rem; cursor: wait; }
.dish-review-actions button.is-spinner::before { content: ""; position: absolute; left: .75rem; top: 50%; width: 1rem; height: 1rem; margin-top: -.5rem; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; }
@media (prefers-reduced-motion: no-preference) { .dish-review-actions button.is-spinner::before { animation: dish-review-spin .8s linear infinite; } }
@keyframes dish-review-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .dish-review-actions button.is-spinner::before { border-style: dashed; } }
@media (max-width: 47.999rem) { .dish-review-actions { display: grid; } .dish-review-actions button { width: 100%; } }
.table-scroll { max-width: 100%; overflow-x: auto; }
.table-scroll table { width: 100%; border-collapse: collapse; }
.table-scroll caption { padding: .75rem 0; text-align: left; }
.table-scroll th, .table-scroll td { padding: .65rem .75rem; border: 1px solid var(--color-border); text-align: left; vertical-align: top; }
.table-scroll th { background: var(--color-surface); }
.table-scroll td { overflow-wrap: anywhere; }
@media (min-width: 48rem) {
  .party-hero { padding: 4rem 0; }
  .party-hero-inner { grid-template-columns: minmax(0, 1fr); gap: 3rem; }
  .party-hero.hero-banner { min-height: 38rem; }
  .party-hero.hero-banner::before { background: linear-gradient(90deg, rgb(10 28 23 / .92), rgb(10 28 23 / .78) 42%, rgb(10 28 23 / .15) 90%); }
  .detail-grid { grid-template-columns: repeat(3, 1fr); }
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-text);
  text-decoration: none;
  font-weight: 700;
  font-size: var(--text-lg);
}

.brand-logo {
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 auto;
  object-fit: contain;
  border-radius: 50%;
  background: #1d5ebd;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--color-text);
  cursor: pointer;
}

@media (max-width: 47.999rem) {
  .has-nav-toggle .nav-toggle { display: inline-flex; }
}

.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  display: block;
  width: 1.25rem;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  position: relative;
}

.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: "";
  position: absolute;
  left: 0;
}

.nav-toggle-bar::before { top: -6px; }
.nav-toggle-bar::after { top: 6px; }

.nav-link {
  display: block;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius);
  color: var(--color-text);
  text-decoration: none;
}

.nav-link:hover {
  background: var(--color-bg);
}

.nav-link[aria-current="page"] {
  color: var(--color-primary);
  font-weight: 600;
}

.account-link {
  display: block;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  color: var(--color-text);
  text-decoration: none;
}

.account-link:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.hero {
  padding: var(--space-12) 0 var(--space-8);
  background: linear-gradient(160deg, var(--color-surface), var(--color-bg));
  border-bottom: 1px solid var(--color-border);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-accent);
  margin-bottom: var(--space-2);
}

.hero-title {
  font-size: var(--text-2xl);
  max-width: 20ch;
}

.lead {
  font-size: var(--text-lg);
  color: var(--color-muted);
  max-width: 60ch;
}

.button {
  display: inline-block;
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius);
  background: var(--color-primary);
  color: var(--color-primary-contrast);
  font-weight: 600;
  text-decoration: none;
}

.button:hover {
  filter: brightness(1.08);
}

.section-title {
  margin-bottom: var(--space-6);
}

.card-grid {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--space-4);
}

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-6);
  box-shadow: var(--shadow);
}

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

.card p:last-child {
  margin-bottom: 0;
}

.prose {
  max-width: 46rem;
}

.steps li {
  margin-bottom: var(--space-2);
}

.media {
  margin: var(--space-6) 0;
}

.media img,
.media video {
  display: block;
  border-radius: var(--radius);
}

.media figcaption {
  margin-top: var(--space-2);
  color: var(--color-muted);
  font-size: var(--text-sm);
}

@media (min-width: 48rem) {
  .nav-toggle {
    display: none;
  }

  .hero-title {
    font-size: var(--text-3xl);
  }

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