:root {
    --royal-blue: #0d2b66;
    --royal-blue-light: #16479b;
    --steel-blue: #526b92;
    --gold: #c99a35;
    --gold-light: #e4c271;
    --text: #101a32;
    --muted: #586985;
    --surface: #ffffff;
    --surface-blue: #f3f6fc;
    --border: #d9e1ee;

    font-family:
        Inter,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    color: var(--text);
}

* {
    box-sizing: border-box;
}

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

body {
    margin: 0;
}

button,
input,
select,
textarea {
    font: inherit;
}

/* -------------------------------------------------
   Willkommen
------------------------------------------------- */

.welcome-body {
    min-height: 100vh;
    overflow-x: hidden;
    background:
        radial-gradient(
            circle at top,
            rgba(255, 255, 255, 0.94),
            rgba(236, 242, 250, 0.96) 62%,
            #dde8f4 100%
        );
}

.alpine-background {
    position: fixed;
    inset: auto 0 0;
    height: 54vh;
    pointer-events: none;
    opacity: 0.24;
    background:
        linear-gradient(
            to top,
            rgba(66, 96, 135, 0.27),
            transparent 70%
        ),
        url("/static/mountains.svg")
        center bottom / min(1500px, 160vw) auto no-repeat;
    filter: saturate(0.8);
}

.welcome-page {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 30px 20px;
}

.welcome-card {
    width: 100%;
    max-width: 740px;
    padding: 56px 58px 50px;
    background: rgba(255, 255, 255, 0.97);
    border: 1px solid rgba(13, 43, 102, 0.07);
    border-radius: 30px;
    box-shadow:
        0 34px 90px rgba(13, 43, 102, 0.17),
        0 5px 20px rgba(13, 43, 102, 0.06);
}

/* -------------------------------------------------
   Premium-Logo
------------------------------------------------- */

.premium-brand {
    margin-bottom: 34px;
    text-align: center;
}

.premium-logo {
    display: block;
    width: min(100%, 650px);
    height: auto;
    margin: 0 auto;
}

.brand-the {
    position: relative;
    z-index: 2;
    color: var(--royal-blue);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.4rem;
    letter-spacing: 0.32rem;
}

.brand-title {
    margin-top: 4px;
    color: var(--royal-blue);
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2rem, 5vw, 3.8rem);
    line-height: 1;
    letter-spacing: 0.13em;
}

.brand-claim {
    margin-top: 16px;
    color: var(--gold);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1rem;
    letter-spacing: 0.42rem;
}

.brand-divider {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 20px;
    max-width: 500px;
    margin: 22px auto 17px;
    color: var(--gold);
}

.brand-divider span {
    height: 1px;
    background: var(--gold);
}

.brand-divider strong {
    font-size: 1.5rem;
}

.digital-title {
    color: var(--royal-blue);
    font-size: 1.15rem;
    font-weight: 600;
}

/* -------------------------------------------------
   Begrüssung
------------------------------------------------- */

.welcome-heading {
    margin-top: 43px;
    text-align: center;
}

.welcome-heading h1 {
    margin: 0;
    color: var(--text);
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.8rem, 7vw, 4.6rem);
    line-height: 1.05;
}

.welcome-heading p {
    max-width: 570px;
    margin: 24px auto 0;
    color: var(--muted);
    font-size: 1.06rem;
    line-height: 1.75;
}

/* -------------------------------------------------
   Buchungsübersicht
------------------------------------------------- */

.booking-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px 32px;
    margin-top: 39px;
    padding: 29px;
    background:
        linear-gradient(
            145deg,
            #f5f8fd,
            #edf3fb
        );
    border: 1px solid var(--border);
    border-radius: 22px;
}

.booking-item {
    display: grid;
    grid-template-columns: 58px 1fr;
    align-items: center;
    gap: 15px;
}

.booking-icon {
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    background: #e9f0fb;
    border: 1px solid #d4deee;
    border-radius: 50%;
}

.booking-icon svg {
    width: 29px;
    height: 29px;
    fill: none;
    stroke: var(--royal-blue);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.booking-item div:last-child {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.booking-item span {
    color: var(--royal-blue);
    font-size: 0.85rem;
}

.booking-item strong {
    color: var(--text);
    font-size: 1.05rem;
}

/* -------------------------------------------------
   Button und Datenschutz
------------------------------------------------- */

.duration {
    margin: 34px 0 24px;
    color: var(--muted);
    font-size: 1rem;
    text-align: center;
}

.premium-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    width: 100%;
    min-height: 67px;
    padding: 17px 28px;
    border-radius: 14px;
    background:
        linear-gradient(
            135deg,
            #0d2b66,
            #1246a1
        );
    color: white;
    font-size: 1.15rem;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 13px 28px rgba(13, 43, 102, 0.22);
    transition:
        transform 160ms ease,
        box-shadow 160ms ease;
}

.premium-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 17px 35px rgba(13, 43, 102, 0.28);
}

