/**
 * Inventory Manager Pro - Frontend Styles
 *
 * @package Inventory_Manager_Pro
 * @since 1.0.0
 */

/* =====================================================
   VARIABLES & BASE
   ===================================================== */

:root {
    --invpro-primary: #2271b1;
    --invpro-success: #00a32a;
    --invpro-danger: #d63638;
    --invpro-warning: #dba617;
    --invpro-gray-100: #f3f4f6;
    --invpro-gray-200: #e5e7eb;
    --invpro-gray-300: #d1d5db;
    --invpro-gray-500: #6b7280;
    --invpro-gray-700: #374151;
    --invpro-gray-900: #111827;
    --invpro-radius: 6px;
    --invpro-shadow: 0 10px 25px rgba(0,0,0,.1);
}

.invpro-frontend {
    font-family: Tahoma, "Segoe UI", sans-serif;
    direction: rtl;
    color: var(--invpro-gray-900);
}

/* =====================================================
   REQUEST FORM
   ===================================================== */

.invpro-request-form {
    max-width: 700px;
    margin: 30px auto;
    background: #fff;
    border-radius: var(--invpro-radius);
    box-shadow: var(--invpro-shadow);
    padding: 25px;
    border: 1px solid var(--invpro-gray-200);
}

.invpro-request-form h3 {
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: bold;
    color: var(--invpro-primary);
}

.invpro-form-group {
    margin-bottom: 18px;
}

.invpro-form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: bold;
    font-size: 13px;
}

.invpro-form-group input,
.invpro-form-group textarea,
.invpro-form-group select {
    width: 100%;
    padding: 10px 12px;
    border-radius: var(--invpro-radius);
    border: 1px solid var(--invpro-gray-300);
    font-size: 14px;
}

.invpro-form-group input:focus,
.invpro-form-group textarea:focus,
.invpro-form-group select:focus {
    outline: none;
    border-color: var(--invpro-primary);
    box-shadow: 0 0 0 2px rgba(34,113,177,.2);
}

/* =====================================================
   ITEM SEARCH (FRONTEND)
   ===================================================== */

.invpro-item-search-wrapper {
    position: relative;
}

.invpro-item-results {
    position: absolute;
    width: 100%;
    background: #fff;
    z-index: 999;
    border: 1px solid var(--invpro-gray-300);
    border-top: none;
    max-height: 250px;
    overflow-y: auto;
    display: none;
}

.invpro-item-results .invpro-item {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid var(--invpro-gray-100);
}

.invpro-item-results .invpro-item:hover {
    background: var(--invpro-gray-100);
}

.invpro-item strong {
    color: var(--invpro-primary);
    font-family: monospace;
}

/* =====================================================
   SUBMIT BUTTON
   ===================================================== */

.invpro-submit-btn {
    background: var(--invpro-primary);
    color: #fff;
    padding: 12px 20px;
    border-radius: var(--invpro-radius);
    border: none;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
}

.invpro-submit-btn:hover {
    background: #135e96;
}

/* =====================================================
   USER REQUESTS TABLE
   ===================================================== */

.invpro-user-requests {
    margin: 40px auto;
    max-width: 900px;
}

.invpro-user-requests table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: var(--invpro-radius);
    overflow: hidden;
    box-shadow: var(--invpro-shadow);
}

.invpro-user-requests th,
.invpro-user-requests td {
    padding: 12px 15px;
    font-size: 13px;
    text-align: center;
    border-bottom: 1px solid var(--invpro-gray-200);
}

.invpro-user-requests th {
    background: var(--invpro-gray-100);
    color: var(--invpro-gray-700);
}

.invpro-status {
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: bold;
}

.invpro-status.pending {
    background: #fff7ed;
    color: #9a3412;
}

.invpro-status.approved {
    background: #ecfdf5;
    color: #065f46;
}

.invpro-status.rejected {
    background: #fef2f2;
    color: #991b1b;
}

/* =====================================================
   RECEIPT MODAL
   ===================================================== */

.invpro-receipt-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    display: none;
    z-index: 99999;
    align-items: center;
    justify-content: center;
}

.invpro-receipt-content {
    background: #fff;
    max-width: 900px;
    width: 95%;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: var(--invpro-radius);
    padding: 20px;
    position: relative;
}

.invpro-receipt-close {
    position: absolute;
    top: 10px;
    left: 10px;
    background: transparent;
    border: none;
    font-size: 18px;
    cursor: pointer;
}

/* =====================================================
   MOBILE
   ===================================================== */

@media (max-width: 640px) {
    .invpro-request-form,
    .invpro-user-requests {
        margin: 15px;
    }

    .invpro-user-requests table {
        font-size: 12px;
    }
}
