/* ============================================
   Pozvánkovna.cz — Styly svatební pozvánky
   Jana & Petr
   ============================================ */

:root {
  --inv-bg:       #FFF9F5;
  --inv-primary:  #E8A598;
  --inv-dark:     #4A3728;
  --inv-gold:     #D4A853;
  --inv-green:    #8BAD7A;
  --inv-cream:    #F5EDE4;
  --inv-white:    #FFFFFF;
  --inv-muted:    #8A7060;

  --inv-font-script:  'Dancing Script', cursive;
  --inv-font-serif:   'Playfair Display', Georgia, serif;
  --inv-font-body:    'Nunito', sans-serif;

  --inv-radius:    20px;
  --inv-shadow:    0 8px 40px rgba(74, 55, 40, 0.12);
  --inv-shadow-lg: 0 20px 60px rgba(74, 55, 40, 0.16);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--inv-font-body);
  background: var(--inv-bg);
  color: var(--inv-dark);
  overflow-x: hidden;
}

/* ============================================
   PANEL — základní layout
   ============================================ */
.panel {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px;
  position: relative;
  overflow: hidden;
}

/* ============================================
   OKVĚTNÍ LÍSTKY — plovoucí
   ============================================ */
.petal-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.petal {
  position: absolute;
  top: -5%;
  animation: petalFall linear infinite;
  pointer-events: none;
  user-select: none;
}

/* ============================================
   PANEL 1 — COVER
   ============================================ */
.panel--cover {
  background: linear-gradient(160deg, #FFF0E8 0%, #FDEAE0 40%, #F5D5C5 100%);
  text-align: center;
  min-height: 100vh;
}

.cover__ornament {
  font-size: 2rem;
  color: var(--inv-gold);
  letter-spacing: 0.5rem;
  margin-bottom: 24px;
  opacity: 0.7;
}

.cover__subtitle {
  font-family: var(--inv-font-serif);
  font-style: italic;
  font-size: clamp(1rem, 3vw, 1.3rem);
  color: var(--inv-muted);
  margin-bottom: 20px;
  animation: fadeIn 1s ease 0.3s both;
}

.cover__names {
  font-family: var(--inv-font-script);
  font-size: clamp(3.5rem, 12vw, 7rem);
  color: var(--inv-dark);
  line-height: 1.1;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cover__names .char {
  display: inline-block;
  opacity: 0;
  animation: charReveal 0.4s ease forwards;
}

.cover__ampersand {
  font-family: var(--inv-font-script);
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: var(--inv-primary);
  display: block;
  margin: -8px 0;
}

.cover__date {
  font-family: var(--inv-font-serif);
  font-size: clamp(1rem, 3vw, 1.2rem);
  color: var(--inv-gold);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-top: 24px;
  animation: fadeUp 0.8s ease 2s both;
}

.cover__divider {
  width: 120px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--inv-primary), transparent);
  margin: 20px auto;
  animation: fadeIn 1s ease 1.8s both;
}

.cover__scroll {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  color: var(--inv-muted);
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  animation: fadeIn 1s ease 2.5s both;
}

.cover__scroll-arrow {
  width: 18px; height: 18px;
  border-right: 2px solid var(--inv-primary);
  border-bottom: 2px solid var(--inv-primary);
  transform: rotate(45deg);
  animation: float 2s ease-in-out infinite;
}

/* ============================================
   PANEL 2 — ODPOČÍTÁVÁNÍ
   ============================================ */
.panel--countdown {
  background: var(--inv-dark);
  color: var(--inv-white);
}

.countdown__label {
  font-family: var(--inv-font-serif);
  font-style: italic;
  font-size: 1.1rem;
  color: rgba(255,255,255,0.6);
  margin-bottom: 40px;
  text-align: center;
}

.countdown__grid {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.countdown__unit {
  text-align: center;
  min-width: 80px;
}

.countdown__number {
  font-family: var(--inv-font-script);
  font-size: clamp(3rem, 12vw, 5.5rem);
  color: var(--inv-primary);
  line-height: 1;
  display: block;
  transition: transform 0.3s ease;
}

.countdown__number.flip {
  animation: pop 0.3s ease;
}

.countdown__unit-label {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  margin-top: 8px;
}

.countdown__colon {
  font-family: var(--inv-font-script);
  font-size: 3rem;
  color: var(--inv-gold);
  align-self: center;
  padding-bottom: 20px;
  opacity: 0.6;
}

/* ============================================
   PANEL 3 — DETAILY
   ============================================ */
.panel--details {
  background: var(--inv-cream);
}

.details__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  max-width: 700px;
  width: 100%;
  margin-top: 32px;
}

@media (min-width: 600px) {
  .details__grid { grid-template-columns: 1fr 1fr; }
}