.button-arrow {
    font-size: 2rem;
    font-weight: 300;
    line-height: 1;
}

.privacy-note {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 13px;
    max-width: 560px;
    margin: 26px auto 0;
    color: #677791;
    font-size: 0.85rem;
    line-height: 1.55;
    text-align: center;
}

.privacy-note svg {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    fill: none;
    stroke: var(--steel-blue);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* -------------------------------------------------
   Bestehendes Check-in-Formular
------------------------------------------------- */

.page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 30px 20px;
    background: #f2f5fa;
}

.card {
    width: 100%;
    max-width: 520px;
    padding: 42px 34px;
    background: white;
    border-radius: 24px;
    box-shadow: 0 24px 70px rgba(13, 43, 102, 0.13);
}

.card-wide {
    max-width: 760px;
}

.brand {
    margin-bottom: 38px;
    text-align: center;
}

.brand::before {
    content: "";
    display: block;
    width: 55px;
    height: 2px;
    margin: 0 auto 18px;
    background: var(--gold);
}

.brand-name {
    margin: 0;
    color: var(--royal-blue);
    font-family: Georgia, "Times New Roman", serif;
    font-weight: 700;
    letter-spacing: 0.22rem;
}

.brand-subtitle {
    margin: 9px 0 0;
    color: var(--steel-blue);
}

.progress {
    margin-bottom: 30px;
}

.progress-bar {
    height: 7px;
    overflow: hidden;
    background: #e5eaf2;
    border-radius: 999px;
}

.progress-bar span {
    display: block;
    height: 100%;
    background: var(--royal-blue);
    border-radius: inherit;
}

.progress p {
    margin: 9px 0 0;
    color: var(--steel-blue);
    font-size: 0.8rem;
    text-align: right;
}

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

.form-header h1 {
    margin: 0;
    font-family: Georgia, "Times New Roman", serif;
    color: var(--royal-blue);
    font-size: 2.25rem;
}

.form-header p {
    max-width: 540px;
    margin: 15px auto 0;
    color: var(--muted);
    line-height: 1.65;
}

.checkin-form {
    margin-top: 30px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 21px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

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

.field span {
    color: var(--text);
    font-size: 0.86rem;
    font-weight: 650;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    min-height: 51px;
    padding: 12px 14px;
    border: 1px solid #cad4e4;
    border-radius: 11px;
    background: white;
    color: var(--text);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--royal-blue);
    box-shadow: 0 0 0 4px rgba(13, 43, 102, 0.11);
}

.form-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 31px;
}

.button {
    display: block;
    width: 100%;
    padding: 16px;
    border: 0;
    border-radius: 12px;
    background: var(--royal-blue);
    color: white;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.button-secondary {
    border: 1px solid var(--royal-blue);
    background: white;
    color: var(--royal-blue);
}

.privacy {
    margin: 18px 0 0;
    color: #78869a;
    font-size: 0.77rem;
    line-height: 1.5;
    text-align: center;
}

/* -------------------------------------------------
   Fehlermeldungen
------------------------------------------------- */

.error-summary {
    margin: 0 0 26px;
    padding: 17px 19px;
    border: 1px solid #e6b8b8;
    border-left: 4px solid #a83232;
    border-radius: 11px;
    background: #fff5f5;
    color: #742626;
    font-size: 0.9rem;
    line-height: 1.55;
}

.error-summary strong {
    display: block;
    margin-bottom: 7px;
}

.error-summary ul {
    margin: 0;
    padding-left: 21px;
}

/* -------------------------------------------------
   Dokument
------------------------------------------------- */

.document-info {
    grid-column: 1 / -1;
    margin-top: 24px;
}

/* -------------------------------------------------
   Mitreisende
------------------------------------------------- */

.guest-count {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
    padding: 15px 18px;
    border-radius: 12px;
    background: #edf3fb;
    color: var(--royal-blue);
}

.guest-list {
    display: grid;
    gap: 13px;
}

.guest-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 15px;
    padding: 17px;
    border: 1px solid #d8e0ed;
    border-radius: 14px;
    background: white;
}

.guest-avatar {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #e7eef9;
    color: var(--royal-blue);
    font-weight: 700;
}

.guest-card-title {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
}

.guest-card-content p {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 0.84rem;
}

.status-badge {
    padding: 4px 8px;
    border-radius: 999px;
    background: var(--royal-blue);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
}

.status-secondary {
    background: #e8eef8;
    color: var(--royal-blue);
}

