:root {
    --olive-700: #73846e;
    --olive-500: #a2af99;
    --lavender-700: #8672a4;
    --lavender-400: #b4a5be;
    --paper: #dedad5;
    --ink: #2f2c2a;
    --white: #ffffff;
    --line: rgba(115, 132, 110, 0.22);
    --radius-lg: 24px;
    --radius-md: 14px;
    --shadow-soft: 0 14px 34px rgba(47, 44, 42, 0.12);
}

html, body {
    margin: 0;
    font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
    color: var(--ink);
    background: linear-gradient(180deg, #f6f4f1 0%, var(--paper) 100%);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

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

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
}

:focus-visible {
    outline: 2px solid var(--lavender-700);
    outline-offset: 2px;
    border-radius: 4px;
}

.app-shell {
    position: relative;
    min-height: 100vh;
}

h1:focus {
    outline: none;
}

a {
    color: inherit;
}

.hero-shell {
    max-width: 1120px;
    margin: 0 auto;
    display: grid;
    gap: 1.25rem;
    align-items: center;
    padding: 0.6rem 0 0.25rem;
}

.hero-copy h1 {
    margin: 0;
    font-size: clamp(2.1rem, 5vw, 3.6rem);
    letter-spacing: -0.02em;
    line-height: 1.05;
    color: var(--olive-700);
}

.hero-subtitle {
    max-width: 640px;
    margin: 0.9rem 0 0;
    font-size: 1.04rem;
    line-height: 1.65;
    color: #494543;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-weight: 700;
    font-size: 0.75rem;
    color: var(--lavender-700);
    margin: 0 0 0.45rem;
}

.hero-meta {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.meta-pill {
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid rgba(134, 114, 164, 0.28);
    border-radius: 999px;
    padding: 0.36rem 0.78rem;
    font-size: 0.83rem;
    color: #554d61;
}

.photo-stack {
    position: relative;
    min-height: 320px;
}

.photo-stack img {
    border-radius: 20px;
    object-fit: cover;
    box-shadow: var(--shadow-soft);
}

.photo-primary {
    width: min(100%, 390px);
    aspect-ratio: 4/5;
}

.photo-secondary {
    width: min(58%, 240px);
    aspect-ratio: 4/5;
    position: absolute;
    right: 0;
    bottom: -16px;
    border: 6px solid rgba(255, 255, 255, 0.88);
}

.flip-toggle,
.submit-btn,
.outline-btn,
.danger-btn,
.secondary-btn,
.ghost-btn {
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.7rem 1.15rem;
    min-height: 42px;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease, color 140ms ease, border-color 140ms ease;
}

.flip-toggle:hover:not(:disabled),
.submit-btn:hover:not(:disabled),
.outline-btn:hover:not(:disabled),
.danger-btn:hover:not(:disabled),
.secondary-btn:hover:not(:disabled),
.ghost-btn:hover:not(:disabled) {
    transform: translateY(-1px);
}

.flip-toggle:disabled,
.submit-btn:disabled,
.outline-btn:disabled,
.danger-btn:disabled,
.secondary-btn:disabled,
.ghost-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}

.flip-toggle,
.submit-btn {
    background: var(--olive-700);
    color: var(--white);
    box-shadow: 0 8px 20px rgba(115, 132, 110, 0.28);
}

.secondary-btn {
    background: #ffffff;
    border-color: rgba(115, 132, 110, 0.45);
    color: var(--olive-700);
}

.ghost-btn {
    background: transparent;
    border-color: rgba(134, 114, 164, 0.35);
    color: #5f546f;
}

.submission-banner {
    max-width: 1120px;
    margin: 0.9rem auto 0.5rem;
    background: linear-gradient(135deg, rgba(162, 175, 153, 0.22), rgba(180, 165, 190, 0.16));
    border: 1px solid rgba(115, 132, 110, 0.32);
    padding: 0.78rem 1rem;
    border-radius: var(--radius-md);
}

.submission-banner p {
    margin: 0;
    line-height: 1.5;
}

.card-section {
    max-width: 980px;
    margin: 1.5rem auto 3rem;
    padding: 0 1rem;
}

.invite-live-panel {
    max-width: 880px;
    margin: 0 auto 1.2rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.85);
    padding: 1.4rem 1.4rem 1.5rem;
    box-shadow: var(--shadow-soft);
    text-align: center;
}

.invite-live-panel h2 {
    margin: 0 0 0.45rem;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(1.7rem, 3vw, 2.1rem);
    letter-spacing: 0.02em;
}

.invite-live-panel p {
    margin: 0;
    color: #565250;
    line-height: 1.55;
}

.invite-live-panel .invite-login-row {
    justify-content: center;
}

.invite-login-row {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-top: 0.75rem;
}

.invite-login-row input {
    min-width: 260px;
    flex: 1;
    border-radius: 12px;
    border: 1px solid rgba(134, 114, 164, 0.3);
    padding: 0.7rem 0.78rem;
    font: inherit;
}

.card-section-header {
    max-width: 720px;
    margin: 0 auto 1.5rem;
    text-align: center;
}

.card-section-header h2 {
    margin: 0;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(1.75rem, 3vw, 2.4rem);
    letter-spacing: 0.02em;
}

.card-section-header p {
    margin: 0.5rem 0 0;
    color: #5c5855;
}

.card-stage {
    width: 100%;
    max-width: 880px;
    margin: 0 auto;
    aspect-ratio: 7 / 5;
    perspective: 1800px;
}

.save-the-date-card {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.85s cubic-bezier(0.2, 0.65, 0.2, 1);
}

.save-the-date-card.flipped {
    transform: rotateY(180deg);
}

.card-face {
    position: absolute;
    inset: 0;
    border-radius: 6px;
    overflow: hidden;
    backface-visibility: hidden;
    box-shadow:
        0 30px 60px -20px rgba(43, 42, 41, 0.35),
        0 18px 36px -18px rgba(43, 42, 41, 0.22);
}

.card-front {
    background: var(--olive-700);
    color: var(--paper);
}

.card-front-layout {
    display: grid;
    grid-template-columns: 0.45fr 1fr;
    height: 100%;
}

.card-front-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 1.5rem 0.7rem;
}

.card-eyebrow {
    margin: 0;
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 400;
    line-height: 1;
    letter-spacing: 0.04em;
    color: #ffffff;
}

.card-eyebrow-script {
    margin: 0.1rem 0;
    font-family: "Great Vibes", "Brush Script MT", cursive;
    font-size: clamp(2rem, 3.6vw, 2.6rem);
    font-weight: 400;
    line-height: 1;
    color: var(--lavender-400);
    font-style: italic;
}

.card-divider {
    width: 70px;
    height: 1px;
    background-color: var(--paper);
    opacity: 0.55;
    margin: 1.25rem 0 1rem;
}

.card-couple {
    margin: 0;
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: clamp(1.1rem, 1.8vw, 1.4rem);
    font-weight: 500;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #ffffff;
}

.card-surname {
    margin: 0.4rem 0 0;
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: clamp(1.4rem, 2.4vw, 1.85rem);
    font-weight: 400;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--paper);
}

.card-detail-block {
    margin-top: 1.5rem;
}

.card-detail {
    margin: 0.2rem 0;
    font-size: 0.9rem;
    letter-spacing: 0.04em;
    color: #ffffff;
    opacity: 0.92;
}

