/* ============================================================================
   Check-in Portal — Oberleithnerův palác
   Elegant multi-step wizard. Palette & type mirror apartmapalac.cz.
   ============================================================================ */
* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --gold: #c8a24a;
    --gold-bright: #d4af37;
    --gold-soft: #efe4c6;
    --green: #1a3c34;
    --green-dark: #132b25;
    --ink: #23211c;
    --cream: #f7f3ea;
    --cream-2: #efe9db;
    --card: #ffffff;
    --muted: #8a8172;
    --border: #e6ded0;
    --error: #b3261e;
    --error-bg: #fbeced;
    --success: #1a7a4b;
    --radius: 16px;
    --radius-sm: 10px;
    --shadow: 0 6px 24px rgba(26, 60, 52, 0.08);
    --shadow-sm: 0 2px 8px rgba(26, 60, 52, 0.06);
    --serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
    --sans: 'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

html { -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--sans);
    background: var(--cream);
    background-image:
        radial-gradient(1200px 500px at 50% -200px, rgba(200, 162, 74, 0.10), transparent 70%);
    background-attachment: fixed;
    color: var(--ink);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

.page { min-height: 100vh; display: flex; flex-direction: column; }

/* ---------------------------------------------------------------- Header */
.header {
    background: linear-gradient(160deg, var(--green) 0%, var(--green-dark) 100%);
    color: #fff;
    padding: 22px 16px;
    border-bottom: 3px solid var(--gold);
}
.header-inner {
    max-width: 680px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.brand { display: flex; flex-direction: column; gap: 2px; }
.brand-name {
    font-family: var(--serif);
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 0.01em;
    line-height: 1.1;
}
.brand-sub {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    color: var(--gold-bright);
}

.lang-switch { display: flex; gap: 4px; }
.lang-switch a {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 6px 9px;
    border-radius: 8px;
    transition: background 0.15s, color 0.15s;
}
.lang-switch a.active, .lang-switch a:hover {
    background: rgba(212, 175, 55, 0.22);
    color: #fff;
}

/* ---------------------------------------------------------------- Layout */
.content {
    flex: 1;
    max-width: 680px;
    width: 100%;
    margin: 0 auto;
    padding: 24px 16px 48px;
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 22px;
    margin-bottom: 16px;
}

h2 {
    font-family: var(--serif);
    font-weight: 700;
    font-size: 22px;
    color: var(--green);
    line-height: 1.2;
}
h3 { font-family: var(--serif); font-weight: 600; }

/* ---------------------------------------------------------------- Progress */
.progress {
    max-width: 680px;
    margin: 0 auto 4px;
}
.progress-track {
    height: 5px;
    background: var(--cream-2);
    border-radius: 99px;
    overflow: hidden;
}
.progress-bar {
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--gold), var(--gold-bright));
    border-radius: 99px;
    transition: width 0.35s ease;
}
.step-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted);
    margin: 10px 2px 14px;
}

/* ---------------------------------------------------------------- Steps */
.step { display: none; }
.step.active { display: block; animation: stepIn 0.32s ease both; }
@keyframes stepIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Intro */
.intro-hero { text-align: center; padding: 30px 22px 26px; }
.intro-emblem {
    width: 58px; height: 58px;
    margin: 0 auto 16px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: radial-gradient(circle at 30% 30%, var(--gold-bright), var(--gold));
    color: #fff;
    font-size: 26px;
    box-shadow: 0 4px 14px rgba(200, 162, 74, 0.4);
}
.intro-hero h2 { margin-bottom: 8px; }
.intro-hero .welcome-text { color: var(--muted); max-width: 430px; margin: 0 auto; }

.stay-row {
    display: flex;
    gap: 14px;
    margin: 22px 0 4px;
}
.stay-item {
    flex: 1;
    background: var(--cream);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
    text-align: left;
}
.stay-item .label {
    display: block;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
    margin-bottom: 4px;
}
.stay-item strong { font-size: 15px; color: var(--green); }
.legal-note {
    font-size: 13px;
    color: var(--muted);
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

/* ---------------------------------------------------------------- Guest step */
.guest-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}
.guest-title { display: flex; align-items: center; gap: 10px; }
.guest-badge {
    width: 40px; height: 40px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
    background: var(--green);
    color: #fff;
    flex-shrink: 0;
}
.guest-card.child .guest-badge { background: var(--gold); }
.guest-title h2 { font-size: 20px; }
.guest-title .guest-kind {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted);
    font-weight: 700;
}
.btn-remove {
    background: none;
    border: 1px solid var(--border);
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 8px;
    transition: all 0.15s;
}
.btn-remove:hover { background: var(--error-bg); color: var(--error); border-color: var(--error); }

.fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-top: 18px;
}
.field-wide { grid-column: 1 / -1; }
.field label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 5px;
    color: var(--ink);
}
.field input,
.field select {
    width: 100%;
    padding: 12px 13px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 15px;
    font-family: var(--sans);
    background: #fff;
    color: var(--ink);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.field select {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 38px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23c8a24a' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    cursor: pointer;
}
.field input:focus,
.field select:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(200, 162, 74, 0.18);
}
.field input.invalid,
.field select.invalid { border-color: var(--error); background-color: var(--error-bg); }

