/* Zuhri Academy live salaah board (/mobile/). Old-browser friendly: flexbox, tables, vw/vh units. */
html { font-size: 2.15vh; } /* landscape (TV, laptop): scale with screen height */
@media (max-aspect-ratio: 1/1) { html { font-size: 3.9vw; } } /* portrait (phone) */
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body.sb {
  font-family: "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: #fff; overflow: hidden;
  background: #0E3440;
  background: radial-gradient(ellipse at 85% -10%, rgba(131, 223, 210, .22), transparent 55%),
              radial-gradient(ellipse at -10% 110%, rgba(46, 163, 125, .30), transparent 55%),
              linear-gradient(160deg, #10414D 0%, #0E3440 55%, #0A2731 100%);
  -webkit-font-smoothing: antialiased;
}
body.no-cursor, body.no-cursor * { cursor: none; }
.sb-wrap { height: 100%; display: -webkit-box; display: -webkit-flex; display: flex; -webkit-flex-direction: column; flex-direction: column; padding: 1.4rem 2.2rem 1rem; }

/* header */
.sb-head { display: -webkit-flex; display: flex; -webkit-align-items: center; align-items: center; -webkit-justify-content: space-between; justify-content: space-between; padding-bottom: 1rem; border-bottom: 1px solid rgba(131, 223, 210, .25); }
.sb-logo { height: 2.6rem; width: auto; -webkit-filter: brightness(0) invert(1); filter: brightness(0) invert(1); }
.sb-dates { text-align: right; }
.sb-date { font-family: "Fraunces", Georgia, serif; font-size: 2.1rem; font-weight: 500; line-height: 1.1; }
.sb-hijri { font-size: 1.25rem; color: #83DFD2; font-weight: 600; margin-top: .2rem; }

/* main: two columns on landscape */
.sb-main { -webkit-flex: 1; flex: 1; display: -webkit-flex; display: flex; -webkit-align-items: stretch; align-items: stretch; padding: 1.4rem 0; min-height: 0; }
.sb-left { width: 40%; display: -webkit-flex; display: flex; -webkit-flex-direction: column; flex-direction: column; -webkit-justify-content: center; justify-content: center; padding-right: 2.2rem; }
.sb-right { width: 60%; display: -webkit-flex; display: flex; -webkit-flex-direction: column; flex-direction: column; -webkit-justify-content: center; justify-content: center; }

.sb-clock { font-size: 6.2rem; font-weight: 800; letter-spacing: -.02em; line-height: 1; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sb-sec { font-size: .42em; font-weight: 700; color: #83DFD2; margin-left: .05em; }
.sb-ampm { font-size: .28em; font-weight: 700; color: rgba(255, 255, 255, .7); margin-left: .35em; letter-spacing: .05em; }

.sb-next { margin-top: 1.6rem; padding: 1.2rem 1.4rem; border-radius: 1.2rem; background: rgba(255, 255, 255, .07); border: 1px solid rgba(131, 223, 210, .28); }
.sb-next.is-soon { background: rgba(237, 184, 54, .16); border-color: rgba(237, 184, 54, .7); }
.sb-next-label { font-size: 1.1rem; color: #83DFD2; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.sb-next-name { font-family: "Fraunces", Georgia, serif; font-size: 3.2rem; line-height: 1.1; margin-top: .2rem; }
.sb-next-time { font-size: 2rem; font-weight: 800; margin-top: .1rem; font-variant-numeric: tabular-nums; }
.sb-count { display: inline-block; margin-top: .6rem; padding: .25rem .9rem; border-radius: 99rem; background: #EDB836; color: #0E3440; font-size: 1.35rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.sb-notice { margin-top: 1rem; font-size: 1.1rem; color: #FFE7A6; font-weight: 600; min-height: 1.4rem; }

/* timetable */
.sb-table-title { font-size: 1.1rem; font-weight: 700; color: #83DFD2; text-transform: uppercase; letter-spacing: .1em; margin: 0 0 .5rem .2rem; }
.sb-table { width: 100%; border-collapse: separate; border-spacing: 0 .45rem; font-variant-numeric: tabular-nums; }
.sb-table th, .sb-table td { padding: .75rem 1.1rem; text-align: center; font-size: 2.6rem; font-weight: 800; line-height: 1.1; }
.sb-table thead th { font-size: 1.15rem; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: rgba(255, 255, 255, .65); padding-top: 0; padding-bottom: 0; }
.sb-table thead th:first-child, .sb-table tbody th { text-align: left; }
.sb-table tbody th { font-family: "Fraunces", Georgia, serif; font-weight: 500; background: rgba(255, 255, 255, .06); border-radius: .9rem 0 0 .9rem; padding-left: 1.4rem; }
.sb-table td.b { background: rgba(46, 163, 125, .22); color: rgba(255, 255, 255, .92); }
.sb-table td.j { background: rgba(131, 223, 210, .16); color: #fff; border-radius: 0 .9rem .9rem 0; }
.sb-table tr.is-sunrise th, .sb-table tr.is-sunrise td { font-size: 1.8rem; color: rgba(255, 255, 255, .6); background: rgba(255, 255, 255, .04); }
.sb-table tr.is-sunrise td { border-radius: 0 .9rem .9rem 0; }
.sb-table tr.is-next th, .sb-table tr.is-next td { background: #EDB836; color: #0E3440; }
.sb-table tr.is-next th { box-shadow: inset .45rem 0 0 #fff; }

/* footer */
.sb-foot { display: -webkit-flex; display: flex; -webkit-justify-content: space-between; justify-content: space-between; font-size: 1rem; color: rgba(255, 255, 255, .55); padding-top: .8rem; border-top: 1px solid rgba(131, 223, 210, .18); }
.sb-hint { position: fixed; left: 50%; bottom: 2.6rem; -webkit-transform: translateX(-50%); transform: translateX(-50%); background: rgba(0, 0, 0, .55); color: #fff; padding: .5rem 1.1rem; border-radius: 99rem; font-size: 1rem; }

/* portrait: stack */
@media (max-aspect-ratio: 1/1) {
  body.sb { overflow: auto; }
  .sb-wrap { height: auto; min-height: 100%; padding: 1rem 1rem .8rem; }
  .sb-head { -webkit-flex-direction: column; flex-direction: column; -webkit-align-items: flex-start; align-items: flex-start; }
  .sb-dates { text-align: left; margin-top: .7rem; }
  .sb-logo { height: 1.9rem; }
  .sb-date { font-size: 1.6rem; }
  .sb-hijri { font-size: 1.05rem; }
  .sb-main { display: block; padding: 1rem 0; }
  .sb-left, .sb-right { width: auto; padding: 0; }
  .sb-clock { font-size: 3.8rem; }
  .sb-next { margin: 1rem 0 0; padding: .9rem 1rem; }
  .sb-next-name { font-size: 2.2rem; }
  .sb-next-time { font-size: 1.5rem; }
  .sb-count { font-size: 1.1rem; }
  .sb-notice { font-size: .95rem; margin-bottom: .6rem; }
  .sb-table th, .sb-table td { font-size: 1.55rem; padding: .6rem .7rem; }
  .sb-table thead th { font-size: .8rem; }
  .sb-table tr.is-sunrise th, .sb-table tr.is-sunrise td { font-size: 1.15rem; }
  .sb-foot { font-size: .8rem; }
}
@media (max-aspect-ratio: 1/1) { .sb-hint { display: none; } }
