:root {
    --lavender: #C7B9FF;
    --rose: #F8BBD0;
    --moon: #B3D4FF;
    --gold: #FCEEC0;
    --euca: #C6E4DC;
    --peach: #FFD5B2;
    --ink: #1f1c2e;
    --muted: #6d6a7d;
    --glass-bg: rgba(255, 255, 255, 0.16);
    --glass-brd: rgba(255, 255, 255, 0.35);
    --shadow-soft: 0 14px 50px rgba(0, 0, 0, 0.18);
    --font-body: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --font-serif: "Cormorant Garamond", serif;
    --font-script: "Allura", cursive;
    color-scheme: light;
}

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

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

body {
    font-family: var(--font-body);
    margin: 0;
    color: var(--ink);
    background: linear-gradient(135deg, #fff5f7, #f0f4ff, #fffdf0);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a {
    color: inherit;
}

a:hover,
a:focus {
    color: inherit;
    text-decoration: underline;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* ----------------------------------------------------------
   Shared Layout Helpers
---------------------------------------------------------- */
.container {
    width: min(1100px, 94vw);
    margin: 0 auto;
}

.frost-card {
    background: var(--glass-bg);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 1px solid var(--glass-brd);
    border-radius: 22px;
    box-shadow: var(--shadow-soft);
}

button {
    font-family: inherit;
}

.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.9s ease, transform 0.9s ease;
    will-change: opacity, transform;
}

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

.site-footer-credit {
    margin-top: 32px;
    padding: 14px 0 24px;
    background: transparent;
    color: inherit;
    box-shadow: none;
}

.site-footer-credit__inner {
    width: min(1100px, 92vw);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.site-footer-credit__label {
    font-size: 13px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    opacity: 0.55;
    font-weight: 700;
}

.site-footer-credit__brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

.site-footer-credit__brand img {
    display: block;
    height: 16px;
    width: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.08));
}

.site-footer-credit__name {
    font-weight: 800;
    letter-spacing: 0.4px;
    background: linear-gradient(90deg, #0a3e53 0%, #0c7b56 100%);
    -webkit-background-clip: text;
    color: transparent;
}

/* ----------------------------------------------------------
   Home Page
---------------------------------------------------------- */
.home-page {
    color: #ffffff;
    background: #0f0f18;
}

.home-page .root {
    position: relative;
    min-height: 100vh;
    isolation: isolate;
}

.home-page .slideshow {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.home-page .slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.6s ease;
}

.home-page .slide.active {
    opacity: 1;
}

.home-page .slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.2) brightness(1.02);
    transform: scale(1.02);
}

.home-page .pastel-glow {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    mix-blend-mode: soft-light;
    background: linear-gradient(135deg, rgba(199, 185, 255, 0.4), rgba(248, 187, 208, 0.4), rgba(252, 238, 192, 0.4));
    animation: glow 14s ease-in-out infinite alternate;
}

@keyframes glow {
    0% {
        background: linear-gradient(135deg, rgba(199, 185, 255, 0.4), rgba(248, 187, 208, 0.4));
    }
    50% {
        background: linear-gradient(135deg, rgba(198, 228, 220, 0.4), rgba(252, 238, 192, 0.4));
    }
    100% {
        background: linear-gradient(135deg, rgba(179, 212, 255, 0.4), rgba(255, 213, 178, 0.4));
    }
}

.home-page .ui {
    position: sticky;
    top: 0;
    height: 100vh;
    display: grid;
    place-items: center;
    z-index: 3;
    pointer-events: none;
}

.home-page .ui-inner {
    pointer-events: auto;
    width: min(960px, 94vw);
    padding: 24px;
    text-align: center;
}

.home-page .hero-card {
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    align-items: center;
}

