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

:root {
    --primary: #fc3f1d;
    --primary-dark: #d93517;
    --bg: #f5f5f5;
    --white: #ffffff;
    --text: #1a1a1a;
    --muted: #666;
    --border: #ddd;
    --radius: 12px;
    --shadow: 0 2px 16px rgba(0,0,0,.08);
}

body {
    font-family: 'YS Text', 'Inter', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    padding: 24px 16px 48px;
}

.container { max-width: 800px; margin: 0 auto; }

h1 { font-size: 1.75rem; font-weight: 700; margin-bottom: 8px; }
.subtitle { color: var(--muted); margin-bottom: 32px; font-size: .95rem; }

.card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 24px;
    margin-bottom: 20px;
}

.card h2 { font-size: 1.1rem; font-weight: 600; margin-bottom: 16px; }

/* Top-level tabs */
.view-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--white);
}
.view-tab {
    flex: 1;
    padding: 11px 14px;
    border: 0;
    border-right: 1px solid var(--border);
    background: transparent;
    color: var(--muted);
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
}
.view-tab:last-child { border-right: none; }
.view-tab.active {
    background: var(--primary);
    color: #fff;
}

/* Step indicators */
.steps {
    display: flex;
    gap: 0;
    margin-bottom: 28px;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--border);
}
.step {
    flex: 1;
    padding: 10px 14px;
    font-size: .8rem;
    font-weight: 500;
    text-align: center;
    color: var(--muted);
    background: var(--white);
    border-right: 1px solid var(--border);
    cursor: default;
}
.step:last-child { border-right: none; }
.step.active { background: var(--primary); color: #fff; }
.step.done   { background: #e8f5e9; color: #2e7d32; }

/* Form */
.form-row { display: grid; gap: 16px; margin-bottom: 16px; }
.form-row.cols-2 { grid-template-columns: 1fr 1fr; }
.form-row.cols-3 { grid-template-columns: 1fr 1fr 1fr; }

.field { display: flex; flex-direction: column; gap: 5px; }
.field label { font-size: .82rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; }
.field input, .field select, .field textarea {
    padding: 10px 12px;
    border: 1.5px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    color: var(--text);
    background: var(--white);
    transition: border-color .15s;
    width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus {
    outline: none;
    border-color: var(--primary);
}
.field textarea { resize: vertical; min-height: 70px; }

/* Rooms list */
.rooms-grid { display: grid; gap: 14px; }
.room-card {
    border: 2px solid var(--border);
    border-radius: 10px;
    padding: 16px;
    cursor: pointer;
    transition: border-color .15s, box-shadow .15s;
    position: relative;
}
.room-card:hover       { border-color: #bbb; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.room-card.selected    { border-color: var(--primary); }
.room-card .room-name  { font-weight: 600; font-size: 1.05rem; margin-bottom: 2px; }
.room-card .room-unit-pill {
    font-size: .82rem;
    color: #3d3d3d;
    margin-bottom: 6px;
    line-height: 1.35;
}
.room-card .room-meta  { font-size: .85rem; color: var(--muted); }
.room-card .room-price {
    position: absolute; top: 16px; right: 16px;
    font-weight: 700; font-size: 1.1rem; color: var(--primary);
}
.room-card .room-price span { font-size: .75rem; font-weight: 400; color: var(--muted); display: block; text-align: right; }

/* Summary */
.summary-table { width: 100%; border-collapse: collapse; }
.summary-table td { padding: 7px 0; font-size: .95rem; }
.summary-table td:last-child { text-align: right; font-weight: 500; }
.summary-table .total td { border-top: 1.5px solid var(--border); padding-top: 12px; font-weight: 700; font-size: 1.05rem; }

/* Buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 13px 24px;
    border: none; border-radius: 8px;
    font-size: 1rem; font-weight: 600; cursor: pointer;
    transition: background .15s, transform .1s;
    text-decoration: none;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--primary); color: #fff; width: 100%; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-primary:disabled { background: #ccc; cursor: not-allowed; }
.btn-secondary { background: var(--bg); color: var(--text); border: 1.5px solid var(--border); }

/* Split badge */
.split-badge {
    display: flex; align-items: center; gap: 10px;
    background: #fff9f0; border: 1.5px solid #ffd699;
    border-radius: 10px; padding: 12px 16px; margin-top: 16px;
    font-size: .88rem;
}
.split-badge svg { flex-shrink: 0; }
.split-badge strong { display: block; margin-bottom: 2px; }

/* Loading / Error */
.loader { text-align: center; padding: 32px; color: var(--muted); }
.loader span { display: inline-block; animation: spin 1s linear infinite; font-size: 1.5rem; }
@keyframes spin { to { transform: rotate(360deg); } }

.alert { border-radius: 8px; padding: 12px 16px; font-size: .9rem; margin-bottom: 16px; }
.alert-error   { background: #fdecea; color: #c62828; border: 1px solid #f5c6cb; }
.alert-success { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }

/* Recent bookings */
.bookings-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}
.bookings-list { overflow-x: auto; }
.bookings-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .88rem;
}
.bookings-table th,
.bookings-table td {
    padding: 8px 6px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: top;
}
.bookings-table th { color: var(--muted); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .3px; }
.status-pill {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 600;
    white-space: nowrap;
}
.status-pending { background: #fff3cd; color: #8a6d3b; }
.status-paid_pending_pms { background: #fff8e1; color: #8d6e63; }
.status-confirmed { background: #e8f5e9; color: #2e7d32; }
.status-cancelled,
.status-failed { background: #fdecea; color: #c62828; }
.status-captured { background: #e8f5e9; color: #2e7d32; }
.status-refunded,
.status-partially_refunded { background: #e3f2fd; color: #1565c0; }

/* Success/Cancel pages */
.result-page { text-align: center; padding: 48px 16px; }
.result-icon { font-size: 3.5rem; margin-bottom: 16px; }
.result-page h1 { font-size: 1.6rem; margin-bottom: 8px; }
.result-page p  { color: var(--muted); margin-bottom: 24px; }

@media (max-width: 560px) {
    .form-row.cols-2, .form-row.cols-3 { grid-template-columns: 1fr; }
}