.card-link-action {
    margin-top: 1.75rem;
    border: 1px solid rgba(222, 218, 213, 0.55);
    background: transparent;
    color: var(--paper);
    padding: 0.55rem 1.4rem;
    cursor: pointer;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    font-size: 0.7rem;
    font-weight: 600;
    transition: background 160ms ease, color 160ms ease, border-color 160ms ease;
}

.card-link-action:hover {
    background: var(--paper);
    color: var(--olive-700);
    border-color: var(--paper);
}

.card-front-photo {
    overflow: hidden;
    background: #1f1f1d;
}

.card-front-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
}

.card-back {
    transform: rotateY(180deg);
    background: #ffffff;
    overflow: hidden;
    padding: 0;
}

.card-back-form {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 1rem 1.1rem;
    gap: 0.65rem;
}

.card-back-header {
    flex: 0 0 auto;
}

.card-back-eyebrow {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--lavender-700);
}

.card-back h3 {
    margin: 0.15rem 0 0;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: 1.4rem;
    font-weight: 500;
}

.card-back-body {
    flex: 1 1 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
    min-height: 0;
}

.card-back-panel {
    background: rgba(222, 218, 213, 0.22);
    border: 1px solid rgba(115, 132, 110, 0.18);
    border-radius: 8px;
    padding: 0.7rem 0.75rem;
    overflow-y: auto;
    min-height: 0;
}

.card-back-panel-right {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

    .card-back-panel-right .member-editor {
        height: auto;
        flex: 0 0 auto;
    }

.household-notes {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
}

    .household-notes .panel-label {
        margin: 0 0 0.35rem;
    }

.household-notes-textarea {
    width: 100%;
    border-radius: 7px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.5rem 0.6rem;
    font: inherit;
    font-size: 0.85rem;
    line-height: 1.5;
    background: #ffffff;
    resize: vertical;
    min-height: 64px;
    box-sizing: border-box;
}

    .household-notes-textarea:focus {
        outline: none;
        border-color: var(--olive-700);
        box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
    }

.household-lodging {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
}

    .household-lodging .panel-label {
        margin: 0 0 0.35rem;
    }

.household-field-hint {
    margin: 0.35rem 0 0;
    color: #6c6864;
    font-size: 0.78rem;
    line-height: 1.45;
    font-style: italic;
}

.member-row-rsvp {
    flex-wrap: wrap;
    row-gap: 0.45rem;
}

.member-meal-row {
    flex: 1 1 100%;
    padding-left: 32px; /* line up with name input below the index pill */
}

.member-meal-label {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.member-meal-eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--olive-700);
}

.member-meal-select {
    width: 100%;
    border-radius: 7px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.42rem 0.55rem;
    font: inherit;
    font-size: 0.85rem;
    background: #ffffff;
    box-sizing: border-box;
}

    .member-meal-select:focus {
        outline: none;
        border-color: var(--olive-700);
        box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
    }

.card-back-status {
    margin: 0.25rem 0 0;
    color: #5e5a57;
    font-size: 0.85rem;
    line-height: 1.45;
}

.rsvp-validation {
    margin: 0.5rem 0 0.25rem;
    font-size: 0.88rem;
    line-height: 1.5;
}

.card-back-panel::-webkit-scrollbar {
    width: 6px;
}

.card-back-panel::-webkit-scrollbar-thumb {
    background: rgba(115, 132, 110, 0.35);
    border-radius: 999px;
}

.card-back-panel::-webkit-scrollbar-track {
    background: transparent;
}

.panel-label {
    margin: 0 0 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--olive-700);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem 0.55rem;
}

.form-grid-full {
    grid-column: 1 / -1;
}

.form-grid label {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    font-weight: 600;
    color: #443f4d;
    font-size: 0.72rem;
    letter-spacing: 0.02em;
}

.form-grid input,
.form-grid textarea,
.admin-toolbar input {
    border-radius: 7px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.42rem 0.55rem;
    font: inherit;
    font-size: 0.85rem;
    background: #ffffff;
}

.form-grid input:focus,
.form-grid textarea:focus,
.admin-toolbar input:focus,
.admin-auth-row input:focus {
    outline: none;
    border-color: var(--olive-700);
    box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
}

.form-grid textarea {
    min-height: 56px;
    resize: vertical;
}

.validation-message,
.validation-errors {
    color: #a33e3e;
    font-size: 0.78rem;
    margin: 0 0 0.4rem;
}

.form-validation-banner {
    margin: 0;
    padding: 0.55rem 0.7rem;
    border-radius: 8px;
    background: rgba(163, 62, 62, 0.08);
    border: 1px solid rgba(163, 62, 62, 0.35);
    color: #8f2c2c;
    font-size: 0.82rem;
    line-height: 1.45;
    box-shadow: 0 0 0 3px rgba(195, 74, 74, 0.12), 0 0 14px rgba(195, 74, 74, 0.1);
    animation: field-error-pulse 2s ease-in-out 1;
}

.form-grid input.invalid,
.form-grid textarea.invalid,
.household-notes-textarea.invalid,
.member-name-input.invalid,
.member-meal-select.invalid,
.form-field-invalid input,
.form-field-invalid textarea,
.form-field-invalid select {
    border-color: #c44a4a;
    box-shadow: 0 0 0 3px rgba(195, 74, 74, 0.22), 0 0 14px rgba(195, 74, 74, 0.14);
}

.members-editor--error .member-list {
    border-radius: 8px;
    box-shadow: 0 0 0 3px rgba(195, 74, 74, 0.18), 0 0 16px rgba(195, 74, 74, 0.12);
}

.members-editor-error {
    margin: 0 0 0.45rem;
    color: #a33e3e;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.4;
}

@keyframes field-error-pulse {
    0%, 100% {
        box-shadow: 0 0 0 3px rgba(195, 74, 74, 0.12), 0 0 10px rgba(195, 74, 74, 0.08);
    }

    50% {
        box-shadow: 0 0 0 5px rgba(195, 74, 74, 0.28), 0 0 18px rgba(195, 74, 74, 0.16);
    }
}

.form-actions {
    flex: 0 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    padding-top: 0.25rem;
}

@media (max-width: 480px) {
    .form-actions {
        justify-content: stretch;
    }

    .form-actions > button,
    .form-actions > .submit-btn,
    .form-actions > .secondary-btn,
    .form-actions > .danger-btn {
        flex: 1 1 calc(50% - 0.5rem);
    }
}

.member-editor {
    display: flex;
    flex-direction: column;
    height: 100%;
    gap: 0.5rem;
}

.member-editor-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
}

.member-editor-head .panel-label {
    margin: 0 0 0.15rem;
}

.member-count {
    margin: 0;
    font-size: 0.72rem;
    color: #6c6864;
    letter-spacing: 0.02em;
}

.icon-add-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    border-radius: 999px;
    border: 1px solid rgba(115, 132, 110, 0.5);
    background: var(--olive-700);
    color: #ffffff;
    padding: 0.32rem 0.7rem;
    font-size: 0.74rem;
    font-weight: 600;
    cursor: pointer;
    letter-spacing: 0.04em;
    transition: background 140ms ease, transform 140ms ease;
}

.icon-add-btn span {
    font-size: 1rem;
    line-height: 1;
}

.icon-add-btn:hover {
    background: #5e6e5a;
    transform: translateY(-1px);
}