.home-page .names {
    font-family: var(--font-script);
    font-size: clamp(48px, 12vw, 112px);
    margin: 12px 0 6px;
    text-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.home-page .date {
    font-family: var(--font-serif);
    font-size: clamp(18px, 4.5vw, 32px);
    letter-spacing: 2px;
    opacity: 0.92;
    text-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.home-page .countdown {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.home-page .tile {
    padding: 14px 16px;
    min-width: 86px;
    border-radius: 16px;
    border: 1px solid var(--glass-brd);
    background: var(--glass-bg);
    transition: transform 0.25s ease;
}

.home-page .tile:hover {
    transform: translateY(-4px);
}

.home-page .num {
    font-family: var(--font-serif);
    font-size: clamp(24px, 6vw, 48px);
    font-weight: 700;
    display: block;
}

.home-page .lbl {
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    opacity: 0.9;
}

.home-page .search {
    width: min(540px, 92%);
    margin-inline: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 8px 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--glass-brd);
    background: var(--glass-bg);
}

.home-page .search input {
    background: transparent;
    border: 0;
    outline: 0;
    flex: 1;
    color: #ffffff;
    font-size: 16px;
    padding: 10px 6px;
}

.home-page .search input::placeholder {
    color: rgba(255, 255, 255, 0.85);
}

.home-page .search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 0;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.home-page .search button:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: translateY(-1px);
}

.home-page .search button svg {
    width: 20px;
    height: 20px;
}

.home-page .stream {
    position: relative;
    z-index: 1;
}

.home-page .search-results.search-page {
    display: none;
    width: 100%;
    max-width: 1400px;
    margin: 4rem auto;
    padding: 2rem;
}

.home-page .search-results.search-page.has-results {
    display: block;
}

.home-page .search-results .results {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 2rem;
    min-height: 400px;
}

@media (max-width: 968px) {
    .home-page .search-results .results {
        grid-template-columns: 1fr;
    }
}

.home-page .results-list {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.home-page .invitation-details {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.home-page .invitation-details[hidden] {
    display: none;
}

.home-page .placeholder,
.home-page .invitation-placeholder {
    text-align: center;
    padding: 3rem 1.5rem;
    color: #666;
}

.home-page .placeholder h3,
.home-page .invitation-placeholder h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.home-page .loading {
    text-align: center;
    padding: 2rem;
    font-size: 1.1rem;
    color: #666;
}

.home-page .result-items {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 1rem;
}

.home-page .result-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    padding: 1rem;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    width: 100%;
}

.home-page .result-item:hover {
    border-color: #d4a574;
    background: #fefaf5;
    transform: translateX(4px);
}

.home-page .result-item.active {
    border-color: #d4a574;
    background: #fef5e7;
}

.home-page .result-name {
    font-weight: 600;
    font-size: 1.1rem;
    color: #333;
}

.home-page .result-family {
    font-size: 0.9rem;
    color: #666;
}

.home-page .result-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: #e3f2fd;
    color: #1976d2;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-top: 0.25rem;
}

.home-page .result-badge.complete {
    background: #e8f5e9;
    color: #2e7d32;
}

.home-page .results-summary {
    padding: 1rem;
    background: #f5f5f5;
    border-radius: 8px;
    font-size: 0.95rem;
    color: #666;
}

.home-page .guest-summary {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #e0e0e0;
}

.home-page .guest-summary h2 {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 0.5rem;
}

.home-page .guest-family {
    color: #666;
    font-size: 1rem;
    margin: 0.5rem 0;
}

.home-page .invitation-card-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
}

