﻿html, body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    font-family: "Segoe UI", Arial, sans-serif;
    background: linear-gradient(180deg, #f4f8fb 0%, #eef3f7 100%);
    color: #1f2937;
}

* {
    box-sizing: border-box;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.app-shell {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    padding: 24px;
    gap: 16px;
}

.app-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    flex: 0 0 auto;
}

.logo-wrap {
    background: #ffffff;
    border-radius: 28px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
    padding: 14px 24px;
    width: 100%;
    max-width: 1100px;
    text-align: center;
}

.company-logo {
    display: block;
    margin: 0 auto;
    max-width: 360px;
    width: 100%;
    height: auto;
    max-height: 110px;
    object-fit: contain;
}

.app-main {
    flex: 1;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    min-height: 0;
}

.home-card {
    width: 100%;
    max-width: 1100px;
    background: #ffffff;
    border-radius: 36px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.10);
    padding: 40px 36px;
}

.home-intro {
    text-align: center;
    margin-bottom: 32px;
}

    .home-intro h1 {
        margin: 0 0 12px 0;
        font-size: 2.2rem;
        font-weight: 700;
        color: #0f172a;
    }

    .home-intro p {
        margin: 0;
        font-size: 1.1rem;
        color: #475569;
    }

.home-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.action-button {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 140px;
    text-decoration: none;
    border-radius: 32px;
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.10);
}

    .action-button:hover {
        transform: translateY(-2px);
        opacity: 0.96;
    }

.action-primary {
    background: linear-gradient(135deg, #0f6fcf 0%, #20c9b5 100%);
    color: #ffffff;
}

.action-secondary {
    background: #f8fafc;
    color: #0f172a;
    border: 2px solid #dbe4ee;
}

@media screen and (max-width: 1024px) {
    .app-shell {
        padding: 14px;
        gap: 12px;
    }

    .logo-wrap {
        border-radius: 22px;
        padding: 10px 16px;
    }

    .company-logo {
        max-width: 280px;
        max-height: 80px;
    }

    .home-card {
        padding: 28px 22px;
        border-radius: 28px;
    }

    .home-intro {
        margin-bottom: 24px;
    }

        .home-intro h1 {
            font-size: 1.8rem;
        }

        .home-intro p {
            font-size: 1rem;
        }

    .home-actions {
        gap: 18px;
    }

    .action-button {
        min-height: 110px;
        font-size: 1.45rem;
        border-radius: 24px;
    }
}

@media screen and (max-height: 850px) {
    .app-shell {
        padding: 12px;
        gap: 10px;
    }

    .logo-wrap {
        padding: 10px 16px;
        border-radius: 20px;
    }

    .company-logo {
        max-width: 300px;
        max-height: 82px;
    }

    .home-card {
        padding: 22px 20px;
    }

    .home-intro {
        margin-bottom: 18px;
    }

        .home-intro h1 {
            font-size: 1.6rem;
            margin-bottom: 8px;
        }

        .home-intro p {
            font-size: 0.95rem;
        }

    .home-actions {
        gap: 14px;
    }

    .action-button {
        min-height: 92px;
        font-size: 1.25rem;
    }
}

@media screen and (max-width: 900px) {
    .app-shell {
        padding: 16px;
        gap: 12px;
    }

    .logo-wrap {
        border-radius: 20px;
        padding: 10px 14px;
    }

    .company-logo {
        max-width: 260px;
        max-height: 72px;
    }

    .home-card {
        padding: 24px 18px;
        border-radius: 24px;
    }

    .home-intro h1 {
        font-size: 1.6rem;
    }

    .home-intro p {
        font-size: 0.95rem;
    }

    .home-actions {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .action-button {
        min-height: 100px;
        font-size: 1.35rem;
        border-radius: 22px;
    }
}

.page-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.page-title {
    margin: 0 0 8px 0;
    font-size: 2.1rem;
    font-weight: 700;
    color: #0f172a;
}

.page-subtitle {
    margin: 0;
    font-size: 1.05rem;
    color: #475569;
}

.soft-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 18px;
    text-decoration: none;
    color: #0f172a;
    background: #f8fafc;
    border: 1px solid #dbe4ee;
    font-weight: 600;
}

.form-card {
    width: 100%;
    max-width: 1100px;
    background: #ffffff;
    border-radius: 36px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.10);
    padding: 40px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group-full {
    grid-column: 1 / -1;
}

.form-group label {
    margin-bottom: 10px;
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
}

.app-input {
    width: 100%;
    height: 62px;
    padding: 0 18px;
    border: 2px solid #dbe4ee;
    border-radius: 20px;
    background: #ffffff;
    font-size: 1.08rem;
    color: #0f172a;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

    .app-input:focus {
        border-color: #23c9b6;
        box-shadow: 0 0 0 4px rgba(35, 201, 182, 0.12);
    }

.consent-box {
    background: #f8fafc;
    border: 2px solid #dbe4ee;
    border-radius: 24px;
    padding: 18px 20px;
    min-height: 150px;
    max-height: 220px;
    overflow-y: auto;
    color: #334155;
    line-height: 1.6;
}

.consent-check-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: 16px;
}

.app-checkbox input {
    width: 24px;
    height: 24px;
    margin-top: 2px;
}

.checkbox-text {
    margin: 0;
    font-size: 1rem;
    color: #1e293b;
    line-height: 1.5;
}

.field-validator {
    display: block;
    margin-top: 8px;
    color: #b91c1c;
    font-size: 0.95rem;
    font-weight: 600;
}

.validation-summary {
    margin-bottom: 24px;
    padding: 16px 18px;
    border-radius: 20px;
    background: #fff1f2;
    border: 1px solid #fecdd3;
    color: #991b1b;
}

    .validation-summary ul {
        margin: 10px 0 0 18px;
        padding: 0;
    }

.form-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 28px;
}

