/* ============================================================
   CSS 17.09 — Wide tables on small screens
   ============================================================
   A table with many columns is wider than a phone.
   Put it in a box and let only the BOX scroll:
     .table-box { overflow: auto; }    (lesson 06)
   Keep the header visible while scrolling down:
     th { position: sticky; top: 0; }  (lesson 10)
   ============================================================ */

.table-box {
  overflow: auto;                   /* scroll inside this box, not the whole page */
  max-height: 280px;                /* a fixed height → it scrolls down too */
  max-width: 100%;
}

.marks th {
  position: sticky;
  top: 0;                           /* header row sticks to the top of the box */
}

.marks {
  min-width: 720px;                 /* the table needs at least this much room */
}
/* Try it: open the phone view (F12 → Ctrl+Shift+M) and scroll the table sideways. */


/* ------------------------------------------------------------
   Only to make the table visible — not part of this lesson
   ------------------------------------------------------------ */
body { font-family: Arial, sans-serif; font-size: 15px; }
.table-box { border: 1px solid #E4E4E4; border-radius: 10px; }
.marks { border-collapse: collapse; width: 100%; }
.marks th, .marks td { padding: 8px 12px; border-bottom: 1px solid #E4E4E4; text-align: left; white-space: nowrap; }
.marks th { background-color: #0F1B3D; color: #FFFFFF; }
.marks tbody tr:nth-child(even) { background-color: #F4F5F7; }