.home-page .invitation-card {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.home-page .invitation-card:hover {
    border-color: #d4a574;
    box-shadow: 0 4px 12px rgba(212, 165, 116, 0.2);
}

.home-page .invitation-card header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.home-page .invitation-card h3 {
    font-size: 1.3rem;
    color: #333;
}

.home-page .invite-card-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.home-page .rsvp-action {
    flex: 1;
    padding: 0.75rem 1.5rem;
    border: 2px solid #e0e0e0;
    background: white;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.home-page .rsvp-action.accept:hover {
    border-color: #4caf50;
    background: #e8f5e9;
    color: #2e7d32;
}

.home-page .rsvp-action.decline:hover {
    border-color: #f44336;
    background: #ffebee;
    color: #c62828;
}

.home-page .rsvp-action.is-selected.accept {
    border-color: #4caf50;
    background: #4caf50;
    color: white;
}

.home-page .rsvp-action.is-selected.decline {
    border-color: #f44336;
    background: #f44336;
    color: white;
}

.home-page .invite-status {
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.home-page .status-accepted {
    background: #e8f5e9;
    color: #2e7d32;
}

.home-page .status-declined {
    background: #ffebee;
    color: #c62828;
}

.home-page .status-pending {
    background: #fff3e0;
    color: #e65100;
}

.home-page .frame {
    height: 100vh;
    background-size: cover;
    background-position: center;
    will-change: transform, opacity, filter;
}

.home-page .frame.enter {
    opacity: 0;
    filter: blur(6px);
}

.home-page .frame.enter.show {
    opacity: 1;
    filter: blur(0);
    transition: opacity 0.8s ease, filter 0.8s ease;
}

/* ----------------------------------------------------------
   Search Page
---------------------------------------------------------- */
.search-page {
    background: #fafafa;
    color: #333333;
}

.search-page .bg-gallery,
.search-backdrop .bg-gallery {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.search-page .bg-slide,
.search-backdrop .bg-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 2s ease;
}

.search-page .bg-slide.active,
.search-backdrop .bg-slide.active {
    opacity: 1;
}

.search-page .bg-slide img,
.search-backdrop .bg-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.12) brightness(1.05);
}

.search-page .overlay,
.search-backdrop .overlay {
    position: fixed;
    inset: 0;
    z-index: 1;
    background: linear-gradient(135deg, rgba(199, 185, 255, 0.35), rgba(248, 187, 208, 0.35), rgba(252, 238, 192, 0.35));
    pointer-events: none;
}

.search-page .content {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    padding: 48px 20px 64px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.search-page .header {
    text-align: center;
    color: #ffffff;
    text-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.search-page .header h1 {
    font-family: var(--font-script);
    font-size: clamp(48px, 10vw, 86px);
    margin-bottom: 12px;
}

.search-page .header p {
    font-size: clamp(16px, 4vw, 22px);
    opacity: 0.95;
}

.search-page .search-section {
    width: min(680px, 94vw);
    padding: 32px;
    border-radius: 24px;
    background: var(--glass-bg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--glass-brd);
    box-shadow: var(--shadow-soft);
}

.search-page .search-box {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 14px 20px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.search-page .search-box input {
    flex: 1;
    border: 0;
    background: transparent;
    font-size: 18px;
    outline: none;
    color: #333333;
}

.search-page .search-box input::placeholder {
    color: rgba(51, 51, 51, 0.6);
}

.search-page .search-box button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 0;
    background: rgba(255, 255, 255, 0.55);
    color: rgba(51, 51, 51, 0.75);
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.search-page .search-box button:hover {
    background: rgba(255, 255, 255, 0.75);
    transform: translateY(-1px);
}

.search-page .search-box button svg {
    width: 18px;
    height: 18px;
    stroke-width: 2.2;
    color: currentColor;
}

.search-page .results {
    width: min(820px, 96vw);
}

.search-page .results-summary {
    margin-bottom: 20px;
    font-size: 15px;
    color: rgba(51, 51, 51, 0.7);
}

.search-page .result-items {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.search-page .result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 16px 18px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.75);
    font-size: 16px;
    color: #4a3f5f;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border 0.2s ease;
}

.search-page .result-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(199, 185, 255, 0.35);
}

.search-page .result-item.active {
    border-color: rgba(199, 185, 255, 0.9);
    box-shadow: 0 12px 32px rgba(199, 185, 255, 0.35);
}

.search-page .result-name {
    font-weight: 600;
}

.search-page .result-family {
    font-size: 13px;
    color: rgba(74, 63, 95, 0.7);
    margin-left: auto;
    margin-right: 12px;
}

.search-page .result-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    background: rgba(199, 185, 255, 0.2);
    color: rgba(74, 63, 95, 0.8);
}

.search-page .result-badge.complete {
    background: rgba(126, 214, 163, 0.3);
    color: #246347;
}

.search-page .invitation-details {
    margin-top: 32px;
    padding: 28px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 18px 50px rgba(74, 63, 95, 0.18);
}

.search-page .guest-summary h2 {
    font-family: var(--font-serif);
    font-size: clamp(28px, 5vw, 40px);
    margin-bottom: 6px;
}

.search-page .guest-family {
    color: rgba(74, 63, 95, 0.7);
    margin-bottom: 8px;
}

.search-page .invitation-intro {
    margin: 24px 0;
    padding: 24px;
    border-radius: 18px;
    background: rgba(248, 239, 255, 0.7);
    text-align: center;
    line-height: 1.6;
}

.search-page .invitation-card-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.search-page .invitation-card {
    border: 1px solid rgba(199, 185, 255, 0.4);
    border-radius: 20px;
    padding: 20px 22px;
    background: #ffffff;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.08);
}

.search-page .invitation-card header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.search-page .invitation-card h3 {
    font-family: var(--font-serif);
    font-size: 22px;
    margin: 0;
}

.search-page .invite-status {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 12px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.search-page .invite-status.status-accepted {
    background: rgba(126, 214, 163, 0.25);
    color: #256849;
}

.search-page .invite-status.status-declined {
    background: rgba(255, 162, 162, 0.3);
    color: #a23a3a;
}

.search-page .invite-status.status-pending {
    background: rgba(252, 224, 140, 0.35);
    color: #7a6520;
}

.search-page .invitation-card-copy {
    font-size: 15px;
    color: rgba(51, 51, 51, 0.75);
    margin-bottom: 14px;
}

.search-page .invitation-card-details {
    list-style: none;
    margin: 0 0 16px;
    padding: 0;
    display: grid;
    gap: 8px;
}

.search-page .invitation-card-details li {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: rgba(51, 51, 51, 0.72);
}

.search-page .invite-card-actions {
    display: flex;
    gap: 10px;
}

.search-page .rsvp-action {
    flex: 1;
    padding: 12px;
    border-radius: 14px;
    border: 1px solid rgba(199, 185, 255, 0.6);
    background: rgba(199, 185, 255, 0.18);
    color: #4a3f5f;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, border 0.2s ease, transform 0.2s ease;
}

.search-page .rsvp-action:hover {
    transform: translateY(-1px);
    border-color: rgba(199, 185, 255, 0.95);
}

.search-page .rsvp-action.accept.is-selected {
    background: rgba(126, 214, 163, 0.35);
    border-color: rgba(126, 214, 163, 0.75);
    color: #256849;
}

.search-page .rsvp-action.decline.is-selected {
    background: rgba(255, 162, 162, 0.35);
    border-color: rgba(255, 162, 162, 0.75);
    color: #a23a3a;
}

.search-page .invite-card-note {
    font-size: 14px;
    color: rgba(51, 51, 51, 0.75);
    margin: 10px 0 0;
}

.search-page .message-section {
    margin-top: 24px;
    padding: 18px 20px;
    border-radius: 18px;
    background: rgba(199, 185, 255, 0.18);
    border: 1px solid rgba(199, 185, 255, 0.35);
}

.search-page .message-section.disabled {
    opacity: 0.7;
}

.search-page .message-trigger {
    margin-top: 12px;
    padding: 10px 18px;
    border-radius: 14px;
    border: none;
    background: linear-gradient(135deg, var(--lavender), var(--rose));
    color: #ffffff;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.search-page .message-trigger:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(199, 185, 255, 0.4);
}

.search-page .invitation-link {
    margin-top: 18px;
    text-align: right;
}

.search-page .view-invitation {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 14px;
    background: transparent;
    border: 1px solid rgba(199, 185, 255, 0.6);
    color: #4a3f5f;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease, transform 0.2s ease, border 0.2s ease;
}

.search-page .view-invitation::after {
    content: "→";
}

.search-page .view-invitation:hover {
    background: rgba(199, 185, 255, 0.2);
    border-color: rgba(199, 185, 255, 0.9);
    transform: translateY(-1px);
}

.search-page .loading,
.search-page .no-results {
    text-align: center;
    padding: 48px 20px;
    border-radius: 24px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-brd);
    color: #ffffff;
}

/* ----------------------------------------------------------
   Invitation Page
---------------------------------------------------------- */
.invite-page {
    color: var(--ink);
}

.invite-page .container {
    margin-top: 48px;
    margin-bottom: 80px;
}

.invite-page .header {
    text-align: center;
    margin-bottom: 40px;
}

.invite-page .header .greeting {
    font-family: var(--font-serif);
    font-size: clamp(20px, 4vw, 26px);
    color: var(--muted);
}

.invite-page .header .line {
    font-family: var(--font-serif);
    font-size: clamp(20px, 4.5vw, 28px);
    color: var(--ink);
    margin-bottom: 4px;
}

.invite-page .header h1 {
    font-family: var(--font-script);
    font-size: clamp(46px, 10vw, 86px);
    color: var(--lavender);
    margin: 16px 0 10px;
}

.invite-page .header .tagline {
    max-width: 620px;
    margin: 0 auto;
    color: var(--muted);
    font-size: 16px;
}

.invite-page .header .subtle {
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #9a96a9;
    margin-top: 14px;
}

.invite-page .story-section {
    margin: 0 auto 48px;
    padding: 28px 32px;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    border: 2px solid rgba(199, 185, 255, 0.25);
    max-width: 720px;
    text-align: center;
}

.invite-page .story-section h2 {
    font-family: var(--font-serif);
    font-size: clamp(30px, 5vw, 44px);
    margin-bottom: 14px;
}

.invite-page .story-section p {
    color: var(--muted);
    line-height: 1.7;
}

.invite-page .family-note {
    margin: 0 auto 12px;
    padding: 16px 20px;
    background: rgba(199, 185, 255, 0.12);
    border: 1px solid rgba(199, 185, 255, 0.4);
    border-radius: 18px;
    max-width: 720px;
    color: #5b4c7a;
    font-size: 15px;
}

.invite-page .events {
    display: grid;
    gap: 28px;
}

.invite-page .event-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    border: 2px solid transparent;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.invite-page .event-card:hover {
    transform: translateY(-4px);
    border-color: var(--lavender);
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.12);
}

