body {
    font-family: "Inter", "Segoe UI", sans-serif;
    background: #f2f7ff;
    color: #1f2f6b;
}

.page-shell {
    min-height: 100vh;
    padding: 24px;
}

.header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.header-clock {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 140px;
    border-radius: 16px;
    background: #eef4ff;
    color: #1f2f6b;
    font-family: 'Segoe UI', sans-serif;
    font-size: 1.4rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    border: 1px solid black;
}

.header-clock span {
    display: block;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 14px;
}

.header-logo {
    width: 52px;
    height: 52px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    background: #e6f0ff;
    color: #1f3a93;
    flex-shrink: 0;
}

.header-logo svg {
    width: 28px;
    height: 28px;
}

.header-brand > div {
    display: flex;
    flex-direction: column;
}

.brand-address {
    margin: 4px 0 0;
    font-size: 0.95rem;
}

.brand-subtitle {
    margin: 6px 0 0;
    color: #46516b;
    font-size: 0.95rem;
}

.header-bar h1 {
    margin: 0;
    font-size: 2rem;
}

@media (max-width: 768px) {
    .header-bar {
        flex-direction: column;
        align-items: stretch;
    }
    .header-brand {
        width: 100%;
    }
}

.card-panel {
    background: #ffffff;
    border: 1px solid #d7e0ff;
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(10, 35, 80, 0.08);
}

.section-card {
    padding: 24px;
    margin-bottom: 20px;
}

.btn-action {
    min-width: 160px;
}

.status-box {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid transparent;
    margin-top: 12px;
}

.status-success { background: #e6f5ea; border-color: #c4e4d1; color: #1f6f46; }
.status-error { background: #fde8e8; border-color: #f5c2c7; color: #9f1239; }
.status-warn { background: #fff4e5; border-color: #ffddb4; color: #92400e; }

.service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; }
.service-card {
    background: #eef4ff;
    border: 1px solid #d5e3ff;
    border-radius: 16px;
    padding: 24px;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-card button {
    width: 100%;
}

.ticket-receipt {
    max-width: 420px;
    margin: 0 auto;
    padding: 24px;
    border: 1px dashed #1f3a93;
    border-radius: 20px;
    background: #ffffff;
}

.ticket-receipt h2 {
    margin: 0 0 12px;
    font-size: 2.4rem;
}

.ticket-receipt .ticket-code {
    font-size: 3.4rem;
    color: #1f3a93;
    margin: 18px 0;
}

.ticket-receipt .small-text {
    color: #5e6d8b;
}

@media print {
    @page {
        size: 80mm auto;
        margin: 5mm;
    }

    html, body {
        width: 80mm;
        height: auto;
        margin: 0;
        padding: 0;
        background: #ffffff;
    }

    body * {
        visibility: hidden;
    }

    #receipt-preview, #receipt-preview * {
        visibility: visible;
    }

    #receipt-preview {
        position: absolute;
        left: 0;
        top: 0;
        width: 80mm;
        max-width: 100%;
        padding: 0;
        margin: 0;
    }

    .ticket-receipt {
        margin: 0;
        box-shadow: none;
        border: none;
    }
}
