body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #f4f6f9;
    color: #222;
    direction: rtl;
}

.page {
    max-width: 1150px;
    margin: 35px auto;
    padding: 0 20px;
}

.topnav {
    background: #102a43;
    color: white;
    padding: 16px 22px;
    border-radius: 14px;
    margin-bottom: 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 18px rgba(0,0,0,0.10);
}

.topnav .brand a {
    color: white;
    text-decoration: none;
    font-size: 22px;
    font-weight: bold;
}

.topnav .menu {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.topnav .menu a {
    color: #d9e2ec;
    text-decoration: none;
    padding: 9px 13px;
    border-radius: 8px;
    font-weight: bold;
}

.topnav .menu a:hover,
.topnav .menu a.active {
    background: #1d4ed8;
    color: white;
}

.header {
    background: #102a43;
    color: white;
    padding: 28px;
    border-radius: 16px;
    margin-bottom: 24px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.10);
}

.header h1 {
    margin: 0 0 8px 0;
    font-size: 30px;
}

.header p {
    margin: 0;
    color: #d9e2ec;
    line-height: 1.6;
}

.actions {
    display: flex;
    gap: 12px;
    margin: 22px 0;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    text-decoration: none;
    background: #1d4ed8;
    color: white;
    padding: 12px 20px;
    border-radius: 9px;
    font-weight: bold;
    border: none;
    cursor: pointer;
    font-size: 15px;
}

.btn.secondary {
    background: #334e68;
}

.btn:hover {
    opacity: 0.92;
}

.cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 26px;
}

.card {
    background: white;
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 3px 14px rgba(0,0,0,0.07);
}

.card .num {
    font-size: 34px;
    font-weight: bold;
    color: #1d3557;
    margin-bottom: 6px;
}

.card .label {
    color: #666;
    font-size: 15px;
}

.panel {
    background: white;
    padding: 22px;
    border-radius: 14px;
    box-shadow: 0 3px 14px rgba(0,0,0,0.07);
    margin-bottom: 24px;
}

.panel h2 {
    margin-top: 0;
    color: #1d3557;
    font-size: 22px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

th, td {
    padding: 12px 10px;
    border-bottom: 1px solid #e4e7eb;
    text-align: right;
    font-size: 14px;
}

th {
    background: #f7f9fc;
    color: #334e68;
}

.empty {
    color: #777;
    background: #f7f9fc;
    padding: 15px;
    border-radius: 10px;
    margin-top: 10px;
}

.status {
    display: inline-block;
    background: #e0ecff;
    color: #1d4ed8;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: 13px;
}

.warning {
    background: #fff4e5;
    color: #9a5b00;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: 13px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.field {
    display: flex;
    flex-direction: column;
}

.field.full {
    grid-column: 1 / -1;
}

label {
    font-weight: bold;
    margin-bottom: 6px;
}

input,
textarea,
select {
    padding: 10px;
    border: 1px solid #ccd3dd;
    border-radius: 8px;
    font-size: 15px;
    font-family: Arial, sans-serif;
}

textarea {
    min-height: 90px;
    resize: vertical;
}

.checkboxes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 10px;
}

.check-item {
    background: #f7f9fc;
    border: 1px solid #dce3ec;
    border-radius: 8px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.check-item input {
    width: auto;
}

.section-title {
    margin-top: 30px;
    padding-bottom: 8px;
    border-bottom: 1px solid #ddd;
    color: #1d3557;
    font-size: 20px;
    font-weight: bold;
}

.note {
    font-size: 13px;
    color: #777;
}

@media (max-width: 850px) {
    .cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .topnav {
        align-items: flex-start;
        gap: 12px;
        flex-direction: column;
    }
}

@media (max-width: 550px) {
    .cards,
    .form-grid,
    .checkboxes {
        grid-template-columns: 1fr;
    }

    .header h1 {
        font-size: 24px;
    }

    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}