/* =========================================================
   HASP SYSTEM — STATIC ADMIN PROTOTYPE
   Soft, clean and eye-friendly UI
   ========================================================= */

:root {
    --page-bg: #f5f8fc;
    --panel-bg: rgba(255, 255, 255, 0.88);
    --white: #ffffff;

    --text-main: #1f2f46;
    --text-muted: #738198;
    --border: #dfe7f1;

    --blue: #4c8fe8;
    --blue-soft: #eaf3ff;
    --blue-line: #a9cdf9;

    --green: #4aaa79;
    --green-soft: #edf9f3;
    --green-line: #b8dfca;

    --danger: #ef5858;

    --shadow-soft: 0 16px 45px rgba(46, 73, 105, 0.10);
    --shadow-card: 0 10px 26px rgba(46, 73, 105, 0.08);

    --sidebar-width: 225px;
    --topbar-height: 74px;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
}

body {
    margin: 0;
    min-height: 100vh;
    overflow: hidden;
    color: var(--text-main);
    background:
        radial-gradient(circle at 30% 20%, #ffffff 0, transparent 35%),
        linear-gradient(145deg, #f8fbff 0%, #eef3f9 100%);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    border: 0;
}

.app-shell {
    width: 100%;
    min-height: 100vh;
    margin: 0;
    display: grid;
    grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
    overflow: hidden;
    border: 1px solid rgba(203, 216, 231, 0.85);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.70);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(18px);
}

/* SIDEBAR */

.sidebar {
    position: relative;
    z-index: 20;
    min-height: 100vh;
    padding: 24px 14px 18px;
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.94);
}

.brand {
    min-height: 42px;
    margin: 0 10px 24px;
    display: flex;
    align-items: center;
    gap: 11px;
    font-size: 19px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.brand-icon {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    color: var(--blue);
    background: var(--blue-soft);
    font-size: 20px;
}

.sidebar-nav {
    display: grid;
    gap: 7px;
}

.nav-item,
.logout-button {
    width: 100%;
    min-height: 44px;
    padding: 0 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-radius: 11px;
    color: #53647b;
    background: transparent;
    cursor: pointer;
    text-align: left;
    transition: 180ms ease;
}

.nav-item i,
.logout-button i {
    width: 20px;
    font-size: 17px;
}

.nav-item:hover {
    color: var(--text-main);
    background: #f4f7fb;
}

.nav-item.active {
    color: #2568bd;
    background: #eaf3ff;
}

.logout-button {
    margin-top: auto;
    color: var(--danger);
}

.logout-button:hover {
    background: #fff1f1;
}

/* MAIN AREA */

.main-area {
    min-width: 0;
}

.topbar {
    height: var(--topbar-height);
    padding: 0 25px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.58);
}

.topbar-spacer {
    flex: 1;
}

.mobile-menu-button {
    display: none;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 11px;
    color: var(--text-main);
    background: #f1f5fa;
    cursor: pointer;
    font-size: 22px;
}

.admin-profile {
    padding: 6px 8px 6px 6px;
    display: flex;
    align-items: center;
    gap: 9px;
    border-radius: 12px;
    color: var(--text-main);
    background: transparent;
    cursor: pointer;
}

.admin-profile:hover {
    background: #f2f6fb;
}

.profile-avatar {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #71839a;
    background: #e8edf3;
}

.profile-arrow {
    font-size: 12px;
}

.dashboard-content {
    min-height: calc(100vh - var(--topbar-height));
    padding: clamp(28px, 4vh, 52px) clamp(28px, 3vw, 54px) 40px;
}

.welcome-block h1 {
    margin: 0 0 8px;
    font-size: clamp(25px, 3vw, 34px);
    letter-spacing: -0.8px;
}

.welcome-block p {
    margin: 0;
    color: var(--text-muted);
    font-size: 16px;
}

.dashboard-grid {
    margin-top: 34px;
    display: grid;
    grid-template-columns: minmax(180px, 220px) minmax(310px, 1fr) minmax(180px, 220px);
    align-items: center;
    gap: 25px;
}

.info-column {
    display: grid;
    gap: 18px;
}

.info-card {
    min-height: 114px;
    padding: 20px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.74);
    box-shadow: 0 6px 18px rgba(53, 78, 106, 0.04);
}

.info-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    font-size: 20px;
}

.info-icon.success {
    color: #299666;
    background: var(--green-soft);
}

.info-icon.blue {
    color: #377ed8;
    background: var(--blue-soft);
}

.info-icon.neutral {
    color: #71839a;
    background: #f0f4f8;
}

.info-card > div:last-child {
    min-width: 0;
    display: grid;
    gap: 6px;
}

.info-label,
.info-card small {
    color: var(--text-muted);
}

.info-card strong {
    font-size: 17px;
    font-weight: 650;
}

.info-card small {
    font-size: 12px;
}

.success-text {
    color: #2d9d6b !important;
}

.blue-text {
    color: #2d70cf;
}

.online-dot {
    width: 6px;
    height: 6px;
    margin-right: 4px;
    display: inline-block;
    border-radius: 50%;
    background: #32aa72;
}

/* MODULE SELECTOR */

.module-selector-card {
    min-height: 390px;
    padding: 40px 35px 30px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    border: 1px solid #d7e1ec;

    /* Dairə əvəzinə küncləri oval kvadrat */
    border-radius: 36px;

    background:
        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.98),
            rgba(245, 249, 253, 0.92)
        );

    box-shadow:
        0 18px 45px rgba(46, 73, 105, 0.11),
        inset 0 0 0 10px rgba(255, 255, 255, 0.30);
}

.selector-heading {
    text-align: center;
}

.selector-heading h2 {
    margin: 0 0 7px;
    font-size: 20px;
}

.selector-heading p,
.selector-note {
    margin: 0;
    color: var(--text-muted);
    font-size: 13px;
}

.module-buttons {
    margin: 28px 0 22px;
    display: flex;
    gap: 28px;
}

.module-button {
    width: 155px;
    height: 145px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 14px;

    /* Yumru yox, küncləri oval kvadrat */
    border-radius: 26px;

    cursor: pointer;
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.90);

    transition:
        transform 180ms ease,
        box-shadow 180ms ease;
}

.module-button:hover {
    transform: translateY(-5px);
}

.module-button.hasp {
    border: 1px solid var(--blue-line);
    box-shadow: 0 12px 28px rgba(76, 143, 232, 0.15);
}

.module-button.gmp {
    border: 1px solid var(--green-line);
    box-shadow: 0 12px 28px rgba(74, 170, 121, 0.15);
}

.module-icon {
    width: 68px;
    height: 68px;

    display: grid;
    place-items: center;

    /* İkon fonu da kvadrat */
    border-radius: 20px;

    font-size: 34px;
}

.hasp .module-icon {
    color: var(--blue);
    background: var(--blue-soft);
}

.gmp .module-icon {
    color: var(--green);
    background: var(--green-soft);
}

.module-button span:last-child {
    font-size: 14px;
    font-weight: 650;
}

.selector-note {
    max-width: 230px;
    text-align: center;
    line-height: 1.5;
}

/* RADIAL POPUP */

.radial-overlay {
    position: fixed;
    z-index: 100;
    inset: 0;
    padding: 20px;
    display: grid;
    place-items: center;
    visibility: hidden;
    opacity: 0;
    background: rgba(219, 228, 239, 0.55);
    backdrop-filter: blur(10px);
    transition: 220ms ease;
}

.radial-overlay.open {
    visibility: visible;
    opacity: 1;
}

.radial-dialog {
    position: relative;
    width: min(620px, 96vw);
    min-height: 580px;
    padding: 48px 30px 24px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.80);
    border-radius: 34px;
    background: rgba(248, 251, 255, 0.86);
    box-shadow: 0 30px 80px rgba(47, 71, 97, 0.20);
    transform: scale(0.88);
    transition: transform 240ms cubic-bezier(.2,.8,.2,1);
}

.radial-overlay.open .radial-dialog {
    transform: scale(1);
}

.radial-dialog.gmp-mode {
    --accent: var(--green);
    --accent-soft: var(--green-soft);
    --accent-line: var(--green-line);
}

.radial-dialog.hasp-mode {
    --accent: var(--blue);
    --accent-soft: var(--blue-soft);
    --accent-line: var(--blue-line);
}

.radial-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #65768c;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--shadow-card);
    cursor: pointer;
}

.radial-ring {
    position: relative;
    width: 440px;
    height: 440px;
    border: 1px solid var(--accent-line);
    border-radius: 50%;
    background:
        radial-gradient(circle at center, rgba(255,255,255,0.88) 0 37%, transparent 38%),
        radial-gradient(circle at center, transparent 0 62%, rgba(255,255,255,0.58) 63% 100%);
    box-shadow: inset 0 0 0 16px rgba(255, 255, 255, 0.30);
}

.radial-ring::before,
.radial-ring::after {
    content: "";
    position: absolute;
    inset: 38px;
    border-radius: 50%;
    border: 1px solid rgba(145, 164, 186, 0.20);
}

.radial-ring::after {
    inset: 118px;
    border-color: var(--accent-line);
}

.radial-center {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 176px;
    height: 176px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transform: translate(-50%, -50%);
    border: 1px solid var(--accent-line);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 18px 38px rgba(46, 73, 105, 0.11);
}

.radial-center-icon {
    width: 70px;
    height: 70px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--accent);
    background: var(--accent-soft);
    font-size: 38px;
}

.radial-center strong {
    font-size: 21px;
}

.radial-center span {
    color: var(--accent);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
}

.radial-item {
    position: absolute;
    width: 78px;
    height: 78px;
    padding: 7px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 1px solid var(--accent-line);
    border-radius: 50%;
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-card);
    cursor: pointer;
    transition: transform 160ms ease, box-shadow 160ms ease;
}

.radial-item:hover {
    transform: scale(1.08);
    box-shadow: 0 14px 30px rgba(46, 73, 105, 0.16);
}

.radial-item i {
    color: var(--accent);
    font-size: 23px;
}

.radial-item span {
    font-size: 10px;
    line-height: 1.1;
}

.item-1 { left: 181px; top: -32px; }
.item-2 { right: 18px; top: 48px; }
.item-3 { right: -30px; top: 181px; }
.item-4 { right: 18px; bottom: 48px; }
.item-5 { left: 181px; bottom: -32px; }
.item-6 { left: 18px; bottom: 48px; }
.item-7 { left: -30px; top: 181px; }
.item-8 { left: 18px; top: 48px; }

.radial-helper {
    margin: 35px 0 0;
    color: var(--text-muted);
    font-size: 13px;
    text-align: center;
}

/* MOBILE SIDEBAR */

.mobile-sidebar-overlay {
    position: fixed;
    z-index: 15;
    inset: 0;
    display: none;
    background: rgba(25, 40, 60, 0.30);
    backdrop-filter: blur(3px);
}

/* RESPONSIVE */

@media (max-width: 1050px) {
    .dashboard-grid {
        grid-template-columns: 1fr 1.25fr;
    }

    .dashboard-grid > .info-column:last-child {
        grid-column: 1 / -1;
        grid-template-columns: repeat(2, 1fr);
    }

    .module-selector-card {
        border-radius: 34px;
    }
}

@media (max-width: 780px) {
    .app-shell {
        width: 100%;
        min-height: 100vh;
        margin: 0;
        grid-template-columns: 1fr;
        border: 0;
        border-radius: 0;
    }

    .sidebar {
        position: fixed;
        left: -260px;
        top: 0;
        bottom: 0;
        width: 235px;
        min-height: 100vh;
        transition: left 220ms ease;
    }

    .sidebar.mobile-open {
        left: 0;
    }

    .mobile-sidebar-overlay.open {
        display: block;
    }

    .mobile-menu-button {
        display: grid;
    }

    .dashboard-content {
        padding: 28px 20px 40px;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-grid > .info-column:last-child {
        grid-column: auto;
        grid-template-columns: 1fr;
    }

    .module-selector-card {
        order: -1;
        min-height: auto;
        border-radius: 28px;
    }

    .radial-dialog {
        min-height: auto;
        padding: 58px 18px 30px;
    }

    .radial-ring {
        width: 340px;
        height: 340px;
        transform: scale(0.88);
    }

    .radial-center {
        width: 144px;
        height: 144px;
    }

    .radial-center-icon {
        width: 58px;
        height: 58px;
        font-size: 30px;
    }

    .radial-center strong {
        font-size: 17px;
    }

    .radial-item {
        width: 68px;
        height: 68px;
    }

    .item-1 { left: 136px; top: -28px; }
    .item-2 { right: 5px; top: 34px; }
    .item-3 { right: -27px; top: 136px; }
    .item-4 { right: 5px; bottom: 34px; }
    .item-5 { left: 136px; bottom: -28px; }
    .item-6 { left: 5px; bottom: 34px; }
    .item-7 { left: -27px; top: 136px; }
    .item-8 { left: 5px; top: 34px; }
}

@media (max-width: 430px) {
    .profile-name,
    .profile-arrow {
        display: none;
    }

    .module-buttons {
        gap: 12px;
    }

    .module-button {
        width: 108px;
        height: 108px;
    }

    .radial-dialog {
        width: 100%;
        overflow: hidden;
    }

    .radial-ring {
        transform: scale(0.72);
        margin: -45px 0;
    }

    .radial-helper {
        margin-top: 0;
    }
}



/* =========================================================
   DOCUMENTS PAGE
   ========================================================= */

.document-page {
    min-height: 100vh;
    padding: 35px;
    background:
        linear-gradient(
            145deg,
            #f8fbff 0%,
            #eef4fa 100%
        );
}

.document-topbar {
    max-width: 1400px;
    margin: 0 auto 25px;
    padding: 25px 30px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    border: 1px solid var(--border);
    border-radius: 22px;

    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow-card);
}

.document-topbar h1 {
    margin: 14px 0 7px;
    font-size: 30px;
}

.document-topbar p {
    margin: 0;
    color: var(--text-muted);
}

.back-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    color: #377ed8;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.document-module-icon {
    width: 62px;
    height: 62px;

    display: grid;
    place-items: center;

    border-radius: 18px;

    color: var(--green);
    background: var(--green-soft);

    font-size: 28px;
}

.document-create-card,
.document-table-card {
    max-width: 1400px;
    margin: 0 auto 25px;
    padding: 28px 30px;

    border: 1px solid var(--border);
    border-radius: 22px;

    background: rgba(255, 255, 255, 0.90);
    box-shadow: var(--shadow-card);
}