.detail-card {
  background: var(--inv-white);
  border-radius: var(--inv-radius);
  padding: 36px 28px;
  text-align: center;
  box-shadow: var(--inv-shadow);
  border-top: 4px solid var(--inv-primary);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.detail-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--inv-shadow-lg);
}

.detail-card__icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 12px;
}

.detail-card__type {
  font-family: var(--inv-font-serif);
  font-style: italic;
  font-size: 0.9rem;
  color: var(--inv-primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.detail-card__name {
  font-family: var(--inv-font-script);
  font-size: 1.6rem;
  color: var(--inv-dark);
  margin-bottom: 8px;
}

.detail-card__addr {
  font-size: 0.9rem;
  color: var(--inv-muted);
  line-height: 1.6;
  margin-bottom: 14px;
}

.detail-card__time {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(232, 165, 152, 0.15);
  color: var(--inv-dark);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 6px 16px;
  border-radius: 9999px;
}

.detail-card__map {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  color: var(--inv-primary);
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none;
  transition: gap 0.2s ease;
}

.detail-card__map:hover { gap: 10px; }

/* ============================================
   PANEL 4 — NÁŠ PŘÍBĚH (timeline)
   ============================================ */
.panel--story {
  background: linear-gradient(160deg, #FFF0E8, #FDE8F5);
}

.story__timeline {
  position: relative;
  max-width: 680px;
  width: 100%;
  margin-top: 40px;
}

.story__line {
  display: none;
}

@media (min-width: 600px) {
  .story__line {
    display: block;
    position: absolute;
    top: 28px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 80px);
    height: 3px;
    background: linear-gradient(90deg, var(--inv-primary), var(--inv-gold));
    border-radius: 2px;
  }

  .story__line.draw {
    animation: none;
  }
}

.story__items {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 600px) {
  .story__items { grid-template-columns: repeat(4, 1fr); gap: 0; }
}

.story__item {
  text-align: center;
  padding: 0 8px;
  position: relative;
}

.story__dot {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, var(--inv-primary), var(--inv-gold));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin: 0 auto 14px;
  box-shadow: 0 4px 16px rgba(232, 165, 152, 0.4);
  position: relative;
  z-index: 1;
}

.story__year {
  font-family: var(--inv-font-script);
  font-size: 1.4rem;
  color: var(--inv-dark);
  margin-bottom: 6px;
}

.story__text {
  font-size: 0.85rem;
  color: var(--inv-muted);
  line-height: 1.5;
}

/* ============================================
   PANEL 5 — DRESS CODE
   ============================================ */
.panel--dresscode {
  background: var(--inv-dark);
  color: var(--inv-white);
  text-align: center;
}

.dresscode__subtitle {
  font-family: var(--inv-font-serif);
  font-style: italic;
  color: rgba(255,255,255,0.65);
  max-width: 480px;
  line-height: 1.7;
  margin: 16px auto 32px;
}

.dresscode__swatches {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.swatch {
  width: 56px; height: 56px;
  border-radius: 50%;
  box-shadow: 0 4px 16px rgba(0,0,0,0.25);
  position: relative;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.swatch:hover {
  transform: scale(1.15) translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.swatch::after {
  content: attr(data-name);
  position: absolute;
  bottom: -24px;
  left: 50%; transform: translateX(-50%);
  font-size: 0.65rem;
  font-weight: 700;
  color: rgba(255,255,255,0.5);
  white-space: nowrap;
}

.dresscode__note {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.45);
  margin-top: 40px;
}

.dresscode__note strong {
  color: var(--inv-primary);
}

/* ============================================
   PANEL 6 — RSVP
   ============================================ */
.panel--rsvp {
  background: var(--inv-cream);
}

.rsvp__card {
  background: var(--inv-white);
  border-radius: var(--inv-radius);
  padding: 48px 36px;
  max-width: 520px;
  width: 100%;
  box-shadow: var(--inv-shadow-lg);
  text-align: center;
}

.rsvp__icon { font-size: 3rem; display: block; margin-bottom: 16px; }

.rsvp__title {
  font-family: var(--inv-font-script);
  font-size: 2.4rem;
  color: var(--inv-dark);
  margin-bottom: 6px;
}

.rsvp__subtitle {
  font-family: var(--inv-font-serif);
  font-style: italic;
  color: var(--inv-muted);
  font-size: 0.9rem;
  margin-bottom: 28px;
}

.rsvp__form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
}

.rsvp__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.rsvp__label {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--inv-dark);
}

.rsvp__input, .rsvp__textarea {
  font-family: var(--inv-font-body);
  font-size: 0.95rem;
  border: 2px solid #EDE0D4;
  border-radius: 12px;
  padding: 12px 16px;
  background: var(--inv-bg);
  color: var(--inv-dark);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}

.rsvp__input:focus, .rsvp__textarea:focus {
  border-color: var(--inv-primary);
  box-shadow: 0 0 0 4px rgba(232, 165, 152, 0.15);
}

.rsvp__textarea { resize: vertical; min-height: 80px; }

/* Toggle přijdu/nepřijdu */
.rsvp__toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.rsvp__toggle-btn {
  padding: 12px;
  border: 2px solid #EDE0D4;
  border-radius: 12px;
  background: var(--inv-bg);
  font-family: var(--inv-font-body);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--inv-dark);
}

