/* =====================================================================
   School Fees & School Transport tables
   Uses the --dyn-* colour variables defined in css/dynamic.css
   (with fallbacks, so it also works on its own).
   ===================================================================== */

.itable{ margin:0 0 40px; }
.itable__head{ display:flex; align-items:center; gap:14px; margin-bottom:16px; }
.itable__head h2{ margin:0; font-size:clamp(1.25rem, 2.4vw, 1.6rem); color:var(--dyn-navy, #0E356E); line-height:1.3; }
.itable__icon{ width:44px; height:44px; flex:0 0 44px; border-radius:12px; display:inline-flex; align-items:center; justify-content:center;
  background:rgba(201,162,39,.16); color:var(--dyn-navy, #0E356E); font-size:1.1rem; }

.itable__wrap{ overflow-x:auto; -webkit-overflow-scrolling:touch; border-radius:18px; border:1px solid var(--dyn-line, rgba(14,53,110,.14));
  background:var(--dyn-paper, #fff); box-shadow:0 10px 30px -18px rgba(14,53,110,.35); }
.itable__table{ width:100%; border-collapse:collapse; font-size:.97rem; min-width:620px; }
.itable__table thead th{ background:var(--dyn-navy, #0E356E); color:#fff; font-weight:700; text-align:left; padding:14px 16px;
  font-size:.85rem; letter-spacing:.02em; text-transform:uppercase; white-space:nowrap; }
.itable__table tbody th,
.itable__table tbody td{ padding:14px 16px; border-top:1px solid var(--dyn-line, rgba(14,53,110,.14)); text-align:left; vertical-align:top;
  color:var(--dyn-ink, #1b2333); line-height:1.55; }
.itable__table tbody th{ font-weight:700; color:var(--dyn-navy, #0E356E); }
.itable__table tbody tr:nth-child(even){ background:rgba(14,53,110,.035); }
.itable__table tbody tr:hover{ background:rgba(201,162,39,.09); }
.itable__sl{ width:52px; text-align:center !important; color:var(--dyn-muted, #5b6475) !important; font-weight:600; }
.itable__strong{ font-weight:700; color:var(--dyn-red, #C41E2A) !important; white-space:nowrap; }
.itable__na{ color:var(--dyn-muted, #5b6475); opacity:.6; }

.itable__note{ margin:-20px 0 32px; color:var(--dyn-muted, #5b6475); font-size:.93rem; }
.itable__note i{ color:var(--dyn-gold, #C9A227); margin-right:4px; }

.itable__notes{ margin:8px 0 0; padding:24px 28px; border-radius:18px; background:rgba(201,162,39,.08); border-left:4px solid var(--dyn-gold, #C9A227); }
.itable__notes > *:last-child{ margin-bottom:0; }

.itable__actions{ display:flex; flex-wrap:wrap; gap:12px; align-items:center; margin-top:32px; }
.itable__contact{ font-weight:600; color:var(--dyn-navy, #0E356E); }
.itable__contact i{ color:var(--dyn-gold, #C9A227); margin-right:6px; }

/* ---------- Phones: each row becomes a card ---------- */
@media (max-width: 680px){
  .itable__wrap{ overflow:visible; border:0; box-shadow:none; background:none; }
  .itable__table{ min-width:0; }
  .itable__table thead{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
  .itable__table, .itable__table tbody, .itable__table tr, .itable__table th, .itable__table td{ display:block; width:100%; }
  .itable__table tbody tr{ margin-bottom:14px; border:1px solid var(--dyn-line, rgba(14,53,110,.14)); border-radius:16px; overflow:hidden;
    background:var(--dyn-paper, #fff) !important; box-shadow:0 8px 22px -16px rgba(14,53,110,.4); }
  .itable__table tbody .itable__sl{ display:none; }
  .itable__table tbody th{ background:var(--dyn-navy, #0E356E); color:#fff; border-top:0; font-size:1.02rem; }
  .itable__table tbody td{ display:flex; justify-content:space-between; gap:16px; text-align:right !important; padding:11px 16px; }
  .itable__table tbody td::before{ content:attr(data-label); font-weight:600; color:var(--dyn-muted, #5b6475); text-align:left; flex:0 0 45%; }
  .itable__table tbody tr > :nth-child(2) + td{ border-top:0; }
  .itable__actions .btn{ flex:1 1 100%; justify-content:center; }
}

@media print{
  .itable__wrap{ box-shadow:none; }
  .itable__actions{ display:none; }
}