.section-heading {
    margin-bottom: 24px;

    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-heading h2 {
    margin: 0 0 6px;
    font-size: 20px;
}

.section-heading p {
    margin: 0;
    color: var(--text-muted);
    font-size: 13px;
}

.section-heading > i {
    color: var(--green);
    font-size: 27px;
}

.document-form-grid {
    display: grid;

    grid-template-columns:
        minmax(220px, 2fr)
        minmax(170px, 1fr)
        minmax(220px, 1.5fr)
        auto;

    align-items: end;
    gap: 18px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    color: #42546b;
    font-size: 13px;
    font-weight: 650;
}

.form-group input {
    width: 100%;
    min-height: 48px;
    padding: 0 14px;

    border: 1px solid #d7e1ec;
    border-radius: 12px;

    outline: none;
    color: var(--text-main);
    background: #ffffff;
}

.form-group input:focus {
    border-color: var(--green);
    box-shadow: 0 0 0 4px rgba(74, 170, 121, 0.10);
}

.form-group input[type="file"] {
    padding: 10px;
}

.save-document-button {
    min-height: 48px;
    padding: 0 22px;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    border-radius: 12px;

    color: #ffffff;
    background: var(--green);

    cursor: pointer;
    font-weight: 650;

    transition: 180ms ease;
}

.save-document-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(74, 170, 121, 0.25);
}

.document-count {
    padding: 8px 13px;

    border-radius: 10px;

    color: #377ed8;
    background: var(--blue-soft);

    font-size: 13px;
    font-weight: 650;
}

.table-responsive {
    width: 100%;
    overflow-x: auto;
}

.document-table {
    width: 100%;
    border-collapse: collapse;
}

.document-table th {
    padding: 15px 14px;

    color: #64758b;
    background: #f5f8fc;

    text-align: left;
    font-size: 12px;
    font-weight: 700;

    border-bottom: 1px solid var(--border);
}

.document-table td {
    padding: 16px 14px;

    border-bottom: 1px solid #edf1f5;

    color: #42546b;
    font-size: 14px;
}

.document-table tbody tr:hover {
    background: #fafcff;
}

.document-name-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.document-name-cell > i {
    width: 40px;
    height: 40px;

    display: grid;
    place-items: center;

    border-radius: 11px;

    color: var(--green);
    background: var(--green-soft);

    font-size: 19px;
}

.document-name-cell div {
    display: grid;
    gap: 4px;
}

.document-name-cell small {
    color: var(--text-muted);
}

.table-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.table-action-button {
    min-height: 36px;
    padding: 0 12px;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;

    border-radius: 9px;

    cursor: pointer;
    text-decoration: none;
    font-size: 12px;
    font-weight: 650;
}

.pdf-button {
    color: #e24848;
    background: #fff0f0;
}

.edit-button {
    color: #3475ca;
    background: #edf5ff;
}

.delete-button {
    color: #e24848;
    background: #fff0f0;
}

.no-pdf-text {
    color: var(--text-muted);
    font-size: 12px;
}

.empty-document-message {
    padding: 55px 20px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    color: var(--text-muted);
    text-align: center;
}

.empty-document-message i {
    margin-bottom: 12px;
    font-size: 46px;
}

.empty-document-message h3 {
    margin: 0 0 7px;
    color: var(--text-main);
}

.empty-document-message p {
    margin: 0;
}

/* Planşet və mobil görünüş */
@media (max-width: 1000px) {
    .document-form-grid {
        grid-template-columns: 1fr 1fr;
    }

    .form-button-group {
        grid-column: 1 / -1;
    }
}

@media (max-width: 650px) {
    .document-page {
        padding: 15px;
    }

    .document-topbar,
    .document-create-card,
    .document-table-card {
        padding: 20px;
        border-radius: 17px;
    }

    .document-form-grid {
        grid-template-columns: 1fr;
    }

    .form-button-group {
        grid-column: auto;
    }

    .save-document-button {
        width: 100%;
    }
}



/* =====================================================
   DOCUMENT TEMPLATE LIST
===================================================== */

.document-template-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 32px;
}

.document-template-card {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 140px;
    padding: 24px;
    color: #17233c;
    text-decoration: none;
    background: #ffffff;
    border: 1px solid #dbe5f1;
    border-radius: 20px;
    box-shadow: 0 12px 30px rgba(24, 51, 84, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.document-template-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(24, 51, 84, 0.14);
}

.document-template-icon {
    display: grid;
    place-items: center;
    flex: 0 0 64px;
    width: 64px;
    height: 64px;
    color: #438cf3;
    font-size: 28px;
    background: #eaf3ff;
    border-radius: 18px;
}

.document-template-content {
    flex: 1;
}

.document-code {
    display: inline-block;
    margin-bottom: 6px;
    color: #438cf3;
    font-size: 14px;
    font-weight: 700;
}

.document-template-content h3 {
    margin: 0 0 8px;
    font-size: 18px;
}

.document-template-content p {
    margin: 0;
    color: #72809a;
    font-size: 14px;
    line-height: 1.5;
}

.document-template-arrow {
    color: #8fa1ba;
    font-size: 20px;
}

/* Radial menyudakı linklər */
.radial-item {
    text-decoration: none;
}

.radial-item i {
    font-size: 24px;
}

.radial-item span {
    display: block;
    margin-top: 5px;
    font-size: 12px;
}



/* =====================================================
   F-5 DOCUMENT EDITOR
===================================================== */

.document-editor-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 28px;
}

.document-editor-header h1 {
    margin: 14px 0 6px;
    color: #17233c;
    font-size: 28px;
}

.document-editor-header p {
    margin: 0;
    color: #72809a;
}

.document-editor-actions {
    display: flex;
    gap: 12px;
}

.document-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    padding: 0 16px;
    font: inherit;
    cursor: pointer;
    border-radius: 12px;
    transition: 0.2s ease;
}

.document-action-button.primary {
    color: #ffffff;
    background: #438cf3;
    border: 1px solid #438cf3;
}

.document-action-button.secondary {
    color: #30415f;
    background: #ffffff;
    border: 1px solid #d8e2ef;
}

.document-editor-wrapper {
    overflow-x: auto;
    padding: 30px;
    background: #edf3f9;
    border-radius: 24px;
}

.a4-document {
    width: 794px;
    min-height: 1123px;
    margin: 0 auto;
    padding: 54px;
    color: #111827;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(23, 35, 60, 0.16);
}

.f5-document-header {
    display: grid;
    grid-template-columns: 140px 1fr 210px;
    align-items: stretch;
    border: 1px solid #111827;
}

.f5-logo-box,
.f5-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 92px;
}

.f5-logo-box {
    border-right: 1px solid #111827;
}

.f5-title-box {
    padding: 12px;
    border-right: 1px solid #111827;
    text-align: center;
}

.f5-title-box h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.f5-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
}

.f5-meta-table th,
.f5-meta-table td {
    padding: 4px 6px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.f5-meta-table tr:last-child th,
.f5-meta-table tr:last-child td {
    border-bottom: 0;
}

.f5-meta-table th {
    width: 60%;
    font-weight: 600;
}

.f5-info-fields {
    margin: 26px 0 8px;
}

.f5-info-fields label {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 600;
}

.f5-info-fields span {
    width: 92px;
}

.f5-info-fields input {
    flex: 1;
    min-width: 0;
    padding: 4px 2px;
    font: inherit;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

.f5-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 10px;
}

.f5-main-table th,
.f5-main-table td {
    height: 38px;
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
}

.f5-main-table th {
    padding: 7px 4px;
    font-weight: 700;
    line-height: 1.2;
}

.f5-main-table th:nth-child(1) {
    width: 14%;
}

.f5-main-table th:nth-child(2),
.f5-main-table th:nth-child(3) {
    width: 14%;
}

.f5-main-table th:nth-child(4) {
    width: 30%;
}

.f5-main-table th:nth-child(5),
.f5-main-table th:nth-child(6) {
    width: 14%;
}

.f5-main-table input {
    width: 100%;
    height: 100%;
    padding: 4px;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
}

.f5-signature-section {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-top: 48px;
}

.signature-column {
    text-align: center;
}

.signature-column > span {
    display: block;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 600;
}

.signature-preview {
    display: grid;
    place-items: center;
    min-height: 90px;
    margin-bottom: 12px;
    color: #9aa7ba;
    font-size: 12px;
    border: 1px dashed #bcc8d7;
}

.f5-document-footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 52px;
    color: #64748b;
    font-size: 10px;
}

@media (max-width: 900px) {
    .document-editor-header {
        flex-direction: column;
    }

    .document-editor-wrapper {
        padding: 16px;
    }
}

@media print {
    body {
        background: #ffffff;
    }

    .sidebar,
    .topbar,
    .document-editor-header {
        display: none !important;
    }

    .main-area,
    .dashboard-content,
    .document-editor-wrapper {
        margin: 0;
        padding: 0;
        background: #ffffff;
    }

    .a4-document {
        box-shadow: none;
    }
}


/* =====================================================
   PAGE SCROLL FIX
===================================================== */

/* Bütün səhifə aşağı-yuxarı hərəkət edə bilsin */
html,
body {
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

/* Əsas layout ekran hündürlüyündən böyük ola bilər */
.app-shell {
    min-height: 100vh;
    height: auto;
}

/* Əsas sağ hissədə scroll açıq olsun */
.main-area {
    min-height: 100vh;
    height: auto;
    overflow: visible;
}

/* Sənəd səhifəsinin tam hündürlüyü görünsün */
.dashboard-content {
    min-height: auto;
    overflow: visible;
}

/* A4 sənəd konteyneri aşağı hissəni kəsməsin */
.document-editor-wrapper {
    overflow-x: auto;
    overflow-y: visible;
    margin-bottom: 40px;
}


.document-logo{
    max-width:110px;
    max-height:70px;
    width:auto;
    height:auto;
    object-fit:contain;
}



/* =====================================================
   DOCUMENT LOGO AND WATERMARK
===================================================== */

.a4-document {
    position: relative;
    overflow: hidden;
}

/* Yuxarı sol kiçik logo */
.document-logo {
    display: block;
    width: auto;
    max-width: 110px;
    max-height: 70px;
    object-fit: contain;
}

/* Səhifənin ortasındakı böyük şəffaf logo */
.document-watermark {
    position: absolute;
    top: 50%;
    left: 58%;
    width: 360px;
    height: auto;
    transform: translate(-50%, -50%);
    opacity: 0.06;
    pointer-events: none;
    user-select: none;
    object-fit: contain;
    z-index: 0;
}

/* Sənədin bütün əsas elementləri watermarkın üstündə qalsın */
.a4-document > *:not(.document-watermark) {
    position: relative;
    z-index: 1;
}



/* =====================================================
   HASSP F-2 — MƏHSULUN QAYTARILMASI FORMASI
===================================================== */

.hassp-document-icon {
    color: #438cf3;
    background: #eaf3ff;
}

/* F-2 sənədinin əlavə daxili ayarları */
.f2-document {
    position: relative;
    overflow: hidden;
}

/* F-2 header */
.f2-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

/* Kiçik logo sahəsi */
.f2-logo-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

/* Sənəd adı */
.f2-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    text-align: center;
    border-right: 1px solid #111827;
}

.f2-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
}

/* Sağ tərəfdə sənəd məlumatları */
.f2-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 10px;
}

.f2-meta-table th,
.f2-meta-table td {
    padding: 3px 6px;
    text-align: left;
    border-bottom: 1px solid #111827;
}

.f2-meta-table tr:last-child th,
.f2-meta-table tr:last-child td {
    border-bottom: 0;
}

.f2-meta-table th {
    width: 60%;
    font-weight: 500;
}

/* Əsas cədvəl */
.f2-table-wrapper {
    position: relative;
    z-index: 1;
    margin-top: 20px;
}

.f2-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 10px;
}

.f2-main-table th,
.f2-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.f2-main-table th {
    height: 58px;
    padding: 6px 4px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
}

.f2-main-table td {
    height: 52px;
}

/* Sütunların ölçüləri */
.f2-main-table th:nth-child(1) {
    width: 16%;
}

.f2-main-table th:nth-child(2) {
    width: 12%;
}

.f2-main-table th:nth-child(3) {
    width: 12%;
}

.f2-main-table th:nth-child(4) {
    width: 14%;
}

.f2-main-table th:nth-child(5) {
    width: 20%;
}

.f2-main-table th:nth-child(6) {
    width: 14%;
}

.f2-main-table th:nth-child(7) {
    width: 12%;
}

/* Cədvəl daxilində inputlar */
.f2-main-table input,
.f2-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 51px;
    padding: 5px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.f2-main-table input:focus,
.f2-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.07);
    box-shadow: inset 0 0 0 2px rgba(67, 140, 243, 0.25);
}

/* İmza və möhür hissəsi */
.f2-approval-section {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 80px;
    margin: 42px 50px 0;
}

/* Footer */
.f2-document-footer {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-top: 42px;
    color: #64748b;
    font-size: 10px;
}

.f2-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.f2-document-footer strong {
    color: #64748b;
    font-size: 10px;
    font-weight: 500;
}

.f2-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 8px;
}

/* Mobil görünüş */
@media (max-width: 900px) {
    .f2-approval-section {
        gap: 20px;
        margin-inline: 0;
    }
}

/* PDF və çap görünüşü */
@media print {
    .f2-document {
        width: 210mm;
        min-height: 297mm;
    }

    .f2-main-table input,
    .f2-main-table textarea {
        box-shadow: none !important;
    }
}


/* F-2 rekvizit sahələrinin inputları */
.f2-meta-table input {
    width: 100%;
    height: 100%;
    min-height: 20px;
    padding: 2px 5px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.f2-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.35);
}



/* =====================================================
   GMP F-3 — TƏMİZLİK VƏ DEZİNFEKSİYA FORMASI
===================================================== */

.f3-document {
    position: relative;
    overflow: hidden;
}

.f3-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.f3-logo-box,
.f3-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.f3-title-box {
    text-align: center;
}

.f3-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
}

.f3-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 10px;
}

