/* 
   GYM PRO CORE STYLES V3 
   Extracted for Performance and Modularization
*/
:root {
  --g-bg: #020617;
  --g-surface: rgba(30, 41, 59, 0.65);
  --g-surface-hover: rgba(51, 65, 85, 0.85);
  --g-border: rgba(255, 255, 255, 0.08);
  --g-primary: #10b981;
  --g-primary-glow: rgba(16, 185, 129, 0.35);
  --g-text: #f8fafc;
  --g-glass-blur: blur(16px);
  --g-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.6);
}

/* UTILITY CLASSES (Design System) */
.g-card-primary {
  background: var(--g-surface);
  border: 1px solid var(--g-border);
  border-radius: 20px;
  padding: 25px;
  backdrop-filter: var(--g-glass-blur);
  -webkit-backdrop-filter: var(--g-glass-blur);
  box-shadow: var(--g-shadow);
  color: var(--g-text);
  transition: all 0.3s ease;
}

.g-card-primary:hover {
  background: var(--g-surface-hover);
  border-color: rgba(16, 185, 129, 0.2);
}

.g-btn-success {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #fff;
  border: none;
  border-radius: 12px;
  padding: 12px 25px;
  font-weight: 900;
  font-size: 1.1rem;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.g-btn-success:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
}

.g-flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

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

/* SIDEBAR SYSTEM */
.g-sidebar-icon { font-size: 2.5rem; line-height: 1; }
.g-sidebar-title { font-weight: 900; font-size: 1.2rem; color: var(--g-primary); margin-top: 15px; letter-spacing: -0.5px; }
.g-sidebar-subtitle { font-size: 0.8rem; color: #64748b; margin-top: 5px; font-weight: bold; }
.g-sidebar-footer { padding: 20px; border-top: 1px solid var(--g-border); background: rgba(0,0,0,0.1); text-align: center; flex-shrink: 0; padding-bottom: max(20px, env(safe-area-inset-bottom)); }
.g-sidebar-user { margin-bottom: 15px; display: flex; flex-direction: column; align-items: center; }
.g-sidebar-avatar { width: 45px; height: 45px; border-radius: 50%; background: linear-gradient(135deg, #38bdf8, #3b82f6); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: bold; margin-bottom: 8px; font-size: 1.5rem; box-shadow: 0 4px 10px rgba(56,189,248,0.3); }
.g-sidebar-name { color: var(--g-text); font-weight: bold; font-size: 0.95rem; margin-bottom: 2px; }
.g-sidebar-email { color: #94a3b8; font-size: 0.75rem; word-break: break-all; }
.g-sidebar-badge { background: var(--g-surface); padding: 6px 15px; border-radius: 12px; font-size: 0.75rem; font-weight: bold; color: var(--g-primary); border: 1px solid var(--g-border); margin-bottom: 12px; display: inline-block; }
.g-btn-settings { font-size: 0.8rem; width: 100%; padding: 8px 12px !important; display: block; text-align: center; margin-bottom: 8px; background: linear-gradient(135deg, #3b82f6, #1d4ed8); border: none; font-weight: bold; cursor: pointer; color: #fff; border-radius: 12px; }
.g-btn-logout { font-size: 0.8rem; width: 100%; padding: 8px 12px !important; display: block; text-align: center; text-decoration: none; border-radius: 12px; }

/* 
============================================
NEW DESIGN SYSTEM CLASSES
============================================
*/

/* --- MODALS --- */
.g-modal-overlay { position:fixed; top:0; left:0; width:100%; height:100%; background:rgba(2, 6, 23, 0.95); z-index:999999999; display:none; flex-direction:column; align-items:center; justify-content:center; backdrop-filter:blur(10px); padding:20px; direction:rtl; overflow-y:auto; }
.g-modal-box { background:var(--g-surface); width:100%; max-width:450px; border-radius:24px; padding:35px; box-shadow:var(--g-shadow); border:1px solid var(--g-border); text-align:right; position:relative; }
.g-modal-title { margin:0; font-size:2rem; color:var(--g-primary); font-weight:900; }
.g-modal-subtitle { margin:0; padding-right:20px; color:#cbd5e1; font-size:0.9rem; line-height:1.6; }

/* --- FORMS & INPUTS --- */
.g-input-field { background:#0f172a !important; border:2px solid #334155 !important; border-radius:12px !important; padding:15px !important; color:#fff !important; font-weight:900 !important; font-size:1.1rem !important; width:100%; margin-bottom:25px; outline:none; }
.g-input-field:focus { border-color:var(--g-primary) !important; box-shadow:0 0 10px var(--g-primary-glow) !important; }
.g-input-label { display:block; font-size:0.85rem; color:#cbd5e1; margin-bottom:5px; font-weight:bold; }
.g-list-box { background:#1e293b; padding:15px; border-radius:15px; max-height:150px; overflow-y:auto; border:1px solid rgba(255,255,255,0.05); }

/* --- PANELS & LAYOUT --- */
.g-panel-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:25px; flex-wrap:wrap; gap:15px; position:relative; z-index:2; }
.g-chart-box { background:rgba(30, 41, 59, 0.45); border:1px solid var(--g-border); backdrop-filter:var(--g-glass-blur); -webkit-backdrop-filter:var(--g-glass-blur); padding:30px; border-radius:24px; transition:0.3s; }
.g-chart-box:hover { background:var(--g-surface-hover); border-color:rgba(16, 185, 129, 0.2); }

/* --- STATS CARDS --- */
.g-stat-value { color:#fff; font-size:2.4rem; font-weight:900; line-height:1; margin-bottom:6px; font-family:sans-serif; }
.g-stat-label { color:#94a3b8; font-size:0.95rem; font-weight:bold; }

/* --- TYPOGRAPHY --- */
.g-text-primary { color: var(--g-primary) !important; }
.g-text-muted { color: #94a3b8 !important; }
.g-text-danger { color: #ef4444 !important; }
.g-text-warning { color: #f59e0b !important; }
.g-text-info { color: #3b82f6 !important; }


@media print {
    body * {
        visibility: hidden;
    }
    #gfin-content-printables, #gfin-content-printables * {
        visibility: visible;
    }
    #gfin-content-printables {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        background: white !important;
        color: black !important;
    }
    .no-print {
        display: none !important;
    }
    .print-page-break {
        page-break-before: always;
    }
    .printable-table {
        width: 100%;
        border-collapse: collapse;
        margin-bottom: 20px;
        direction: rtl;
    }
    .printable-table th, .printable-table td {
        border: 1px solid #000;
        padding: 8px;
        text-align: center;
        color: #000 !important;
    }
    .printable-table th {
        background-color: #f2f2f2 !important;
        font-weight: bold;
    }
    .printable-header {
        text-align: center;
        margin-bottom: 20px;
        border-bottom: 2px solid #000;
        padding-bottom: 10px;
    }
}
