/* ============================================================
   Nile Arms B2B — app.css
   Refined Military-industrial aesthetic: Dark navy, antique gold
   Fonts: Playfair Display (headings) + DM Sans (body)
   ============================================================ */

:root {
  --na-gold:       #C8972B;
  --na-gold-lt:    #e4b84a;
  --na-gold-dk:    #9a6f1a;
  --na-navy:       #0d1b2e;
  --na-navy-2:     #142338;
  --na-navy-3:     #1c3050;
  --na-navy-lt:    #243d5a;
  --na-slate:      #2e4a6a;
  --na-blue:       #2563eb;
  --na-text:       #e8edf4;
  --na-text-muted: #8fa3bc;
  --na-text-dim:   #5a7a99;
  --na-surface:    rgba(255,255,255,0.04);
  --na-surface-2:  rgba(255,255,255,0.07);
  --na-border:     rgba(255,255,255,0.08);
  --na-border-2:   rgba(200,151,43,0.2);
  --na-red:        #dc2626;
  --na-green:      #16a34a;
  --na-amber:      #d97706;
  --na-shadow:     0 4px 24px rgba(0,0,0,0.4);
  --na-radius:     10px;
  --na-radius-lg:  16px;
  --na-font-head:  'Playfair Display', Georgia, serif;
  --na-font-body:  'DM Sans', system-ui, sans-serif;
  --na-font-ar:    'Cairo', system-ui, sans-serif;
  --na-transition: 0.2s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html[lang="ar"] { font-family: var(--na-font-ar); }
html[lang="en"] { font-family: var(--na-font-body); }

body {
  background: var(--na-navy);
  color: var(--na-text);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--na-gold); text-decoration: none; transition: color var(--na-transition); }
a:hover { color: var(--na-gold-lt); }

/* ===== AUTH LAYOUT ===== */
.na-auth-body { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.na-auth-bg {
  position: fixed; inset: 0; z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 80%, rgba(200,151,43,0.08) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 80% 20%, rgba(37,99,235,0.06) 0%, transparent 60%),
    linear-gradient(160deg, #0a1520 0%, #0d1b2e 50%, #0a1016 100%);
}
.na-auth-overlay { position: absolute; inset: 0; background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23C8972B' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E"); }
.na-auth-decor { position: absolute; border: 1px solid rgba(200,151,43,0.12); border-radius: 50%; pointer-events: none; }
.na-auth-decor-1 { width: 600px; height: 600px; top: -200px; right: -150px; }
.na-auth-decor-2 { width: 400px; height: 400px; bottom: -100px; left: -100px; }

.na-auth-container { position: relative; z-index: 1; width: 100%; max-width: 480px; }

.na-lang-switch {
  text-align: center; margin-bottom: 16px; font-size: 12px; letter-spacing: 1px;
  color: var(--na-text-muted);
}
.na-lang-switch a { color: var(--na-text-muted); }
.na-lang-switch a.active { color: var(--na-gold); font-weight: 600; }
.na-lang-switch span { margin: 0 8px; }

.na-auth-card {
  background: rgba(13,27,46,0.85);
  backdrop-filter: blur(24px);
  border: 1px solid var(--na-border-2);
  border-radius: var(--na-radius-lg);
  padding: 44px 40px;
  box-shadow: 0 32px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.04) inset;
}

.na-auth-logo { display: flex; align-items: center; gap: 14px; margin-bottom: 32px; }
.na-logo-icon svg { width: 40px; height: 40px; }
.na-logo-text { display: flex; flex-direction: column; }
.na-logo-title { font-family: var(--na-font-head); font-size: 20px; font-weight: 700; color: var(--na-gold); letter-spacing: 3px; line-height: 1; }
.na-logo-sub { font-size: 10px; letter-spacing: 2px; color: var(--na-text-muted); text-transform: uppercase; margin-top: 3px; }

.na-auth-heading { margin-bottom: 28px; }
.na-auth-heading h2 { font-family: var(--na-font-head); font-size: 26px; color: var(--na-text); font-weight: 600; line-height: 1.2; }
.na-auth-heading p { font-size: 13px; color: var(--na-text-muted); margin-top: 6px; }

.na-auth-footer { text-align: center; font-size: 11px; color: var(--na-text-dim); margin-top: 20px; letter-spacing: 0.3px; }

/* ===== ALERTS ===== */
.na-alert { display: flex; align-items: flex-start; gap: 10px; padding: 12px 16px; border-radius: var(--na-radius); font-size: 13px; margin-bottom: 18px; }
.na-alert svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 1px; }
.na-alert-error { background: rgba(220,38,38,0.12); border: 1px solid rgba(220,38,38,0.3); color: #fca5a5; }
.na-alert-success { background: rgba(22,163,74,0.12); border: 1px solid rgba(22,163,74,0.3); color: #86efac; }
.na-alert ul { margin: 6px 0 0 16px; }
.na-alert li { margin-bottom: 2px; }

/* ===== FORMS ===== */
.na-auth-form { display: flex; flex-direction: column; gap: 18px; }
.na-form-group { display: flex; flex-direction: column; gap: 6px; }
.na-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.na-form-group label { font-size: 12px; font-weight: 600; letter-spacing: 0.5px; text-transform: uppercase; color: var(--na-text-muted); display: flex; justify-content: space-between; align-items: center; }
.na-label-link { font-size: 11px; text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--na-gold); }

.na-input {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--na-border);
  border-radius: 8px;
  padding: 11px 14px;
  color: var(--na-text);
  font-size: 14px;
  font-family: inherit;
  transition: all var(--na-transition);
  outline: none;
}
.na-input::placeholder { color: var(--na-text-dim); }
.na-input:focus { border-color: var(--na-gold); background: rgba(200,151,43,0.06); box-shadow: 0 0 0 3px rgba(200,151,43,0.12); }
.na-input.error { border-color: rgba(220,38,38,0.6); }
.na-select { appearance: none; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%238fa3bc' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }
.na-select option { background: var(--na-navy-2); color: var(--na-text); }
.na-textarea { resize: vertical; min-height: 80px; }

.na-input-icon-wrap { position: relative; }
.na-input-icon-wrap .na-input { padding-right: 44px; }
.na-eye-toggle { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--na-text-muted); padding: 4px; transition: color var(--na-transition); }
.na-eye-toggle:hover { color: var(--na-gold); }
.na-eye-toggle svg { width: 16px; height: 16px; display: block; }