.f3-meta-table th,
.f3-meta-table td {
    padding: 3px 6px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.f3-meta-table tr:last-child th,
.f3-meta-table tr:last-child td {
    border-bottom: 0;
}

.f3-meta-table th {
    width: 57%;
    font-weight: 500;
}

.f3-meta-table input {
    width: 100%;
    min-height: 19px;
    padding: 1px 4px;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.f3-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

.f3-general-fields {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    border: 1px solid #111827;
    border-top: 0;
}

.f3-general-fields label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
}

.f3-general-fields label:first-child {
    border-right: 1px solid #111827;
}

.f3-general-fields input {
    flex: 1;
    min-width: 0;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.f3-table-wrapper {
    position: relative;
    z-index: 1;
}

.f3-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.f3-main-table th,
.f3-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.f3-main-table th {
    height: 46px;
    padding: 4px 2px;
    font-size: 8px;
    line-height: 1.1;
}

.f3-main-table td {
    height: 31px;
}

.f3-main-table th:nth-child(1) {
    width: 9%;
}

.f3-main-table th:nth-child(2) {
    width: 12%;
}

.f3-main-table th:nth-child(3) {
    width: 10%;
}

.f3-main-table th:nth-child(4) {
    width: 19%;
}

.f3-main-table th:nth-child(5) {
    width: 8%;
}

.f3-main-table th:nth-child(6) {
    width: 15%;
}

.f3-main-table th:nth-child(7) {
    width: 11%;
}

.f3-main-table th:nth-child(8) {
    width: 10%;
}

.f3-main-table th:nth-child(9) {
    width: 6%;
}

.f3-main-table input,
.f3-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 30px;
    padding: 3px;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.f3-main-table input:focus,
.f3-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
}

.f3-approval-section {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 70px;
    margin: 36px 50px 0;
}

.f3-document-footer {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-top: 35px;
    color: #64748b;
    font-size: 9px;
}

.f3-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}



/* =====================================================
   GMP F-4 — AVADANLIQLARIN KALİBRASİYA FORMASI
===================================================== */

.f4-document {
    position: relative;
    overflow: hidden;
}

.f4-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.f4-logo-box,
.f4-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.f4-title-box {
    text-align: center;
}

.f4-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.2;
}

.f4-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 10px;
}

.f4-meta-table th,
.f4-meta-table td {
    padding: 3px 6px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.f4-meta-table tr:last-child th,
.f4-meta-table tr:last-child td {
    border-bottom: 0;
}

.f4-meta-table th {
    width: 58%;
    font-weight: 500;
}

.f4-meta-table input {
    width: 100%;
    min-height: 19px;
    padding: 1px 4px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.f4-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.3);
}

.f4-table-wrapper {
    position: relative;
    z-index: 1;
    margin-top: 12px;
}

.f4-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 9px;
}

.f4-main-table th,
.f4-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.f4-main-table th {
    height: 42px;
    padding: 5px 4px;
    font-size: 9px;
    font-weight: 600;
    line-height: 1.15;
}

.f4-main-table td {
    height: 34px;
}

.f4-main-table th:nth-child(1) {
    width: 18%;
}

.f4-main-table th:nth-child(2) {
    width: 31%;
}

.f4-main-table th:nth-child(3) {
    width: 15%;
}

.f4-main-table th:nth-child(4) {
    width: 10%;
}

.f4-main-table th:nth-child(5) {
    width: 26%;
}

.f4-main-table input,
.f4-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 33px;
    padding: 4px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.f4-main-table input:focus,
.f4-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

.f4-main-table tfoot td {
    height: 34px;
    text-align: left;
}

.f4-main-table tfoot textarea {
    min-height: 32px;
    padding: 8px;
    text-align: left;
}

.f4-approval-section {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 40px 50px 0;
}

.f4-document-footer {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-top: 40px;
    color: #64748b;
    font-size: 9px;
}

.f4-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.f4-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.f4-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 8px;
}

@media (max-width: 900px) {
    .f4-approval-section {
        gap: 20px;
        margin-inline: 0;
    }
}

@media print {
    .f4-main-table input,
    .f4-main-table textarea,
    .f4-meta-table input {
        box-shadow: none !important;
    }
}


/* =====================================================
   GMP F-6 — SAHƏLƏRİN MİKROİQLİMƏ NƏZARƏT FORMASI
===================================================== */

.f6-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.f6-document {
    position: relative;
    overflow: hidden;
}

/* Sənəd başlığı */
.f6-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.f6-logo-box,
.f6-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.f6-title-box {
    text-align: center;
}

.f6-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.2;
}

/* Rekvizit cədvəli */
.f6-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.f6-meta-table th,
.f6-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.f6-meta-table tr:last-child th,
.f6-meta-table tr:last-child td {
    border-bottom: 0;
}

.f6-meta-table th {
    width: 58%;
    font-weight: 500;
}

.f6-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.f6-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Müəssisə, sahə və ay sahələri */
.f6-general-fields {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 2fr 1fr;
    border: 1px solid #111827;
    border-top: 0;
}

.f6-general-fields label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 31px;
    padding: 4px 8px;
    font-size: 10px;
    font-weight: 600;
}

.f6-general-fields label:not(.f6-field-full) {
    border-top: 1px solid #111827;
}

.f6-general-fields label:nth-child(2) {
    border-right: 1px solid #111827;
}

.f6-field-full {
    grid-column: 1 / -1;
}

.f6-general-fields span {
    white-space: nowrap;
}

.f6-general-fields input {
    flex: 1;
    min-width: 0;
    padding: 2px 4px;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

/* Əsas cədvəl */
.f6-table-wrapper {
    position: relative;
    z-index: 1;
}

.f6-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 7px;
}

.f6-main-table th,
.f6-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.f6-main-table th {
    padding: 3px 2px;
    font-weight: 600;
    line-height: 1.1;
}

.f6-main-table thead tr:first-child th {
    height: 25px;
}

.f6-main-table thead tr:nth-child(2) th,
.f6-main-table thead tr:nth-child(3) th {
    height: 20px;
}

.f6-main-table td {
    height: 21px;
}

/* Sütun ölçüləri */
.f6-day-header {
    width: 5%;
}

.f6-main-table th:nth-child(2),
.f6-main-table th:nth-child(3),
.f6-main-table th:nth-child(4),
.f6-main-table th:nth-child(5),
.f6-main-table th:nth-child(6),
.f6-main-table th:nth-child(7) {
    width: 6%;
}

.f6-work-header {
    width: 43%;
}

.f6-responsible-header {
    width: 16%;
}

.f6-day-number {
    font-weight: 600;
}

/* Cədvəl inputları */
.f6-main-table input,
.f6-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 20px;
    padding: 2px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.f6-main-table input:focus,
.f6-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

/* İkinci səhifənin cədvəli */
.f6-second-page-table {
    margin-top: 16px;
}

/* Saxlanma məlumatı */
.f6-storage-information {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 35px;
    font-size: 9px;
}

.f6-storage-information p {
    margin: 0;
    text-align: right;
}

/* İmza və möhür */
.f6-approval-section {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 65px 50px 0;
}

/* Footer */
.f6-document-footer {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-top: 16px;
    color: #64748b;
    font-size: 8px;
}

.f6-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.f6-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.f6-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

.f6-second-footer {
    margin-top: 90px;
}

/* Mobil görünüş */
@media (max-width: 900px) {
    .f6-approval-section {
        gap: 20px;
        margin-inline: 0;
    }
}

/* Çap və PDF üçün */
@media print {
    .f6-editor-wrapper {
        display: block;
        padding: 0;
        background: #ffffff;
    }

    .f6-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .f6-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .f6-main-table input,
    .f6-main-table textarea,
    .f6-meta-table input,
    .f6-general-fields input {
        box-shadow: none !important;
    }
}


.month-year-fields {
    display: grid;
    grid-template-columns: 1fr 90px;
    gap: 6px;
    flex: 1;
}

.month-year-fields select,
.month-year-fields input {
    width: 100%;
    min-width: 0;
    padding: 3px 5px;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}




/* =====================================================
   GMP F-7 — SOYUDUCULARIN TEMPERATURUNA NƏZARƏT FORMASI
===================================================== */

.f7-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.f7-document {
    position: relative;
    overflow: hidden;
}

/* Sənəd başlığı */
.f7-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.f7-logo-box,
.f7-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.f7-title-box {
    text-align: center;
}

.f7-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.2;
}

/* Rekvizit cədvəli */
.f7-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.f7-meta-table th,
.f7-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.f7-meta-table tr:last-child th,
.f7-meta-table tr:last-child td {
    border-bottom: 0;
}

.f7-meta-table th {
    width: 58%;
    font-weight: 500;
}

.f7-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.f7-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Sahə, avadanlıq və ay/il */
.f7-general-fields {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 2fr 1fr;
    border: 1px solid #111827;
    border-top: 0;
}

.f7-general-fields label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 31px;
    padding: 4px 8px;
    font-size: 10px;
    font-weight: 600;
}

.f7-general-fields label:not(.f7-field-full) {
    border-top: 1px solid #111827;
}

.f7-general-fields label:nth-child(2) {
    border-right: 1px solid #111827;
}

.f7-field-full {
    grid-column: 1 / -1;
}

.f7-general-fields span {
    white-space: nowrap;
}

.f7-general-fields input {
    flex: 1;
    min-width: 0;
    padding: 2px 4px;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

/* Azərbaycan dilində ay və il sahələri */
.month-year-fields {
    display: grid;
    grid-template-columns: 1fr 78px;
    gap: 5px;
    flex: 1;
}

.month-year-fields select,
.month-year-fields input {
    width: 100%;
    min-width: 0;
    padding: 3px 4px;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

/* Əsas cədvəl */
.f7-table-wrapper {
    position: relative;
    z-index: 1;
}

.f7-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.f7-main-table th,
.f7-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.f7-main-table th {
    height: 66px;
    padding: 4px 3px;
    font-size: 8px;
    font-weight: 600;
    line-height: 1.15;
}

.f7-main-table td {
    height: 22px;
}

/* Sütun ölçüləri */
.f7-main-table th:nth-child(1) {
    width: 7%;
}

.f7-main-table th:nth-child(2),
.f7-main-table th:nth-child(3),
.f7-main-table th:nth-child(4) {
    width: 7%;
}

.f7-main-table th:nth-child(5) {
    width: 57%;
}

.f7-main-table th:nth-child(6) {
    width: 15%;
}

.f7-day-number {
    font-weight: 700;
}

/* Inputlar */
.f7-main-table input,
.f7-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 21px;
    padding: 2px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.f7-main-table input:focus,
.f7-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

/* İkinci səhifə */
.f7-second-page-table {
    margin-top: 14px;
}

/* İmza və möhür */
.f7-approval-section {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 80px 50px 0;
}

/* Footer */
.f7-document-footer {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-top: 16px;
    color: #64748b;
    font-size: 8px;
}

.f7-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.f7-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.f7-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

.f7-second-footer {
    margin-top: 90px;
}

/* Mobil görünüş */
@media (max-width: 900px) {
    .f7-approval-section {
        gap: 20px;
        margin-inline: 0;
    }
}

/* PDF və çap */
@media print {
    .f7-editor-wrapper {
        display: block;
        padding: 0;
        background: #ffffff;
    }

    .f7-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .f7-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .f7-main-table input,
    .f7-main-table textarea,
    .f7-meta-table input,
    .f7-general-fields input {
        box-shadow: none !important;
    }
}



/* =====================================================
   GMP P-001 — TƏMİZLİK VƏ DEZİNFEKSİYA PLANI
===================================================== */

.p001-document {
    position: relative;
    overflow: hidden;
}

.p001-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.p001-logo-box,
.p001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.p001-title-box {
    text-align: center;
}

.p001-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 21px;
    font-weight: 500;
    line-height: 1.2;
}

.p001-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.p001-meta-table th,
.p001-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.p001-meta-table tr:last-child th,
.p001-meta-table tr:last-child td {
    border-bottom: 0;
}

.p001-meta-table th {
    width: 58%;
    font-weight: 500;
}

.p001-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.p001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Əsas cədvəl */
.p001-table-wrapper {
    position: relative;
    z-index: 1;
    margin-top: 30px;
}

.p001-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.p001-main-table th,
.p001-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.p001-main-table th {
    height: 72px;
    padding: 5px 3px;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.15;
}

.p001-main-table td {
    height: 35px;
}

/* Sütun ölçüləri */
.p001-main-table th:nth-child(1) {
    width: 12%;
}

.p001-main-table th:nth-child(2) {
    width: 12%;
}

.p001-main-table th:nth-child(3) {
    width: 14%;
}

.p001-main-table th:nth-child(4) {
    width: 8%;
}

.p001-main-table th:nth-child(5) {
    width: 11%;
}

.p001-main-table th:nth-child(6) {
    width: 18%;
}

.p001-main-table th:nth-child(7) {
    width: 13%;
}

.p001-main-table th:nth-child(8) {
    width: 10%;
}

.p001-main-table th:nth-child(9) {
    width: 12%;
}

.p001-main-table input,
.p001-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 34px;
    padding: 4px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.p001-main-table input:focus,
.p001-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

/* İmza və möhür */
.p001-approval-section {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 38px 50px 0;
}

/* Footer */
.p001-document-footer {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    margin-top: 38px;
    color: #64748b;
    font-size: 8px;
}

.p001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.p001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.p001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

@media (max-width: 900px) {
    .p001-approval-section {
        gap: 20px;
        margin-inline: 0;
    }
}

@media print {
    .p001-main-table input,
    .p001-main-table textarea,
    .p001-meta-table input {
        box-shadow: none !important;
    }
}



/* =====================================================
   GMP T-003 — ŞƏXSİ GİGİYENA TƏLİMATI
===================================================== */

.t003-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.t003-document {
    position: relative;
    overflow: hidden;
}

.t003-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.t003-logo-box,
.t003-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.t003-title-box {
    text-align: center;
}

.t003-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
}

.t003-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.t003-meta-table th,
.t003-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.t003-meta-table tr:last-child th,
.t003-meta-table tr:last-child td {
    border-bottom: 0;
}

.t003-meta-table th {
    width: 58%;
    font-weight: 500;
}

.t003-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.t003-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

.t003-content {
    position: relative;
    z-index: 1;

    /* Yuxarı məzmun boşluğu */
    padding-top: 34px;

    /* Footer-in üstünə mətn gəlməsin */
    padding-bottom: 130px;

    color: #111827;
    font-size: 12px;
    line-height: 1.45;
}

.t003-content h3 {
    margin: 0 0 12px;
    font-size: 15px;
}

.t003-content h4 {
    margin: 18px 0 10px;
    font-size: 14px;
    font-weight: 600;
}

.t003-content h5 {
    margin: 14px 0 8px;
    font-size: 12px;
}

.t003-content ul,
.t003-content ol {
    margin: 8px 0 16px;
    padding-left: 28px;
}

.t003-content li {
    margin-bottom: 7px;
}

.t003-content hr {
    margin: 20px 0;
    border: 0;
    border-top: 1px solid #9ca3af;
}