.member-list {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.member-row {
    background: #ffffff;
    border: 1px solid rgba(115, 132, 110, 0.2);
    border-radius: 8px;
    padding: 0.45rem 0.55rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
}

.member-row .member-name-input {
    min-width: 140px;
}

.member-index {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: var(--paper);
    color: var(--olive-700);
    font-size: 0.7rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.member-name-input {
    flex: 1 1 auto;
    min-width: 0;
    border-radius: 6px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.35rem 0.5rem;
    font: inherit;
    font-size: 0.85rem;
}

.member-name-input:focus {
    outline: none;
    border-color: var(--olive-700);
    box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
}

.inline-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: #4e4856;
    font-weight: 600;
    flex: 0 0 auto;
    white-space: nowrap;
}

.inline-toggle input[type="checkbox"] {
    margin: 0;
}

.row-remove-btn {
    border: 1px solid rgba(143, 44, 44, 0.35);
    background: transparent;
    color: #8f2c2c;
    border-radius: 999px;
    width: 24px;
    height: 24px;
    padding: 0;
    line-height: 1;
    font-size: 1rem;
    cursor: pointer;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 140ms ease;
}

.row-remove-btn:hover:not(:disabled) {
    background: #fff0f0;
}

.row-remove-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.admin-shell {
    max-width: 1200px;
    margin: 0 auto;
}

.admin-section {
    margin-top: 1rem;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    padding: clamp(0.95rem, 2.5vw, 1.4rem);
    box-shadow: 0 4px 12px rgba(47, 44, 42, 0.04);
}

    .admin-section + .admin-section {
        margin-top: 1rem;
    }

.admin-section h2 {
    margin-top: 0;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.admin-header h1 {
    margin: 0.15rem 0 0;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(1.55rem, 4vw, 2rem);
    letter-spacing: 0.02em;
}

.admin-section h2 {
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    color: var(--olive-700);
    font-size: clamp(1.35rem, 2.4vw, 1.65rem);
    letter-spacing: 0.02em;
    margin: 0 0 0.4rem;
}

.admin-section p {
    color: #565250;
    line-height: 1.55;
    margin: 0 0 0.55rem;
}

.admin-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--line);
    padding-bottom: 0.4rem;
}

.admin-tab {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.55rem 1.05rem;
    font-weight: 600;
    font-size: 0.88rem;
    color: #5e5a57;
    cursor: pointer;
    white-space: nowrap;
    transition: background 140ms ease, color 140ms ease, border-color 140ms ease;
}

.admin-tab:hover {
    background: rgba(115, 132, 110, 0.08);
    color: var(--olive-700);
}

.admin-tab.active {
    background: var(--olive-700);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(115, 132, 110, 0.28);
}

@media (max-width: 760px) {
    .admin-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: thin;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 0.6rem;
        margin: 0 -0.5rem 1rem;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        scroll-snap-type: x proximity;
        mask-image: linear-gradient(to right, transparent 0, #000 0.5rem, #000 calc(100% - 0.5rem), transparent 100%);
    }

    .admin-tab {
        flex: 0 0 auto;
        scroll-snap-align: start;
    }
}

.phase-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: center;
    margin-top: 0.75rem;
}

.story-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
    margin: 0.5rem 0 0.75rem;
}

.registry-url-label {
    display: block;
    font-weight: 600;
    color: #443f4d;
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
}

.registry-url-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: center;
}

.registry-url-row input {
    flex: 1 1 320px;
    min-width: 240px;
    border-radius: 8px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.55rem 0.75rem;
    font: inherit;
    background: #ffffff;
}

.registry-url-row input:focus {
    outline: none;
    border-color: var(--olive-700);
    box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
}

.registry-url-row .submit-btn {
    flex: 0 0 auto;
}

.registry-note-textarea {
    width: 100%;
    border-radius: 8px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.7rem 0.85rem;
    font: inherit;
    font-size: 0.95rem;
    line-height: 1.55;
    background: #ffffff;
    resize: vertical;
    min-height: 110px;
    margin-bottom: 0.75rem;
}

.registry-note-textarea:focus {
    outline: none;
    border-color: var(--olive-700);
    box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
}

.upload-error {
    color: #a33e3e;
    font-size: 0.88rem;
}

.story-upload-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 1.1rem;
    background: var(--olive-700);
    color: #ffffff;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.88rem;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(115, 132, 110, 0.22);
    transition: background 140ms ease, transform 140ms ease;
    overflow: hidden;
}

.story-upload-btn:hover {
    background: #5e6e5a;
    transform: translateY(-1px);
}

.story-upload-btn input[type="file"] {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    font-size: 0;
}

.rich-text-editor {
    background: #ffffff;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid rgba(115, 132, 110, 0.25);
    position: relative;
}

.rich-text-editor-host {
    min-height: 280px;
    font-family: "Inter", "Segoe UI", system-ui, sans-serif;
    font-size: 1rem;
    line-height: 1.6;
}

.rich-text-editor .ql-toolbar.ql-snow,
.rich-text-editor .ql-container.ql-snow {
    border: none;
}

.rich-text-editor .ql-toolbar.ql-snow {
    background: rgba(222, 218, 213, 0.45);
    border-bottom: 1px solid rgba(115, 132, 110, 0.2);
}

.rich-text-editor .ql-container.ql-snow {
    position: relative;
}

.rich-text-editor .ql-editor img {
    cursor: pointer;
    max-width: 100%;
    height: auto;
}

.rich-text-editor .ql-toolbar .ql-html {
    width: 48px !important;
    border-radius: 6px;
    border: 1px solid rgba(115, 132, 110, 0.3) !important;
    background: #ffffff;
    margin-left: 0.25rem;
}

.rich-text-editor .ql-toolbar .ql-html::before {
    content: 'HTML';
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--olive-700);
}

.rich-text-editor .ql-toolbar .ql-html.ql-active {
    background: var(--olive-700);
}

.rich-text-editor .ql-toolbar .ql-html.ql-active::before {
    color: #ffffff;
}

.rich-text-html-source-wrapper {
    position: relative;
    background: #fbfaf8;
}

.rich-text-html-source {
    width: 100%;
    min-height: 320px;
    border: none;
    outline: none;
    padding: 2.4rem 1rem 0.85rem;
    font-family: "Cascadia Code", "Consolas", "Monaco", "Courier New", monospace;
    font-size: 0.85rem;
    line-height: 1.55;
    background: #fbfaf8;
    color: #2f2c2a;
    resize: vertical;
    box-sizing: border-box;
    tab-size: 2;
    white-space: pre;
}

.rich-text-format-btn {
    position: absolute;
    top: 0.55rem;
    right: 0.65rem;
    background: var(--olive-700);
    color: #ffffff;
    border: none;
    border-radius: 999px;
    padding: 0.3rem 0.85rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(115, 132, 110, 0.25);
    transition: background 140ms ease, transform 140ms ease;
    z-index: 5;
}

.rich-text-format-btn:hover {
    background: #5e6e5a;
    transform: translateY(-1px);
}

.rich-text-image-picker {
    background: #ffffff;
    border: 1px solid rgba(115, 132, 110, 0.4);
    border-radius: 999px;
    padding: 0.25rem;
    display: inline-flex;
    gap: 0.2rem;
    box-shadow: 0 6px 16px rgba(47, 44, 42, 0.18);
}

.rich-text-image-picker button {
    background: transparent;
    border: none;
    border-radius: 999px;
    padding: 0.3rem 0.55rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--olive-700);
    cursor: pointer;
    line-height: 1;
    min-width: 30px;
}

.rich-text-image-picker button:hover {
    background: rgba(115, 132, 110, 0.14);
}

.admin-auth-card {
    max-width: 560px;
    margin: 2.2rem auto 0;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
    padding: 1.35rem;
}