.app-button {
    min-width: 260px;
    min-height: 62px;
    border: none;
    border-radius: 22px;
    font-size: 1.08rem;
    font-weight: 700;
    cursor: pointer;
    padding: 0 24px;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.10);
}

.app-button-primary {
    background: linear-gradient(135deg, #0f6fcf 0%, #20c9b5 100%);
    color: #ffffff;
}

.status-message {
    display: block;
    margin-top: 24px;
    padding: 18px 20px;
    border-radius: 20px;
    font-weight: 600;
}

.success-message {
    background: #ecfeff;
    border: 1px solid #a5f3fc;
    color: #155e75;
}

@media screen and (max-width: 900px) {
    .form-card {
        padding: 26px 20px;
        border-radius: 28px;
    }

    .page-title {
        font-size: 1.7rem;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .app-input {
        height: 58px;
        font-size: 1rem;
        border-radius: 18px;
    }

    .form-actions {
        justify-content: stretch;
    }

    .app-button {
        width: 100%;
        min-width: 0;
        min-height: 58px;
        border-radius: 20px;
    }
}

.consent-title {
    margin-bottom: 10px;
    font-size: 1.05rem;
    font-weight: 700;
    color: #0f172a;
}

.error-message {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.compact-card {
    max-width: 760px;
}

.single-column-grid {
    grid-template-columns: 1fr;
}

.badge-input {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.result-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 9999;
}

    .result-modal-overlay.show {
        display: flex;
    }

.result-modal-card {
    width: 100%;
    max-width: 520px;
    background: #ffffff;
    border-radius: 28px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
    padding: 28px 24px;
    border: 3px solid transparent;
    text-align: center;
}

    .result-modal-card.modal-success {
        border-color: #67e8f9;
    }

    .result-modal-card.modal-error {
        border-color: #fca5a5;
    }

.result-modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 14px;
}

.result-modal-message {
    font-size: 1.05rem;
    color: #334155;
    line-height: 1.6;
    white-space: pre-line;
}

.result-modal-actions {
    margin-top: 22px;
    display: flex;
    justify-content: center;
}

.result-modal-button {
    min-width: 140px;
    min-height: 52px;
    border: none;
    border-radius: 18px;
    background: linear-gradient(135deg, #0f6fcf 0%, #20c9b5 100%);
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    padding: 0 20px;
}

@media screen and (max-width: 900px) {
    .result-modal-card {
        border-radius: 24px;
        padding: 24px 18px;
    }

    .result-modal-title {
        font-size: 1.3rem;
    }

    .result-modal-message {
        font-size: 1rem;
    }
}

.soft-button {
    min-height: 48px;
    padding: 0 18px;
    border-radius: 18px;
    border: 1px solid #dbe4ee;
    background: #f8fafc;
    color: #0f172a;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
}

.admin-menu-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
    margin-top: 28px;
}

.admin-menu-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 26px;
    border-radius: 28px;
    background: #f8fafc;
    border: 2px solid #dbe4ee;
    text-decoration: none;
    color: #0f172a;
    min-height: 160px;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.07);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

    .admin-menu-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 16px 30px rgba(15, 23, 42, 0.10);
    }