.t003-clean-image-block {
    margin: 24px 0;
    text-align: center;
}

.t003-cleaning-steps-image {
    display: block;
    width: 100%;
    max-width: 640px;
    margin: 12px auto 0;
    object-fit: contain;
}

.t003-signoff-section {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 12px 16px;
    margin-top: 30px;
}

.t003-signoff-section label {
    display: contents;
}

.t003-signoff-section input {
    width: 100%;
    min-height: 30px;
    padding: 4px 6px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

.t003-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 60px 50px 0;
}

.t003-document-footer {
    position: absolute;
    right: 54px;
    bottom: 40px;
    left: 20px;   /* əvvəl 54px idi */
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.t003-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.t003-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.t003-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

@media print {
    .t003-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .t003-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .t003-meta-table input,
    .t003-signoff-section input {
        box-shadow: none !important;
    }
}




/* =====================================================
   GMP XSP-001 — XAMMAL SPESİFİKASİYASI
===================================================== */

.xsp001-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.xsp001-document {
    position: relative;
    overflow: hidden;
}

.xsp001-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.xsp001-logo-box,
.xsp001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.xsp001-title-box {
    text-align: center;
}

.xsp001-title-box h2 {
    display: flex;
    flex-direction: column;
    gap: 3px;
    width: 100%;
    margin: 0;
    color: #374151;
    font-size: 19px;
    font-weight: 500;
    line-height: 1.2;
}

.xsp001-title-box input {
    width: 100%;
    padding: 0;
    color: inherit;
    font: inherit;
    font-weight: 500;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
}

.xsp001-title-box input:focus {
    background: rgba(67, 140, 243, 0.08);
}

.xsp001-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.xsp001-meta-table th,
.xsp001-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.xsp001-meta-table tr:last-child th,
.xsp001-meta-table tr:last-child td {
    border-bottom: 0;
}

.xsp001-meta-table th {
    width: 58%;
    font-weight: 500;
}

.xsp001-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.xsp001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Məzmun */
.xsp001-content {
    position: relative;
    z-index: 1;
    padding: 30px 0 115px;
    color: #111827;
    font-size: 11px;
    line-height: 1.4;
}

.xsp001-section {
    margin-bottom: 18px;
}

.xsp001-section h3 {
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: 700;
}

.xsp001-section h4 {
    margin: 10px 0 8px;
    font-size: 11px;
}

.xsp001-section ul {
    margin: 8px 0;
    padding-left: 55px;
}

.xsp001-section li {
    margin-bottom: 3px;
}

/* Mətn sahələri */
.xsp001-section textarea {
    display: block;
    width: 100%;
    padding: 7px 8px;
    color: #111827;
    font: inherit;
    line-height: 1.4;
    background: rgba(255, 255, 255, 0.35);
    border: 0;
    border-bottom: 1px dotted #64748b;
    outline: none;
    resize: vertical;
}

.xsp001-section textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    border-bottom-color: #438cf3;
}

/* İkinci səhifə */
.xsp001-second-page-content {
    padding-top: 38px;
}

.xsp001-additional-section {
    margin-top: 35px;
}

/* Tərtib və təsdiq */
.xsp001-signoff-section {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px 24px;
    margin-top: 35px;
}

.xsp001-signoff-section label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.xsp001-signoff-section span {
    min-width: 75px;
    font-weight: 600;
}

.xsp001-signoff-section input {
    flex: 1;
    min-width: 0;
    padding: 4px 5px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* İmza və möhür */
.xsp001-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 60px 50px 0;
}

/* Footer */
.xsp001-document-footer {
    position: absolute;
    right: 54px;
    bottom: 38px;
    left: 20px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.xsp001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.xsp001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.xsp001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

@media print {
    .xsp001-editor-wrapper {
        display: block;
        padding: 0;
        background: #ffffff;
    }

    .xsp001-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .xsp001-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .xsp001-meta-table input,
    .xsp001-title-box input,
    .xsp001-section textarea,
    .xsp001-signoff-section input {
        box-shadow: none !important;
    }
}



/* =====================================================
   HASSP HCP-1 — HACCP KOMANDASI ƏMRİ
===================================================== */

.hcp1-document {
    position: relative;
    overflow: hidden;
}

.hcp1-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.hcp1-logo-box,
.hcp1-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.hcp1-title-box {
    text-align: center;
}

.hcp1-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
}

.hcp1-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.hcp1-meta-table th,
.hcp1-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.hcp1-meta-table tr:last-child th,
.hcp1-meta-table tr:last-child td {
    border-bottom: 0;
}

.hcp1-meta-table th {
    width: 58%;
    font-weight: 500;
}

.hcp1-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.hcp1-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Əsas məzmun */
.hcp1-content {
    position: relative;
    z-index: 1;
    padding: 18px 0 135px;
    color: #111827;
    font-size: 10px;
    line-height: 1.35;
}

.hcp1-content h3 {
    margin: 0 0 8px;
    font-size: 11px;
    font-weight: 700;
}

.hcp1-text-section {
    margin-bottom: 16px;
}

.hcp1-text-section textarea {
    display: block;
    width: 100%;
    padding: 5px 0;
    color: #111827;
    font: inherit;
    line-height: 1.35;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.hcp1-text-section textarea:focus {
    background: rgba(67, 140, 243, 0.07);
}

/* Komanda cədvəli */
.hcp1-team-section {
    margin-bottom: 20px;
}

.hcp1-team-section h3 {
    display: flex;
    align-items: center;
    gap: 5px;
}

.hcp1-table-wrapper {
    margin-top: 10px;
}

.hcp1-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 9px;
}

.hcp1-main-table th,
.hcp1-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.hcp1-main-table th {
    height: 42px;
    padding: 5px;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.15;
}

.hcp1-main-table td {
    height: 31px;
}

.hcp1-main-table th:nth-child(1) {
    width: 25%;
}

.hcp1-main-table th:nth-child(2) {
    width: 27%;
}

.hcp1-main-table th:nth-child(3) {
    width: 24%;
}

.hcp1-main-table th:nth-child(4) {
    width: 24%;
}

.hcp1-role-row td {
    height: 27px;
    font-weight: 500;
    background: rgba(248, 250, 252, 0.55);
}

.hcp1-main-table input,
.hcp1-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 30px;
    padding: 4px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.hcp1-main-table input:focus,
.hcp1-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Təşkilat rəhbərinin məlumatı */
.hcp1-signoff-fields {
    display: grid;
    gap: 8px;
    margin-top: 15px;
}

.hcp1-signoff-fields label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hcp1-signoff-fields span {
    min-width: 185px;
    font-weight: 600;
}

.hcp1-signoff-fields input {
    flex: 1;
    min-width: 0;
    padding: 4px 5px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* İmza və möhür */
.hcp1-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 32px 50px 0;
}

/* Footer */
.hcp1-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.hcp1-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hcp1-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.hcp1-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

@media print {
    .hcp1-meta-table input,
    .hcp1-main-table input,
    .hcp1-main-table textarea,
    .hcp1-text-section textarea,
    .hcp1-signoff-fields input {
        box-shadow: none !important;
    }
}



/* =====================================================
   GMP HSP-001 — HAZIR MƏHSUL SPESİFİKASİYASI
===================================================== */

.hsp001-document {
    position: relative;
    overflow: hidden;
}

.hsp001-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.hsp001-logo-box,
.hsp001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.hsp001-title-box {
    text-align: center;
}

.hsp001-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
    line-height: 1.25;
}

.hsp001-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.hsp001-meta-table th,
.hsp001-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.hsp001-meta-table tr:last-child th,
.hsp001-meta-table tr:last-child td {
    border-bottom: 0;
}

.hsp001-meta-table th {
    width: 58%;
    font-weight: 500;
}

.hsp001-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.hsp001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Əsas məzmun */
.hsp001-content {
    position: relative;
    z-index: 1;
    padding: 25px 0 125px;
    color: #111827;
    font-size: 11px;
    line-height: 1.4;
}

.hsp001-section {
    margin-bottom: 16px;
}

.hsp001-section h3 {
    margin: 0 0 7px;
    font-size: 12px;
    font-weight: 700;
}

/* Yazıla bilən mətn sahələri */
.hsp001-section textarea {
    display: block;
    width: 100%;
    min-height: 45px;
    padding: 6px 7px;
    color: #111827;
    font: inherit;
    line-height: 1.4;
    background: rgba(255, 255, 255, 0.3);
    border: 0;
    border-bottom: 1px dotted #64748b;
    outline: none;
    resize: vertical;
}

.hsp001-section textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    border-bottom-color: #438cf3;
}

/* Tərtib və təsdiq məlumatları */
.hsp001-signoff-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 24px;
    margin-top: 28px;
}

.hsp001-signoff-section label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hsp001-signoff-section span {
    min-width: 78px;
    font-weight: 600;
}

.hsp001-signoff-section input {
    flex: 1;
    min-width: 0;
    padding: 4px 5px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* İmza və möhür */
.hsp001-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 40px 50px 0;
}

/* Footer */
.hsp001-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.hsp001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hsp001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.hsp001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

/* Mobil görünüş */
@media (max-width: 900px) {
    .hsp001-signoff-section {
        grid-template-columns: 1fr;
    }

    .hsp001-approval-section {
        gap: 20px;
        margin-inline: 0;
    }
}

/* Çap və PDF görünüşü */
@media print {
    .hsp001-meta-table input,
    .hsp001-section textarea,
    .hsp001-signoff-section input {
        box-shadow: none !important;
    }
}




/* =====================================================
   HASSP HPAD-001 — HACCP PROSES AXIN DİAQRAM FORMASI
===================================================== */

.hpad001-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.hpad001-document {
    position: relative;
    overflow: hidden;
}

/* Sənəd başlığı */
.hpad001-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.hpad001-logo-box,
.hpad001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.hpad001-title-box {
    text-align: center;
}

.hpad001-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 19px;
    font-weight: 500;
    line-height: 1.2;
}

/* Rekvizitlər */
.hpad001-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.hpad001-meta-table th,
.hpad001-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.hpad001-meta-table tr:last-child th,
.hpad001-meta-table tr:last-child td {
    border-bottom: 0;
}

.hpad001-meta-table th {
    width: 58%;
    font-weight: 500;
}

.hpad001-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.hpad001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Birinci səhifə məzmunu */
.hpad001-content {
    position: relative;
    z-index: 1;
    padding: 16px 0 120px;
}

.hpad001-content > h3 {
    margin: 0 0 14px;
    text-align: center;
    font-size: 11px;
}

/* Proses axını */
.hpad001-flow {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hpad001-step {
    position: relative;
    display: flex;
    align-items: center;
    width: 360px;
    min-height: 33px;
    border: 1px solid #111827;
    background: rgba(255, 255, 255, 0.45);
}

.hpad001-step-number {
    width: 38px;
    padding-left: 10px;
    font-size: 10px;
    flex-shrink: 0;
}

.hpad001-step input {
    width: 100%;
    min-height: 31px;
    padding: 5px;
    color: #111827;
    font-size: 10px;
    background: transparent;
    border: 0;
    outline: none;
}

.hpad001-step input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Yaşıl oxlar */
.hpad001-arrow {
    position: relative;
    width: 24px;
    height: 19px;
}

.hpad001-arrow-line {
    position: absolute;
    top: 0;
    left: 7px;
    width: 10px;
    height: 12px;
    background: #8bd247;
    border: 1px solid #111827;
    border-bottom: 0;
}

.hpad001-arrow-head {
    position: absolute;
    bottom: 0;
    left: 1px;
    width: 0;
    height: 0;
    border-top: 8px solid #8bd247;
    border-right: 11px solid transparent;
    border-left: 11px solid transparent;
    filter: drop-shadow(0 1px 0 #111827);
}

/* İkinci səhifə */
.hpad001-approval-content {
    position: relative;
    z-index: 1;
    padding: 20px 0 125px;
    color: #111827;
    font-size: 10px;
}

.hpad001-approval-content h3 {
    margin: 0 0 14px;
    font-size: 10px;
    font-weight: 700;
}

/* Qrup rəhbəri */
.hpad001-signature-section {
    margin-bottom: 42px;
}

.hpad001-person-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 22px;
    margin-bottom: 22px;
}

.hpad001-person-fields label:last-child {
    grid-column: 1 / -1;
}

.hpad001-person-fields label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hpad001-person-fields span {
    min-width: 85px;
    font-weight: 600;
}

.hpad001-person-fields input {
    flex: 1;
    min-width: 0;
    padding: 4px 5px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* Qrup üzvləri cədvəli */
.hpad001-members-section {
    margin-top: 36px;
}

.hpad001-members-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 9px;
}

.hpad001-members-table th,
.hpad001-members-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.hpad001-members-table th {
    height: 36px;
    padding: 5px;
    font-weight: 700;
}

.hpad001-members-table td {
    height: 35px;
}

.hpad001-members-table th:nth-child(1) {
    width: 6%;
}

.hpad001-members-table th:nth-child(2) {
    width: 29%;
}

.hpad001-members-table th:nth-child(3) {
    width: 25%;
}

.hpad001-members-table th:nth-child(4) {
    width: 18%;
}

.hpad001-members-table th:nth-child(5) {
    width: 22%;
}

.hpad001-members-table input {
    width: 100%;
    height: 100%;
    min-height: 34px;
    padding: 4px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
}

.hpad001-members-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Möhür hissəsi */
.hpad001-stamp-section {
    width: 45%;
    margin: 42px auto 0;
}

/* Footer */
.hpad001-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.hpad001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hpad001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.hpad001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

/* Mobil görünüş */
@media (max-width: 900px) {
    .hpad001-step {
        width: 90%;
    }

    .hpad001-person-fields {
        grid-template-columns: 1fr;
    }

    .hpad001-person-fields label:last-child {
        grid-column: auto;
    }

    .hpad001-stamp-section {
        width: 100%;
    }
}

/* Çap və PDF */
@media print {
    .hpad001-editor-wrapper {
        display: block;
        padding: 0;
        background: #ffffff;
    }

    .hpad001-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .hpad001-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .hpad001-meta-table input,
    .hpad001-step input,
    .hpad001-person-fields input,
    .hpad001-members-table input {
        box-shadow: none !important;
    }
}



/* =====================================================
   HASSP HPAD-002 — AXIN DİAQRAMININ YERİNDƏ TƏSDİQİ
===================================================== */

.hpad002-document {
    position: relative;
    overflow: hidden;
}

.hpad002-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.hpad002-logo-box,
.hpad002-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.hpad002-title-box {
    text-align: center;
}

.hpad002-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.2;
}