.admin-auth-card h1 {
    margin: 0;
    color: #3c3937;
}

.admin-auth-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 0.9rem;
}

.admin-auth-row input {
    min-width: 220px;
    flex: 1;
    border-radius: 12px;
    border: 1px solid rgba(134, 114, 164, 0.3);
    padding: 0.68rem 0.75rem;
    font: inherit;
}

.auth-error {
    color: #a33e3e;
    margin: 0.65rem 0 0;
    font-weight: 500;
}

.auth-tip {
    margin-top: 0.85rem;
    color: #5d5a58;
    font-size: 0.89rem;
}

.admin-metrics {
    margin-top: 1rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.7rem;
}

.metric-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 20px rgba(47, 44, 42, 0.07);
    padding: 0.78rem 0.88rem;
}

.metric-card h3 {
    margin: 0;
    font-size: 0.86rem;
    color: #625e5a;
    font-weight: 600;
}

.metric-card strong {
    display: block;
    margin-top: 0.35rem;
    font-size: 1.5rem;
    color: var(--olive-700);
}

.admin-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem;
    margin: 1rem 0 0.75rem;
}

.admin-toolbar input {
    min-width: 250px;
    flex: 1;
}

@media (max-width: 760px) {
    .admin-toolbar input {
        min-width: 0;
        width: 100%;
    }

    .admin-toolbar {
        gap: 0.55rem;
    }

    .admin-toolbar > button {
        flex: 1 1 auto;
    }
}

.outline-btn {
    background: var(--white);
    color: var(--olive-700);
    border: 1px solid rgba(115, 132, 110, 0.45);
}

.danger-btn {
    background: #f8eaea;
    color: #8f2c2c;
    border: 1px solid #d29f9f;
}

.results-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 0.8rem;
    color: #5d5d5a;
    font-size: 0.92rem;
}

.table-wrap {
    overflow-x: auto;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 14px;
    border: 1px solid rgba(134, 114, 164, 0.18);
    box-shadow: 0 14px 30px rgba(47, 44, 42, 0.08);
}

.invite-portal {
    max-width: 720px;
    margin: 1.5rem auto 0;
}

.invite-portal-card {
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid var(--line);
    border-radius: 22px;
    box-shadow: var(--shadow-soft);
    padding: 2rem 2rem 1.85rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

    .invite-portal-card::before {
        content: "";
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 84px;
        height: 4px;
        border-radius: 0 0 999px 999px;
        background: linear-gradient(90deg, #8c9b86 0%, #b4a5be 100%);
    }

    .invite-portal-card h1 {
        margin: 0.4rem 0 0.4rem;
        color: var(--olive-700);
        font-family: "Cormorant Garamond", "Times New Roman", serif;
        font-weight: 500;
        font-size: clamp(1.9rem, 5vw, 2.5rem);
        letter-spacing: 0.02em;
    }

    .invite-portal-card p {
        margin: 0 0 1rem;
        color: #4a4642;
        line-height: 1.55;
    }

.invite-portal-card .invite-login-row {
    margin-top: 1rem;
}

.invite-card-section {
    max-width: 980px;
    margin: 1.25rem auto 3rem;
    padding: 0 1rem;
}

.card-stage-invite {
    /* Slightly taller stage when showing a full invite image so portrait
       artwork can breathe without too much letter-boxing. */
    aspect-ratio: 5 / 6;
    max-width: 720px;
}

.card-front-as-image {
    background: #1a1a18;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.card-front-invite-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    background: #1a1a18;
}

.card-link-action-floating {
    position: absolute;
    right: 0.75rem;
    bottom: 0.75rem;
    margin-top: 0;
    background: rgba(31, 31, 29, 0.55);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.55);
}

    .card-link-action-floating:hover {
        background: rgba(255, 255, 255, 0.92);
        color: var(--olive-700);
        border-color: rgba(255, 255, 255, 0.92);
    }

.invite-members-view {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 1.1rem 1.25rem;
    gap: 0.8rem;
}

.invite-members-body {
    flex: 1 1 auto;
    overflow-y: auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.invite-members-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

    .invite-members-list li {
        background: rgba(222, 218, 213, 0.45);
        border: 1px solid rgba(115, 132, 110, 0.18);
        border-radius: 10px;
        padding: 0.5rem 0.7rem;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.5rem;
    }

.invite-member-name {
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: 1.15rem;
    color: var(--ink);
    letter-spacing: 0.01em;
}

.invite-member-tag {
    background: var(--lavender-700);
    color: #ffffff;
    border-radius: 999px;
    padding: 0.15rem 0.55rem;
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    font-weight: 600;
}

.invite-members-empty {
    margin: 0;
    color: #6c6864;
    font-style: italic;
}

.invite-members-meta {
    margin: 0;
    color: #5a5552;
    font-size: 0.92rem;
    line-height: 1.55;
}

.invite-members-edit-link {
    background: transparent;
    border: none;
    padding: 0;
    color: var(--lavender-700);
    text-decoration: underline;
    cursor: pointer;
    font: inherit;
    font-weight: 600;
}

    .invite-members-edit-link:hover {
        color: #5e6e5a;
    }

.invite-banner {
    max-width: 720px;
    margin: 1rem auto 0;
}

.invite-meta-row {
    margin: 1.3rem auto 0;
    max-width: 720px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.2rem;
    padding: 1.1rem 1.3rem;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 18px rgba(47, 44, 42, 0.06);
}

.invite-meta-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 0;
}

.invite-meta-eyebrow {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--olive-700);
}

.invite-meta-code {
    font-family: "Cascadia Code", "Consolas", "Monaco", "Courier New", monospace;
    font-size: 1.05rem;
    color: var(--ink);
    background: rgba(222, 218, 213, 0.55);
    border-radius: 8px;
    padding: 0.35rem 0.55rem;
    align-self: flex-start;
    word-break: break-all;
}

.invite-meta-help {
    margin: 0;
    color: #6c6864;
    font-size: 0.85rem;
    line-height: 1.45;
}

.invite-meta-qr {
    width: 110px;
    height: 110px;
    border-radius: 12px;
    background: #ffffff;
    padding: 0.4rem;
    border: 1px solid var(--line);
    flex: 0 0 auto;
}

@media (max-width: 600px) {
    .invite-meta-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .invite-meta-qr {
        align-self: center;
    }
}

.returning-rsvp-link-row {
    max-width: 720px;
    margin: 1.1rem auto 0;
    text-align: center;
    padding: 0 1rem;
}

.returning-rsvp-link {
    background: transparent;
    border: none;
    padding: 0.5rem 0.75rem;
    font: inherit;
    font-size: 0.92rem;
    color: #5a5552;
    cursor: pointer;
    border-radius: 999px;
    transition: color 140ms ease, background 140ms ease;
}

    .returning-rsvp-link:hover {
        color: var(--olive-700);
        background: rgba(115, 132, 110, 0.08);
    }

    .returning-rsvp-link:focus-visible {
        outline: 2px solid var(--lavender-700);
        outline-offset: 3px;
    }

.returning-rsvp-link-cta {
    color: var(--lavender-700);
    font-weight: 600;
    margin-left: 0.25rem;
}

.returning-rsvp-row-inline {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    max-width: 480px;
    margin: 0 auto;
    width: 100%;
}