.admin-menu-title {
    font-size: 1.2rem;
    font-weight: 700;
}

.admin-menu-text {
    font-size: 0.98rem;
    color: #475569;
    line-height: 1.5;
}

@media screen and (max-width: 900px) {
    .admin-menu-grid {
        grid-template-columns: 1fr;
    }
}

.list-card {
    width: 100%;
    max-width: 1100px;
    background: #ffffff;
    border-radius: 36px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.10);
    padding: 32px 36px;
    margin-top: 24px;
}

.page-title-small {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    color: #0f172a;
}

.app-select {
    appearance: none;
}

.checkbox-box {
    min-height: 62px;
    display: flex;
    align-items: center;
    padding: 0 4px;
    font-size: 1rem;
    color: #1e293b;
}

.admin-gridview {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

    .admin-gridview th {
        text-align: left;
        padding: 14px 12px;
        background: #f8fafc;
        color: #334155;
        font-size: 0.95rem;
        font-weight: 700;
        border-bottom: 1px solid #dbe4ee;
    }

    .admin-gridview td {
        padding: 14px 12px;
        border-bottom: 1px solid #e2e8f0;
        color: #0f172a;
        vertical-align: middle;
    }

.status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 86px;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 700;
}

.status-active {
    background: #dcfce7;
    color: #166534;
}

.status-inactive {
    background: #fee2e2;
    color: #991b1b;
}

.grid-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 14px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px solid #dbe4ee;
    color: #0f172a;
    text-decoration: none;
    font-weight: 600;
}

@media screen and (max-width: 900px) {
    .list-card {
        padding: 24px 18px;
        border-radius: 28px;
    }

    .admin-gridview {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

.page-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.summary-strip {
    display: flex;
    gap: 18px;
    margin: 24px 0;
    flex-wrap: wrap;
}

.summary-box {
    min-width: 220px;
    background: #f8fafc;
    border: 2px solid #dbe4ee;
    border-radius: 24px;
    padding: 18px 20px;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.06);
}

.summary-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: #475569;
    margin-bottom: 6px;
}

.summary-value {
    font-size: 2rem;
    font-weight: 700;
    color: #0f172a;
}

.print-button {
    min-width: 140px;
    min-height: 48px;
    border-radius: 18px;
    padding: 0 18px;
}

@media print {
    .no-print,
    .soft-button,
    .soft-link,
    .app-button,
    .page-actions {
        display: none !important;
    }

    html, body {
        background: #ffffff !important;
    }

    .app-shell {
        padding: 0 !important;
        gap: 0 !important;
    }

    .logo-wrap,
    .list-card,
    .form-card,
    .home-card {
        box-shadow: none !important;
        border-radius: 0 !important;
        margin: 0 !important;
    }

    .list-card {
        padding: 0 !important;
    }

    .admin-gridview th {
        background: #ffffff !important;
    }
}

.filter-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
    margin-top: 18px;
}

@media screen and (max-width: 900px) {
    .filter-row {
        grid-template-columns: 1fr;
        gap: 18px;
    }
}

.page-stack {
    width: 100%;
    max-width: 1100px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

    .page-stack > .form-card,
    .page-stack > .list-card {
        width: 100%;
        max-width: none;
        margin-top: 0;
    }

.print-context {
    margin-bottom: 18px;
    font-size: 1rem;
    color: #334155;
}

@media print {
    .page-stack {
        max-width: none !important;
        gap: 0 !important;
    }

        .page-stack > .list-card {
            width: 100% !important;
            max-width: none !important;
        }

    .print-context {
        display: block !important;
    }
}