.hpad002-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.hpad002-meta-table th,
.hpad002-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.hpad002-meta-table tr:last-child th,
.hpad002-meta-table tr:last-child td {
    border-bottom: 0;
}

.hpad002-meta-table th {
    width: 58%;
    font-weight: 500;
}

.hpad002-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.hpad002-content {
    position: relative;
    z-index: 1;
    padding: 15px 0 135px;
    color: #111827;
    font-size: 9px;
    line-height: 1.3;
}

/* Ümumi sahələr */
.hpad002-general-fields {
    display: grid;
    gap: 4px;
    margin-bottom: 14px;
}

.hpad002-general-fields label {
    display: flex;
    align-items: center;
    gap: 7px;
    font-weight: 700;
}

.hpad002-general-fields span {
    min-width: 245px;
}

.hpad002-general-fields input {
    flex: 1;
    min-width: 0;
    padding: 3px 4px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* Yoxlama cədvəli */
.hpad002-check-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.hpad002-check-table th,
.hpad002-check-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.hpad002-check-table th {
    height: 48px;
    padding: 4px;
    font-weight: 700;
    line-height: 1.15;
}

.hpad002-check-table td {
    height: 27px;
}

.hpad002-check-table th:nth-child(1) {
    width: 5%;
}

.hpad002-check-table th:nth-child(2) {
    width: 23%;
}

.hpad002-check-table th:nth-child(3) {
    width: 31%;
}

.hpad002-check-table th:nth-child(4) {
    width: 25%;
}

.hpad002-check-table th:nth-child(5) {
    width: 16%;
}

.hpad002-check-table input,
.hpad002-check-table select,
.hpad002-check-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 26px;
    padding: 3px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

/* Nəticə */
.hpad002-result-section {
    margin-top: 15px;
}

.hpad002-result-section h3,
.hpad002-team-section h3,
.hpad002-leader-section h3 {
    margin: 0 0 7px;
    font-size: 10px;
}

.hpad002-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin-bottom: 5px;
}

.hpad002-checkbox-label input {
    margin-top: 2px;
}

/* Komanda cədvəli */
.hpad002-team-section {
    margin-top: 15px;
}

.hpad002-team-table {
    width: 58%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.hpad002-team-table th,
.hpad002-team-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.hpad002-team-table th {
    height: 25px;
    padding: 3px;
}

.hpad002-team-table td {
    height: 25px;
}

.hpad002-team-table th:nth-child(1) {
    width: 8%;
}

.hpad002-team-table th:nth-child(2) {
    width: 35%;
}

.hpad002-team-table th:nth-child(3) {
    width: 23%;
}

.hpad002-team-table th:nth-child(4) {
    width: 17%;
}

.hpad002-team-table th:nth-child(5) {
    width: 17%;
}

.hpad002-team-table input {
    width: 100%;
    height: 100%;
    min-height: 24px;
    padding: 2px;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
}

/* Rəhbər təsdiqi */
.hpad002-leader-section {
    display: grid;
    gap: 6px;
    margin-top: 14px;
}

.hpad002-leader-section label {
    display: flex;
    align-items: center;
    gap: 7px;
}

.hpad002-leader-section span {
    min-width: 90px;
    font-weight: 600;
}

.hpad002-leader-section input {
    width: 280px;
    padding: 3px 4px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* İmza və möhür */
.hpad002-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 28px 50px 0;
}

/* Footer */
.hpad002-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.hpad002-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hpad002-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.hpad002-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

@media print {
    .hpad002-meta-table input,
    .hpad002-general-fields input,
    .hpad002-check-table input,
    .hpad002-check-table select,
    .hpad002-check-table textarea,
    .hpad002-team-table input,
    .hpad002-leader-section input {
        box-shadow: none !important;
    }
}




/* =====================================================
   HASSP TP-001 — TƏHLÜKƏ ANALİZİ CƏDVƏLİ
===================================================== */

.tp001-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.tp001-document {
    position: relative;
    overflow: hidden;
}

/* Header */
.tp001-document-header {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 135px 1fr 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.tp001-logo-box,
.tp001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.tp001-title-box {
    text-align: center;
}

.tp001-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 20px;
    font-weight: 500;
}

/* Meta cədvəli */
.tp001-meta-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 9px;
}

.tp001-meta-table th,
.tp001-meta-table td {
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.tp001-meta-table tr:last-child th,
.tp001-meta-table tr:last-child td {
    border-bottom: 0;
}

.tp001-meta-table th {
    width: 58%;
    font-weight: 500;
}

.tp001-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.tp001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Başlıq */
.tp001-table-title {
    position: relative;
    z-index: 1;
    margin: 16px 0 12px;
    text-align: center;
    font-size: 10px;
    font-weight: 700;
}

/* Əsas cədvəl */
.tp001-table-wrapper {
    position: relative;
    z-index: 1;
}

.tp001-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 7px;
}

.tp001-main-table th,
.tp001-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.tp001-main-table th {
    padding: 4px 3px;
    font-weight: 700;
    line-height: 1.15;
}

.tp001-main-table td {
    height: 35px;
}

.tp001-column-numbers th {
    height: 20px;
    font-weight: 500;
}

/* Sütun ölçüləri */
.tp001-main-table th:nth-child(1) {
    width: 8%;
}

.tp001-main-table th:nth-child(2) {
    width: 28%;
}

.tp001-main-table th:nth-child(3) {
    width: 14%;
}

.tp001-main-table th:nth-child(4) {
    width: 17%;
}

.tp001-main-table th:nth-child(5) {
    width: 21%;
}

.tp001-main-table th:nth-child(6) {
    width: 12%;
}

.tp001-subhead-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin: 5px -3px -4px;
    border-top: 1px solid #111827;
}

.tp001-subhead-options span {
    padding: 3px;
}

.tp001-subhead-options span:first-child {
    border-right: 1px solid #111827;
}

/* Proses sahəsi */
.tp001-process-cell input {
    width: 100%;
    height: 100%;
    min-height: 105px;
    padding: 4px;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
}

/* Təhlükə sahəsi */
.tp001-hazard-field {
    display: grid;
    grid-template-columns: 24px 1fr;
    height: 100%;
    min-height: 34px;
}

.tp001-hazard-field strong {
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #111827;
}

.tp001-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 34px;
    padding: 3px;
    color: #111827;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.tp001-main-table textarea:focus,
.tp001-process-cell input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Bəli/Xeyr */
.tp001-choice-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    height: 100%;
}

.tp001-choice-group label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-height: 34px;
    cursor: pointer;
}

.tp001-choice-group label:first-child {
    border-right: 1px solid #111827;
}

.tp001-choice-group input {
    width: 10px;
    height: 10px;
    margin: 0;
}

/* İkinci səhifə */
.tp001-second-page-content {
    position: relative;
    z-index: 1;
    padding: 16px 0 130px;
    color: #111827;
    font-size: 9px;
}

.tp001-second-page-content > h3 {
    margin: 0 0 20px;
    font-size: 10px;
}

.tp001-notes-section label {
    display: grid;
    gap: 8px;
}

.tp001-notes-section span {
    font-weight: 700;
}

.tp001-notes-section textarea {
    width: 100%;
    min-height: 220px;
    padding: 8px;
    font: inherit;
    background: rgba(255, 255, 255, 0.3);
    border: 1px solid #111827;
    outline: none;
    resize: vertical;
}

/* Komanda cədvəli */
.tp001-team-section {
    margin-top: 28px;
}

.tp001-team-section h3,
.tp001-leader-section h3 {
    margin: 0 0 8px;
    font-size: 10px;
}

.tp001-team-table {
    width: 75%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.tp001-team-table th,
.tp001-team-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
}

.tp001-team-table th {
    height: 26px;
    padding: 3px;
}

.tp001-team-table td {
    height: 28px;
}

.tp001-team-table th:nth-child(1) {
    width: 7%;
}

.tp001-team-table th:nth-child(2) {
    width: 33%;
}

.tp001-team-table th:nth-child(3) {
    width: 25%;
}

.tp001-team-table th:nth-child(4) {
    width: 17%;
}

.tp001-team-table th:nth-child(5) {
    width: 18%;
}

.tp001-team-table input {
    width: 100%;
    height: 100%;
    min-height: 27px;
    padding: 3px;
    font: inherit;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
}

/* Rəhbərin təsdiqi */
.tp001-leader-section {
    display: grid;
    gap: 7px;
    margin-top: 24px;
}

.tp001-leader-section label {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tp001-leader-section span {
    min-width: 90px;
    font-weight: 600;
}

.tp001-leader-section input {
    width: 280px;
    padding: 4px;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* İmza və möhür */
.tp001-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 42px 50px 0;
}

/* Footer */
.tp001-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    color: #64748b;
    font-size: 8px;
}

.tp001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.tp001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.tp001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

/* Çap və PDF */
@media print {
    .tp001-editor-wrapper {
        display: block;
        padding: 0;
        background: #ffffff;
    }

    .tp001-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .tp001-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .tp001-meta-table input,
    .tp001-main-table textarea,
    .tp001-process-cell input,
    .tp001-notes-section textarea,
    .tp001-team-table input,
    .tp001-leader-section input {
        box-shadow: none !important;
    }
}



/* =====================================================
   HASSP HP-001 — HACCP PLANI
===================================================== */

.hp001-document {
    position: relative;
    overflow: hidden;
}

/* =====================================================
   SƏNƏD BAŞLIĞI
===================================================== */

.hp001-document-header {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr) 280px;
    min-height: 142px;
    border: 1px solid #111827;
}

.hp001-logo-box,
.hp001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    border-right: 1px solid #111827;
}

.hp001-logo-box .document-logo {
    display: block;
    width: 135px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.hp001-title-box {
    text-align: center;
}

.hp001-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 28px;
    font-weight: 600;
    line-height: 1.2;
}

/* =====================================================
   SƏNƏD REKVİZİTLƏRİ
===================================================== */

.hp001-meta-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 10px;
}

.hp001-meta-table th,
.hp001-meta-table td {
    height: 27px;
    padding: 3px 7px;
    border-bottom: 1px solid #111827;
    text-align: left;
    vertical-align: middle;
}

.hp001-meta-table tr:last-child th,
.hp001-meta-table tr:last-child td {
    border-bottom: 0;
}

.hp001-meta-table th {
    width: 60%;
    font-weight: 500;
}

.hp001-meta-table td {
    width: 40%;
}

.hp001-meta-table input {
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 20px;
    padding: 2px 4px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.hp001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

/* =====================================================
   CƏDVƏL BAŞLIĞI
===================================================== */

.hp001-table-title {
    position: relative;
    z-index: 2;
    margin: 22px 0 18px;
    text-align: center;
    font-size: 16px;
    font-weight: 700;
}

/* =====================================================
   ƏSAS HACCP CƏDVƏLİ
===================================================== */

.hp001-table-wrapper {
    position: relative;
    z-index: 2;
    width: 100%;
    overflow: visible;
}

.hp001-main-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 7px;
}

.hp001-main-table th,
.hp001-main-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.hp001-main-table th {
    padding: 5px 3px;
    font-size: 7px;
    font-weight: 700;
    line-height: 1.15;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;
}

/* Sütun nömrələri */
.hp001-column-numbers th {
    height: 25px;
    padding: 3px;
    font-size: 8px;
    font-style: italic;
    font-weight: 500;
}

/* Monitorinq əsas başlığı olan sıra */
.hp001-main-table thead tr:nth-child(2) th {
    height: 35px;
}

/* Monitorinq alt başlıqları */
.hp001-main-table thead tr:nth-child(3) th {
    height: 92px;
    padding: 5px 2px;
    font-size: 6.5px;
    line-height: 1.15;
}

/* Body sətirləri */
.hp001-main-table tbody td {
    height: 39px;
}

/*
|--------------------------------------------------------------------------
| Dəqiq sütun ölçüləri
|--------------------------------------------------------------------------
|
| 1  CCP                          10%
| 2  Mühüm təhlükələr            14%
| 3  Kritik hədd                 15%
| 4  Nə izləniləcək               7%
| 5  Necə izləniləcək             7%
| 6  İzləmə vaxtı və tezliyi      10%
| 7  Məsul şəxs                    7%
| 8  Düzəldici fəaliyyətlər       11%
| 9  Verifikasiya fəaliyyətləri   11%
| 10 Qeydlər                       8%
|
*/

.hp001-main-table col:nth-child(1) {
    width: 10%;
}

.hp001-main-table col:nth-child(2) {
    width: 14%;
}

.hp001-main-table col:nth-child(3) {
    width: 15%;
}

.hp001-main-table col:nth-child(4) {
    width: 7%;
}

.hp001-main-table col:nth-child(5) {
    width: 7%;
}

.hp001-main-table col:nth-child(6) {
    width: 10%;
}

.hp001-main-table col:nth-child(7) {
    width: 7%;
}

.hp001-main-table col:nth-child(8) {
    width: 11%;
}

.hp001-main-table col:nth-child(9) {
    width: 11%;
}

.hp001-main-table col:nth-child(10) {
    width: 8%;
}

/* Input və textarea */
.hp001-main-table input,
.hp001-main-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 38px;
    padding: 4px 3px;
    color: #111827;
    font: inherit;
    line-height: 1.25;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
    overflow: hidden;
}

.hp001-main-table input:focus,
.hp001-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

/* =====================================================
   HAZIRLAYAN / YOXLAYAN / TƏSDİQLƏYƏN
===================================================== */

.hp001-signoff-table-wrapper {
    position: relative;
    z-index: 2;
    width: 82%;
    margin: 24px auto 0;
}

.hp001-signoff-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 9px;
}

.hp001-signoff-table th,
.hp001-signoff-table td {
    border: 1px solid #111827;
    vertical-align: top;
}

.hp001-signoff-table th {
    height: 30px;
    padding: 5px;
    font-size: 13px;
    font-weight: 700;
    text-align: center;
}

.hp001-signoff-table td {
    height: 118px;
    padding: 8px;
}

.hp001-signoff-table label {
    display: grid;
    grid-template-columns: 68px minmax(0, 1fr);
    align-items: center;
    gap: 6px;
    margin-bottom: 7px;
}

.hp001-signoff-table label:last-child {
    margin-bottom: 0;
}

.hp001-signoff-table span {
    font-size: 8px;
    font-weight: 600;
    white-space: nowrap;
}

.hp001-signoff-table input {
    width: 100%;
    min-width: 0;
    padding: 3px 4px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #94a3b8;
    outline: none;
}

