/**
 * RSVP Page Styles
 * Slumber party invitation page for Frank
 */

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

:root {
    --touch-min: 44px;
    /* Light teal palette */
    --bg-light: #e8f4f3;
    --teal-soft: #b8d9d6;
    --teal-mid: #7eb8b3;
    --teal-dark: #4a9690;
    /* Cream from card's text box */
    --cream: #f5ebe0;
    --cream-dark: #e8dcc8;
    /* Text */
    --text-dark: #2d4a48;
    --text-muted: #5a7876;
}

html, body {
    min-height: 100%;
}

/* ==================== */
/* Generic 404 Page     */
/* ==================== */
.page-404 {
    display: none;
    padding: 20px;
}

body.show-404 .page-404 {
    display: block;
}

/* ==================== */
/* RSVP Content (Frank) */
/* ==================== */
body.show-rsvp {
    background: var(--bg-light);
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-dark);
    min-height: 100vh;
}

.rsvp-content {
    display: none;
}

body.show-rsvp .rsvp-content {
    display: block;
}

/* Card Hero - FULL BLEED */
.card-hero {
    width: 100%;
    line-height: 0; /* Remove any gap below image */
}

.card-hero img {
    width: 100%;
    height: auto;
    display: block;
}

/* Content below card */
.rsvp-body {
    padding: 0 20px 40px;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
}

/* Post-it Note for Flight Details */
.sticky-postit {
    position: relative;
    z-index: 10;
    background: #fff9c4; /* Pastel yellow */
    border-radius: 1px;
    padding: 20px 18px 16px;
    margin: 50px auto 20px;
    max-width: 260px;
    box-shadow:
        0 4px 8px rgba(0, 0, 0, 0.12),
        0 1px 3px rgba(0, 0, 0, 0.08);
    transform: rotate(-1.5deg);
}

/* Tape effect */
.sticky-postit::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%) rotate(1deg);
    width: 50px;
    height: 18px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 1px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.postit-date {
    font-family: 'Caveat', cursive;
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.postit-flight {
    font-family: 'Caveat', cursive;
    font-size: 18px;
    color: #333;
    line-height: 1.5;
    margin-bottom: 12px;
}

.postit-signature {
    font-family: 'Caveat', cursive;
    font-size: 18px;
    color: #333;
    text-align: right;
    margin-top: 16px;
}

/* Invite Details Section (collapsible) */
.faq-section {
    padding-top: 40px;
    margin-bottom: 24px;
}

.faq-header {
    font-family: 'Nunito', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: var(--teal-dark);
    margin-bottom: 16px;
}


.faq-item {
    margin-bottom: 16px;
}

.faq-question {
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.faq-answer {
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
}

/* RSVP Deadline */
.rsvp-deadline {
    text-align: center;
    margin-bottom: 24px;
    padding: 16px;
    background: var(--teal-soft);
    border-radius: 8px;
}

.rsvp-deadline-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--teal-dark);
    margin-bottom: 4px;
}

.rsvp-deadline-date {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
}

/* RSVP Actions */
.rsvp-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn {
    min-height: var(--touch-min);
    padding: 14px 24px;
    border: none;
    border-radius: 8px;
    font-family: 'Nunito', sans-serif;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.btn:active {
    transform: scale(0.98);
}

.btn-yes {
    background: var(--teal-dark);
    color: white;
}

.btn-yes:hover {
    background: var(--teal-mid);
}

.btn-time {
    background: transparent;
    color: var(--teal-dark);
    border: 2px solid var(--teal-mid);
}

.btn-time:hover {
    background: var(--teal-soft);
}

/* Date picker section - gray style */
.date-picker-section {
    display: none;
    background: #4a4a4a;
    border-radius: 8px;
    padding: 20px;
    margin-top: 16px;
    overflow: hidden;
}

.date-picker-section.visible {
    display: block;
}

.date-picker-section label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #f5f5f5;
    margin-bottom: 8px;
    text-align: center;
}