.invite-page .event-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.invite-page .event-icon {
    font-size: 40px;
}

.invite-page .event-title {
    font-family: var(--font-serif);
    font-size: 28px;
    font-weight: 600;
}

.invite-page .event-subtitle {
    font-size: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 4px;
}

.invite-page .detail-row {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 14px;
}

.invite-page .detail-label {
    font-size: 14px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: 600;
}

.invite-page .detail-value a {
    color: var(--lavender);
    text-decoration: none;
}

.invite-page .detail-value a:hover {
    text-decoration: underline;
}

.invite-page .family-selector {
    margin: 18px 0;
    padding: 16px;
    background: #f8f9ff;
    border-radius: 12px;
    border: 1px solid #e0e5ff;
}

.invite-page .family-selector select {
    width: 100%;
    padding: 10px 14px;
    border-radius: 8px;
    border: 2px solid #ddd;
    background: #ffffff;
    font-size: 16px;
    cursor: pointer;
}

.invite-page .family-selector select:focus {
    outline: 0;
    border-color: var(--lavender);
}

.invite-page .rsvp-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.invite-page .rsvp-btn {
    flex: 1;
    min-width: 150px;
    padding: 14px 22px;
    border-radius: 12px;
    border: 2px solid transparent;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.invite-page .rsvp-btn.accept {
    background: linear-gradient(135deg, var(--euca), var(--moon));
    color: #2d5f4d;
}

.invite-page .rsvp-btn.decline {
    background: linear-gradient(135deg, #f0f0f0, #dcdcdc);
    color: #666666;
}

.invite-page .rsvp-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.invite-page .badge {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
}

.invite-page .badge.success {
    background: var(--euca);
    color: #2d5f4d;
}

.invite-page .badge.declined {
    background: #f0f0f0;
    color: #666666;
}

.invite-page .additional-fields {
    margin-top: 20px;
}

.invite-page .field-group {
    margin-bottom: 16px;
}

.invite-page .field-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--muted);
    margin-bottom: 6px;
}