.hp001-signoff-table input:focus {
    background: rgba(67, 140, 243, 0.08);
    border-bottom-color: #438cf3;
}

/* =====================================================
   İMZA VƏ MÖHÜR
===================================================== */

.hp001-approval-section {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 80px;
    margin: 34px 70px 145px;
}

.hp001-approval-section .signature-column {
    min-width: 0;
}

/* =====================================================
   FOOTER
===================================================== */

.hp001-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 2;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    color: #64748b;
    font-size: 8px;
}

.hp001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hp001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.hp001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

/* =====================================================
   MOBİL GÖRÜNÜŞ
===================================================== */

@media (max-width: 900px) {
    .hp001-signoff-table-wrapper {
        width: 100%;
    }

    .hp001-approval-section {
        gap: 20px;
        margin-right: 0;
        margin-left: 0;
    }
}

/* =====================================================
   ÇAP VƏ PDF
===================================================== */

@media print {
    .hp001-document {
        overflow: hidden;
    }

    .hp001-meta-table input,
    .hp001-main-table input,
    .hp001-main-table textarea,
    .hp001-signoff-table input {
        box-shadow: none !important;
    }

    .hp001-approval-section {
        margin-bottom: 130px;
    }
}



/* =====================================================
   HASSP HP-002 — CCP QƏRAR AĞACI
===================================================== */

.hp002-document {
    position: relative;
    overflow: hidden;
}

/* Header */
.hp002-document-header {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 135px minmax(0, 1fr) 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.hp002-logo-box,
.hp002-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.hp002-title-box {
    text-align: center;
}

.hp002-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 17px;
    font-weight: 600;
    line-height: 1.25;
}

/* Meta */
.hp002-meta-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 9px;
}

.hp002-meta-table th,
.hp002-meta-table td {
    height: 19px;
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
}

.hp002-meta-table tr:last-child th,
.hp002-meta-table tr:last-child td {
    border-bottom: 0;
}

.hp002-meta-table th {
    width: 58%;
    font-weight: 500;
}

.hp002-meta-table input {
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.hp002-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Başlıq */
.hp002-tree-title {
    position: relative;
    z-index: 2;
    margin: 18px 0;
    text-align: center;
    font-size: 14px;
    font-weight: 700;
}

/* Qərar ağacı */
.hp002-tree {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.hp002-question-box {
    position: relative;
    width: 480px;
    min-height: 64px;
    padding: 9px 12px 8px 64px;
    background: rgba(255, 255, 255, 0.72);
    border: 2px solid #82aed7;
    border-radius: 12px;
}

.hp002-question-number {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    display: grid;
    place-items: center;
    width: 56px;
    color: #315f89;
    font-size: 11px;
    font-weight: 700;
    border-right: 1px solid #82aed7;
}

.hp002-question-box textarea {
    display: block;
    width: 100%;
    min-height: 44px;
    padding: 3px;
    color: #111827;
    font: inherit;
    font-size: 10px;
    line-height: 1.35;
    text-align: center;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.hp002-question-box textarea:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Budaqlar */
.hp002-branches {
    display: grid;
    grid-template-columns: repeat(2, 225px);
    justify-content: center;
    gap: 45px;
}

.hp002-branch {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hp002-answer {
    display: grid;
    place-items: center;
    min-width: 56px;
    min-height: 28px;
    padding: 4px 10px;
    color: #ffffff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 18px;
}

.hp002-answer.yes {
    background: #4a9d49;
}

.hp002-answer.no {
    background: #d05d5d;
}

.hp002-arrow-down {
    position: relative;
    display: block;
    width: 2px;
    height: 22px;
    margin-bottom: 7px;
    background: #6d9d52;
}

.hp002-arrow-down::after {
    position: absolute;
    bottom: -1px;
    left: 50%;
    width: 8px;
    height: 8px;
    content: "";
    border-right: 2px solid #6d9d52;
    border-bottom: 2px solid #6d9d52;
    transform: translateX(-50%) rotate(45deg);
}

.hp002-result-box,
.hp002-continue-box,
.hp002-final-result {
    display: grid;
    place-items: center;
    width: 225px;
    min-height: 46px;
    padding: 8px;
    font-size: 9px;
    line-height: 1.3;
    text-align: center;
    background: rgba(255, 255, 255, 0.75);
    border: 2px solid #82aed7;
    border-radius: 10px;
}

.hp002-result-box.warning {
    border-color: #d7a248;
}

.hp002-continue-box {
    color: #315f89;
    font-weight: 700;
}

.hp002-final-result {
    min-height: 52px;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
}

.hp002-final-result.ccp {
    background: #4a9d49;
    border-color: #377d36;
}

.hp002-final-result.not-ccp {
    background: #718096;
    border-color: #526071;
}

/* Qiymətləndirmə */
.hp002-evaluation-section {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 9px;
    margin-top: 30px;
}

.hp002-evaluation-section h3 {
    margin: 0 0 4px;
    font-size: 11px;
}

.hp002-evaluation-section label {
    display: grid;
    grid-template-columns: 185px minmax(0, 1fr);
    align-items: start;
    gap: 8px;
}

.hp002-evaluation-section span {
    padding-top: 4px;
    font-size: 9px;
    font-weight: 600;
}

.hp002-evaluation-section input,
.hp002-evaluation-section select,
.hp002-evaluation-section textarea {
    width: 100%;
    padding: 4px 6px;
    color: #111827;
    font: inherit;
    font-size: 9px;
    background: transparent;
    border: 1px solid #94a3b8;
    outline: none;
    resize: vertical;
}

/* Qeyd */
.hp002-note {
    position: relative;
    z-index: 2;
    margin-top: 22px;
    font-size: 9px;
    line-height: 1.45;
}

.hp002-note strong {
    display: block;
    margin-bottom: 5px;
}

.hp002-note p {
    margin: 0 0 5px;
}

/* İmza məlumatları */
.hp002-signoff-section {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 15px;
    margin-top: 18px;
}

.hp002-signoff-section label {
    display: grid;
    gap: 4px;
}

.hp002-signoff-section span {
    font-size: 9px;
    font-weight: 600;
}

.hp002-signoff-section input {
    width: 100%;
    padding: 4px;
    font: inherit;
    font-size: 9px;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* İmza və möhür */
.hp002-approval-section {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 28px 55px 125px;
}

/* Footer */
.hp002-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 2;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    color: #64748b;
    font-size: 8px;
}

.hp002-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hp002-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.hp002-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

@media print {
    .hp002-meta-table input,
    .hp002-question-box textarea,
    .hp002-evaluation-section input,
    .hp002-evaluation-section select,
    .hp002-evaluation-section textarea,
    .hp002-signoff-section input {
        box-shadow: none !important;
    }
}

.hp002-scheme-wrapper {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 14px;
}

.hp002-scheme-image {
    display: block;
    width: 100%;
    max-width: 610px;
    height: auto;
    object-fit: contain;
}


/* =====================================================
   HASSP VF-001 — VALİDASİYA FORMASI
===================================================== */

.vf001-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.vf001-document {
    position: relative;
    overflow: hidden;
}

/* Header */
.vf001-document-header {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 135px minmax(0, 1fr) 225px;
    min-height: 94px;
    border: 1px solid #111827;
}

.vf001-logo-box,
.vf001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-right: 1px solid #111827;
}

.vf001-title-box {
    text-align: center;
}

.vf001-title-box h2 {
    margin: 0;
    color: #374151;
    font-size: 17px;
    font-weight: 600;
    line-height: 1.25;
}

.vf001-title-box h2 span {
    font-size: 15px;
}

/* Meta */
.vf001-meta-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 9px;
}

.vf001-meta-table th,
.vf001-meta-table td {
    height: 19px;
    padding: 2px 5px;
    border-bottom: 1px solid #111827;
    text-align: left;
    vertical-align: middle;
}

.vf001-meta-table tr:last-child th,
.vf001-meta-table tr:last-child td {
    border-bottom: 0;
}

.vf001-meta-table th {
    width: 58%;
    font-weight: 500;
}

.vf001-meta-table input {
    display: block;
    width: 100%;
    min-height: 18px;
    padding: 1px 3px;
    color: #111827;
    font: inherit;
    background: transparent;
    border: 0;
    outline: none;
}

.vf001-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* İzah */
.vf001-intro {
    position: relative;
    z-index: 2;
    margin-top: 14px;
    color: #111827;
    font-size: 9px;
    line-height: 1.4;
}

.vf001-intro p {
    margin: 0 0 7px;
}

/* Cədvəl və qeyd sahəsi */
.vf001-validation-layout {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 56% 44%;
    margin-top: 10px;
}

.vf001-questions-wrapper {
    min-width: 0;
}

.vf001-questions-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 8px;
}

.vf001-questions-table th,
.vf001-questions-table td {
    padding: 0;
    border: 1px solid #111827;
    text-align: center;
    vertical-align: middle;
}

.vf001-questions-table th {
    height: 24px;
    padding: 3px;
    font-weight: 700;
}

.vf001-questions-table th:first-child {
    width: 82%;
    text-align: left;
}

.vf001-questions-table th:nth-child(2),
.vf001-questions-table th:nth-child(3) {
    width: 9%;
}

.vf001-questions-table td {
    height: 40px;
}

.vf001-questions-table textarea {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 39px;
    padding: 4px 6px;
    color: #111827;
    font: inherit;
    line-height: 1.25;
    text-align: left;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.vf001-questions-table textarea:focus {
    background: rgba(67, 140, 243, 0.08);
}

/* Bəli/Xeyr checkbox görünüşü */
.vf001-choice {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.vf001-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.vf001-choice span {
    display: block;
    width: 13px;
    height: 13px;
    border: 1px solid #111827;
    background: #ffffff;
}

.vf001-choice input:checked + span {
    position: relative;
    background: #438cf3;
}

.vf001-choice input:checked + span::after {
    position: absolute;
    top: 1px;
    left: 4px;
    width: 3px;
    height: 7px;
    content: "";
    border-right: 2px solid #ffffff;
    border-bottom: 2px solid #ffffff;
    transform: rotate(45deg);
}

/* Validasiya qeydləri */
.vf001-validation-records {
    min-height: 116px;
    padding: 5px;
    border: 1px solid #111827;
    border-top: 0;
}

.vf001-validation-records h3,
.vf001-justified-notes h3 {
    margin: 0 0 7px;
    font-size: 9px;
    font-weight: 700;
}

.vf001-record-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px 14px;
}

.vf001-record-grid label {
    display: grid;
    gap: 3px;
}

.vf001-record-grid span {
    font-size: 8px;
}

.vf001-record-grid input {
    width: 100%;
    padding: 3px 4px;
    font: inherit;
    font-size: 8px;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #111827;
    outline: none;
}

/* Əsaslandırılmış qeydlər */
.vf001-justified-notes {
    min-width: 0;
    min-height: 556px;
    border: 1px solid #111827;
    border-left: 0;
}

.vf001-justified-notes h3 {
    height: 24px;
    margin: 0;
    padding: 5px;
    text-align: center;
    border-bottom: 1px solid #111827;
}

.vf001-justified-notes textarea {
    display: block;
    width: 100%;
    height: calc(100% - 24px);
    min-height: 530px;
    padding: 8px;
    color: #111827;
    font: inherit;
    font-size: 9px;
    line-height: 1.4;
    background: transparent;
    border: 0;
    outline: none;
    resize: none;
}

.vf001-justified-notes textarea:focus {
    background: rgba(67, 140, 243, 0.06);
}

/* İmza və möhür */
.vf001-approval-section {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 25px 55px 125px;
}

/* İkinci səhifə */
.vf001-second-page-content {
    position: relative;
    z-index: 2;
    padding: 22px 0 130px;
}

.vf001-second-page-content h3 {
    margin: 0 0 10px;
    font-size: 11px;
}

.vf001-second-page-content > textarea {
    display: block;
    width: 100%;
    min-height: 500px;
    padding: 10px;
    color: #111827;
    font: inherit;
    font-size: 10px;
    line-height: 1.45;
    background: transparent;
    border: 1px solid #111827;
    outline: none;
    resize: vertical;
}

.vf001-second-signoff {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 25px;
    margin-top: 24px;
}

.vf001-second-signoff label {
    display: grid;
    gap: 4px;
}

.vf001-second-signoff span {
    font-size: 9px;
    font-weight: 600;
}

.vf001-second-signoff input,
.vf001-second-signoff select {
    width: 100%;
    padding: 5px;
    font: inherit;
    font-size: 9px;
    background: transparent;
    border: 1px solid #94a3b8;
    outline: none;
}

.vf001-second-approval {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;
    margin: 45px 55px 0;
}

/* Footer */
.vf001-document-footer {
    position: absolute;
    right: 54px;
    bottom: 36px;
    left: 20px;
    z-index: 2;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
    color: #64748b;
    font-size: 8px;
}

.vf001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.vf001-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.vf001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 7px;
}

/* Çap və PDF */
@media print {
    .vf001-editor-wrapper {
        display: block;
        padding: 0;
        background: #ffffff;
    }

    .vf001-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        box-shadow: none;
        page-break-after: always;
        break-after: page;
    }

    .vf001-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .vf001-meta-table input,
    .vf001-questions-table textarea,
    .vf001-record-grid input,
    .vf001-justified-notes textarea,
    .vf001-second-page-content textarea,
    .vf001-second-signoff input,
    .vf001-second-signoff select {
        box-shadow: none !important;
    }
}



/* =====================================================
   HASSP VF-002 — VERİFİKASİYA FORMASI
===================================================== */

.vf002-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.vf002-document {
    position: relative;
    overflow: hidden;

    /* Footer üçün təhlükəsiz aşağı boşluq */
    padding-bottom: 135px;
}

/* =====================================================
   SƏNƏD BAŞLIĞI
===================================================== */

.vf002-document-header {
    position: relative;
    z-index: 2;

    display: grid;
    grid-template-columns: 135px minmax(0, 1fr) 225px;

    min-height: 94px;

    border: 1px solid #111827;
}

.vf002-logo-box,
.vf002-title-box {
    display: flex;
    align-items: center;
    justify-content: center;

    padding: 12px;

    border-right: 1px solid #111827;
}

.vf002-logo-box .document-logo {
    display: block;

    width: 110px;
    max-width: 100%;
    height: auto;

    object-fit: contain;
}

.vf002-title-box {
    text-align: center;
}

.vf002-title-box h2 {
    display: flex;
    flex-direction: column;

    margin: 0;

    color: #374151;

    font-size: 17px;
    font-weight: 600;
    line-height: 1.2;
}