.date-picker-section input[type="date"] {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-height: var(--touch-min);
    padding: 12px;
    font-family: 'Nunito', sans-serif;
    font-size: 16px;
    border: 1px solid #666;
    border-radius: 8px;
    background: #5a5a5a;
    color: #f5f5f5;
    margin-bottom: 12px;
    -webkit-appearance: none;
    appearance: none;
}

.date-picker-section input[type="date"]:focus {
    outline: none;
    border-color: #888;
}

.btn-submit-date {
    width: 100%;
    background: #f5f5f5;
    color: #3a3a3a;
}

.btn-submit-date:hover {
    background: #fff;
}

/* Loading state */
.btn.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Confirmation overlay */
.confirmation {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-light);
    z-index: 100;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 24px;
}

.confirmation.visible {
    display: flex;
}

.confirmation-image {
    width: 150px;
    height: auto;
    margin-bottom: 24px;
}

.confirmation p {
    font-size: 16px;
    color: var(--text-dark);
    width: 90%;
    max-width: 400px;
    line-height: 1.6;
}

.confirmation .btn-back {
    margin-top: 32px;
    background: transparent;
    color: var(--teal-dark);
    border: 2px solid var(--teal-mid);
    padding: 12px 32px;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
}

.confirmation .btn-back:hover {
    background: var(--teal-soft);
}

/* Desktop - limit card width but keep proportions */
@media (min-width: 600px) {
    .card-hero {
        max-width: 500px;
        margin: 0 auto;
        padding-top: 20px;
    }

    .card-hero img {
        border-radius: 12px;
        box-shadow: 0 8px 32px rgba(74, 150, 144, 0.2);
    }

    .rsvp-body {
        padding-top: 32px;
    }
}

/* ==================== */
/* Trip Updates Section */
/* ==================== */
.trip-updates-section {
    padding-top: 40px;
    margin-bottom: 24px;
}

.updates-header {
    font-size: 20px;
    font-weight: 700;
    color: var(--teal-dark);
    margin-bottom: 16px;
}

.update-card {
    padding: 16px 0;
    border-bottom: 1px solid #e0e0e0;
    opacity: 1;
    max-height: 1000px;
    overflow: hidden;
    transition: opacity 300ms ease, max-height 300ms ease, padding 300ms ease;
}

.update-card:last-child {
    border-bottom: none;
}

.update-card.hidden {
    opacity: 0;
    max-height: 0;
    padding: 0;
    border-bottom: none;
}

.update-date {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.update-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.update-content {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
}

.update-content p {
    margin: 0 0 8px 0;
}

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

/* Image grid container (matches Seahawks blog gallery pattern) */
.update-images {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    margin-top: 12px;
}

/* Image wrapper with aspect ratio and caption positioning */
.update-image-wrapper {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    border-radius: 6px;
}

/* Last odd image spans full width */
.update-image-wrapper:last-child:nth-child(odd) {
    grid-column: 1 / -1;
}

.update-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
}

/* Caption overlay - frosted glass with gradient */
.update-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0.75rem 0.5rem 0.35rem;
    background: linear-gradient(to top,
        rgba(230, 230, 230, 0.95) 0%,
        rgba(230, 230, 230, 0.8) 70%,
        rgba(230, 230, 230, 0) 100%
    );
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    font-family: 'Nunito', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: #333;
    text-align: center;
    cursor: pointer;
    /* Truncate long captions on mobile */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.show-all-link {
    display: block;
    width: 100%;
    padding: 12px;
    margin-top: 8px;
    background: none;
    border: none;
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--teal-dark);
    cursor: pointer;
    text-align: center;
}

.show-all-link:hover {
    text-decoration: underline;
}

/* ==================== */
/* Lightbox             */
/* ==================== */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.92);
    z-index: 200;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    opacity: 0;
    transition: opacity 200ms ease;
}

.lightbox.visible {
    display: flex;
    opacity: 1;
}

.lightbox-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    color: white;
    font-size: 32px;
    cursor: pointer;
    z-index: 201;
}

.lightbox-close:hover {
    opacity: 0.8;
}

.lightbox img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
}

.lightbox-caption {
    color: white;
    font-size: 14px;
    text-align: center;
    max-width: 600px;
    margin-top: 16px;
    padding: 0 20px;
}