.rsvp__toggle-btn:hover,
.rsvp__toggle-btn.active {
  border-color: var(--inv-primary);
  background: linear-gradient(135deg, #FFF0E8, #FDE8E4);
  color: var(--inv-dark);
}

.rsvp__toggle-btn.active--no:hover,
.rsvp__toggle-btn.active--no {
  border-color: #B0A090;
  background: #F5F0EB;
}

/* Počet osob */
.rsvp__count {
  display: flex;
  gap: 8px;
}

.rsvp__count-btn {
  padding: 8px 16px;
  border: 2px solid #EDE0D4;
  border-radius: 10px;
  background: var(--inv-bg);
  font-family: var(--inv-font-body);
  font-weight: 800;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  color: var(--inv-dark);
}

.rsvp__count-btn:hover,
.rsvp__count-btn.active {
  border-color: var(--inv-primary);
  background: linear-gradient(135deg, #FFF0E8, #FDE8E4);
}

/* Submit */
.rsvp__submit {
  background: linear-gradient(135deg, var(--inv-primary), #D4856A);
  color: white;
  border: none;
  border-radius: 14px;
  padding: 16px;
  font-family: var(--inv-font-body);
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 24px rgba(232, 165, 152, 0.45);
  margin-top: 4px;
}

.rsvp__submit:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(232, 165, 152, 0.55);
}

.rsvp__deadline {
  font-size: 0.8rem;
  color: var(--inv-muted);
  margin-top: 12px;
  text-align: center;
}

/* Stav po odeslání */
.rsvp__success {
  display: none;
  text-align: center;
  padding: 24px 0;
}

.rsvp__success.is-visible {
  display: block;
  animation: bounceIn 0.6s ease both;
}

.rsvp__success-emoji { font-size: 4rem; display: block; margin-bottom: 16px; }
.rsvp__success-title {
  font-family: var(--inv-font-script);
  font-size: 2rem;
  color: var(--inv-dark);
  margin-bottom: 8px;
}
.rsvp__success-text {
  color: var(--inv-muted);
  line-height: 1.6;
}

/* ============================================
   PANEL 7 — SIGN-OFF
   ============================================ */
.panel--signoff {
  background: linear-gradient(160deg, #FFF0E8 0%, #FDEAE0 100%);
  text-align: center;
  padding: 100px 24px;
}

.signoff__deco { font-size: 3rem; display: block; margin-bottom: 24px; }

.signoff__names {
  font-family: var(--inv-font-script);
  font-size: clamp(2.8rem, 10vw, 5rem);
  color: var(--inv-dark);
  margin-bottom: 8px;
}

.signoff__date {
  font-family: var(--inv-font-serif);
  font-style: italic;
  color: var(--inv-gold);
  font-size: 1.1rem;
  margin-bottom: 28px;
}

.signoff__message {
  font-family: var(--inv-font-serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--inv-muted);
  max-width: 420px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

.signoff__divider {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: center;
  margin-bottom: 32px;
  opacity: 0.5;
}

.signoff__divider::before,
.signoff__divider::after {
  content: '';
  height: 1px;
  width: 80px;
  background: var(--inv-primary);
}

.signoff__credit {
  font-size: 0.8rem;
  color: var(--inv-muted);
  opacity: 0.7;
}

.signoff__credit a {
  color: var(--inv-primary);
  font-weight: 700;
  text-decoration: none;
}

/* ============================================
   SEKCE HLAVIČKY (sdílené uvnitř panelů)
   ============================================ */
.inv-section-header {
  text-align: center;
  margin-bottom: 32px;
}

.inv-section-header .inv-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--inv-primary);
  background: rgba(232, 165, 152, 0.15);
  padding: 3px 12px;
  border-radius: 9999px;
  margin-bottom: 10px;
}

.inv-section-header h2 {
  font-family: var(--inv-font-script);
  font-size: clamp(2rem, 6vw, 3rem);
  color: inherit;
}

/* ============================================
   SCROLL ANIMACE
   ============================================ */
.inv-fade {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.inv-fade.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   RESPONZIVITA
   ============================================ */
@media (min-width: 768px) {
  .panel { padding: 80px 48px; }
  .rsvp__card { padding: 56px 48px; }
}