.vf002-title-box h2 span {
    margin-top: 3px;

    font-size: 14px;
}

/* =====================================================
   SƏNƏD REKVİZİTLƏRİ
===================================================== */

.vf002-meta-table {
    width: 100%;

    border-collapse: collapse;
    table-layout: fixed;

    font-size: 9px;
}

.vf002-meta-table th,
.vf002-meta-table td {
    height: 19px;

    padding: 2px 5px;

    border-bottom: 1px solid #111827;

    text-align: left;
    vertical-align: middle;
}

.vf002-meta-table tr:last-child th,
.vf002-meta-table tr:last-child td {
    border-bottom: 0;
}

.vf002-meta-table th {
    width: 58%;

    font-weight: 500;
}

.vf002-meta-table td {
    width: 42%;
}

.vf002-meta-table input {
    display: block;

    width: 100%;
    min-width: 0;
    min-height: 18px;

    padding: 1px 3px;

    color: #111827;

    font: inherit;

    background: transparent;

    border: 0;
    outline: none;
}

.vf002-meta-table input:focus {
    background: rgba(67, 140, 243, 0.08);

    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.25);
}

/* =====================================================
   GİRİŞ MƏTNİ
===================================================== */

.vf002-intro {
    position: relative;
    z-index: 2;

    margin: 14px 0 10px;

    color: #111827;

    font-size: 8px;
    line-height: 1.35;
}

.vf002-intro p {
    margin: 0 0 5px;
}

/* =====================================================
   ƏSAS VERİFİKASİYA CƏDVƏLİ
===================================================== */

.vf002-main-table {
    position: relative;
    z-index: 2;

    width: 100%;

    border-collapse: collapse;
    table-layout: fixed;

    font-size: 7px;
}

.vf002-main-table th,
.vf002-main-table td {
    padding: 0;

    border: 1px solid #111827;

    vertical-align: middle;
}

.vf002-main-table th {
    height: 24px;

    padding: 3px;

    font-weight: 700;
    text-align: center;
    line-height: 1.15;

    white-space: normal;
    overflow-wrap: anywhere;
}

/* Sütun ölçüləri */
.vf002-main-table th:nth-child(1) {
    width: 36%;
}

.vf002-main-table th:nth-child(2),
.vf002-main-table th:nth-child(3) {
    width: 6%;
}

.vf002-main-table th:nth-child(4) {
    width: 52%;
}

/* Birinci səhifə sətirləri */
.vf002-main-table td {
    height: 58px;
}

.vf002-main-table textarea {
    display: block;

    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 57px;

    padding: 5px;

    color: #111827;

    font: inherit;
    line-height: 1.3;

    background: transparent;

    border: 0;
    outline: none;

    resize: none;
    overflow: hidden;
}

.vf002-main-table textarea:focus {
    background: rgba(67, 140, 243, 0.07);

    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.22);
}

/* Sağ tərəfdə sualın başlığı */
.vf002-detail-label {
    display: block;

    min-height: 20px;

    padding: 4px 5px;

    font-weight: 500;
    line-height: 1.25;

    border-bottom: 1px solid #111827;
}


/* =====================================================
   BİRİNCİ SƏHİFƏ — XÜSUSİ DÜZƏLİŞ
===================================================== */

.vf002-page:first-child {
    padding-bottom: 150px;
}

.vf002-page:first-child .vf002-intro {
    margin: 9px 0 7px;
    font-size: 7.3px;
    line-height: 1.22;
}

.vf002-page:first-child .vf002-intro p {
    margin-bottom: 3px;
}

.vf002-page:first-child .vf002-main-table th {
    height: 22px;
    padding: 2px 3px;
}

.vf002-page:first-child .vf002-main-table td {
    height: 55px;
}

.vf002-page:first-child .vf002-main-table textarea {
    min-height: 54px;
    padding: 4px;
    line-height: 1.2;
}

.vf002-page:first-child .vf002-detail-label {
    min-height: 18px;
    padding: 3px 4px;
    line-height: 1.15;
}

.vf002-page:first-child .vf002-document-footer {
    position: static !important;
    margin: 18px 20px 0 !important;
}

/* =====================================================
   BƏLİ / XEYR CHECKBOX
===================================================== */

.vf002-check {
    position: relative;

    display: grid;
    place-items: center;

    width: 100%;
    height: 100%;

    cursor: pointer;
}

.vf002-check input {
    position: absolute;

    opacity: 0;
    pointer-events: none;
}

.vf002-check span {
    display: block;

    width: 13px;
    height: 13px;

    background: #ffffff;

    border: 1px solid #111827;
}

.vf002-check input:checked + span {
    position: relative;

    background: #438cf3;
}

.vf002-check input:checked + span::after {
    position: absolute;
    top: 1px;
    left: 4px;

    width: 3px;
    height: 7px;

    content: "";

    border-right: 2px solid #ffffff;
    border-bottom: 2px solid #ffffff;

    transform: rotate(45deg);
}

/* =====================================================
   İKİNCİ SƏHİFƏ CƏDVƏLİ
===================================================== */

.vf002-page-two-table {
    margin-top: 14px;
}

/* İkinci səhifədə sətirləri yığcam saxlayırıq */
.vf002-page-two-table td {
    height: 74px;
}

.vf002-page-two-table textarea {
    min-height: 73px;
}

/* =====================================================
   QEYDLƏR BLOKU
===================================================== */

.vf002-notes-block {
    position: relative;
    z-index: 2;

    margin-bottom: 125px;

    border: 1px solid #111827;
    border-top: 0;
}

.vf002-notes-block h3 {
    height: 25px;

    margin: 0;
    padding: 5px;

    font-size: 8px;
    font-weight: 700;
    text-align: center;

    border-bottom: 1px solid #111827;
}

.vf002-notes-block textarea {
    display: block;

    width: 100%;
    min-height: 82px;

    padding: 7px;

    color: #111827;

    font: inherit;
    font-size: 8px;
    line-height: 1.35;

    background: transparent;

    border: 0;
    outline: none;

    resize: none;
    overflow: hidden;
}

.vf002-notes-block textarea:focus {
    background: rgba(67, 140, 243, 0.06);
}

/* =====================================================
   ÜÇÜNCÜ SƏHİFƏ
===================================================== */

.vf002-third-page-content {
    position: relative;
    z-index: 2;

    padding: 25px 0 150px;
}

.vf002-final-notes h3,
.vf002-result-section h3 {
    margin: 0 0 8px;

    font-size: 11px;
    font-weight: 700;
}

.vf002-final-notes textarea {
    display: block;

    width: 100%;
    min-height: 390px;

    padding: 10px;

    color: #111827;

    font: inherit;
    font-size: 9px;
    line-height: 1.4;

    background: transparent;

    border: 1px solid #111827;
    outline: none;

    resize: vertical;
}

.vf002-final-notes textarea:focus {
    background: rgba(67, 140, 243, 0.06);
}

/* Nəticə seçimləri */
.vf002-result-section {
    display: grid;
    gap: 8px;

    margin-top: 22px;
}

.vf002-result-section label {
    display: flex;
    align-items: flex-start;
    gap: 8px;

    font-size: 9px;
}

.vf002-result-section input {
    margin-top: 1px;
}

/* =====================================================
   İMZA MƏLUMATLARI
===================================================== */

.vf002-signoff-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 24px;

    margin-top: 24px;
}

.vf002-signoff-grid label {
    display: grid;
    gap: 4px;
}

.vf002-signoff-grid span {
    font-size: 9px;
    font-weight: 600;
}

.vf002-signoff-grid input {
    width: 100%;
    min-width: 0;

    padding: 5px;

    font: inherit;
    font-size: 9px;

    background: transparent;

    border: 0;
    border-bottom: 1px solid #111827;

    outline: none;
}

.vf002-signoff-grid input:focus {
    background: rgba(67, 140, 243, 0.06);

    border-bottom-color: #438cf3;
}

/* =====================================================
   İMZA VƏ MÖHÜR
===================================================== */

.vf002-approval-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px;

    margin: 42px 55px 0;
}

/* =====================================================
   FOOTER
===================================================== */

.vf002-document-footer {
    position: absolute;

    right: 54px;
    bottom: 30px;
    left: 20px;

    z-index: 5;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;

    padding-top: 4px;

    color: #64748b;

    font-size: 8px;

    background: #ffffff;
}

.vf002-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.vf002-document-footer strong {
    font-size: 9px;
    font-weight: 500;
}

.vf002-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;

    font-size: 7px;
}

/* =====================================================
   MOBİL GÖRÜNÜŞ
===================================================== */

@media (max-width: 900px) {
    .vf002-signoff-grid {
        grid-template-columns: 1fr;
    }

    .vf002-approval-section {
        gap: 20px;

        margin-right: 0;
        margin-left: 0;
    }
}

/* =====================================================
   ÇAP VƏ PDF
===================================================== */

@media print {
    .vf002-editor-wrapper {
        display: block;

        padding: 0;

        background: #ffffff;
    }

    .vf002-page {
        width: 210mm;
        min-height: 297mm;

        margin: 0;

        box-shadow: none;

        page-break-after: always;
        break-after: page;
    }

    .vf002-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .vf002-document {
        padding-bottom: 135px;
    }

    .vf002-meta-table input,
    .vf002-main-table textarea,
    .vf002-notes-block textarea,
    .vf002-final-notes textarea,
    .vf002-signoff-grid input {
        box-shadow: none !important;
    }

    .vf002-document-footer {
        bottom: 28px;

        background: #ffffff;
    }
}




/* =====================================================
   HASSP HZS-001 — HACCP SİSTEMİ ÜZRƏ ZƏRURİ SƏNƏDLƏR
===================================================== */

/* Bütün HZS elementlərində ölçüyə padding daxil edilir */
.hzs001-editor-wrapper,
.hzs001-editor-wrapper *,
.hzs001-editor-wrapper *::before,
.hzs001-editor-wrapper *::after {
    box-sizing: border-box;
}

/* Səhifələrin ümumi konteyneri */
.hzs001-editor-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;

    width: 100%;
    max-width: 100%;

    padding: 30px 20px 60px;

    overflow-x: auto;
}

/* =====================================================
   A4 SƏHİFƏ
===================================================== */

.hzs001-page {
    position: relative;

    flex: 0 0 auto;

    width: 210mm !important;
    max-width: 210mm !important;
    min-width: 210mm !important;

    min-height: 297mm !important;

    margin: 0 auto !important;
    padding: 18mm 16mm 30mm !important;

    overflow: hidden;

    background: #ffffff;

    box-shadow: 0 10px 35px rgba(15, 23, 42, 0.12);
}

/* Watermark səhifədən çıxmasın */
.hzs001-page .document-watermark {
    position: absolute;

    top: 50%;
    left: 50%;

    z-index: 0;

    width: 430px;
    max-width: 58%;
    height: auto;

    opacity: 0.055;

    pointer-events: none;

    transform: translate(-50%, -50%);
}

/* =====================================================
   SƏNƏD HEADER
===================================================== */

.hzs001-document-header {
    position: relative;
    z-index: 2;

    display: grid;
    grid-template-columns: 125px minmax(0, 1fr) 205px;

    width: 100%;
    max-width: 100%;
    min-height: 92px;

    overflow: hidden;

    border: 1px solid #111827;
}

.hzs001-logo-box,
.hzs001-title-box {
    display: flex;
    align-items: center;
    justify-content: center;

    min-width: 0;

    padding: 10px;

    border-right: 1px solid #111827;
}

.hzs001-logo-box .document-logo {
    display: block;

    width: 100px;
    max-width: 100%;
    height: auto;
    max-height: 70px;

    object-fit: contain;
}

.hzs001-title-box {
    text-align: center;
}

.hzs001-title-box h2 {
    width: 100%;
    max-width: 100%;

    margin: 0;

    color: #374151;

    font-size: 16px;
    font-weight: 600;
    line-height: 1.25;

    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;

    outline: none;
}

/* =====================================================
   META CƏDVƏLİ
===================================================== */

.hzs001-meta-table {
    width: 100%;
    max-width: 100%;

    border-collapse: collapse;
    table-layout: fixed;

    font-size: 8px;
}

.hzs001-meta-table th,
.hzs001-meta-table td {
    height: 18px;

    padding: 2px 4px;

    border-bottom: 1px solid #111827;

    text-align: left;
    vertical-align: middle;

    overflow: hidden;
}

.hzs001-meta-table tr:last-child th,
.hzs001-meta-table tr:last-child td {
    border-bottom: 0;
}

.hzs001-meta-table th {
    width: 54%;

    font-weight: 500;
}

.hzs001-meta-table td {
    width: 46%;
}

.hzs001-meta-table input {
    display: block;

    width: 100%;
    min-width: 0;
    max-width: 100%;
    min-height: 16px;

    padding: 1px 2px;

    color: #111827;

    font: inherit;

    background: transparent;

    border: 0;
    outline: none;
}

/* =====================================================
   SƏHİFƏ MƏZMUNU
===================================================== */

.hzs001-page-content {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 100%;
}

.hzs001-main-title,
.hzs001-trace-title {
    width: 100%;

    margin: 17px 0 11px;

    text-align: center;

    font-size: 12px;
    font-weight: 700;
    line-height: 1.3;

    white-space: normal;
    overflow-wrap: anywhere;

    outline: none;
}

/* =====================================================
   ƏSAS CƏDVƏL
===================================================== */

.hzs001-table-wrapper {
    width: 100%;
    max-width: 100%;

    margin-top: 12px;

    overflow: hidden;
}

.hzs001-main-table,
.hzs001-trace-table {
    width: 100% !important;
    max-width: 100% !important;

    border-collapse: collapse;
    table-layout: fixed;

    font-size: 6.7px;
    line-height: 1.2;
}

/* Sütun ölçüləri */
.hzs001-main-table .col-no {
    width: 6%;
}

.hzs001-main-table .col-name {
    width: 20%;
}

.hzs001-main-table .col-desc {
    width: 35%;
}

.hzs001-main-table .col-step {
    width: 16%;
}

.hzs001-main-table .col-docs {
    width: 23%;
}

.hzs001-main-table th,
.hzs001-main-table td,
.hzs001-trace-table th,
.hzs001-trace-table td {
    min-width: 0;

    border: 1px solid #111827;

    vertical-align: top;

    overflow: hidden;
}

.hzs001-main-table th {
    padding: 4px 3px;

    text-align: center;

    font-size: 7px;
    font-weight: 700;
    line-height: 1.15;

    white-space: normal;
    overflow-wrap: anywhere;
}