.invite-page .field-group textarea {
    resize: vertical;
    min-height: 80px;
}

.invite-page .faq-section {
    margin-top: 60px;
}

.invite-page .faq-list {
    display: grid;
    gap: 14px;
}

.invite-page .faq-item {
    background: #ffffff;
    border-radius: 16px;
    border: 2px solid #f0f0f0;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.invite-page .faq-item.active {
    border-color: var(--lavender);
}

.invite-page .faq-question {
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-weight: 600;
}

.invite-page .faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
    padding: 0 24px;
    color: var(--muted);
}

.invite-page .faq-item.active .faq-answer {
    max-height: 480px;
    padding: 0 24px 20px;
}

/* ----------------------------------------------------------
   Message Success Page
---------------------------------------------------------- */
.message-success-page {
    background: linear-gradient(135deg, rgba(199, 185, 255, 0.3), rgba(248, 187, 208, 0.35));
    display: grid;
    place-items: center;
    min-height: 100vh;
    padding: 40px 18px;
}

.message-success-card {
    width: min(520px, 96vw);
    padding: 48px 36px;
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.18);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.message-success-card::before {
    content: "";
    position: absolute;
    inset: -40% -40%;
    background: radial-gradient(circle at center, rgba(199, 185, 255, 0.45), transparent 60%);
    animation: pulse 8s linear infinite;
    z-index: 0;
}

