:root {
    --bg: #fafafa;
    --surface: #ffffff;
    --text: #0a0a0a;
    --text-muted: #737373;
    --line: #e5e5e5;
    --line-strong: #d4d4d4;
    --accent: #0a0a0a;
    --accent-soft: #f5f5f5;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-full: 9999px;
    --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color-scheme: only light;
}

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

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.page-layout {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 100vh;
    align-items: stretch;
}

@media (min-width: 900px) {
    .page-layout {
        grid-template-columns: 2fr 1fr;
        min-height: 100vh;
        height: 100vh;
    }
}

.page-flag {
    position: relative;
    overflow: hidden;
    background: var(--accent-soft);
    min-height: 32vh;
    width: 100%;
}

@media (min-width: 900px) {
    .page-flag {
        min-height: 100%;
        height: 100%;
        align-self: stretch;
    }
}

.page-flag-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

@media (max-width: 899px) {
    .page-flag {
        aspect-ratio: 16 / 10;
        min-height: 0;
    }
}

.page-booking {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-width: 0;
    background: var(--bg);
    padding-left: clamp(1.25rem, 6vw, 2.25rem);
    padding-right: clamp(1.25rem, 6vw, 2.25rem);
}

.app-header {
    padding: clamp(0.5rem, 1.5vw, 0.75rem) 0 0;
}

.app-brand-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    width: 100%;
}

.app-brand-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    flex: 1;
    min-width: 0;
}

.app-heading-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.app-logo {
    display: block;
    height: auto;
    max-height: 3.5rem;
    width: auto;
    max-width: min(100%, 14rem);
    object-fit: contain;
}

.app-meet-img {
    flex-shrink: 1;
    width: 580px;
    max-width: 100%;
    height: auto;
    margin-left: auto;
    object-fit: contain;
}

.app-title {
    margin: 0;
    font-size: clamp(1.5rem, 4vw, 1.875rem);
    font-weight: 600;
    letter-spacing: -0.03em;
    line-height: 1.2;
}

.app-subtitle {
    margin: 0;
    max-width: 28rem;
    font-size: 0.9375rem;
    font-weight: 400;
    color: var(--text-muted);
    letter-spacing: -0.01em;
}

.booking-main {
    flex: 1;
    padding: 0 0 clamp(1.5rem, 4vw, 2rem);
    overflow-y: auto;
}

.booking-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--line);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.booking-grid {
    display: grid;
    grid-template-columns: 1fr;
}

.panel {
    padding: clamp(1.25rem, 3vw, 1.75rem) clamp(1.25rem, 3vw, 1.75rem);
    border-bottom: 1px solid var(--line);
}

.page-booking .panel--calendar {
    border-bottom: 1px solid var(--line);
}

.panel-heading {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin: 0 0 1.25rem;
}

.panel-heading--spaced {
    margin-top: 2rem;
}

.panel-heading--section {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #0c2d6b;
    margin-bottom: 1rem;
}

.cal-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    gap: 0.75rem;
}

.cal-nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border: none;
    border-radius: var(--radius-full);
    background: transparent;
    color: var(--text);
    font: inherit;
    cursor: pointer;
    transition: background 0.15s ease;
}

.cal-nav-btn:hover:not(:disabled) {
    background: var(--accent-soft);
}

.cal-nav-btn:disabled {
    opacity: 0.25;
    cursor: not-allowed;
}

.cal-nav-icon {
    font-size: 1.35rem;
    line-height: 1;
    font-weight: 300;
    margin-top: -0.1em;
}

.cal-month {
    font-weight: 600;
    font-size: 0.9375rem;
    letter-spacing: -0.02em;
    color: var(--text);
}

.cal-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    margin-bottom: 0.5rem;
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    text-align: center;
    text-transform: uppercase;
}

.cal-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
}

.cal-pad {
    min-height: 40px;
}

.cal-day {
    aspect-ratio: 1;
    max-height: 40px;
    margin: 0 auto;
    width: 100%;
    max-width: 40px;
    border: none;
    border-radius: var(--radius-full);
    background: transparent;
    font: inherit;
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: -0.02em;
    cursor: pointer;
    color: var(--text);
    transition: background 0.15s ease, color 0.15s ease;
}

.cal-day:hover:not(:disabled):not(.cal-day--muted):not(.cal-day--off) {
    background: var(--accent-soft);
}

.cal-day--muted {
    color: #d4d4d4;
    cursor: default;
}