.na-checkbox-label { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; font-size: 13px; color: var(--na-text-muted); }
.na-checkbox-label input { margin-top: 2px; accent-color: var(--na-gold); }

/* ===== BUTTONS ===== */
.na-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 22px; border-radius: 8px; font-size: 14px; font-weight: 600;
  font-family: inherit; cursor: pointer; border: none; transition: all var(--na-transition);
  white-space: nowrap; letter-spacing: 0.3px;
}
.na-btn svg { width: 16px; height: 16px; }
.na-btn-full { width: 100%; }
.na-btn-sm { padding: 7px 14px; font-size: 12px; }

.na-btn-primary { background: linear-gradient(135deg, var(--na-navy-lt), var(--na-slate)); color: var(--na-text); border: 1px solid rgba(255,255,255,0.12); }
.na-btn-primary:hover { background: linear-gradient(135deg, var(--na-slate), var(--na-navy-lt)); color: white; border-color: rgba(255,255,255,0.2); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,0,0,0.4); }

.na-btn-gold { background: linear-gradient(135deg, var(--na-gold-dk), var(--na-gold)); color: #0d1b2e; font-weight: 700; }
.na-btn-gold:hover { background: linear-gradient(135deg, var(--na-gold), var(--na-gold-lt)); color: #0d1b2e; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(200,151,43,0.35); }

.na-btn-outline { background: transparent; color: var(--na-text-muted); border: 1px solid var(--na-border); }
.na-btn-outline:hover { border-color: var(--na-gold); color: var(--na-gold); }

.na-btn-danger { background: rgba(220,38,38,0.15); color: #fca5a5; border: 1px solid rgba(220,38,38,0.3); }
.na-btn-danger:hover { background: rgba(220,38,38,0.25); }

/* ===== AUTH DIVIDER ===== */
.na-auth-divider { text-align: center; font-size: 12px; color: var(--na-text-dim); padding: 6px 0; }
.na-auth-divider span { }
.na-auth-link { color: var(--na-text-muted); font-size: 13px; }

/* ===== VERIFY EMAIL ===== */
.na-verify-success, .na-verify-error { text-align: center; padding: 20px 0; }
.na-verify-icon { margin-bottom: 20px; }
.na-verify-icon svg { width: 64px; height: 64px; }
.na-verify-success h3, .na-verify-error h3 { font-family: var(--na-font-head); font-size: 22px; margin-bottom: 10px; }
.na-verify-success p, .na-verify-error p { color: var(--na-text-muted); font-size: 14px; margin-bottom: 24px; line-height: 1.7; }

/* ===== FLASH MESSAGES ===== */
.na-flash { display: flex; align-items: center; gap: 10px; padding: 12px 20px; font-size: 13px; position: relative; }
.na-flash button { margin-left: auto; background: none; border: none; cursor: pointer; color: inherit; opacity: 0.6; font-size: 16px; }
.na-flash-success { background: rgba(22,163,74,0.15); border-bottom: 1px solid rgba(22,163,74,0.2); color: #86efac; }
.na-flash-error { background: rgba(220,38,38,0.15); border-bottom: 1px solid rgba(220,38,38,0.2); color: #fca5a5; }

/* ===== STATUS PILLS ===== */
.na-status-pill { display: inline-flex; align-items: center; font-size: 11px; font-weight: 600; letter-spacing: 0.5px; text-transform: uppercase; padding: 3px 10px; border-radius: 20px; }
.na-status-open, .na-status-approved, .na-status-paid, .na-status-active, .na-status-completed { background: rgba(22,163,74,0.15); color: #86efac; border: 1px solid rgba(22,163,74,0.25); }
.na-status-draft, .na-status-pending, .na-status-review-pending { background: rgba(200,151,43,0.15); color: var(--na-gold-lt); border: 1px solid rgba(200,151,43,0.25); }
.na-status-closed, .na-status-rejected, .na-status-void, .na-status-suspended, .na-status-canceled { background: rgba(220,38,38,0.12); color: #fca5a5; border: 1px solid rgba(220,38,38,0.25); }
.na-status-in-progress, .na-status-partially-paid { background: rgba(37,99,235,0.12); color: #93c5fd; border: 1px solid rgba(37,99,235,0.25); }

/* ===== CARDS ===== */
.na-card {
  background: var(--na-surface);
  border: 1px solid var(--na-border);
  border-radius: var(--na-radius-lg);
  overflow: hidden;
}
.na-card-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--na-border); }
.na-card-header h3 { font-size: 14px; font-weight: 600; color: var(--na-text); }
.na-card-link { font-size: 12px; color: var(--na-gold); }
.na-card-body { padding: 4px 0; }
.na-mt { margin-top: 20px; }

/* ===== LIST ===== */
.na-list { }
.na-list-item { display: flex; align-items: center; justify-content: space-between; padding: 12px 20px; border-bottom: 1px solid var(--na-border); transition: background var(--na-transition); color: var(--na-text); }
.na-list-item:last-child { border-bottom: none; }
.na-list-item:hover { background: var(--na-surface-2); }
.na-list-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.na-list-title { font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.na-list-sub { font-size: 11px; color: var(--na-text-muted); }

/* ===== EMPTY STATE ===== */
.na-empty-state { text-align: center; padding: 32px 20px; color: var(--na-text-muted); font-size: 13px; }
.na-empty-state svg { width: 48px; height: 48px; margin-bottom: 12px; opacity: 0.3; display: block; margin-left: auto; margin-right: auto; }
.na-empty-state a { color: var(--na-gold); }

/* ===== NOTIFICATION BADGE ===== */
.na-notif-btn { position: relative; display: flex; align-items: center; color: var(--na-text-muted); padding: 6px; border-radius: 8px; transition: color var(--na-transition); }
.na-notif-btn svg { width: 20px; height: 20px; }
.na-notif-btn:hover { color: var(--na-text); }
.na-badge { position: absolute; top: 0; right: 0; background: var(--na-red); color: white; font-size: 9px; font-weight: 700; min-width: 16px; height: 16px; border-radius: 8px; display: flex; align-items: center; justify-content: center; padding: 0 3px; }