.returning-rsvp-input {
    flex: 1 1 200px;
    min-width: 0;
    border-radius: 12px;
    border: 1px solid rgba(134, 114, 164, 0.32);
    padding: 0.65rem 0.8rem;
    font: inherit;
    background: #ffffff;
    letter-spacing: 0.04em;
}

    .returning-rsvp-input:focus {
        outline: none;
        border-color: var(--olive-700);
        box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.18);
    }

.returning-rsvp-cancel {
    width: 38px;
    min-height: 38px;
    padding: 0;
    border-radius: 999px;
    line-height: 1;
    font-size: 1.2rem;
    flex: 0 0 auto;
}

@media (max-width: 480px) {
    .returning-rsvp-row-inline {
        flex-wrap: nowrap;
    }

    .returning-rsvp-input {
        flex: 1 1 auto;
    }
}

.our-story-page,
.registry-page,
.contact-page {
    max-width: 980px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    padding: clamp(1.1rem, 3vw, 2rem);
    box-shadow: var(--shadow-soft);
}

.contact-page {
    max-width: 720px;
}

.contact-page-header h1 {
    margin: 0.25rem 0 0.5rem;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(1.9rem, 4vw, 2.5rem);
    letter-spacing: 0.02em;
}

.contact-page-tagline {
    margin: 0 0 1.4rem;
    color: #4a4642;
    line-height: 1.6;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.contact-form-grid {
    grid-template-columns: 1fr;
    gap: 0.7rem;
}

.contact-form-grid label {
    font-size: 0.78rem;
    color: var(--olive-700);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
}

.contact-form-grid input[type="text"],
.contact-form-grid input[type="email"],
.contact-form-grid input,
.contact-textarea {
    border-radius: 10px;
    border: 1px solid rgba(115, 132, 110, 0.3);
    padding: 0.65rem 0.8rem;
    font: inherit;
    font-size: 1rem;
    background: #ffffff;
    box-sizing: border-box;
}

    .contact-form-grid input:focus,
    .contact-textarea:focus {
        outline: none;
        border-color: var(--olive-700);
        box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.18);
    }

.contact-textarea {
    width: 100%;
    resize: vertical;
    min-height: 140px;
    line-height: 1.55;
}

.contact-banner {
    margin: 0 0 1.2rem;
}

/* ---- Things to Do display-mode toggle in admin ---- */
.things-to-do-mode {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin: 0.5rem 0 0.85rem;
}

.things-to-do-mode-option {
    display: flex;
    gap: 0.7rem;
    padding: 0.85rem 1rem;
    background: rgba(222, 218, 213, 0.4);
    border: 1px solid var(--line);
    border-radius: 12px;
    cursor: pointer;
    transition: background 140ms ease, border-color 140ms ease;
}

    .things-to-do-mode-option:hover {
        background: rgba(115, 132, 110, 0.08);
        border-color: rgba(115, 132, 110, 0.45);
    }

    .things-to-do-mode-option:has(input:checked) {
        background: rgba(180, 165, 190, 0.12);
        border-color: var(--lavender-700);
        box-shadow: 0 0 0 2px rgba(134, 114, 164, 0.18);
    }

    .things-to-do-mode-option input[type="radio"] {
        margin: 0.25rem 0 0 0;
        flex: 0 0 auto;
        accent-color: var(--lavender-700);
    }

    .things-to-do-mode-option strong {
        display: block;
        color: var(--olive-700);
        margin-bottom: 0.25rem;
    }

    .things-to-do-mode-option span {
        color: #5a5552;
        font-size: 0.92rem;
        line-height: 1.5;
    }

    .things-to-do-mode-option code {
        background: rgba(115, 132, 110, 0.12);
        padding: 0.05rem 0.35rem;
        border-radius: 4px;
        font-size: 0.86rem;
    }

.rick-roll-counter-section {
    background: linear-gradient(135deg, rgba(115, 132, 110, 0.1) 0%, rgba(180, 165, 190, 0.14) 100%);
}

.rick-roll-counter-lede {
    margin-bottom: 0.75rem;
}

.rick-roll-counter-value {
    margin: 0 0 1rem;
    font-size: 1.05rem;
    color: #443f4d;
}

.rick-roll-counter-number {
    display: inline-block;
    min-width: 2.5ch;
    margin-right: 0.35rem;
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-size: clamp(2.2rem, 5vw, 3rem);
    font-weight: 600;
    line-height: 1;
    color: var(--olive-700);
}

.things-to-do-link-grid {
    margin-bottom: 0.5rem;
}

.registry-page h1 {
    margin: 0;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(2rem, 5vw, 2.7rem);
    letter-spacing: 0.02em;
}

.registry-note {
    margin: 0.85rem 0 1.25rem;
    color: #504b48;
    line-height: 1.7;
    font-size: 1.02rem;
    max-width: 720px;
}

.registry-cta {
    display: inline-flex;
    align-items: center;
    background: var(--olive-700);
    color: #ffffff;
    padding: 0.75rem 1.5rem;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 0.06em;
    font-size: 0.95rem;
    box-shadow: 0 8px 20px rgba(115, 132, 110, 0.28);
    transition: transform 140ms ease, background 140ms ease;
}

.registry-cta:hover {
    background: #5e6e5a;
    transform: translateY(-1px);
    color: #ffffff;
}

.registry-empty {
    color: #6c6864;
    font-style: italic;
}

.our-story-page h1 {
    margin: 0;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(2rem, 5vw, 2.7rem);
    letter-spacing: 0.02em;
}

.our-story-lead {
    margin: 0.75rem 0 0;
    color: #504b48;
    line-height: 1.65;
}

/* Constrain the eyebrow + body to a single readable column so images and text
   share the same left/right edges instead of looking like they're at different
   widths inside the wider card. */
.our-story-page > .eyebrow,
.our-story-content {
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
}

.our-story-content {
    margin-top: 1rem;
    line-height: 1.7;
    color: #3a3734;
    font-size: 1.04rem;
}

.our-story-content p {
    margin: 0.6rem 0 0;
}

.our-story-content h1,
.our-story-content h2,
.our-story-content h3 {
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    margin-top: 1.5rem;
    margin-bottom: 0.4rem;
}

.our-story-content h1 { font-size: 1.85rem; }
.our-story-content h2 { font-size: 1.55rem; }
.our-story-content h3 { font-size: 1.3rem; }

.our-story-content ul,
.our-story-content ol {
    padding-left: 1.4rem;
    margin: 0.6rem 0 0;
}

.our-story-content blockquote {
    margin: 1rem 0;
    padding: 0.6rem 1rem;
    border-left: 3px solid var(--lavender-700);
    background: rgba(180, 165, 190, 0.12);
    color: #4a4548;
    font-style: italic;
}

.our-story-content a {
    color: var(--lavender-700);
    text-decoration: underline;
}

.our-story-content img {
    max-width: 100%;
    height: auto;
    border-radius: 14px;
    margin: 1.5rem 0;
    display: block;
    box-shadow: var(--shadow-soft);
    border: 6px solid #ffffff;
    outline: 1px solid var(--line);
}

.our-story-content p:has(> img:only-child) {
    margin-top: 1rem;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 1080px;
}

.admin-table th,
.admin-table td {
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid rgba(180, 165, 190, 0.25);
    padding: 0.78rem;
    line-height: 1.4;
}

.admin-table th {
    color: var(--olive-700);
    background: rgba(222, 218, 213, 0.6);
}

.status-pill {
    display: inline-block;
    padding: 0.2rem 0.68rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
}

.status-pill.pending {
    background: rgba(180, 165, 190, 0.25);
    color: #584968;
}

.status-pill.ready {
    background: rgba(115, 132, 110, 0.2);
    color: #496045;
}