.cal-day--off {
    color: #e5e5e5;
    cursor: not-allowed;
}

.cal-day--selected {
    background: var(--accent);
    color: #fff;
}

.cal-day--selected:hover {
    background: #262626;
    color: #fff;
}

.cal-day:disabled {
    cursor: not-allowed;
}

.slots {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0;
    min-height: 2.5rem;
}

.slot-btn {
    border: 1px solid var(--line);
    background: var(--surface);
    border-radius: var(--radius-full);
    padding: 0.4rem 0.95rem;
    font: inherit;
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.slot-btn:hover {
    border-color: var(--line-strong);
    background: var(--accent-soft);
}

.slot-btn--active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.slot-btn--active:hover {
    background: #262626;
    border-color: #262626;
    color: #fff;
}

.form-group {
    margin-bottom: 1.125rem;
}

.form-group label {
    display: block;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface);
    font: inherit;
    font-size: 0.9375rem;
    letter-spacing: -0.01em;
    color: var(--text);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #a3a3a3;
}

.form-group input:hover,
.form-group textarea:hover {
    border-color: var(--line-strong);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--text);
    box-shadow: 0 0 0 3px rgba(10, 10, 10, 0.06);
}

.form-row {
    display: grid;
    gap: 1rem;
}

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

.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.7rem 1.25rem;
    border: none;
    border-radius: var(--radius-sm);
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    font-size: 0.875rem;
    letter-spacing: -0.01em;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.1s ease;
}

.page-booking .btn-primary {
    width: 100%;
}

.btn-primary:hover:not(:disabled) {
    background: #262626;
}

.btn-primary:active:not(:disabled) {
    transform: scale(0.98);
}

.btn-primary:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin: -0.25rem 0 1.125rem;
    letter-spacing: -0.01em;
}

.alert {
    padding: 0.75rem 0.875rem;
    border-radius: var(--radius-sm);
    font-size: 0.8125rem;
    margin-bottom: 1rem;
    letter-spacing: -0.01em;
}

.alert--error {
    background: #fef2f2;
    color: #991b1b;
}

.alert--success {
    background: #f0fdf4;
    color: #166534;
}

.alert--confirmation {
    background: #f8fafc;
    color: var(--text);
    border: 1px solid var(--line);
    padding: 1rem 1.125rem;
    max-height: min(70vh, 32rem);
    overflow-y: auto;
}

.confirmation {
    font-size: 0.8125rem;
    line-height: 1.55;
}

.confirmation-banner {
    margin: 0 0 1rem;
    text-align: center;
}

.confirmation-banner-img {
    display: block;
    max-width: 380px;
    width: 100%;
    height: auto;
    margin: 0 auto;
    border-radius: var(--radius-sm);
}

.confirmation-kicker {
    margin: 0 0 0.75rem;
    font-weight: 700;
    font-size: 1.375rem;
    line-height: 1.3;
    color: #0c2d6b;
}

.confirmation-subject {
    margin: 0 0 1rem;
    color: var(--text-muted);
}

.confirmation p {
    margin: 0 0 0.75rem;
}

.confirmation-h {
    margin: 1rem 0 0.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #0c2d6b;
}

.confirmation-list {
    margin: 0 0 0.75rem;
    padding-left: 1.25rem;
}

.confirmation-list li {
    margin-bottom: 0.35rem;
}

.confirmation-note {
    font-size: 0.8125rem;
}

.confirmation a {
    color: #0c2d6b;
}

.loader {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.65s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.empty-slots {
    color: var(--text-muted);
    font-size: 0.8125rem;
    letter-spacing: -0.01em;
}

body.modal-open {
    overflow: hidden;
}

.booking-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.booking-modal[hidden] {
    display: none;
}

.booking-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(12, 45, 107, 0.45);
}

.booking-modal-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 26rem);
    padding: 1.75rem 1.5rem 1.5rem;
    background: #fff;
    border-radius: var(--radius);
    box-shadow: 0 18px 48px rgba(12, 45, 107, 0.22);
}

.booking-modal-title {
    margin: 0 0 0.75rem;
    font-size: 1.125rem;
    font-weight: 700;
    color: #0c2d6b;
}

.booking-modal-text {
    margin: 0 0 1.25rem;
    font-size: 0.9375rem;
    line-height: 1.55;
    color: var(--text);
}

.booking-modal-btn {
    width: 100%;
}