.hzs001-main-table td {
    padding: 0;
}

.hzs001-main-table td > div,
.hzs001-trace-table th > div,
.hzs001-trace-table td > div {
    display: block;

    width: 100%;
    min-width: 0;
    max-width: 100%;
    min-height: 100%;

    padding: 5px 4px;

    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;

    outline: none;
}

.hzs001-main-table td:first-child > div {
    text-align: center;

    font-weight: 600;
}

.hzs001-main-table td:nth-child(4) > div,
.hzs001-main-table td:nth-child(5) > div {
    text-align: center;
}

/* Sətirə min-height td ilə yox, daxili div ilə verilir */
.hzs001-data-row > td > div {
    min-height: 82px;
}

.hzs001-data-row.continuation-row td:first-child,
.hzs001-data-row.continuation-row td:nth-child(2),
.hzs001-data-row.continuation-row td:nth-child(4) {
    background: rgba(241, 245, 249, 0.45);
}

/* =====================================================
   QEYD
===================================================== */

.hzs001-note {
    width: 100%;
    max-width: 100%;

    margin-top: 14px;
    padding: 9px 10px;

    font-size: 8px;
    line-height: 1.4;

    border: 1px solid #111827;

    white-space: normal;
    overflow-wrap: anywhere;

    outline: none;
}

/* =====================================================
   İZLƏNİLMƏ CƏDVƏLİ
===================================================== */

.hzs001-trace-table {
    margin-top: 18px;

    font-size: 8.5px;
}

.hzs001-trace-table th {
    width: 26%;

    padding: 0;

    text-align: center;
    vertical-align: middle;
}

.hzs001-trace-table td {
    width: 74%;

    padding: 0;
}

.hzs001-trace-table th > div,
.hzs001-trace-table td > div {
    min-height: 145px;

    padding: 10px;

    line-height: 1.4;
}

/* =====================================================
   İMZA VƏ MÖHÜR
===================================================== */

.hzs001-approval-section {
    position: relative;
    z-index: 2;

    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 50px;

    margin: 45px 40px 115px;
}

.hzs001-approval-section .signature-column {
    min-width: 0;
}

/* =====================================================
   FOOTER
===================================================== */

.hzs001-document-footer {
    position: absolute;

    right: 16mm;
    bottom: 12mm;
    left: 16mm;

    z-index: 3;

    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;

    color: #64748b;

    font-size: 8px;

    background: #ffffff;
}

.hzs001-document-footer div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hzs001-document-footer strong {
    font-size: 8.5px;
    font-weight: 500;
}

.hzs001-document-footer small {
    display: flex;
    align-items: center;
    gap: 4px;

    font-size: 7px;
}

.hzs001-document-footer > span {
    flex: 0 0 auto;

    white-space: nowrap;
}

/* Redaktə edilən element */
.hzs001-page [contenteditable="true"]:focus {
    background: rgba(67, 140, 243, 0.08);

    box-shadow: inset 0 0 0 1px rgba(67, 140, 243, 0.2);
}

/* =====================================================
   KİÇİK EKRAN
===================================================== */

@media (max-width: 1100px) {
    .hzs001-editor-wrapper {
        align-items: flex-start;

        padding-right: 15px;
        padding-left: 15px;
    }

    .hzs001-page {
        margin-right: auto !important;
        margin-left: auto !important;
    }
}

/* =====================================================
   ÇAP VƏ PDF
===================================================== */

@media print {
    .hzs001-editor-wrapper {
        display: block;

        width: auto;

        padding: 0;

        overflow: visible;

        background: #ffffff;
    }

    .hzs001-page {
        width: 210mm !important;
        min-width: 210mm !important;
        max-width: 210mm !important;

        min-height: 297mm !important;

        margin: 0 !important;

        padding: 18mm 16mm 30mm !important;

        box-shadow: none !important;

        page-break-after: always;
        break-after: page;
    }

    .hzs001-page:last-child {
        page-break-after: auto;
        break-after: auto;
    }

    .hzs001-document-footer {
        bottom: 12mm;
    }

    .hzs001-meta-table input,
    .hzs001-page [contenteditable="true"] {
        box-shadow: none !important;
    }
}



/* =====================================================
   HZS-001 — SƏHİFƏ MƏZMUNUNU DÜZGÜN UZAT
===================================================== */

.hzs001-page {
    display: flex;
    flex-direction: column;
}

.hzs001-document-header {
    flex: 0 0 auto;
}

.hzs001-page-content {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

/* Cədvəl səhifədə mövcud sahəni doldursun */
.hzs001-table-wrapper {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

.hzs001-main-table {
    height: auto;
}

/* Hər səhifədəki son sətir bir az uzansın */
.hzs001-main-table tbody tr:last-child td > div {
    min-height: 180px;
}

/* 1-ci səhifədə ikinci sətir daha hündür olsun */
.hzs001-page:nth-child(1) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 300px;
}

/* 2-ci səhifə */
.hzs001-page:nth-child(2) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 390px;
}

/* 3-cü səhifə */
.hzs001-page:nth-child(3) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 330px;
}

/* 4-cü səhifə */
.hzs001-page:nth-child(4) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 610px;
}

/* 5-ci səhifə */
.hzs001-page:nth-child(5) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 360px;
}

/* 6-cı səhifə */
.hzs001-page:nth-child(6) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 230px;
}

/* 7-ci səhifə */
.hzs001-page:nth-child(7) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 340px;
}

/* 8-ci səhifə */
.hzs001-page:nth-child(8) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 240px;
}

/* 9-cu səhifə */
.hzs001-page:nth-child(9) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 390px;
}

/* 10-cu səhifə */
.hzs001-page:nth-child(10) .hzs001-main-table tbody tr:last-child td > div {
    min-height: 500px;
}

/* Footer həmişə aşağıda qalsın */
.hzs001-document-footer {
    position: absolute;
    right: 16mm;
    bottom: 12mm;
    left: 16mm;
}



/* =====================================================
   HZS-001 — ŞRİFT VƏ FOOTER SON DÜZƏLİŞİ
===================================================== */

/* Ümumi cədvəl şriftini böyüt */
.hzs001-main-table,
.hzs001-trace-table {
    font-size: 8px !important;
    line-height: 1.35 !important;
}

/* Cədvəl başlıqları */
.hzs001-main-table th {
    font-size: 8.5px !important;
    line-height: 1.25 !important;
    padding: 6px 4px !important;
}

/* Cədvəl mətnləri */
.hzs001-main-table td > div {
    padding: 7px 6px !important;
    font-size: 8px !important;
    line-height: 1.35 !important;
}

/* Sənədin əsas başlığı */
.hzs001-title-box h2 {
    font-size: 18px !important;
    line-height: 1.3 !important;
}

/* Cədvəlin üstündəki başlıq */
.hzs001-main-title,
.hzs001-trace-title {
    font-size: 14px !important;
    line-height: 1.35 !important;
}

/* Meta cədvəli */
.hzs001-meta-table {
    font-size: 9px !important;
}

.hzs001-meta-table th,
.hzs001-meta-table td {
    font-size: 9px !important;
}

/* Footer bir az sola və aşağı */
.hzs001-document-footer {
    left: 12mm !important;
    right: 12mm !important;
    bottom: 8mm !important;

    font-size: 9px !important;
}

/* Footer departament adı */
.hzs001-document-footer strong {
    font-size: 10px !important;
}

/* Footer email və telefon */
.hzs001-document-footer small {
    font-size: 8px !important;
}

/* Sağ tərəfdəki ad */
.hzs001-document-footer > span {
    font-size: 9px !important;
}



/* =====================================================
   SIDEBAR MENYU LINKLƏRİ
===================================================== */

.sidebar-nav .nav-item {
    display: flex;
    align-items: center;
    gap: 14px;

    width: 100%;
    min-height: 52px;

    padding: 13px 16px;

    color: #52647e;
    background: transparent;

    border: 0;
    border-radius: 14px;

    font: inherit;
    font-size: 15px;
    font-weight: 500;

    text-align: left;
    text-decoration: none;

    cursor: pointer;
    transition: 0.2s ease;
}

.sidebar-nav .nav-item i {
    flex: 0 0 22px;

    width: 22px;

    color: #60738d;

    font-size: 18px;
    text-align: center;
}

.sidebar-nav .nav-item span {
    display: block;
    line-height: 1.3;
}

.sidebar-nav .nav-item:hover {
    color: #2563eb;
    background: #f1f6ff;
    text-decoration: none;
}

.sidebar-nav .nav-item:hover i {
    color: #2563eb;
}

.sidebar-nav .nav-item.active {
    color: #2563eb;
    background: #e8f1ff;
}

.sidebar-nav .nav-item.active i {
    color: #2563eb;
}



/* =====================================================
   PDF / PRINT CHECKBOX VƏ RADIO İŞARƏLƏRİ
===================================================== */

.print-choice-mark {
    display: none;
}

@media print {
    /* Standart checkbox çapda gizlənir */
    .a4-document input[type="checkbox"],
    .a4-document input[type="radio"] {
        display: none !important;
    }

    /* Əvəzinə çap üçün sabit kvadrat göstərilir */
    .print-choice-mark {
        display: inline-flex !important;
        align-items: center;
        justify-content: center;

        width: 13px;
        height: 13px;

        color: #000000;
        background: #ffffff;

        border: 1px solid #000000;
        box-sizing: border-box;

        font-size: 11px;
        font-weight: 700;
        line-height: 1;

        vertical-align: middle;
    }

    * {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
}



/* AUTH / ADMIN */
.auth-page{min-height:100vh;display:grid;place-items:center;background:#f4f7fb;font-family:Arial,sans-serif}.auth-card{width:min(420px,90vw);padding:36px;background:#fff;border:1px solid #e2e8f0;border-radius:18px;box-shadow:0 20px 60px rgba(15,23,42,.1)}.auth-logo{font-weight:800;color:#2563eb}.auth-card h1{margin:18px 0 6px}.auth-card p{color:#64748b}.auth-card label{display:block;margin:14px 0;color:#334155;font-weight:600}.auth-card input:not([type=checkbox]),.admin-form input,.admin-form select{width:100%;box-sizing:border-box;margin-top:7px;padding:12px;border:1px solid #cbd5e1;border-radius:9px}.auth-card button,.primary-button,.primary-link{display:inline-flex;justify-content:center;padding:11px 16px;background:#2563eb;color:#fff;border:0;border-radius:9px;text-decoration:none;cursor:pointer}.auth-card button{width:100%;margin-top:12px}.auth-remember{font-weight:400!important}.auth-error{margin:12px 0;padding:10px;background:#fef2f2;color:#b91c1c;border-radius:8px}.admin-page{padding:38px;max-width:1300px}.admin-page-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:24px}.admin-page-head h1{margin:0}.admin-page-head p{color:#64748b}.admin-card,.admin-form,.setting-card{background:#fff;border:1px solid #e2e8f0;border-radius:14px;padding:20px}.admin-table{width:100%;border-collapse:collapse}.admin-table th,.admin-table td{padding:12px;border-bottom:1px solid #edf2f7;text-align:left}.row-actions{display:flex;gap:10px}.row-actions form{margin:0}.row-actions button{border:0;background:none;color:#dc2626;cursor:pointer}.admin-form{max-width:650px}.admin-form label{display:block;margin-bottom:15px}.check-row{display:flex!important;gap:8px;align-items:center}.check-row input{width:auto!important;margin:0!important}.settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.setting-card img{display:block;max-width:220px;max-height:160px;object-fit:contain;margin:20px auto}.alert-success-box{padding:12px;background:#ecfdf5;color:#166534;border-radius:9px;margin-bottom:15px}.role-chip{font-size:10px;text-transform:uppercase;background:#eef2ff;color:#3730a3;padding:4px 7px;border-radius:999px}.sign-modal{position:fixed;inset:0;background:rgba(15,23,42,.55);display:grid;place-items:center;z-index:9999}.sign-modal[hidden]{display:none}.sign-modal-card{width:min(420px,90vw);background:#fff;padding:26px;border-radius:14px}.sign-modal-card input{width:100%;box-sizing:border-box;padding:11px;margin:15px 0}.sign-modal-card>div{display:flex;justify-content:flex-end;gap:8px}.system-approval-block{position:absolute;left:70px;right:70px;bottom:55px;display:flex;justify-content:center;gap:90px;align-items:flex-end;z-index:8}.system-approval-block>div{display:flex;flex-direction:column;align-items:center;font-size:9px}.system-approval-block img{width:130px;height:80px;object-fit:contain}.system-approval-block small{margin-top:3px;color:#64748b}@media print{.system-approval-block{display:flex!important}.system-approval-block img{print-color-adjust:exact;-webkit-print-color-adjust:exact}}




/* İmza və möhür ölçüləri */
.signature-preview img {
    width: auto !important;
    height: auto !important;
    max-width: 180px !important;
    max-height: 90px !important;
    object-fit: contain !important;
}

.stamp-preview img {
    width: auto !important;
    height: auto !important;
    max-width: 125px !important;
    max-height: 125px !important;
    object-fit: contain !important;
}

/* Preview qutularında ortala */
.signature-preview,
.stamp-preview {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
/* =====================================================
   İMZA / MÖHÜR — ÇAP GÖRÜNÜŞÜ
===================================================== */
@media print {
    /* Redaktə qutularının sərhədləri PDF-də görünməsin. */
    .a4-document .signature-preview,
    .a4-document .stamp-preview {
        border: 0 !important;
        outline: 0 !important;
        box-shadow: none !important;
        background: transparent !important;
    }

    /* İmza və möhür əlavə etmə düymələri PDF-də görünməsin. */
    .a4-document button[data-approval-type],
    .a4-document [data-add-signature],
    .a4-document [data-add-stamp] {
        display: none !important;
    }

    .a4-document .approval-preview-image {
        print-color-adjust: exact !important;
        -webkit-print-color-adjust: exact !important;
    }
}


/* FINAL: imza və möhür ayrı preview-larda */
.approval-signature-image {
    display: block;
    width: auto !important;
    height: auto !important;
    max-width: 180px !important;
    max-height: 90px !important;
    object-fit: contain !important;
}

.approval-stamp-image {
    display: block;
    width: auto !important;
    height: auto !important;
    max-width: 125px !important;
    max-height: 125px !important;
    object-fit: contain !important;
}

[data-approval-preview="signature"],
[data-approval-preview="stamp"] {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

@media print {
    [data-approval-preview="signature"],
    [data-approval-preview="stamp"] {
        border: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    [data-approval-type] {
        display: none !important;
    }
}