.delete-button {
    border: 0;
    background: transparent;
    color: #9b3030;
    cursor: pointer;
}

.companion-panel {
    margin-top: 24px;
    border: 1px solid #d8e0ed;
    border-radius: 15px;
    background: #fafcff;
}

.companion-panel summary {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px;
    color: var(--royal-blue);
    font-weight: 700;
    cursor: pointer;
    list-style: none;
}

.companion-panel summary::-webkit-details-marker {
    display: none;
}

.plus-symbol {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--royal-blue);
    color: white;
    font-size: 1.25rem;
}

.companion-form {
    margin: 0;
    padding: 4px 18px 20px;
}

.companion-save-button {
    margin-top: 24px;
}

.form-actions form {
    width: 100%;
}

/* -------------------------------------------------
   Zusammenfassung
------------------------------------------------- */

.summary-section {
    margin-top: 25px;
    padding: 23px;
    border: 1px solid #d8e0ed;
    border-radius: 16px;
    background: #ffffff;
}

.summary-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    margin-bottom: 19px;
}

.summary-heading h2 {
    margin: 0;
    color: var(--royal-blue);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.45rem;
}

.summary-edit {
    color: var(--royal-blue);
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
}

.summary-edit:hover {
    text-decoration: underline;
}

.summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 17px;
}

.summary-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 14px;
    border-radius: 11px;
    background: #f3f6fb;
}

.summary-item span {
    color: var(--steel-blue);
    font-size: 0.77rem;
}

.summary-item strong {
    color: var(--text);
}

.summary-person {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: start;
    gap: 17px;
}

.summary-person + .summary-person {
    margin-top: 19px;
    padding-top: 19px;
    border-top: 1px solid #e2e7ef;
}

.summary-person-content {
    min-width: 0;
}

.summary-person-content h3 {
    margin: 2px 0 16px;
    color: var(--text);
    font-size: 1.08rem;
}

.summary-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 13px 22px;
    margin: 0;
}

.summary-details div {
    min-width: 0;
}

.summary-details dt {
    margin-bottom: 4px;
    color: var(--steel-blue);
    font-size: 0.75rem;
}

.summary-details dd {
    margin: 0;
    color: var(--text);
    font-size: 0.9rem;
    overflow-wrap: anywhere;
}

.summary-companions {
    display: grid;
}

/* -------------------------------------------------
   Schritt 5 – Check-in abschliessen
------------------------------------------------- */

.confirmation-box {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin: 25px 0;
}

.confirmation-option {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    padding: 20px;
    border: 1px solid #d9e2ef;
    border-radius: 14px;
    background: #f9fbff;
    color: var(--text);
    line-height: 1.55;
    cursor: pointer;
    transition:
        background 160ms ease,
        border-color 160ms ease;
}

.confirmation-option:hover {
    border-color: var(--royal-blue);
    background: #f3f7ff;
}

.confirmation-option input {
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    margin: 4px 0 0;
    accent-color: var(--royal-blue);
}

.confirmation-option strong {
    display: block;
    margin-bottom: 6px;
    color: var(--royal-blue);
    font-size: 1rem;
}

.confirmation-option p {
    margin: 0;
    color: #58667f;
    line-height: 1.6;
}

.information-note {
    margin: 25px 0;
    padding: 18px;
    border-left: 4px solid var(--gold);
    border-radius: 10px;
    background: #fffaf2;
    color: #5a6478;
    font-size: 0.86rem;
    line-height: 1.6;
}

.complete-checkin-button {
    border: 1px solid var(--gold);
}

/* -------------------------------------------------
   Erfolgsseite – konfliktfreie Animation
------------------------------------------------- */

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

.success-card .premium-brand {
    text-align: center;
}

.checkin-success-icon {
    width: 94px;
    height: 94px;
    margin: 22px auto 30px;
}

.checkin-success-svg {
    display: block;
    width: 94px;
    height: 94px;
    overflow: visible;
}

.checkin-success-ring {
    fill: #edf8f1;
    stroke: #2f7d4a;
    stroke-width: 2.5;
    stroke-dasharray: 150;
    stroke-dashoffset: 150;
    transform-origin: center;
    animation:
        checkin-draw-ring 0.7s ease forwards,
        checkin-ring-pop 0.35s ease 0.65s forwards;
}

.checkin-success-tick {
    fill: none;
    stroke: #2f7d4a;
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 40;
    stroke-dashoffset: 40;
    animation:
        checkin-draw-tick 0.45s ease 0.55s forwards;
}

.checkin-success-content {
    opacity: 0;
    transform: translateY(12px);
    animation:
        checkin-show-content 0.55s ease forwards;
}