/* Signature */
.signature-block { margin-top: 18px; }
.signature-block > label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 5px;
}
.signature-pad {
    width: 100%;
    height: 150px;
    border: 1.5px dashed #cdbfa3;
    border-radius: var(--radius-sm);
    background:
        repeating-linear-gradient(45deg, #fcfaf4, #fcfaf4 12px, #f8f4ea 12px, #f8f4ea 24px);
    touch-action: none;
    display: block;
    cursor: crosshair;
}
.signature-pad.invalid { border-color: var(--error); }
.signature-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}
.signature-foot small { color: var(--muted); font-size: 12px; }
.btn-clear {
    background: none;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 5px 14px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--muted);
    transition: all 0.15s;
}
.btn-clear:hover { border-color: var(--gold); color: var(--green); }

/* ---------------------------------------------------------------- Summary */
.summary-head { margin-bottom: 4px; }
.summary-head h2 { margin-bottom: 6px; }
.summary-head p { color: var(--muted); font-size: 14px; }

.summary-guest {
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 16px 18px;
    margin-bottom: 12px;
    background: #fff;
}
.summary-guest-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--gold-soft);
}
.summary-guest-head .who {
    display: flex; align-items: center; gap: 10px;
    font-family: var(--serif); font-weight: 600; font-size: 17px; color: var(--green);
}
.summary-guest-head .dot {
    width: 10px; height: 10px; border-radius: 50%; background: var(--green);
}
.summary-guest.child .summary-guest-head .dot { background: var(--gold); }
.btn-edit {
    background: none;
    border: none;
    color: var(--gold);
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 6px;
}
.btn-edit:hover { color: var(--green); text-decoration: underline; }
.summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 20px;
}
.summary-grid .s-item { min-width: 0; }
.summary-grid .s-item.wide { grid-column: 1 / -1; }
.summary-grid .s-label {
    display: block;
    font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em;
    color: var(--muted); margin-bottom: 1px;
}
.summary-grid .s-value { font-size: 14px; word-break: break-word; }
.summary-grid .s-value.empty { color: var(--error); font-style: italic; }
.summary-sign img {
    height: 54px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
    margin-top: 2px;
}

.add-more {
    text-align: center;
    margin: 4px 0 18px;
}
.add-more .add-label { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.add-buttons { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

.gdpr {
    font-size: 12.5px;
    color: var(--muted);
    background: var(--cream);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    margin: 4px 0 14px;
}

/* ---------------------------------------------------------------- Buttons / nav */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    border-radius: 12px;
    padding: 13px 22px;
    font-size: 15px;
    font-family: var(--sans);
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s, transform 0.05s, box-shadow 0.15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
    background: var(--green);
    color: #fff;
    box-shadow: 0 4px 14px rgba(26, 60, 52, 0.22);
}
.btn-primary:hover { background: var(--green-dark); }
.btn-primary:disabled { opacity: 0.6; cursor: wait; }
.btn-gold {
    background: linear-gradient(135deg, var(--gold-bright), var(--gold));
    color: #fff;
    box-shadow: 0 4px 14px rgba(200, 162, 74, 0.3);
}
.btn-gold:hover { filter: brightness(1.05); }
.btn-gold:disabled { opacity: 0.6; cursor: wait; }
.btn-outline {
    background: #fff;
    border: 1px solid var(--border);
    color: var(--green);
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold); }
.btn-ghost {
    background: transparent;
    color: var(--muted);
    padding: 13px 10px;
}
.btn-ghost:hover { color: var(--green); }

.step-nav {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
}
.step-nav .spacer { flex: 1; }
.step-nav .btn-primary, .step-nav .btn-gold { min-width: 160px; }

.btn-block { width: 100%; }

.form-error {
    background: var(--error-bg);
    color: var(--error);
    border: 1px solid #f1c9cc;
    border-radius: var(--radius-sm);
    padding: 11px 14px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 14px;
}

/* ---------------------------------------------------------------- Status pages */
.status-card { text-align: center; padding: 52px 26px; }
.status-icon {
    width: 68px; height: 68px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 32px;
    margin: 0 auto 20px;
    color: #fff;
}
.status-icon.success { background: var(--success); }
.status-icon.error { background: var(--error); }
.status-card h2 { margin-bottom: 10px; }
.status-card p { color: var(--muted); max-width: 420px; margin: 0 auto; }

/* ---------------------------------------------------------------- Footer */
.footer {
    text-align: center;
    padding: 18px;
    font-size: 12px;
    color: var(--muted);
}
.footer strong { color: var(--green); }

/* ---------------------------------------------------------------- Mobile */
@media (max-width: 540px) {
    .fields { grid-template-columns: 1fr; }
    .summary-grid { grid-template-columns: 1fr; }
    .brand-name { font-size: 20px; }
    .stay-row { flex-direction: column; gap: 10px; }
    .step-nav .btn-primary, .step-nav .btn-gold { min-width: 0; flex: 1; }
    .step-nav { gap: 8px; }
}