.actions {
    display: grid;
    gap: 0.4rem;
}

.invite-editor {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.invite-editor-header h2 {
    margin: 0;
    color: var(--olive-700);
}

.invite-editor-header p {
    margin: 0.35rem 0 0;
    color: #585350;
    line-height: 1.55;
    max-width: 760px;
}

.invite-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.7rem 1rem;
    padding: 0.85rem;
    background: rgba(222, 218, 213, 0.35);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
}

.invite-editor-add {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.invite-editor-add label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 600;
    color: #443f4d;
    font-size: 0.86rem;
}

.invite-editor-add-label {
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.74rem;
    color: var(--olive-700);
}

.invite-editor-add select {
    border-radius: 8px;
    border: 1px solid rgba(115, 132, 110, 0.32);
    padding: 0.4rem 0.55rem;
    font: inherit;
    background: #ffffff;
    min-width: 180px;
}

.invite-editor-actions {
    margin-left: auto;
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.invite-fonts-panel {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.78);
    padding: 0;
    overflow: hidden;
}

    .invite-fonts-panel > summary {
        display: flex;
        align-items: center;
        gap: 0.6rem;
        padding: 0.85rem 1rem;
        cursor: pointer;
        list-style: none;
        user-select: none;
        font-weight: 600;
        color: var(--olive-700);
        background: rgba(222, 218, 213, 0.32);
    }

    .invite-fonts-panel > summary::-webkit-details-marker {
        display: none;
    }

    .invite-fonts-panel > summary::before {
        content: "";
        flex: 0 0 auto;
        width: 0;
        height: 0;
        border-left: 6px solid var(--olive-700);
        border-top: 5px solid transparent;
        border-bottom: 5px solid transparent;
        transition: transform 160ms ease;
    }

    .invite-fonts-panel[open] > summary::before {
        transform: rotate(90deg);
    }

.invite-fonts-panel-title {
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: 1.2rem;
    letter-spacing: 0.02em;
    color: var(--olive-700);
}

.invite-fonts-panel-meta {
    margin-left: auto;
    font-size: 0.78rem;
    color: #6c6864;
    font-weight: 500;
    letter-spacing: 0.04em;
}

.invite-fonts-panel-help {
    margin: 0.85rem 1rem 0.4rem;
    color: #5a5552;
    font-size: 0.9rem;
    line-height: 1.55;
}

.invite-fonts-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem;
    padding: 0.4rem 1rem 0.85rem;
}

.invite-fonts-empty {
    margin: 0 1rem 1rem;
    color: #6c6864;
    font-style: italic;
    font-size: 0.92rem;
}