.success-heading {
    text-align: center;
    animation-delay: 0.9s;
}

.success-heading h1 {
    margin-bottom: 12px;
}

.success-heading p {
    max-width: 520px;
    margin: 0 auto 28px;
    text-align: center;
}

.success-booking {
    width: min(360px, 100%);
    margin: 0 auto 30px;
    padding: 20px;
    border: 1px solid #dbe3f0;
    border-radius: 15px;
    background: #f5f8fc;
    text-align: center;
    animation-delay: 1.05s;
}

.success-booking span {
    display: block;
    margin-bottom: 7px;
    color: var(--steel-blue);
    font-size: 0.8rem;
}

.success-booking strong {
    display: block;
    color: var(--royal-blue);
    font-size: 1.2rem;
}

.success-message {
    max-width: 560px;
    margin: 0 auto 32px;
    color: #4d5d7a;
    font-size: 1rem;
    line-height: 1.7;
    text-align: center;
    animation-delay: 1.2s;
}

.success-button {
    display: flex;
    width: 100%;
    justify-content: center;
    animation-delay: 1.35s;
}

@keyframes checkin-draw-ring {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes checkin-draw-tick {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes checkin-ring-pop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes checkin-show-content {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* -------------------------------------------------
   Mobile
------------------------------------------------- */

@media (max-width: 700px) {
    .welcome-page {
        padding: 0;
    }

    .welcome-card {
        min-height: 100vh;
        padding: 38px 22px 35px;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .mountain-logo {
        width: 96%;
        height: 62px;
        margin-bottom: -18px;
    }

    .brand-title {
        font-size: 2.15rem;
        letter-spacing: 0.08em;
    }

    .brand-claim {
        font-size: 0.8rem;
        letter-spacing: 0.3rem;
    }

    .welcome-heading {
        margin-top: 35px;
    }

    .booking-summary {
        grid-template-columns: 1fr;
        gap: 19px;
        padding: 22px;
    }

    .booking-item {
        grid-template-columns: 50px 1fr;
    }

    .booking-icon {
        width: 50px;
        height: 50px;
    }

    .booking-icon svg {
        width: 25px;
        height: 25px;
    }

    .page {
        padding: 0;
    }

    .card {
        min-height: 100vh;
        padding: 35px 22px;
        border-radius: 0;
        box-shadow: none;
    }

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

    .field-full,
    .document-info {
        grid-column: auto;
    }

    .guest-card {
        grid-template-columns: auto 1fr;
    }

    .guest-card form {
        grid-column: 1 / -1;
    }

    .delete-button {
        width: 100%;
        padding: 9px;
        border: 1px solid #e5caca;
        border-radius: 9px;
    }

    .guest-count {
        flex-direction: column;
    }

    .summary-section {
        padding: 18px;
    }

    .summary-grid,
    .summary-details {
        grid-template-columns: 1fr;
    }

    .summary-person {
        grid-template-columns: 1fr;
    }

    .summary-person .guest-avatar {
        margin-bottom: 2px;
    }

    .confirmation-option {
        gap: 13px;
        padding: 17px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .checkin-success-ring,
    .checkin-success-tick,
    .checkin-success-content {
        animation: none;
        opacity: 1;
        stroke-dashoffset: 0;
        transform: none;
    }
}
/* -------------------------------------------------
   Finale Erfolgsseite
------------------------------------------------- */

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

.final-success-icon {
    width: 88px;
    height: 88px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 16px auto 28px;
    border: 2px solid #2f7d4a;
    border-radius: 50%;
    background: #edf8f1;
    color: #2f7d4a;
    font-size: 44px;
    font-weight: 700;
    line-height: 1;
    box-shadow: 0 10px 25px rgba(47, 125, 74, 0.12);
}

.final-success-heading {
    text-align: center;
}

.final-success-heading h1 {
    margin: 0 0 12px;
}

.final-success-heading p {
    max-width: 520px;
    margin: 0 auto;
    text-align: center;
}

.final-success-booking {
    width: min(360px, 100%);
    margin: 28px auto;
    padding: 20px;
    border: 1px solid #dbe3f0;
    border-radius: 15px;
    background: #f5f8fc;
    text-align: center;
}

.final-success-booking span {
    display: block;
    margin-bottom: 7px;
    color: var(--steel-blue);
    font-size: 0.8rem;
}

.final-success-booking strong {
    display: block;
    color: var(--royal-blue);
    font-size: 1.2rem;
}

.final-success-message {
    max-width: 560px;
    margin: 0 auto 30px;
    color: #4d5d7a;
    font-size: 1rem;
    line-height: 1.7;
    text-align: center;
}

.final-success-button {
    display: flex;
    justify-content: center;
    width: 100%;
}