@keyframes pulse {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.message-success-card > * {
    position: relative;
    z-index: 1;
}

.message-success-card h1 {
    font-family: var(--font-serif);
    font-size: clamp(36px, 8vw, 54px);
    color: var(--lavender);
    margin-bottom: 12px;
}

.message-success-card p {
    color: var(--muted);
    font-size: 17px;
    margin-bottom: 24px;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--lavender), var(--rose));
    color: #ffffff;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 10px 30px rgba(199, 185, 255, 0.45);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 40px rgba(199, 185, 255, 0.6);
}

.particle-container {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    top: 100%;
    left: var(--x, 50%);
    width: 12px;
    height: 12px;
    background: radial-gradient(circle at center, rgba(248, 187, 208, 0.9), rgba(248, 187, 208, 0));
    border-radius: 50%;
    animation: float-up 6s ease-in infinite;
    animation-delay: var(--delay, 0s);
}

@keyframes float-up {
    0% {
        transform: translate(-50%, 0) scale(0.6);
        opacity: 0;
    }
    20% {
        opacity: 1;
    }
    80% {
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -220px) scale(1.2);
        opacity: 0;
    }
}

.text-center {
    text-align: center;
}

/* ----------------------------------------------------------
   Responsive tweaks
---------------------------------------------------------- */
@media (max-width: 768px) {
    .home-page .tile {
        min-width: 72px;
        padding: 12px;
    }

    .home-page .names {
        font-size: clamp(46px, 14vw, 96px);
    }

    .home-page .date {
        font-size: clamp(16px, 5vw, 26px);
    }

    .invite-page .event-card {
        padding: 24px;
    }

    .invite-page .rsvp-actions {
        flex-direction: column;
    }

    .invite-page .rsvp-btn {
        width: 100%;
    }

    .invite-page .story-section {
        padding: 24px;
    }

    .search-page .search-section {
        padding: 26px 22px;
    }
}
