/* Global application styles */

/* IBM Plex Sans Arabic - Self-hosted */
@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-300-arabic.woff2') format('woff2');
    unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 300;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-300-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-400-arabic.woff2') format('woff2');
    unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-400-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-500-arabic.woff2') format('woff2');
    unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-500-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-600-arabic.woff2') format('woff2');
    unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-600-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-700-arabic.woff2') format('woff2');
    unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
    font-family: 'IBM Plex Sans Arabic';
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url('fonts/IBMPlexSansArabic-700-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
    --rz-text-font-family: 'IBM Plex Sans Arabic', sans-serif;
}

html, body {
    font-family: 'IBM Plex Sans Arabic', sans-serif;
}

/* Modal form label styling */
.modal-label {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

/* Modal action button row */
.modal-actions {
    flex-shrink: 0;
    padding-top: 1rem;
}

/* Modal action button */
.modal-btn {
    width: 100%;
    font-size: 0.9rem;
}

/* Empty state card */
.empty-state-card {
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed var(--rz-border-color);
    border-radius: 12px;
}

/* Validation error message */
.field-validation-error {
    color: var(--rz-danger);
    font-size: 12px;
    margin-top: 4px;
}

/* Image upload input */
.image-upload-input {
    width: 100%;
    padding: 0.5rem;
    border: 2px dashed var(--rz-border-color);
    border-radius: 8px;
    background-color: var(--rz-base-background-color);
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.image-upload-input:hover {
    border-color: var(--rz-primary);
}

/* Card group consistent spacing */
.rz-card-group {
    gap: 12px;
}

/* Stat card hover effect */
.stat-card {
    transition: transform 0.15s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
}

/* Navigation card polish */
.nav-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 2px solid var(--rz-border-color);
}

.nav-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border-color: var(--rz-primary);
}

/* Vendor card hover */
.vendor-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.vendor-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15) !important;
}


/* DataGrid empty template */
.rz-data-grid .rz-datatable-emptymessage td {
    padding: 2rem 1rem;
}

/* Better badge pill style */
.rz-badge {
    font-weight: 500;
}

/* Info card label style */
.info-card-label {
    color: var(--rz-text-secondary-color);
    font-size: 0.85rem;
}

.info-card-value {
    font-weight: 600;
    font-size: 1rem;
}

/* ========== Mobile Responsive ========== */
@media (max-width: 768px) {
    /* Stat cards: 2 per row on mobile */
    .rz-card-group {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .rz-card-group > .rz-card {
        width: 100% !important;
        min-width: unset !important;
    }

    /* Tighter card padding on mobile */
    .stat-card {
        padding: 0.75rem;
    }

    .stat-card .rz-icon {
        font-size: 1.5rem !important;
    }


    /* Compact page titles */
    .rz-text-h4 {
        font-size: 1.25rem;
    }

    /* Better touch targets on mobile */
    .rz-button-sm {
        min-height: 36px;
        min-width: 36px;
    }

    /* Navigation cards grid: 2 columns on mobile */
    .nav-card {
        padding: 1rem;
    }

    .nav-card .rz-icon {
        font-size: 2.5rem !important;
    }

    /* Vendor card compact */
    .vendor-card {
        margin-bottom: 12px !important;
    }

    /* Inspection card footer wraps nicely */
    .rz-card .rz-stack[style*="margin-bottom"] {
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    /* Even smaller screens: single column stat cards */
    .rz-card-group {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Smaller icons on very small screens */
    .stat-card .rz-icon {
        font-size: 1.25rem !important;
    }

    .info-card-value {
        font-size: 0.9rem;
    }

    /* Ensure buttons don't overflow */
    .rz-button {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}
