/* =====================================================================
   Sherween Beneficiary Portal — self-contained styles
   Brand navy #262a69. Arabic RTL. Cairo font.
   ===================================================================== */
:root {
    --navy: #262a69;
    --navy-dark: #12253f;
    --navy-light: #262a69;
    --grad: linear-gradient(135deg, #262a69 0%, #262a69 100%);
    --bg: #f4f6fa;
    --surface: #ffffff;
    --text: #1a2233;
    --muted: #64748b;
    --border: #e2e8f0;
    --ring: rgba(42, 79, 138, .35);

    --success: #16a34a; --success-bg: #dcfce7;
    --warn: #d97706;    --warn-bg: #fef3c7;
    --danger: #dc2626;  --danger-bg: #fee2e2;
    --info: #262a69;    --info-bg: #e0e8f4;
    --muted-bg: #eef1f6;

    --radius: 14px;
    --shadow: 0 4px 18px rgba(18, 37, 63, .08);
    --shadow-lg: 0 10px 34px rgba(18, 37, 63, .14);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: 'Cairo', 'Segoe UI', Tahoma, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 16px;
}
a { color: var(--navy-light); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 .5rem; font-weight: 700; color: var(--navy); line-height: 1.3; }
img { max-width: 100%; }
:focus-visible { outline: 3px solid var(--ring); outline-offset: 2px; border-radius: 6px; }

/* ---- Top navigation ---- */
.pt-nav {
    background: var(--grad);
    color: #fff;
    box-shadow: var(--shadow);
    position: sticky; top: 0; z-index: 100;
}
.pt-nav__inner {
    max-width: 1140px; margin: 0 auto; padding: 0 20px;
    display: flex; align-items: center; gap: 16px; height: 66px;
}
.pt-nav__brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 800; font-size: 1.1rem; }
.pt-nav__brand img { height: 40px; width: auto; }
.pt-nav__links { display: flex; align-items: center; gap: 4px; margin-inline-start: auto; }
.pt-nav__link {
    color: #dfe7f3; padding: 9px 14px; border-radius: 10px; font-weight: 600; font-size: .95rem;
    display: inline-flex; align-items: center; gap: 7px; transition: background .2s, color .2s; white-space: nowrap;
}
.pt-nav__link:hover { background: rgba(255,255,255,.12); color: #fff; text-decoration: none; }
.pt-nav__link.is-active { background: rgba(255,255,255,.18); color: #fff; }
.pt-nav__link .pt-badge { background: #dc2626; }
.pt-nav__toggle { display: none; background: none; border: 0; color: #fff; font-size: 1.5rem; cursor: pointer; margin-inline-start: auto; }

.pt-badge {
    background: var(--navy-light); color: #fff; font-size: .72rem; font-weight: 700;
    min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
    display: inline-flex; align-items: center; justify-content: center; line-height: 1;
}

/* ---- Layout ---- */
.pt-main { min-height: calc(100vh - 66px - 60px); padding: 28px 0 48px; }
.pt-container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.pt-page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.pt-page-head h1 { font-size: 1.6rem; margin: 0; }
.pt-muted { color: var(--muted); }
.pt-grid { display: grid; gap: 18px; }
.pt-grid--3 { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.pt-grid--stats { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }

/* ---- Cards ---- */
.pt-card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px;
}
.pt-card__title { display: flex; align-items: center; gap: 8px; font-size: 1.1rem; margin-bottom: 12px; }
.pt-stat { display: flex; flex-direction: column; gap: 4px; }
.pt-stat__num { font-size: 2rem; font-weight: 800; color: var(--navy); line-height: 1; }
.pt-stat__label { color: var(--muted); font-size: .9rem; }
.pt-stat__icon { width: 44px; height: 44px; border-radius: 12px; background: var(--info-bg); color: var(--navy-light);
    display: flex; align-items: center; justify-content: center; font-size: 1.2rem; margin-bottom: 8px; }

.pt-service-card { display: flex; flex-direction: column; }
.pt-service-card__body { flex: 1; }
.pt-service-card__cat { font-size: .8rem; color: var(--navy-light); font-weight: 700; }

/* ---- Buttons ---- */
.pt-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 20px; border-radius: 10px; border: 1px solid transparent;
    font-family: inherit; font-size: .95rem; font-weight: 700; cursor: pointer;
    transition: transform .12s, box-shadow .2s, background .2s; text-decoration: none; min-height: 44px;
}
.pt-btn:hover { text-decoration: none; }
.pt-btn--primary { background: var(--grad); color: #fff; box-shadow: 0 4px 12px rgba(42,79,138,.3); }
.pt-btn--primary:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(42,79,138,.4); }
.pt-btn--ghost { background: #fff; color: var(--navy); border-color: var(--border); }
.pt-btn--ghost:hover { background: var(--muted-bg); }
.pt-btn--success { background: var(--success); color: #fff; }
.pt-btn--danger { background: var(--danger); color: #fff; }
.pt-btn--block { width: 100%; }
.pt-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

/* ---- Chips ---- */
.pt-chip {
    display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px;
    font-size: .82rem; font-weight: 700; line-height: 1.4;
}
.pt-chip::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.pt-chip--success { color: var(--success); background: var(--success-bg); }
.pt-chip--warn    { color: var(--warn);    background: var(--warn-bg); }
.pt-chip--danger  { color: var(--danger);  background: var(--danger-bg); }
.pt-chip--info    { color: var(--info);    background: var(--info-bg); }
.pt-chip--muted   { color: var(--muted);   background: var(--muted-bg); }

/* ---- Progress ---- */
.pt-progress { background: var(--muted-bg); border-radius: 999px; height: 10px; overflow: hidden; }
.pt-progress__bar { height: 100%; background: var(--grad); border-radius: 999px; transition: width .4s ease; }
.pt-progress-label { font-size: .82rem; color: var(--muted); margin-top: 6px; }

/* ---- Step timeline (stepper) ---- */
.pt-steps { list-style: none; margin: 0; padding: 0; }
.pt-step { position: relative; padding-inline-start: 44px; padding-bottom: 22px; }
.pt-step:not(:last-child)::before {
    content: ''; position: absolute; inset-inline-start: 15px; top: 30px; bottom: 0; width: 2px; background: var(--border);
}
.pt-step__dot {
    position: absolute; inset-inline-start: 0; top: 2px; width: 32px; height: 32px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center; font-size: .85rem; font-weight: 700;
    background: var(--muted-bg); color: var(--muted); border: 2px solid var(--border);
}
.pt-step--approved  .pt-step__dot { background: var(--success); color: #fff; border-color: var(--success); }
.pt-step--under_review .pt-step__dot { background: var(--warn); color: #fff; border-color: var(--warn); }
.pt-step--rejected  .pt-step__dot { background: var(--danger); color: #fff; border-color: var(--danger); }
.pt-step--available .pt-step__dot { background: var(--navy-light); color: #fff; border-color: var(--navy-light); }
.pt-step__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.pt-step__title { font-weight: 700; color: var(--navy); }
.pt-step__body { margin-top: 10px; }
.pt-step__note { background: var(--warn-bg); color: #92400e; border-radius: 10px; padding: 10px 12px; margin-top: 10px; font-size: .9rem; }

/* ---- Forms ---- */
.pt-field { margin-bottom: 16px; }
.pt-label { display: block; font-weight: 600; margin-bottom: 6px; color: var(--navy); }
.pt-label .req { color: var(--danger); }
.pt-input, .pt-select, .pt-textarea {
    width: 100%; padding: 11px 14px; border: 1px solid var(--border); border-radius: 10px;
    font-family: inherit; font-size: 1rem; background: #fff; color: var(--text); min-height: 44px;
}
.pt-input:focus, .pt-select:focus, .pt-textarea:focus { border-color: var(--navy-light); outline: 3px solid var(--ring); outline-offset: 0; }
.pt-textarea { min-height: 88px; resize: vertical; }
.pt-help { font-size: .82rem; color: var(--muted); margin-top: 4px; }
.pt-check { display: inline-flex; align-items: center; gap: 8px; margin: 4px 14px 4px 0; }
.pt-check input { width: 18px; height: 18px; accent-color: var(--navy-light); }
.pt-fileslot { border: 1px dashed var(--border); border-radius: 10px; padding: 12px; }
.pt-fileslot--done { border-color: var(--success); background: var(--success-bg); }

/* ---- Auth card ---- */
.pt-auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; background: var(--grad); }
.pt-auth__card { background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); padding: 34px; width: 100%; max-width: 420px; }
.pt-auth__logo { text-align: center; margin-bottom: 18px; }
.pt-auth__logo img { height: 60px; }

/* ---- Alerts / empty ---- */
.pt-alert { border-radius: 10px; padding: 12px 16px; margin-bottom: 16px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.pt-alert-success { background: var(--success-bg); color: #14532d; }
.pt-alert-danger  { background: var(--danger-bg);  color: #7f1d1d; }
.pt-alert-info    { background: var(--info-bg);    color: #1e3a5f; }
.pt-empty { text-align: center; padding: 48px 20px; color: var(--muted); }
.pt-empty i { font-size: 2.6rem; color: var(--border); display: block; margin-bottom: 12px; }

/* ---- Notifications / lists ---- */
.pt-list { display: flex; flex-direction: column; gap: 10px; }
.pt-notif { display: flex; gap: 12px; padding: 14px; border: 1px solid var(--border); border-radius: 12px; background: #fff; }
.pt-notif--unread { border-inline-start: 4px solid var(--navy-light); background: #fbfcfe; }
.pt-notif__icon { width: 40px; height: 40px; flex: none; border-radius: 10px; background: var(--info-bg); color: var(--navy-light); display: flex; align-items: center; justify-content: center; }
.pt-notif__time { font-size: .78rem; color: var(--muted); }

.pt-footer { background: var(--navy-dark); color: #b9c4d6; text-align: center; padding: 18px; font-size: .88rem; }

/* ---- Responsive ---- */
@media (max-width: 820px) {
    .pt-nav__toggle { display: block; }
    .pt-nav__links {
        position: fixed; inset: 66px 0 auto 0; flex-direction: column; align-items: stretch;
        background: var(--navy-dark); padding: 10px; gap: 4px; margin: 0;
        transform: translateY(-140%); transition: transform .3s ease; box-shadow: var(--shadow-lg);
    }
    .pt-nav__links.is-open { transform: translateY(0); }
    .pt-nav__link { padding: 12px 14px; }
}