.invite-fonts-list {
    list-style: none;
    margin: 0;
    padding: 0 0.5rem 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.invite-fonts-row {
    background: #ffffff;
    border: 1px solid rgba(115, 132, 110, 0.18);
    border-radius: 12px;
    padding: 0.7rem 0.85rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.invite-fonts-family {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.invite-fonts-family-name {
    font-size: 1.4rem;
    line-height: 1.2;
    color: var(--ink);
}

.invite-fonts-family-count {
    color: #6c6864;
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.invite-fonts-files {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.invite-fonts-file {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.55rem;
    background: rgba(222, 218, 213, 0.4);
    border-radius: 8px;
    padding: 0.35rem 0.55rem 0.35rem 0.7rem;
}

.invite-fonts-file-meta {
    color: #4d4844;
    font-size: 0.84rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.invite-editor-warn {
    display: block;
    margin-top: 0.35rem;
    color: #b3691f;
    font-size: 0.78rem;
    line-height: 1.4;
}

@media (max-width: 760px) {
    .invite-editor-toolbar {
        padding: 0.7rem;
        gap: 0.55rem;
    }

    .invite-editor-add {
        flex: 1 1 100%;
    }

    .invite-editor-add label {
        flex: 1 1 auto;
    }

    .invite-editor-add select {
        flex: 1 1 auto;
        min-width: 0;
    }

    .invite-editor-actions {
        margin-left: 0;
        width: 100%;
        flex-wrap: wrap;
    }

    .invite-editor-actions > button {
        flex: 1 1 auto;
    }

    .invite-editor-panel {
        position: static;
    }
}

.invite-generate-btn {
    background: var(--lavender-700);
    box-shadow: 0 8px 20px rgba(134, 114, 164, 0.32);
}

.invite-editor-empty {
    border: 1.5px dashed rgba(115, 132, 110, 0.45);
    border-radius: var(--radius-md);
    padding: 2.5rem 1rem;
    text-align: center;
    color: #5a5552;
    background: rgba(255, 255, 255, 0.6);
}

.invite-editor-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
}

@media (min-width: 1100px) {
    .invite-editor-grid {
        grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr);
        align-items: start;
    }
}

.invite-editor-stage-wrap {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.invite-editor-stage {
    position: relative;
    width: 100%;
    background: #1f1f1d;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    user-select: none;
    touch-action: none;
}

.invite-editor-img {
    display: block;
    width: 100%;
    height: auto;
    -webkit-user-drag: none;
    user-select: none;
    pointer-events: none;
}

.invite-editor-hint {
    margin: 0;
    color: #5d5854;
    font-size: 0.86rem;
}

.invite-overlay {
    position: absolute;
    box-sizing: border-box;
    border: 1px dashed rgba(134, 114, 164, 0.55);
    background: rgba(255, 255, 255, 0.04);
    cursor: grab;
    padding: 2px 4px;
    border-radius: 3px;
    color: #ffffff;
    transition: border-color 120ms ease, background 120ms ease;
}

.invite-overlay:hover {
    border-color: rgba(134, 114, 164, 0.95);
    background: rgba(255, 255, 255, 0.08);
}

.invite-overlay.selected {
    border: 1.5px solid var(--lavender-700);
    background: rgba(180, 165, 190, 0.18);
    box-shadow: 0 0 0 3px rgba(134, 114, 164, 0.22);
}

.invite-overlay.dragging {
    cursor: grabbing;
    opacity: 0.9;
}

.invite-overlay-content {
    pointer-events: none;
    line-height: inherit;
    font-family: inherit;
    word-wrap: break-word;
    white-space: pre-wrap;
}

.invite-overlay-line {
    line-height: inherit;
}

.invite-overlay-handle-resize {
    position: absolute;
    right: -7px;
    bottom: -7px;
    width: 14px;
    height: 14px;
    background: var(--lavender-700);
    border: 2px solid #ffffff;
    border-radius: 999px;
    cursor: nwse-resize;
    box-shadow: 0 2px 6px rgba(47, 44, 42, 0.35);
}

/* ---- QR code overlay ---- */
.invite-overlay-qr {
    aspect-ratio: 1 / 1;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

    .invite-overlay-qr:hover {
        background: transparent;
    }

    .invite-overlay-qr.selected .invite-overlay-qr-frame {
        box-shadow: 0 0 0 3px rgba(134, 114, 164, 0.25);
    }

.invite-overlay-qr-frame {
    position: absolute;
    inset: 0;
    border: 1.5px solid var(--qr-frame-color, #3b3a37);
    border-radius: 10%;
    background: #ffffff;
    padding: 3%;
    box-sizing: border-box;
    pointer-events: none;
    transition: box-shadow 140ms ease;
}

.invite-overlay-qr-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}

/* ---- ColorBox layer ---- */
.invite-overlay-colorbox {
    border: 1px dashed rgba(134, 114, 164, 0.45);
    cursor: grab;
}

    .invite-overlay-colorbox.selected {
        outline: 1.5px solid var(--lavender-700);
        outline-offset: -1.5px;
    }

/* ---- Image layer ---- */
.invite-overlay-image {
    border: 1px dashed rgba(134, 114, 164, 0.45);
    background: rgba(255, 255, 255, 0.04);
    cursor: grab;
    overflow: hidden;
}

    .invite-overlay-image.selected {
        outline: 1.5px solid var(--lavender-700);
        outline-offset: -1.5px;
    }

.invite-overlay-image-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

.invite-overlay-image-empty {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 0.85rem;
    background: rgba(31, 31, 29, 0.55);
    pointer-events: none;
    text-align: center;
    padding: 0 0.5rem;
}

/* ---- Editor canvas size picker + blank canvas ---- */
.invite-editor-canvas select {
    min-width: 220px;
}

.invite-editor-stage-blank {
    background: linear-gradient(135deg, #f6f4f1 0%, var(--paper) 100%);
    width: 100%;
    height: auto;
}

.invite-editor-img-blank {
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(45deg, rgba(115, 132, 110, 0.08) 0 12px, rgba(115, 132, 110, 0) 12px 24px),
        #ffffff;
    pointer-events: none;
}

.invite-editor-stage-locked {
    /* Canvas locks to the chosen print size; the bg image (if any) cover-fits inside. */
}

.invite-editor-img-cover {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ---- Z-order buttons ---- */
.invite-editor-zorder {
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding-top: 0.4rem;
    border-top: 1px solid var(--line);
    margin-top: 0.6rem;
}

.invite-editor-zorder-actions {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.3rem;
}

    .invite-editor-zorder-actions .outline-btn {
        padding: 0.4rem 0.65rem;
        min-height: 34px;
        font-size: 0.8rem;
    }

.invite-overlay:not(.selected) .invite-overlay-handle-resize {
    opacity: 0.6;
}

.invite-editor-panel {
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    box-shadow: 0 8px 18px rgba(47, 44, 42, 0.06);
    position: sticky;
    top: 1rem;
}

.invite-editor-panel h3 {
    margin: 0;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: 1.35rem;
}

.invite-editor-panel-empty {
    margin: 0;
    color: #6c6864;
    font-size: 0.92rem;
    line-height: 1.55;
}

.invite-editor-field {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1 1 auto;
    min-width: 0;
}

.invite-editor-field > span {
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--olive-700);
}

.invite-editor-field input[type="text"],
.invite-editor-field input[type="number"],
.invite-editor-field select,
.invite-editor-field textarea {
    border-radius: 8px;
    border: 1px solid rgba(115, 132, 110, 0.3);
    padding: 0.45rem 0.55rem;
    font: inherit;
    background: #ffffff;
    width: 100%;
    box-sizing: border-box;
}

.invite-editor-field input[type="number"]:focus,
.invite-editor-field input[type="text"]:focus,
.invite-editor-field select:focus,
.invite-editor-field textarea:focus {
    outline: none;
    border-color: var(--olive-700);
    box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
}

.invite-editor-field input[type="color"] {
    height: 40px;
    width: 100%;
    border-radius: 8px;
    border: 1px solid rgba(115, 132, 110, 0.3);
    padding: 0.2rem 0.3rem;
    background: #ffffff;
    cursor: pointer;
}

.invite-editor-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.invite-editor-toggles {
    align-items: center;
    gap: 1rem;
}

.invite-editor-panel-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 0.4rem;
}

.food-prefs-list {
    list-style: none;
    margin: 0.5rem 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.food-prefs-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #ffffff;
    border: 1px solid rgba(115, 132, 110, 0.2);
    border-radius: 10px;
    padding: 0.45rem 0.55rem;
}

.food-prefs-handle {
    flex: 0 0 auto;
    width: 26px;
    height: 26px;
    border-radius: 999px;
    background: var(--paper);
    color: var(--olive-700);
    font-size: 0.78rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.food-prefs-input {
    flex: 1 1 auto;
    min-width: 0;
    border-radius: 7px;
    border: 1px solid rgba(115, 132, 110, 0.28);
    padding: 0.45rem 0.6rem;
    font: inherit;
    font-size: 0.92rem;
    background: #fbfaf8;
}

    .food-prefs-input:focus {
        outline: none;
        border-color: var(--olive-700);
        box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.16);
        background: #ffffff;
    }

.food-prefs-actions {
    justify-content: space-between;
    margin-top: 0.85rem;
}

.invite-member-line {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.invite-member-meal {
    display: inline-block;
    margin-top: 0.15rem;
    color: var(--lavender-700);
    font-size: 0.82rem;
    letter-spacing: 0.04em;
}

.invite-members-rsvped {
    margin: 0;
    padding: 0.45rem 0.7rem;
    background: rgba(115, 132, 110, 0.16);
    border-radius: 999px;
    font-size: 0.84rem;
    color: #4a5448;
    text-align: center;
    align-self: center;
}

.invite-members-extra {
    background: rgba(222, 218, 213, 0.4);
    border: 1px solid rgba(115, 132, 110, 0.18);
    border-radius: 10px;
    padding: 0.55rem 0.75rem;
}

.invite-members-extra-label {
    margin: 0 0 0.2rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.66rem;
    font-weight: 700;
    color: var(--olive-700);
}

.invite-members-extra-text {
    margin: 0;
    color: #4d4844;
    font-size: 0.92rem;
    line-height: 1.5;
    white-space: pre-wrap;
}

.access-key-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 0.85rem;
    margin: 0.85rem 0 0.5rem;
}

.access-key-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.access-key-label {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--olive-700);
}

.access-key-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.access-key-value {
    flex: 1 1 220px;
    min-width: 0;
    background: rgba(222, 218, 213, 0.5);
    border: 1px solid rgba(115, 132, 110, 0.25);
    border-radius: 8px;
    padding: 0.55rem 0.7rem;
    font-family: "Cascadia Code", "Consolas", "Monaco", "Courier New", monospace;
    font-size: 0.92rem;
    color: var(--ink);
    overflow-x: auto;
    white-space: nowrap;
}

.access-key-link {
    font-size: 0.85rem;
}

.access-key-status {
    color: #6c6864;
    font-style: italic;
    font-size: 0.88rem;
    padding-left: 0.4rem;
}

.private-shell {
    background: linear-gradient(180deg, #f6f4f1 0%, var(--paper) 100%);
}

.private-page {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1.25rem;
}

@media (max-width: 760px) {
    .private-page {
        align-items: flex-start;
        padding: 1.5rem 1rem 2.5rem;
    }
}

.private-card {
    width: 100%;
    max-width: 540px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 2.1rem 2rem 1.85rem;
    box-shadow: var(--shadow-soft);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.private-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 84px;
    height: 4px;
    border-radius: 0 0 999px 999px;
    background: linear-gradient(90deg, #8c9b86 0%, #b4a5be 100%);
}

@media (max-width: 480px) {
    .private-card {
        padding: 1.6rem 1.25rem 1.4rem;
        border-radius: 18px;
    }
}

.private-eyebrow {
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--lavender-700);
}

.private-title {
    margin: 0.5rem 0 0.25rem;
    color: var(--olive-700);
    font-family: "Cormorant Garamond", "Times New Roman", serif;
    font-weight: 500;
    font-size: clamp(2.1rem, 5vw, 2.8rem);
    letter-spacing: 0.02em;
}

.private-subtitle {
    margin: 0;
    color: #5b5754;
    font-size: 0.95rem;
    letter-spacing: 0.06em;
}

.private-tagline {
    margin: 1.05rem 0 1.2rem;
    color: #4a4642;
    line-height: 1.55;
    font-size: 0.96rem;
}

.private-form {
    text-align: left;
    margin-top: 0.4rem;
}

.private-label {
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--olive-700);
    margin-bottom: 0.4rem;
}

.private-row {
    display: flex;
    gap: 0.55rem;
    flex-wrap: wrap;
}

.private-row input {
    flex: 1 1 220px;
    min-width: 0;
    border-radius: 12px;
    border: 1px solid rgba(134, 114, 164, 0.32);
    padding: 0.7rem 0.8rem;
    font: inherit;
    background: #ffffff;
}

.private-row input:focus {
    outline: none;
    border-color: var(--olive-700);
    box-shadow: 0 0 0 3px rgba(115, 132, 110, 0.18);
}

.private-row .submit-btn {
    flex: 0 0 auto;
}

@media (max-width: 480px) {
    .private-row {
        gap: 0.5rem;
    }

    .private-row input,
    .private-row .submit-btn {
        flex: 1 1 100%;
    }
}

.private-divider {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin: 1.2rem 0 0.85rem;
    color: #8a8580;
    font-size: 0.78rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.private-divider::before,
.private-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: rgba(115, 132, 110, 0.28);
}

.private-inline-error {
    margin: 0.5rem 0 0;
}

.private-footnote {
    margin: 1.4rem 0 0;
    color: #6c6864;
    font-size: 0.86rem;
    line-height: 1.5;
}

@media (max-width: 760px) {
    .hero-shell {
        padding-top: 0.3rem;
    }

    .photo-stack {
        min-height: 260px;
    }

    .photo-secondary {
        bottom: -8px;
    }

    .card-section {
        margin: 1rem auto 2rem;
        padding: 0 0.5rem;
    }

    .card-stage {
        aspect-ratio: auto;
        max-width: 100%;
        height: auto;
        min-height: 520px;
        perspective: 1600px;
        transition: min-height 0.45s ease, height 0.45s ease;
    }

    .card-stage:not(:has(.save-the-date-card.flipped)) {
        min-height: min(78dvh, 620px);
        height: min(78dvh, 620px);
    }

    .card-stage:has(.save-the-date-card.flipped) {
        min-height: min(92dvh, 940px);
        height: min(92dvh, 940px);
    }

    .save-the-date-card {
        min-height: 520px;
    }

    .save-the-date-card.flipped {
        min-height: 100%;
    }

    .card-front {
        overflow-x: hidden;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .card-front-layout {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto;
        height: auto;
        min-height: 100%;
    }

    .card-front-photo {
        order: 0;
        min-height: 0;
        max-height: 200px;
        height: 200px;
    }

    .card-front-copy {
        order: -1;
        padding: 1.35rem 1rem 1.15rem;
        justify-content: flex-start;
        flex-shrink: 0;
    }

    .card-front-copy .card-eyebrow {
        font-size: 1.75rem;
    }

    .card-front-copy .card-eyebrow-script {
        font-size: 1.85rem;
    }

    .card-front-copy .card-divider {
        margin: 0.85rem 0 0.7rem;
    }

    .card-front-copy .card-detail-block {
        margin-top: 0.9rem;
    }

    .card-front-copy .card-link-action {
        margin-top: 1.1rem;
        min-height: 44px;
        padding: 0.6rem 1.35rem;
        flex-shrink: 0;
    }

    .card-back-form {
        padding: 0.85rem 0.75rem 0.65rem;
        gap: 0.5rem;
        height: 100%;
        min-height: 0;
        overflow: hidden;
    }

    .card-back-form > .card-back-header,
    .card-back-form > .form-validation-banner,
    .card-back-form > .rsvp-validation {
        flex: 0 0 auto;
    }

    .card-back-form > .card-back-body {
        flex: 1 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
        gap: 0.55rem;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        touch-action: pan-y;
        transform: translateZ(0);
        scrollbar-width: thin;
        padding-right: 0.15rem;
    }

    .card-back-body {
        grid-template-columns: 1fr;
        gap: 0.55rem;
    }

    .card-back-panel {
        max-height: none;
        overflow: visible;
        padding: 0.7rem 0.65rem;
        flex: 0 0 auto;
    }

    .card-back h3 {
        font-size: 1.25rem;
    }

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

    .member-editor-head {
        align-items: center;
    }

    .icon-add-btn {
        min-height: 44px;
        padding: 0.45rem 0.9rem;
        font-size: 0.8rem;
    }

    .member-row {
        display: grid;
        grid-template-columns: 28px minmax(0, 1fr) 44px;
        grid-template-rows: auto auto;
        align-items: center;
        gap: 0.5rem 0.55rem;
        padding: 0.6rem 0.55rem;
    }

    .member-index {
        grid-row: 1;
        grid-column: 1;
        width: 28px;
        height: 28px;
        font-size: 0.75rem;
    }

    .member-row .member-name-input {
        grid-row: 1;
        grid-column: 2;
        min-width: 0;
        width: 100%;
        min-height: 44px;
        padding: 0.5rem 0.6rem;
    }

    .row-remove-btn {
        grid-row: 1;
        grid-column: 3;
        width: 44px;
        height: 44px;
        font-size: 1.25rem;
    }

    .inline-toggle {
        grid-row: 2;
        grid-column: 1 / -1;
        min-height: 36px;
        padding-left: 0.15rem;
    }

    .inline-toggle input[type="checkbox"] {
        width: 1.1rem;
        height: 1.1rem;
    }

    .member-meal-row {
        grid-column: 1 / -1;
        padding-left: 0;
    }

    .member-meal-select {
        min-height: 44px;
        padding: 0.5rem 0.6rem;
    }

    .household-notes-textarea {
        min-height: 88px;
        font-size: 16px;
    }

    .card-back .form-actions {
        flex: 0 0 auto;
        flex-direction: column;
        align-items: stretch;
        gap: 0.55rem;
        position: sticky;
        bottom: 0;
        z-index: 2;
        margin-top: auto;
        padding-top: 0.5rem;
        padding-bottom: max(0.35rem, env(safe-area-inset-bottom, 0px));
        background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #ffffff 28%);
    }

    .card-back .form-actions > button,
    .card-back .form-actions > .submit-btn,
    .card-back .form-actions > .secondary-btn,
    .card-back .form-actions > .danger-btn {
        flex: 1 1 auto;
        width: 100%;
        min-height: 48px;
    }

    /* Bump form input font-size to 16px on mobile so iOS Safari does not zoom on focus */
    .form-grid input,
    .form-grid textarea,
    .admin-toolbar input,
    .invite-login-row input,
    .registry-url-row input,
    .access-key-value,
    .admin-passcode-input,
    .admin-auth-row input,
    .private-row input,
    .returning-rsvp-input,
    .invite-portal-card .invite-login-row input,
    .invite-editor-field input[type="text"],
    .invite-editor-field input[type="number"],
    .invite-editor-field select,
    .invite-editor-field textarea,
    .registry-note-textarea,
    .household-notes-textarea,
    .food-prefs-input,
    .member-meal-select,
    .member-name-input {
        font-size: 16px;
    }

    .card-section-header h2 {
        font-size: clamp(1.55rem, 4.5vw, 2rem);
    }
}

@media (min-width: 900px) {
    .hero-shell {
        grid-template-columns: 1.1fr 0.9fr;
    }
}
