/*
    ═══════════════════════════════════════════════════════════════════════════
    What the MudBlazor theme cannot say.
    ═══════════════════════════════════════════════════════════════════════════

    Colours, type and radii live in Components/Theme/HawzaTheme.cs and reach the
    page as MudBlazor's --mud-* custom properties. This file is only for what a
    theme has no slot for: the two faces, figures inside Arabic sentences, and
    the chrome's one decorative flourish. Everything here reads the theme's
    variables, so both schemes follow without a second copy.
*/

/* ── THE READING FACE ───────────────────────────────────────────────────────
   IBM Plex Sans Arabic, for everything that is not a title: a sans drawn for
   screens, compact enough for the dense tables, whose own Latin sets a code or
   a date inside an Arabic line without a change of voice. IBM's complete files,
   unmodified — the licence reserves the name «Plex», so a subset made here
   could not be served under it. Four weights, because MudBlazor draws 500
   where the theme draws 400, 600 and 700. OFL — see
   fonts/IBMPlexSansArabic-OFL.txt. */
@font-face {
    font-family: "IBM Plex Sans Arabic";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("fonts/IBMPlexSansArabic-Regular.woff2") format("woff2");
}

@font-face {
    font-family: "IBM Plex Sans Arabic";
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url("fonts/IBMPlexSansArabic-Medium.woff2") format("woff2");
}

@font-face {
    font-family: "IBM Plex Sans Arabic";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("fonts/IBMPlexSansArabic-SemiBold.woff2") format("woff2");
}

@font-face {
    font-family: "IBM Plex Sans Arabic";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("fonts/IBMPlexSansArabic-Bold.woff2") format("woff2");
}

/* ── THE TITLE FACE ─────────────────────────────────────────────────────────
   Amiri Bold, split the way the font's own distribution splits it so a page
   of Arabic titles fetches the Arabic file and nothing else. `swap`: a title
   drawn first in the system face and then in Amiri is better than a title not
   drawn at all on a slow link. OFL — see fonts/Amiri-OFL.txt. */
@font-face {
    font-family: "Amiri";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("fonts/amiri-700-arabic.woff2") format("woff2");
    unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF,
        U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

@font-face {
    font-family: "Amiri";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("fonts/amiri-700-latin.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304,
        U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── BOXES ──────────────────────────────────────────────────────────────────
   ONE HEIGHT FOR EVERY SINGLE-LINE BOX: 48px. MudBlazor sizes an outlined box
   by its margin — 55px normal, 39px dense — so a filter bar's select stood a
   third shorter than the form's text box beside it, and nothing in the product
   chose either on purpose. One padding for both margins ends that.

   AND ROOM UNDER THE LABEL. Once a label moves onto the border it ends 7.8px
   into the box; in a dense box the text began at 10.5px, and Arabic letters
   rise above their line, so the two touched. At 15px of padding, with the
   label lifted to sit on the border line itself, the value has air above it.
   The resting label is centred in the new height, and set in the medium
   weight: a bold placeholder shouted louder than the value typed after it.

   No page sets a box's Margin any more, so every box is
   MudBlazor's default and only these selectors reach it; the «dense» ones stay
   for MudBlazor's own boxes — the table pager's page-size select is one — so
   even they stand at the same height. */
.mud-input > input.mud-input-root-outlined,
.mud-input > div.mud-input-slot.mud-input-root-outlined,
.mud-input > input.mud-input-root-outlined.mud-input-root-margin-dense,
.mud-input > div.mud-input-slot.mud-input-root-outlined.mud-input-root-margin-dense {
    padding-top: 15px;
    padding-bottom: 15px;
}

.mud-input-control > .mud-input-control-input-container > .mud-input-label-inputcontrol {
    font-weight: 500;
}

.mud-application-layout-rtl .mud-input-label-outlined,
.mud-application-layout-rtl .mud-input-label-outlined.mud-input-label-margin-dense {
    transform: translate(-14px, 15px) scale(1);
}

.mud-application-layout-rtl .mud-shrink ~ label.mud-input-label.mud-input-label-inputcontrol.mud-input-label-outlined,
.mud-application-layout-rtl .mud-input:focus-within ~ label.mud-input-label.mud-input-label-inputcontrol.mud-input-label-outlined,
.mud-application-layout-rtl .mud-input:has(:-webkit-autofill) ~ label.mud-input-label.mud-input-label-inputcontrol.mud-input-label-outlined {
    transform: translate(-14px, -8px) scale(0.75);
}

/* A LEFT-TO-RIGHT BOX IN A RIGHT-TO-LEFT FORM — a username, a password.
   MudBlazor clears the icon's side of the box with LOGICAL padding, and a
   logical side resolves against the input's own direction: in a `dir="ltr"`
   input «start» is the left, so the clearance landed on the wrong side and the
   typed text ran into the left border. Stated physically instead: the icon is
   on the right of a right-to-left form whatever the input's direction. */
.mud-application-layout-rtl .mud-input > input.mud-input-root-outlined.mud-input-root-adorned-start[dir="ltr"] {
    padding-left: 14px;
    padding-right: 0;
}

.mud-application-layout-rtl .mud-input > input.mud-input-root-outlined.mud-input-root-adorned-end[dir="ltr"] {
    padding-left: 0;
    padding-right: 14px;
}

/* ── FIGURES ────────────────────────────────────────────────────────────────
   A date, a code or a quantity inside an Arabic sentence. The paragraph's own
   direction would reorder «21-09-2026» into «2026-09-21» and move a minus sign
   to the wrong end, so the run is isolated and laid out left to right whatever
   surrounds it. Tabular, so a column of them lines up. */
.num {
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    direction: ltr;
    unicode-bidi: isolate-override;
}

/* A phrase built round a figure — «92.0 من 100», «1 من 3», a sentence saying
   why a figure is not shown, a year's name. The override above would force its
   Arabic letters left to right too, and «من» would read «ن م»; so the phrase is
   only isolated from its neighbours, keeps its tabular digits, and leaves its
   letters in the page's own order. It may wrap, for a «why» in a narrow cell.
   A date inside a phrase still gets a .num of its own (FiguredText). */
.num-text {
    font-variant-numeric: tabular-nums;
    unicode-bidi: isolate;
}

/* ── THE HEADING FocusOnNavigate LANDS ON ─────────────────────────────────
   Routes.razor focuses each page's <h1> so a screen reader announces where the
   reader arrived. It is not a control, and a focus ring round the title of
   every screen marks something to operate that is not there. */
h1[tabindex="-1"]:focus-visible {
    outline: none;
}

/* ── THE BAR ────────────────────────────────────────────────────────────────
   The one place the interface decorates. The seminary's green, deepening
   toward the reading edge, over a faint lattice of eight-pointed stars — the
   khatam of the tilework in any madrasa courtyard — and a gold hairline taken
   from the full lockup. Everything below it stays plain. */
.hawza-appbar.mud-appbar {
    background-color: #012921;
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='56' viewBox='0 0 56 56'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='0.07' stroke-width='1'%3E%3Crect x='16' y='16' width='24' height='24'/%3E%3Crect x='16' y='16' width='24' height='24' transform='rotate(45 28 28)'/%3E%3Cpath d='M0 28h8M48 28h8M28 0v8M28 48v8'/%3E%3C/g%3E%3C/svg%3E"),
        linear-gradient(to left, #024e41 0%, #013a30 45%, #012921 100%);
    box-shadow: inset 0 -2px 0 var(--mud-palette-secondary);
}

.hawza-lockup {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: inherit;
    text-decoration: none;
    min-width: 0;
}

.hawza-lockup img {
    height: 2.25rem;
    width: auto;
    flex-shrink: 0;
}

.hawza-lockup-name {
    display: block;
    font-family: var(--mud-typography-h1-family);
    font-weight: 700;
    font-size: 1.3125rem;
    line-height: 1.2;
    white-space: nowrap;
}

.hawza-lockup-sub {
    display: block;
    font-size: 0.75rem;
    line-height: 1.3;
    color: #a4d3c6;
}

/* ── THE DRAWER ─────────────────────────────────────────────────────────────
   MudBlazor draws the page being read in the primary colour, which on the
   drawer's own green is green on green. Here it is white on a lifted band,
   marked on the reading edge by the same gold as the bar's hairline. */
.hawza-drawer .mud-nav-link {
    border-radius: 8px;
    margin-inline: 0.5rem;
    width: auto;
    padding-block: 0.5rem;
    color: var(--mud-palette-drawer-text);
}

.hawza-drawer .mud-nav-link:hover:not(.mud-nav-link-disabled) {
    background-color: rgb(255 255 255 / 0.08);
    color: #ffffff;
}

.hawza-drawer .mud-nav-link {
    position: relative;
}

.hawza-drawer .mud-nav-link.active:not(.mud-nav-link-disabled),
.hawza-drawer .mud-nav-link.active:not(.mud-nav-link-disabled) .mud-nav-link-text {
    background-color: rgb(255 255 255 / 0.13);
    color: #ffffff;
    font-weight: 600;
}

.hawza-drawer .mud-nav-link.active .mud-nav-link-text {
    background: none;
}

/* The marker on the reading edge: a straight bar of its own, so the band's
   rounded corners never bend it into a bracket. */
.hawza-drawer .mud-nav-link.active::before {
    content: "";
    position: absolute;
    inset-block: 0.5rem;
    inset-inline-start: 0;
    width: 3px;
    border-radius: 3px;
    background: var(--mud-palette-secondary);
}

.hawza-drawer .mud-nav-link.active .mud-nav-link-icon {
    color: var(--mud-palette-secondary-lighten);
}

.hawza-drawer .mud-navmenu {
    padding-block: 0.75rem 1.5rem;
}

.hawza-drawer .mud-nav-group > .mud-nav-link {
    font-weight: 600;
}

/* The entry's label is the row the count sits in: a flex row, so the count goes to the far end of it and
   keeps a gap of its own from a long label (an inline badge never took its auto margin, and touched the text). */
.hawza-drawer .mud-nav-link-text {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* What is waiting behind an entry, at the far end of its row: the gold of the bar's hairline on the
   drawer's green, dark ink on it. */
.hawza-nav-count {
    flex: none;
    margin-inline-start: auto;
    min-width: 22px;
    padding-inline: 6px;
    border-radius: 11px;
    background: var(--mud-palette-secondary);
    color: #1c1a10;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 22px;
    text-align: center;
}

/* ── THE USER, AT THE END OF THE BAR ─────────────────────────────────────── */
.hawza-user.mud-button-root {
    padding-inline: 0.5rem;
    text-align: start;
}

.hawza-user .mud-button-label {
    gap: 0.625rem;
}

.hawza-user-avatar {
    font-weight: 700;
}

.hawza-user-text {
    display: none;
    line-height: 1.25;
}

.hawza-user-name {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
}

.hawza-user-role {
    display: block;
    font-size: 0.6875rem;
    color: #a4d3c6;
}

@media (min-width: 600px) {
    .hawza-user-text {
        display: block;
    }
}

.hawza-user-card {
    padding: 0.75rem 1rem 0.5rem;
    min-width: 13rem;
}

/* Sign-out is a command posted from inside a menu: it lines up with the menu's
   items rather than sitting in it as a button. */
.hawza-signout.mud-button-root {
    justify-content: flex-start;
    padding-inline: 1rem;
    border-radius: 0;
}

/* ── THE ACTION BAR ──────────────────────────────────────────────────────────
   The buttons of a long form, kept in reach: they stay at the bottom edge of the
   window while the form runs past it, so saving never means scrolling to the end
   and back. On a form that fits the window it is simply the row they were in. */
.hawza-actionbar {
    position: sticky;
    bottom: 0;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding-block: 12px;
    background: var(--mud-palette-background);
    border-top: 1px solid var(--mud-palette-lines-default);
}

/* ── THE PERIOD, IN THE BAR ─────────────────────────────────────────────────
   The year and term every screen reads (WorkingContext). A quiet pill beside the
   seminary's name; gold while the period is not today's, so a director cannot
   read last year's numbers as this year's without the bar saying so. On a phone
   the pill is its icon: there is no room in the bar for a year's name, and the
   banner under it speaks whenever the period is not the current one. */
.hawza-context.mud-button-root {
    min-height: 44px;
    padding-inline: 0.75rem;
    border-radius: 999px;
    background-color: rgb(255 255 255 / 0.08);
    font-size: 0.8125rem;
}

.hawza-context.mud-button-root:hover {
    background-color: rgb(255 255 255 / 0.14);
}

.hawza-context .mud-button-label {
    gap: 0.5rem;
}

.hawza-context-year {
    font-weight: 600;
}

.hawza-context-term {
    color: #cfe6df;
}

.hawza-context--away.mud-button-root {
    background-color: rgb(212 165 90 / 0.28);
    box-shadow: inset 0 0 0 1px rgb(212 165 90 / 0.7);
}

.hawza-context--away .hawza-context-term {
    color: #ffe9bf;
}

@media (max-width: 599.98px) {
    .hawza-context-year,
    .hawza-context-term {
        display: none;
    }

    .hawza-context.mud-button-root {
        min-width: 44px;
        padding-inline: 0.5rem;
    }

    /* Just the calendar: the chevron would make a round button a pill again. */
    .hawza-context .mud-button-icon-end {
        display: none;
    }
}

.hawza-context-heading {
    padding: 0.625rem 1rem 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-context-chosen {
    font-weight: 600;
    color: var(--mud-palette-primary);
}

/* Under the bar while the screens read a period that is not today's. */
.hawza-context-banner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1rem;
    padding: 0.625rem 1.5rem;
    background-color: rgba(var(--mud-palette-secondary-rgb), 0.16);
    border-bottom: 1px solid rgba(var(--mud-palette-secondary-rgb), 0.5);
    color: var(--mud-palette-text-primary);
    font-size: 0.875rem;
}

.hawza-context-banner .mud-button-root {
    margin-inline-start: auto;
}

/* ── THE PAGE ───────────────────────────────────────────────────────────── */
.hawza-main {
    min-height: 100dvh;
}

.hawza-page {
    padding-block: 1.75rem 3rem;
}

.hawza-page-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem 1.5rem;
    margin-bottom: 1.5rem;
}

.hawza-page-head-text {
    min-width: 0;
    max-width: 48rem;
}

.hawza-page-title {
    color: var(--mud-palette-text-primary);
}

.hawza-page-note {
    margin-top: 0.25rem;
    color: var(--mud-palette-text-secondary);
}

.hawza-trail {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.375rem;
    margin-bottom: 0.25rem;
    font-size: 0.8125rem;
    color: var(--mud-palette-text-secondary);
}

.hawza-trail a {
    color: var(--mud-palette-primary);
}

.hawza-trail a:hover {
    text-decoration: underline;
}

.hawza-page-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

/* ── SECTIONS ───────────────────────────────────────────────────────────────
   A register's page rather than a floating card: a hairline edge and no
   shadow, so a screen of several reads as one document in parts. */
.hawza-panel {
    overflow: hidden;
}

.hawza-panel + .hawza-panel {
    margin-top: 1.25rem;
}

.hawza-panel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid var(--mud-palette-divider);
}

.hawza-panel-icon {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    color: var(--mud-palette-primary);
    background: rgba(var(--mud-palette-primary-rgb), 0.1);
}

/* Wide enough to take the row on a phone, so the actions wrap under the
   title instead of squeezing a long note into a column beside them. */
.hawza-panel-titles {
    min-width: 0;
    flex: 1 1 16rem;
}

.hawza-panel-note {
    display: block;
    color: var(--mud-palette-text-secondary);
}

.hawza-panel-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hawza-panel-body {
    padding: 1.25rem;
}

.hawza-notice {
    margin-bottom: 1rem;
}

/* The line a page shows for the instant before it knows who is reading. */
.hawza-checking {
    color: var(--mud-palette-text-secondary);
}

/* ── TABLES ─────────────────────────────────────────────────────────────────
   Inside a flush panel the table meets the panel's edges; its header row sits
   on the sunken paper so the columns read as a register's ruled head — whether
   the table is MudTable's (a DataList, cells) or MudSimpleTable's (plain th). */
.hawza-table .mud-table-head .mud-table-cell,
.hawza-table.mud-simple-table thead th {
    background: var(--mud-palette-background-gray);
    color: var(--mud-palette-text-secondary);
    font-weight: 600;
    font-size: 0.8125rem;
    white-space: nowrap;
}

.hawza-table .mud-table-cell {
    vertical-align: top;
}

/* A HEAD THAT SORTS IS A BUTTON DRESSED AS THE HEAD'S WORDS (SortHead): it takes
   the band's ink and type, the arrow sits after the words, and the keyboard's
   focus ring is drawn, since the button's own frame is not. */
.hawza-sort-head {
    display: inline-flex;
    align-items: center;
    gap: 0.25em;
    padding: 0;
    border: 0;
    background: none;
    font: inherit;
    color: inherit;
    white-space: nowrap;
    cursor: pointer;
}

.hawza-sort-head:focus-visible {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

/* BELOW A DESK, A TABLE KEEPS ITS COLUMNS AND SCROLLS. Squeezed to a phone's
   width every cell wrapped to a sliver and a row grew a screen tall; at its own
   width — each cell capped, so a long name still wraps — it reads as a table
   and slides sideways inside its panel. */
@media (max-width: 959.98px) {
    .hawza-table.mud-simple-table table {
        width: max-content;
        min-width: 100%;
    }

    .hawza-table.mud-simple-table th,
    .hawza-table.mud-simple-table td {
        max-width: 16rem;
    }
}

/* DataList — the bar above a register: search, the page's own filters, what is ticked. */
.hawza-datalist {
    min-width: 0;
}

.hawza-datalist-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
    padding: 16px;
}

.hawza-datalist-search {
    flex: 1 1 16rem;
    max-width: 24rem;
}

/* THE PHONE'S SORT. Where MudTable turns rows into cards (Breakpoint.Sm, its own
   «max-width: 960px», matched here to the pixel) the heads are hidden, so one
   select sorts the cards; on a desk the heads do, and a bar that holds only the
   select is not drawn at all. */
.hawza-datalist-sort {
    display: none;
    flex: 0 1 14rem;
}

.hawza-datalist-bar--sort-only {
    display: none;
}

@media (max-width: 960px) {
    .hawza-datalist-sort {
        display: block;
    }

    .hawza-datalist-bar--sort-only {
        display: flex;
    }
}

.hawza-datalist-bulk {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-inline-start: auto;
}

/* A card on a phone holds a Latin name or an email whole: it breaks rather than push the page sideways (A2). */
.hawza-datalist .mud-table-cell {
    overflow-wrap: anywhere;
}

/* A report's sections on the desktop table (DataList's Breakpoint.Sm: a table from 960px): a word is never broken
   inside — «التفس / ير» — so a column is at least as wide as its longest word; the cards below keep «anywhere». */
@media (min-width: 960px) {
    .hawza-report .hawza-datalist .mud-table-cell {
        overflow-wrap: break-word;
    }
}

/* …but the cell's own label stays whole: beside a long value it was broken letter by letter («الط / لب»). */
.hawza-datalist .mud-table-cell::before {
    white-space: nowrap;
    overflow-wrap: normal;
    padding-inline-end: 12px;
}

/* A chip lays its content out as flex items, which drops the space between a
   word and the figure after it — «بانتظار القرار:0». The gap puts it back. */
.mud-chip .mud-chip-content {
    gap: 0.25em;
}

/* ── BUTTONS ────────────────────────────────────────────────────────────────
   The quiet outlined button borders in the paper's own line colour, not in
   ink: a row of them is a row of options, and six near-black frames read as
   six alarms. It takes the seminary's green only when pointed at. */
.mud-button-outlined.mud-button-outlined-default {
    border-color: var(--mud-palette-lines-inputs);
    color: var(--mud-palette-text-primary);
}

.mud-button-outlined.mud-button-outlined-default:hover {
    border-color: var(--mud-palette-primary);
    color: var(--mud-palette-primary);
    background-color: rgba(var(--mud-palette-primary-rgb), 0.04);
}

/* ── TOUCH ──────────────────────────────────────────────────────────────────
   A finger is bigger than a pointer. MudBlazor's buttons are 36-37px tall, its
   clear-a-box icon 26px and a small link chip 24px — fine under a mouse, and a
   coin toss on a phone held in one hand between two lessons. On a phone every
   control that is pressed is 44px by 44px or more (the audit's A6); the account
   button, which is the one control on every screen, is 44px everywhere. Rows in
   a table scroll sideways inside their own box and keep the compact size until
   the list becomes cards. */
.hawza-user.mud-button-root {
    min-height: 44px;
}

@media (max-width: 599.98px) {
    .mud-button-root.mud-button {
        min-height: 44px;
    }

    .mud-button-root.mud-icon-button {
        min-width: 44px;
        min-height: 44px;
    }

    .mud-chip[href] {
        min-height: 44px;
    }
}

/* The cell that names the row. */
.hawza-lead {
    font-weight: 600;
    color: var(--mud-palette-text-primary);
}

/* A second line under the lead, dimmer. */
.hawza-sub {
    display: block;
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
}

/* A value that says «nothing», still written and drawn faintly: «لا» in the permission table. */
.hawza-faint {
    color: var(--mud-palette-text-disabled);
}

/* Boxes inside a table cell: sized to the column, not to the form. A figure
   is typed left to right, as it is read. */
.hawza-cell-select { min-width: 9rem; }
.hawza-cell-mark { min-width: 6rem; max-width: 8rem; }
.hawza-cell-time { min-width: 8rem; max-width: 9.5rem; }
.hawza-cell-code { max-width: 5rem; }

.hawza-num-input input {
    direction: ltr;
    font-variant-numeric: tabular-nums;
}

/* ── ROW ACTIONS ────────────────────────────────────────────────────────────
   One affordance per act, compact and aligned. TWO SHAPES, because the class
   is worn by two kinds of element: on a bar it is a flex row; on a TABLE CELL
   it must stay a cell — a row that wraps cells into one anonymous cell stacks
   three action columns under two headers — so its buttons flow inline to the
   cell's end edge, on one line: a row with more acts than fit keeps the rest
   in a menu (⋮) rather than wrapping them into a column of buttons. */
.hawza-row-actions:not(td) {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.375rem;
}

td.hawza-row-actions {
    text-align: end;
    white-space: nowrap;
}

td.hawza-row-actions > * {
    margin-block: 0.125rem;
    white-space: nowrap;
    vertical-align: middle;
}

td.hawza-row-actions > * + * {
    margin-inline-start: 0.375rem;
}

/* ── A SECTION'S OWN HEAD ───────────────────────────────────────────────────
   Title over its notes, on a hairline that divides it from the body. */
.hawza-card-head {
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid var(--mud-palette-divider);
}

.hawza-card-head .hawza-panel-note {
    margin-top: 0.125rem;
}

.hawza-panel-title {
    color: var(--mud-palette-text-primary);
}

.hawza-empty-title {
    font-weight: 600;
    color: var(--mud-palette-text-primary);
}

.hawza-back {
    margin-bottom: 0.75rem;
}

.hawza-basis-full {
    flex-basis: 100%;
}

.hawza-basis-22 {
    flex-basis: 22rem;
}

.hawza-min-w-48 {
    min-width: 12rem;
}

.hawza-clip {
    overflow: hidden;
}

/* ── WHY A STUDENT MAY NOT CONTINUE ─────────────────────────────────────────
   spec:643 «تعرض كل سبب منفصلاً وحالته وموعده … معالجة سبب لا تغلق الأسباب
   الأخرى»: one row per condition, each with its own state and its own remedy
   beside it, and never one collapsed sentence. */
.reasons {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.reasons > li {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--mud-palette-lines-default);
    font-size: 0.8125rem;
}

.reasons > li:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.reason-what {
    font-weight: 600;
    color: var(--mud-palette-text-primary);
}

.reason-note {
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
}

/* ── THE DECISION BAR ───────────────────────────────────────────────────────
   The acts on the whole sheet, in a row under the list they act on. In the flow
   and never pinned to the window: pinned, it floated over whichever rows lay
   beneath it and read as two buttons in the middle of the table. */
.decision-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    border-top: 1px solid var(--mud-palette-lines-default);
}

.hawza-refused {
    margin-bottom: 1rem;
}

/* A dashed box: a place that exists and holds nothing yet. */
.hawza-empty {
    border: 1px dashed var(--mud-palette-lines-inputs);
    border-radius: var(--mud-default-borderradius);
    padding: 2.5rem 1.5rem;
    text-align: center;
}

.hawza-empty-icon {
    color: var(--mud-palette-text-disabled);
    margin-bottom: 0.5rem;
}

.hawza-empty-title {
    color: var(--mud-palette-text-primary);
}

.hawza-empty-note {
    max-width: 32rem;
    margin: 0.25rem auto 0;
    color: var(--mud-palette-text-secondary);
}

.hawza-empty-actions {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

/* ── THE BOARD ──────────────────────────────────────────────────────────────
   The greeting, over the seal in watermark, is the board's one flourish;
   everything under it is a count that leads to its own rows. */
.hawza-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem 1.5rem;
    margin-bottom: 1.75rem;
    padding: 1.75rem 1.75rem 1.5rem;
    border-radius: 14px;
    border: 1px solid var(--mud-palette-lines-default);
    background:
        linear-gradient(to left, rgba(var(--mud-palette-primary-rgb), 0.07), transparent 60%),
        var(--mud-palette-surface);
}

.hawza-hero-text {
    position: relative;
    z-index: 1;
    max-width: 44rem;
}

.hawza-hero-note {
    margin-top: 0.375rem;
    color: var(--mud-palette-text-secondary);
}

.hawza-hero-time {
    position: relative;
    z-index: 1;
}

.hawza-hero-seal {
    position: absolute;
    inset-inline-end: 1.5rem;
    top: 50%;
    width: 9.5rem;
    height: auto;
    transform: translateY(-50%);
    opacity: 0.07;
    pointer-events: none;
}

.hawza-section-title {
    margin-bottom: 0.75rem;
    color: var(--mud-palette-text-primary);
}

.hawza-tiles {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
    margin-bottom: 2rem;
}

.hawza-tile {
    --rail: var(--mud-palette-lines-inputs);
    --rail-rgb: var(--mud-palette-primary-rgb);
    --rail-ink: var(--mud-palette-primary);
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.125rem 1.25rem 1rem;
    border-radius: 12px;
    border: 1px solid var(--mud-palette-lines-default);
    background: var(--mud-palette-surface);
    color: inherit;
    text-decoration: none;
    overflow: hidden;
    transition: box-shadow 160ms ease, border-color 160ms ease;
}

.hawza-tile::before {
    content: "";
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    width: 4px;
    background: var(--rail);
}

.hawza-tile:hover {
    border-color: transparent;
    box-shadow: var(--mud-elevation-4);
}

.hawza-tile:focus-visible {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

.hawza-tile--blocking {
    --rail: var(--mud-palette-error);
    --rail-rgb: var(--mud-palette-error-rgb);
    --rail-ink: var(--mud-palette-error);
}

.hawza-tile--attention {
    --rail: var(--mud-palette-warning);
    --rail-rgb: var(--mud-palette-warning-rgb);
    --rail-ink: var(--mud-palette-warning);
}

.hawza-tile-head {
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.hawza-tile-icon {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 10px;
    color: var(--rail-ink);
    background: rgba(var(--rail-rgb), 0.12);
}

.hawza-tile-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-tile-figure,
.hawza-tile-blank {
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1.1;
}

.hawza-tile-figure {
    color: var(--mud-palette-text-primary);
}

.hawza-tile-blank {
    color: var(--mud-palette-text-disabled);
}

.hawza-tile-note {
    font-size: 0.75rem;
    line-height: 1.5;
    color: var(--mud-palette-text-secondary);
}

.hawza-today {
    margin-bottom: 1.5rem;
}

/* «اليوم» and «الوضع العام»: the two group headings of the director's and the assistant's homes, each over the sections
   it gathers. The day is named beside «اليوم» as the board names it. */
.hawza-group-title {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.75rem;
    margin: 2rem 0 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--mud-palette-lines-default);
    color: var(--mud-palette-text-primary);
}

.hawza-today-first > .hawza-group-title {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.hawza-group-day {
    font-size: 1rem;
    font-weight: 400;
    color: var(--mud-palette-text-secondary);
}

.hawza-today-occasion {
    margin-bottom: 0.75rem;
}

/* A tile of two figures, approved apart from not yet approved: not one link but two, each to its own rows. */
.hawza-tile--split:hover {
    border-color: var(--mud-palette-lines-default);
    box-shadow: none;
}

.hawza-tile-parts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}

.hawza-tile-part {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    color: inherit;
    text-decoration: none;
}

.hawza-tile-part:hover {
    background: rgba(var(--rail-rgb), 0.08);
}

.hawza-tile-part:focus-visible {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

.hawza-capabilities-head {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* ── THE SMALL VOCABULARY ───────────────────────────────────────────────────
   Layout and text helpers the screens compose with, beside MudBlazor's own
   spacing and flex utilities (mt-4, gap-2, d-flex, align-center…), which
   share their 4px scale. */
.hawza-grid {
    display: grid;
}

.hawza-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.hawza-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

@media (min-width: 600px) {
    .hawza-cols-sm-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hawza-cols-sm-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .hawza-cols-sm-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .hawza-span-sm-2 { grid-column: span 2 / span 2; }
}

@media (min-width: 960px) {
    .hawza-cols-md-2, .hawza-cols-lg-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hawza-cols-md-3, .hawza-cols-lg-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .hawza-cols-md-4, .hawza-cols-lg-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .hawza-span-md-2, .hawza-span-lg-2 { grid-column: span 2 / span 2; }
}

.hawza-span-2 { grid-column: span 2 / span 2; }
.hawza-span-full, .hawza-span-sm-full, .hawza-span-md-full, .hawza-span-lg-full { grid-column: 1 / -1; }

.hawza-stack-1, .hawza-stack-2, .hawza-stack-3, .hawza-stack-4,
.hawza-stack-5, .hawza-stack-6, .hawza-stack-8 {
    display: flex;
    flex-direction: column;
}

.hawza-stack-1 { gap: 0.25rem; }
.hawza-stack-2 { gap: 0.5rem; }
.hawza-stack-3 { gap: 0.75rem; }
.hawza-stack-4 { gap: 1rem; }
.hawza-stack-5 { gap: 1.25rem; }
.hawza-stack-6 { gap: 1.5rem; }
.hawza-stack-8 { gap: 2rem; }

.hawza-nowrap { white-space: nowrap; }
.hawza-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hawza-min-w-0 { min-width: 0; }
.hawza-break { overflow-wrap: anywhere; }
.hawza-scroll-x { overflow-x: auto; }
.hawza-text-center { text-align: center; }
.hawza-text-start { text-align: start; }
.hawza-text-end, .hawza-n { text-align: end; }
.hawza-strong { font-weight: 600; }
.hawza-normal { font-weight: 400; }
.hawza-italic { font-style: italic; }
.hawza-underline { text-decoration: underline; }
.hawza-dim { color: var(--mud-palette-text-secondary); }
.hawza-small { font-size: 0.8125rem; }
.hawza-list { list-style: disc; padding-inline-start: 1.25rem; }
.hawza-list-numbered { list-style: decimal; padding-inline-start: 1.25rem; }

.hawza-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* A sentence that explains the screen or a section, dimmer than its text. */
.hawza-note,
.hawza-page-note,
.hawza-panel-note {
    font-size: 0.8125rem;
    line-height: 1.65;
    color: var(--mud-palette-text-secondary);
}

.hawza-note p + p,
.hawza-page-note p + p,
.hawza-panel-note p + p {
    margin-top: 0.375rem;
}

/* A hint under a field, when it carries more than one plain sentence. */
.hawza-help {
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
}

/* The strip of choices above a list: which year, which day, which words. */
.hawza-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem 1rem;
    margin-bottom: 1.25rem;
    padding: 0.875rem 1rem;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 12px;
    background: var(--mud-palette-surface);
}

/* The boxes share the strip and keep a width a choice can be read in; buttons
   and ticks keep their own size. */
.hawza-toolbar > .mud-input-control,
.hawza-toolbar > .mud-select,
.hawza-toolbar > .mud-picker {
    flex: 1 1 12rem;
    min-width: 12rem;
    max-width: 22rem;
}

.hawza-toolbar-count {
    margin-inline-start: auto;
    font-size: 0.8125rem;
    color: var(--mud-palette-text-secondary);
}

.hawza-picker {
    max-width: 22rem;
}

/* A group of ticks or radios under one legend. */
.hawza-choices {
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 12px;
    padding: 0.5rem 1rem 0.875rem;
}

.hawza-choices > legend {
    padding-inline: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-choice {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    cursor: pointer;
}

/* A progress bar a page draws itself. */
.hawza-meter {
    height: 0.375rem;
    width: 100%;
    overflow: hidden;
    border-radius: 999px;
    background: var(--mud-palette-background-gray);
}

.hawza-meter > span {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: currentColor;
}

.hawza-skeleton,
.hawza-skeleton-line {
    border-radius: 6px;
    background: var(--mud-palette-skeleton);
}

.hawza-skeleton-line {
    height: 0.75rem;
}

/* ── NATIVE CONTROLS ────────────────────────────────────────────────────────
   Boxes that still post over plain HTTP to a controller — a row's hidden
   revision beside its button, a file to upload — drawn to sit beside
   MudBlazor's outlined fields without looking foreign. */
.hawza-native {
    width: 100%;
    min-height: 2.5rem;
    padding: 0.375rem 0.75rem;
    border: 1px solid var(--mud-palette-lines-inputs);
    border-radius: var(--mud-default-borderradius);
    background: var(--mud-palette-surface);
    color: var(--mud-palette-text-primary);
    font: inherit;
}

.hawza-native:focus {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: -1px;
    border-color: transparent;
}

input[type="checkbox"],
input[type="radio"] {
    accent-color: var(--mud-palette-primary);
    width: 1rem;
    height: 1rem;
}

/* ── A FILE TO UPLOAD ───────────────────────────────────────────────────────
   The native input stays — it is what the form posts — but out of sight and
   still in the tab order; its focus is shown on the button drawn for it. */
.hawza-file {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
}

.hawza-file-input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.hawza-file-button {
    gap: 0.375rem;
    padding: 0.375rem 1rem;
    pointer-events: none;
}

.hawza-file-input:focus-visible + .hawza-file-button {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

.hawza-file-name {
    font-size: 0.8125rem;
    color: var(--mud-palette-text-secondary);
    overflow-wrap: anywhere;
}

/* A file chosen as one of the buttons of a row — «استبدال» — which flows with the other buttons, not a line of its own. */
.hawza-file-inline {
    display: inline-flex;
    gap: 0.375rem;
}

/* ── A LESSON'S RECORDINGS ──────────────────────────────────────────────────
   One card per recording, the player across its whole width: a recording is heard here, never downloaded. */
.hawza-recording-cards {
    display: grid;
    gap: 8px;
    padding: 12px;
}

.hawza-recording-card {
    display: grid;
    gap: 0.5rem;
    padding: 12px 16px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: var(--mud-default-borderradius);
    background: var(--mud-palette-surface);
}

.hawza-recording-player {
    width: 100%;
    max-width: 36rem;
}

/* ── FIELDS DRAWN NATIVELY ──────────────────────────────────────────────────
   The few boxes that post by name to a controller, labelled by Field. */
.hawza-field {
    display: grid;
    gap: 0.375rem;
}

.hawza-field > label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-required {
    color: var(--mud-palette-error);
    font-weight: 400;
}

.hawza-field-error {
    display: block;
}

/* ── SIGNING IN ─────────────────────────────────────────────────────────────
   The seminary's green fills the screen behind the card, with the bar's star
   lattice larger over it: the first thing anybody meets is the seminary. */
.hawza-signin {
    display: grid;
    place-items: center;
    min-height: 100dvh;
    padding: 1.25rem;
    background-color: #012921;
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' viewBox='0 0 56 56'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='0.06' stroke-width='0.8'%3E%3Crect x='16' y='16' width='24' height='24'/%3E%3Crect x='16' y='16' width='24' height='24' transform='rotate(45 28 28)'/%3E%3Cpath d='M0 28h8M48 28h8M28 0v8M28 48v8'/%3E%3C/g%3E%3C/svg%3E"),
        radial-gradient(ellipse at 50% 35%, #055d4e 0%, #024e41 40%, #012921 100%);
}

.hawza-signin-card.mud-paper {
    width: 100%;
    max-width: 25rem;
    padding: 2rem 1.75rem 1.75rem;
    border-top: 3px solid var(--mud-palette-secondary);
}

.hawza-signin-logo {
    display: block;
    width: 100%;
    max-width: 13rem;
    height: auto;
    margin: 0 auto 1.25rem;
}

.hawza-signin-title {
    text-align: center;
}

.hawza-signin-note {
    text-align: center;
    margin: 0.25rem 0 1.5rem;
    color: var(--mud-palette-text-secondary);
}

/* The way between the sign-in page and «أول دخول أو رمز جديد» (US 13.1 c1). */
.hawza-signin-link {
    display: block;
    text-align: center;
}

/* THE SIGN-IN SLIP (US 13.1 c1, c6): shown once on a person's file, and printed alone. The code is large, spaced and in
   its own order, to be read out at the desk without a slip of the eye. */
.hawza-slip {
    border: 2px dashed var(--mud-palette-lines-default);
    border-radius: 0.5rem;
    padding: 1.25rem;
    max-width: 32rem;
}

.hawza-slip-title {
    margin: 0 0 0.75rem;
    font-size: 1.15rem;
}

.hawza-slip-facts {
    display: grid;
    gap: 0.5rem;
    margin: 0 0 0.75rem;
}

.hawza-slip-facts dt {
    color: var(--mud-palette-text-secondary);
    font-size: 0.85rem;
}

.hawza-slip-facts dd {
    margin: 0;
    font-weight: 600;
    text-align: start;
    unicode-bidi: isolate;
}

.hawza-slip-code {
    font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
    font-size: 1.5rem;
    letter-spacing: 0.08em;
}

.hawza-slip-line {
    margin: 0.25rem 0;
}

@media print {
    body * {
        visibility: hidden;
    }

    .hawza-slip,
    .hawza-slip * {
        visibility: visible;
    }

    .hawza-slip {
        position: absolute;
        inset-block-start: 0;
        inset-inline-start: 0;
        border-color: #000;
    }

    .hawza-slip-screen-only,
    .hawza-slip-screen-only * {
        display: none;
    }
}

/* A definition list of facts about one record, label over value. */
.hawza-facts {
    display: grid;
    gap: 0.75rem 1.25rem;
    grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
}

.hawza-facts dt {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-facts dd {
    margin-top: 0.125rem;
    font-size: 0.875rem;
    color: var(--mud-palette-text-primary);
}

/* A text a person typed over several lines — a meeting's minutes — kept in its own lines. */
.hawza-typed-lines {
    white-space: pre-line;
}

/* ── THE FRAMEWORK'S OWN STRIPS ─────────────────────────────────────────────
   blazor.web.js finds #blazor-error-ui by its id and shows it by setting
   display, so the box keeps a rule keyed on that id. */
#blazor-error-ui {
    display: none;
    position: fixed;
    inset-inline: 0;
    bottom: 0;
    z-index: 2000;
    padding: 0.75rem 1.25rem;
    background: var(--mud-palette-error);
    color: var(--mud-palette-error-text);
    box-shadow: 0 -1px 6px rgb(0 0 0 / 0.2);
}

#blazor-error-ui a {
    color: inherit;
    text-decoration: underline;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    margin-inline-start: 0.75rem;
}

.blazor-error-boundary {
    padding: 1rem 1.25rem;
    border-radius: var(--mud-default-borderradius);
    background: var(--mud-palette-error);
    color: var(--mud-palette-error-text);
}

.blazor-error-boundary::after {
    content: "حدث خطأ في هذا الجزء من الصفحة.";
}

/* ── THE PREFECT'S DAY ───────────────────────────────────────────────────────
   A lesson as a card and the whole card a link to its form: thumb-sized, one per lesson, the hour at the
   start edge and the state where the eye lands after the name. */
.hawza-session-cards {
    display: grid;
    gap: 8px;
    padding: 12px;
}

.hawza-session-card {
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 72px;
    padding: 12px 16px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: var(--mud-default-borderradius);
    background: var(--mud-palette-surface);
    color: var(--mud-palette-text-primary);
    text-decoration: none;
}

.hawza-session-card:hover,
.hawza-session-card:focus-visible {
    border-color: var(--mud-palette-primary);
    background: var(--mud-palette-action-default-hover);
}

.hawza-session-card--off {
    opacity: 0.7;
}

/* The lesson he is in now: first in the list, and marked on the edge the eye reads from. */
.hawza-session-card--now {
    border-inline-start: 4px solid var(--mud-palette-primary);
}

/* A lesson a swap took off his list: it keeps its place in his day to say where it went, and is no door. */
.hawza-session-card--away:hover {
    border-color: var(--mud-palette-lines-default);
    background: var(--mud-palette-surface);
}

.hawza-session-time {
    min-width: 3.5rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.hawza-session-body {
    display: grid;
    flex: 1;
    gap: 2px;
}

.hawza-session-state {
    margin-top: 4px;
}

.hawza-session-go {
    color: var(--mud-palette-text-secondary);
}

/* ── THE STEPS OF A TASK ────────────────────────────────────────────────────
   The session form is done in order — start, roll call, write-up, send — and a
   row of steps under the bar says where the person is in it. It stays under the
   bar while the roster scrolls. On a phone each step is a mark over a word and
   shares the row; on a desk the mark sits beside the word. A step is a place and
   never a gate, so all of them are pressable and none is drawn disabled. */
.hawza-steps {
    position: sticky;
    top: var(--mud-appbar-height, 56px);
    z-index: 2;
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    padding-block: 8px;
    background: var(--mud-palette-background);
    border-bottom: 1px solid var(--mud-palette-lines-default);
}

.hawza-step {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    min-height: 56px;
    padding: 4px;
    border: 0;
    border-bottom: 3px solid transparent;
    background: transparent;
    color: var(--mud-palette-text-secondary);
    font: inherit;
    font-size: 0.8125rem;
    cursor: pointer;
}

.hawza-step:hover,
.hawza-step:focus-visible {
    color: var(--mud-palette-text-primary);
}

.hawza-step-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 2px solid currentColor;
    border-radius: 50%;
    font-weight: 600;
}

.hawza-step-current {
    border-bottom-color: var(--mud-palette-primary);
    color: var(--mud-palette-primary);
    font-weight: 600;
}

.hawza-step-done .hawza-step-mark {
    border-color: var(--mud-palette-success);
    color: var(--mud-palette-success);
}

.hawza-step-page[hidden] {
    display: none;
}

/* Where a link's fragment lands, once the page has drawn it (FragmentLanding): under the bar, not behind it. */
.hawza-landing {
    scroll-margin-top: calc(var(--mud-appbar-height, 56px) + 16px);
}

/* Where a step change lands: just under the row of steps, not behind it. */
.hawza-step-anchor {
    scroll-margin-top: calc(var(--mud-appbar-height, 56px) + 72px);
    outline: none;
}

.hawza-step-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: space-between;
    margin-bottom: 24px;
}

@media (min-width: 600px) {
    .hawza-step {
        flex: 0 1 11rem;
        flex-direction: row;
        gap: 8px;
        min-height: 48px;
        font-size: 0.875rem;
    }
}

/* ── ONE ANSWER OUT OF A FEW ────────────────────────────────────────────────
   Buttons in a row, 44px tall, sharing the width. The chosen one is tinted in
   the colour of what it means AND ticked, and the tint is only a tint — the
   words stay in the ordinary text colour, which is what keeps them readable in
   both schemes. */
.hawza-choice {
    display: flex;
    overflow: hidden;
    border: 1px solid var(--mud-palette-lines-inputs);
    border-radius: 10px;
}

.hawza-choice-item {
    display: inline-flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    min-height: 44px;
    padding-inline: 8px;
    border: 0;
    background: transparent;
    color: var(--mud-palette-text-primary);
    font: inherit;
    cursor: pointer;
}

.hawza-choice-item + .hawza-choice-item {
    border-inline-start: 1px solid var(--mud-palette-lines-inputs);
}

.hawza-choice-item:hover:not(:disabled) {
    background: var(--mud-palette-action-default-hover);
}

.hawza-choice-item:disabled {
    cursor: default;
}

.hawza-choice-chosen {
    font-weight: 600;
}

.hawza-choice-chosen.hawza-choice-good {
    background: rgba(var(--mud-palette-success-rgb), 0.22);
    box-shadow: inset 0 -3px 0 var(--mud-palette-success);
}

.hawza-choice-chosen.hawza-choice-warn {
    background: rgba(var(--mud-palette-warning-rgb), 0.22);
    box-shadow: inset 0 -3px 0 var(--mud-palette-warning);
}

.hawza-choice-chosen.hawza-choice-crit {
    background: rgba(var(--mud-palette-error-rgb), 0.22);
    box-shadow: inset 0 -3px 0 var(--mud-palette-error);
}

.hawza-choice-chosen.hawza-choice-plain {
    background: rgba(var(--mud-palette-primary-rgb), 0.16);
    box-shadow: inset 0 -3px 0 var(--mud-palette-primary);
}

/* ── WHO IS PICKED ──────────────────────────────────────────────────────────
   Under an EntityPicker that takes several: a pill for each person, with the
   button that takes the pick back. Every pill is 44px tall because the button
   in it is a finger's target on a phone (the audit's A6), and a pill is as tall
   as what it holds. */
.hawza-picked {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
}

.hawza-picked-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    max-width: 100%;
    min-height: 44px;
    padding-inline: 12px 4px;
    border: 1px solid var(--mud-palette-lines-inputs);
    border-radius: 10px;
    overflow-wrap: anywhere;
}

/* A picked row that holds more than a name (PickedContent): one row each, as wide as the box, wrapping on a phone. */
.hawza-picked-rows {
    flex-direction: column;
    align-items: stretch;
}

.hawza-picked-rows .hawza-picked-item {
    flex-wrap: wrap;
    padding-block: 4px;
}

.hawza-picked-code {
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
}

/* ── THE ROLL ───────────────────────────────────────────────────────────────
   One row a student. On a phone it is a card: the name over the answer, the
   arrival time under it only when the answer is «late», and the events link at
   the foot, each as wide as the screen. From tablet up it is a table's row
   again — name, answer, time, events — without being a table, so nothing about
   it scrolls sideways. */
.hawza-roster {
    display: flex;
    flex-direction: column;
}

.hawza-roster-head {
    display: none;
}

.hawza-roster-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    align-items: center;
    padding-block: 12px;
    border-top: 1px solid var(--mud-palette-lines-default);
}

.hawza-roster-who {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.hawza-roster-arrival:empty {
    display: none;
}

@media (min-width: 720px) {
    .hawza-roster-head,
    .hawza-roster-row {
        grid-template-columns: minmax(10rem, 1.3fr) minmax(15rem, 18rem) 9rem minmax(8rem, auto);
        gap: 16px;
    }

    .hawza-roster-head {
        display: grid;
        padding-block: 8px;
        color: var(--mud-palette-text-secondary);
        font-weight: 600;
    }
}

.hawza-roster-status {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.hawza-roster-events {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 8px;
}

.hawza-step-title {
    min-width: 0;
    line-height: 1.2;
    text-align: center;
}

/* ── THE PREFECT'S BAR ──────────────────────────────────────────────────────
   Home, his sessions, his account, at the foot of a phone. Nowhere else: on a
   desk the prefect has the drawer, and a bar that is drawn but never seen would
   still be counted by the audit. The page gets room under it, and the sticky
   bar of a long form sits above it instead of behind it. */
.hawza-phonebar {
    display: none;
}

@media (max-width: 599.98px) {
    .hawza-phonebar {
        position: fixed;
        inset-inline: 0;
        bottom: 0;
        z-index: 3;
        display: flex;
        background: var(--mud-palette-surface);
        border-top: 1px solid var(--mud-palette-lines-default);
    }

    .hawza-phonebar-item {
        display: flex;
        flex: 1 1 0;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2px;
        min-height: 56px;
        color: var(--mud-palette-text-secondary);
        font-size: 0.8125rem;
        text-decoration: none;
    }

    .hawza-phonebar-active {
        color: var(--mud-palette-primary);
        font-weight: 600;
    }

    /* What is waiting behind an item, on the corner of its icon and not at the far end of a row. */
    .hawza-phonebar-item {
        position: relative;
    }

    .hawza-phonebar-item .hawza-nav-count {
        position: absolute;
        top: 6px;
        inset-inline-start: calc(50% + 6px);
        margin-inline-start: 0;
    }

    .hawza-has-phonebar {
        padding-bottom: 64px;
    }

    .hawza-has-phonebar .hawza-actionbar {
        bottom: 56px;
    }
}

/* ── THE PORTAL'S BAR ───────────────────────────────────────────────────────
   A student's or a teacher's places (PortalBar), at the foot at EVERY width:
   the portal has no drawer to fall back on, on a phone or on a desk. The same
   shape as the prefect's bar, which is drawn on phones alone. */
.hawza-portalbar {
    position: fixed;
    inset-inline: 0;
    bottom: 0;
    z-index: 3;
    display: flex;
    background: var(--mud-palette-surface);
    border-top: 1px solid var(--mud-palette-lines-default);
}

.hawza-portalbar-item {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-height: 56px;
    color: var(--mud-palette-text-secondary);
    font-size: 0.8125rem;
    text-decoration: none;
}

.hawza-portalbar-active {
    color: var(--mud-palette-primary);
    font-weight: 600;
}

.hawza-has-portalbar {
    padding-bottom: 64px;
}

/* The portal's pages (US 13.1): label-and-value rows stacked one under the other, and one card per course, so a phone
   never scrolls sideways. */
.hawza-portal-lines {
    margin: 0;
}

.hawza-portal-line {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--mud-palette-lines-default);
}

.hawza-portal-line:last-child {
    border-bottom: none;
}

.hawza-portal-line dt {
    min-width: 120px;
    color: var(--mud-palette-text-secondary);
}

.hawza-portal-line dd {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    overflow-wrap: anywhere;
}

.hawza-portal-cards {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
}

.hawza-portal-card {
    padding: 12px 16px;
}

.hawza-portal-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.hawza-portal-period,
.hawza-portal-term {
    margin: 12px 0 8px;
}

.hawza-portal-note {
    margin-top: 16px;
    color: var(--mud-palette-text-secondary);
}

/* Where a refusal lands when it is brought into view: under the bar, and with no ring, since the
   notice is not a control. */
.hawza-notice-frame {
    scroll-margin-top: calc(var(--mud-appbar-height, 56px) + 16px);
    outline: none;
}

/* ── THE SNACKBAR ───────────────────────────────────────────────────────────
   «Done», bottom centre. On a phone it rides above what sits at the foot — the
   sticky bar of a long form and the prefect's bar — instead of covering them for
   the five seconds it stays. */
@media (max-width: 599.98px) {
    .mud-snackbar-location-bottom-center {
        bottom: 72px;
    }
}

/* A refusal brought into view lands under the bar, with no ring: it is not a control. */
.hawza-field-error {
    scroll-margin-top: calc(var(--mud-appbar-height, 56px) + 16px);
    outline: none;
}

/* ── THE FILE OF A PERSON, A CLASS, A COURSE ────────────────────────────────
   The identity block above every tab and the row of tabs under it. The block is
   the page's header with a line of its own — the code and the states — and,
   under it, the few facts a reader wants before opening anything. The tabs are
   links; on a phone the row scrolls inside its own strip and never the page,
   and every tab is 44px tall. */
.hawza-entity-line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.hawza-entity-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 24px;
    margin: 8px 0 0;
}

.hawza-entity-facts > div {
    display: flex;
    gap: 6px;
}

.hawza-entity-facts dt {
    color: var(--mud-palette-text-secondary);
}

.hawza-entity-facts dt::after {
    content: ":";
}

.hawza-entity-facts dd {
    margin: 0;
    color: var(--mud-palette-text-primary);
}

.hawza-filetabs {
    display: flex;
    gap: 4px;
    margin-bottom: 24px;
    overflow-x: auto;
    border-bottom: 1px solid var(--mud-palette-lines-default);
}

.hawza-filetab {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding-inline: 16px;
    border-bottom: 3px solid transparent;
    color: var(--mud-palette-text-secondary);
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
}

.hawza-filetab:hover,
.hawza-filetab:focus-visible {
    background: var(--mud-palette-action-default-hover);
    color: var(--mud-palette-text-primary);
}

.hawza-filetab-current {
    border-bottom-color: var(--mud-palette-primary);
    color: var(--mud-palette-primary);
    font-weight: 600;
}

.hawza-filetab-count {
    min-width: 1.5rem;
    padding-inline: 6px;
    border-radius: 999px;
    background: var(--mud-palette-background-gray);
    color: var(--mud-palette-text-secondary);
    font-size: 0.75rem;
    text-align: center;
}

/* A file whose tabs fall into groups — a person's own tabs, then each role's: each group is its heading over its own
   row of tabs, and the groups stand side by side on the one hairline. A group with no heading (the person's own)
   sits on that hairline too, its row level with the others' rather than with their headings. */
.hawza-filetabs-grouped {
    gap: 1.5rem;
    align-items: flex-end;
}

.hawza-filetab-group {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
}

.hawza-filetab-heading {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 1rem 0;
    color: var(--mud-palette-text-secondary);
    font-size: 0.8125rem;
    font-weight: 600;
}

.hawza-filetab-row {
    display: flex;
    gap: 4px;
}

/* On a phone no tab hides off the edge: the tabs wrap onto further lines, and each group of a grouped file
   takes a row of its own (its heading, then its tabs) so the teacher's group drops below the student's. */
@media (max-width: 599.98px) {
    .hawza-filetabs {
        flex-wrap: wrap;
        overflow-x: visible;
    }

    .hawza-filetabs-grouped {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }

    .hawza-filetab-row {
        flex-wrap: wrap;
    }
}

/* ── THE QUICK SEARCH ───────────────────────────────────────────────────────
   One box over the page, and a list of what it found under it, grouped by
   kind. The marked result is the one Enter goes to; the hover and the mark are
   the same tint, because a pointer and the arrow keys are one way of choosing. */
.hawza-palette-list {
    display: flex;
    flex-direction: column;
    max-height: min(60vh, 28rem);
    margin-top: 8px;
    overflow-y: auto;
}

.hawza-palette-group {
    padding: 12px 12px 4px;
    color: var(--mud-palette-text-secondary);
    font-size: 0.8125rem;
    font-weight: 600;
}

.hawza-palette-hit {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 8px 12px;
    border-radius: 10px;
    color: var(--mud-palette-text-primary);
    text-decoration: none;
}

/* An act offered under the marked person (slice 4): indented under him, on the reading side. */
.hawza-palette-act {
    min-height: 40px;
    padding-inline-start: 44px;
    color: var(--mud-palette-text-secondary);
}

.hawza-palette-hit:hover,
.hawza-palette-active {
    background: rgba(var(--mud-palette-primary-rgb), 0.12);
}

.hawza-palette-title {
    flex: 1 1 auto;
    min-width: 0;
    font-weight: 600;
}

.hawza-palette-sub {
    color: var(--mud-palette-text-secondary);
    font-size: 0.8125rem;
}

.hawza-palette-none {
    padding: 24px 12px;
    color: var(--mud-palette-text-secondary);
    text-align: center;
}

/* ── THE SIDE SHEET ─────────────────────────────────────────────────────────
   A record beside its list. 560px on a desk, the whole screen on a phone. The
   head keeps the title and the way out where the thumb finds them while the
   body scrolls. */
:root {
    --hawza-sheet-width: min(560px, 100vw);
}

.hawza-sheet {
    z-index: 1300;
}

.hawza-sheet-head {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 16px;
    background: var(--mud-palette-surface);
    border-bottom: 1px solid var(--mud-palette-lines-default);
}

.hawza-sheet-body {
    padding: 16px;
}

/* ── THE YEAR'S SETUP ───────────────────────────────────────────────────────
   The office's order as a list: a mark, what it is, how much is there, and the
   way to it. A step with something in it wears a tick, never a colour alone. */
.hawza-setup {
    margin: 0;
    padding: 0;
    list-style: none;
}

.hawza-setup-step {
    display: grid;
    grid-template-columns: 32px minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    border-top: 1px solid var(--mud-palette-lines-default);
}

.hawza-setup-step:first-child {
    border-top: 0;
}

.hawza-setup-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 2px solid var(--mud-palette-text-secondary);
    border-radius: 50%;
    color: var(--mud-palette-text-secondary);
    font-weight: 600;
}

.hawza-setup-done {
    border-color: var(--mud-palette-success);
    color: var(--mud-palette-success);
}

.hawza-setup-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.hawza-setup-count {
    display: flex;
    align-items: baseline;
    gap: 6px;
    min-width: 6rem;
}

@media (max-width: 599.98px) {
    .hawza-setup-step {
        grid-template-columns: 32px minmax(0, 1fr);
        row-gap: 8px;
    }

    .hawza-setup-count,
    .hawza-setup-step > .mud-button-root {
        grid-column: 2;
    }
}

.hawza-sheet-title {
    margin: 0;
}

/* The sheet is a paper over the page, not a second navigation drawer: it wears the surface and the ordinary ink
   and not the drawer's green. */
.mud-drawer.hawza-sheet {
    background-color: var(--mud-palette-surface);
    color: var(--mud-palette-text-primary);
}

/* ── VISUALS ────────────────────────────────────────────────────────────────
   The small pictures of a person's file (Components/Shared/Visuals): a face, a
   ring, a meter, a bar of parts, a strip of dots, a tile, a list of what needs
   attention and a timeline. Each draws figures a page has already worked out,
   and each prints them as text too, so a picture is never the only way to read
   a value.

   ONE TONE VARIABLE. A tone class sets --hawza-tone to a palette colour and
   every shape inside draws with it, so dark mode is the theme's business and
   no picture names a colour. Only a judgment carries a tone of its own; a
   plain measure is primary and a plain count is the secondary ink.

   A TRACK IS THE LINES COLOUR: the same hairline as a panel's border, so an
   empty track reads as «nothing here yet», not as a value of its own.

   RIGHT TO LEFT. Fills and parts are laid out with logical sizes from the
   inline start, so in Arabic they grow from the right with nothing mirrored.
   A ring is the one exception that keeps its geometry: it starts at the top
   and runs clockwise in either direction, like a clock face. */
.hawza-tone-neutral { --hawza-tone: var(--mud-palette-text-secondary); }
.hawza-tone-primary { --hawza-tone: var(--mud-palette-primary); }
.hawza-tone-success { --hawza-tone: var(--mud-palette-success); }
.hawza-tone-warning { --hawza-tone: var(--mud-palette-warning); }
.hawza-tone-error { --hawza-tone: var(--mud-palette-error); }

/* A face. The four tints are the brand's colours and none is a verdict; the
   initials stay in the ordinary ink, measured on each tint in
   ThemeContrastTests at the 18% drawn here. */
.hawza-avatar {
    display: inline-grid;
    place-items: center;
    flex: none;
    inline-size: var(--hawza-avatar-size);
    block-size: var(--hawza-avatar-size);
    border-radius: 50%;
    overflow: hidden;
    background: color-mix(in srgb, var(--hawza-avatar-tint) 18%, var(--mud-palette-surface));
    box-shadow: inset 0 0 0 1px var(--mud-palette-lines-default);
}

.hawza-avatar-tint-0 { --hawza-avatar-tint: var(--mud-palette-primary); }
.hawza-avatar-tint-1 { --hawza-avatar-tint: var(--mud-palette-secondary); }
.hawza-avatar-tint-2 { --hawza-avatar-tint: var(--mud-palette-tertiary); }
.hawza-avatar-tint-3 { --hawza-avatar-tint: var(--mud-palette-info); }

.hawza-avatar-portrait {
    inline-size: 100%;
    block-size: 100%;
    object-fit: cover;
}

.hawza-avatar-initials {
    font-size: calc(var(--hawza-avatar-size) * 0.38);
    font-weight: 600;
    line-height: 1;
    color: var(--mud-palette-text-primary);
}

/* A ring. The figure sits in the centre as text, sized with the ring so a
   smaller ring keeps its proportions. */
.hawza-ring {
    position: relative;
    flex: none;
    inline-size: var(--hawza-ring-size);
    block-size: var(--hawza-ring-size);
}

.hawza-ring-svg {
    display: block;
    inline-size: 100%;
    block-size: 100%;
    transform: rotate(-90deg); /* SVG strokes start at three o'clock; the reading starts at twelve */
}

.hawza-ring-track,
.hawza-ring-arc {
    fill: none;
    stroke-width: 3.2;
}

.hawza-ring-track { stroke: var(--mud-palette-lines-default); }
.hawza-ring-arc { stroke: var(--hawza-tone); }

.hawza-ring-figure {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: calc(var(--hawza-ring-size) * 0.2);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    line-height: 1;
    white-space: nowrap;
    unicode-bidi: plaintext;
    color: var(--mud-palette-text-primary);
}

/* A meter. */
.hawza-gauge {
    block-size: 8px;
    inline-size: 100%;
    overflow: hidden;
    border-radius: 999px;
    background: var(--mud-palette-lines-default);
}

.hawza-gauge-fill {
    block-size: 100%;
    border-radius: inherit;
    background: var(--hawza-tone);
}

/* A bar of parts, with its legend under it. A hairline of the surface between
   two parts keeps neighbours of close tones apart. */
.hawza-parts {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-inline-size: 0;
}

.hawza-parts-bar {
    display: flex;
    block-size: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: var(--mud-palette-lines-default);
}

.hawza-parts-segment {
    box-sizing: border-box;
    background: var(--hawza-tone);
}

.hawza-parts-segment + .hawza-parts-segment {
    border-inline-start: 2px solid var(--mud-palette-surface);
}

.hawza-parts-legend,
.hawza-dot-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 16px;
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: 0.8125rem;
    color: var(--mud-palette-text-secondary);
}

.hawza-parts-legend > li,
.hawza-dot-legend > li {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.hawza-parts-legend .num {
    font-weight: 600;
    color: var(--mud-palette-text-primary);
}

.hawza-swatch {
    flex: none;
    inline-size: 10px;
    block-size: 10px;
    border-radius: 3px;
    background: var(--hawza-tone);
}

/* A strip of dots, oldest first. Each shape draws in currentColor, so the
   tone class is all it needs. */
.hawza-dots {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.hawza-dot-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hawza-dot {
    display: inline-flex;
    flex: none;
    inline-size: 16px;
    block-size: 16px;
    color: var(--hawza-tone);
}

.hawza-dot > svg {
    inline-size: 100%;
    block-size: 100%;
}

/* A standing tile. It is a link to the tab that holds the detail, so it lifts
   on hover; a picture that needs the width (a bar, a meter) takes the whole
   line, a ring stands beside its sentence. */
.hawza-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

@media (max-width: 959.98px) {
    .hawza-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 599.98px) {
    .hawza-stats { gap: 8px; }
}

.hawza-stat {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-inline-size: 0;
    padding: 16px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 10px;
    background: var(--mud-palette-surface);
    color: var(--mud-palette-text-primary);
    text-decoration: none;
}

.hawza-stat-link {
    transition: box-shadow 120ms ease-out;
}

.hawza-stat-link:hover {
    box-shadow: var(--mud-elevation-1);
}

.hawza-stat-link:focus-visible {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

.hawza-stat-head {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--mud-palette-text-secondary);
}

.hawza-stat-body {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 16px;
}

.hawza-stat-visual {
    flex: none;
}

.hawza-stat-visual:has(> .hawza-parts, > .hawza-gauge) {
    flex: 1 1 100%;
}

.hawza-stat-text {
    display: flex;
    flex: 1 1 8rem;
    flex-direction: column;
    gap: 4px;
    min-inline-size: 0;
}

.hawza-stat-figure {
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.25;
    font-variant-numeric: tabular-nums;
    overflow-wrap: anywhere;
}

.hawza-stat-caption {
    font-size: 0.8125rem;
    color: var(--mud-palette-text-secondary);
}

/* What needs attention. The icon carries the tone on a faint disc of it; the
   sentence stays in the ordinary ink, or the link colour when it opens
   something. */
.hawza-attention {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hawza-attention-line {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding-block: 8px;
}

.hawza-attention-line + .hawza-attention-line {
    border-block-start: 1px solid var(--mud-palette-lines-default);
}

.hawza-attention-icon {
    display: inline-grid;
    place-items: center;
    flex: none;
    inline-size: 28px;
    block-size: 28px;
    border-radius: 50%;
    color: var(--hawza-tone);
    background: color-mix(in srgb, var(--hawza-tone) 12%, transparent);
}

.hawza-attention-text {
    padding-block: 4px;
    min-inline-size: 0;
    color: var(--mud-palette-text-primary);
}

a.hawza-attention-text {
    color: var(--mud-palette-primary);
    text-decoration: none;
}

a.hawza-attention-text:hover {
    text-decoration: underline;
}

/* A timeline, newest first, grouped by month. A rail joins the icons along
   the inline start; the old value of a change is struck through beside the
   new one. */
.hawza-timeline,
.hawza-timeline-items {
    margin: 0;
    padding: 0;
    list-style: none;
}

.hawza-timeline-month {
    margin: 24px 0 8px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-timeline > li:first-child > .hawza-timeline-month {
    margin-block-start: 0;
}

.hawza-timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 12px;
    padding-block-end: 16px;
}

.hawza-timeline-item::before {
    content: "";
    position: absolute;
    inset-inline-start: 13px;
    inset-block: 32px 4px;
    inline-size: 2px;
    border-radius: 1px;
    background: var(--mud-palette-lines-default);
}

.hawza-timeline-item:last-child::before {
    display: none;
}

.hawza-timeline-icon {
    display: inline-grid;
    place-items: center;
    inline-size: 28px;
    block-size: 28px;
    border-radius: 50%;
    color: var(--mud-palette-text-secondary);
    background: color-mix(in srgb, var(--mud-palette-text-primary) 8%, transparent);
}

.hawza-timeline-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-inline-size: 0;
    padding-block-start: 4px;
}

.hawza-timeline-title {
    font-weight: 500;
    color: var(--mud-palette-text-primary);
}

.hawza-timeline-change {
    font-size: 0.875rem;
    overflow-wrap: anywhere;
}

.hawza-timeline-change del {
    color: var(--mud-palette-text-secondary);
}

.hawza-timeline-meta {
    font-size: 0.8125rem;
    color: var(--mud-palette-text-secondary);
}

/* ── THE PERSON'S HEADER ────────────────────────────────────────────────────
   The band above every tab of a person's file: a face, and beside it the
   page's own header — the trail, the name as the screen's one title, the code
   and the states, the few facts a reader wants before opening anything — with
   the acts at the far end. A tint of the primary over the surface, and behind
   the words the bar's lattice of stars, far fainter: it is a mask over a layer
   of the primary, so the theme colours it in both schemes.

   ON A PHONE the face is smaller and the line of facts wraps. The acts stay at
   the inline end, on a line of their own when the name leaves them no room. */
.hawza-hero {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-block-end: 24px;
    padding: 16px 24px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 10px;
    background: color-mix(in srgb, var(--mud-palette-primary) 6%, var(--mud-palette-surface));
}

.hawza-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    background: var(--mud-palette-primary);
    opacity: 0.1;
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='56' viewBox='0 0 56 56'%3E%3Cg fill='none' stroke='%23000' stroke-width='1'%3E%3Crect x='16' y='16' width='24' height='24'/%3E%3Crect x='16' y='16' width='24' height='24' transform='rotate(45 28 28)'/%3E%3Cpath d='M0 28h8M48 28h8M28 0v8M28 48v8'/%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.hawza-hero > .hawza-page-head {
    flex: 1 1 0;
    align-items: center;
    min-inline-size: 0;
    margin-block-end: 0;
}

.hawza-hero .hawza-page-title {
    overflow-wrap: anywhere;
}

.hawza-hero-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 24px;
    margin: 0;
    margin-block-start: 8px;
    padding: 0;
    list-style: none;
    color: var(--mud-palette-text-secondary);
}

.hawza-hero-fact {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-inline-size: 0;
    overflow-wrap: anywhere;
}

.hawza-hero-fact a {
    color: var(--mud-palette-primary);
    text-decoration: none;
}

.hawza-hero-fact a:hover,
.hawza-hero-fact a:focus-visible {
    text-decoration: underline;
}

@media (max-width: 599.98px) {
    .hawza-hero {
        align-items: flex-start;
        gap: 12px;
        padding: 12px 16px;
    }

    /* The component sets the face's size in pixels, so the phone's smaller one is set here, the monogram kept at the
       proportion the avatar gives it (38% of the face). */
    .hawza-hero .hawza-avatar {
        inline-size: 56px;
        block-size: 56px;
    }

    .hawza-hero .hawza-avatar-initials {
        font-size: 21px;
    }

    .hawza-hero .hawza-page-actions {
        margin-inline-start: auto;
    }
}

/* ── THE OVERVIEW OF A PERSON'S FILE ────────────────────────────────────────
   What needs attention, the standing as tiles, the term's attendance, and
   then side by side who he is and what has happened to his file. One rhythm
   of 24px between the parts, so the page reads as one document; the panels
   inside the two columns keep it too, instead of the stack's own margin. */
.hawza-overview {
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-inline-size: 0;
}

.hawza-overview .hawza-panel + .hawza-panel {
    margin-top: 0;
}

.hawza-overview-heading,
.hawza-overview-role {
    margin: 0 0 8px;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0;
    color: var(--mud-palette-text-secondary);
}

/* A role's name over its tiles, on a hairline that runs to the far edge, so
   the student's set and the teacher's read as two parts of one grid. */
.hawza-overview-role {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-block-end: 12px;
    font-size: 0.875rem;
    color: var(--mud-palette-primary);
}

.hawza-overview-role::after {
    content: "";
    flex: 1 1 auto;
    block-size: 1px;
    background: var(--mud-palette-lines-default);
}

.hawza-overview-subheading {
    margin: 0 0 12px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--mud-palette-text-primary);
}

/* What needs attention sits on the surface like a panel, a hairline of the
   warning tone on its inline start: it is the one part of the page that
   asks something of its reader. */
.hawza-overview-attention {
    padding: 12px 20px 8px;
    border: 1px solid var(--mud-palette-lines-default);
    border-inline-start: 4px solid var(--mud-palette-warning);
    border-radius: 10px;
    background: var(--mud-palette-surface);
}

/* A verdict as a badge: the tone's icon on a faint disc of it, near the size
   of a ring, so the tiles of a row stand level. */
.hawza-verdict {
    display: inline-grid;
    place-items: center;
    inline-size: 64px;
    block-size: 64px;
    border-radius: 50%;
    color: var(--hawza-tone);
    background: color-mix(in srgb, var(--hawza-tone) 14%, transparent);
    box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--hawza-tone) 45%, transparent);
}

.hawza-verdict .mud-icon-root {
    font-size: 2rem;
}

/* Names in a tile: small chips under the figure, each cut with an ellipsis
   rather than pushing the tile wider than its column. */
.hawza-stat-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hawza-stat-chips > li {
    max-inline-size: 100%;
    padding: 2px 10px;
    overflow: hidden;
    border-radius: 999px;
    font-size: 0.8125rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: var(--mud-palette-text-primary);
    background: color-mix(in srgb, var(--mud-palette-text-primary) 8%, transparent);
}

/* A picture that takes the tile's width goes under the figure it explains:
   the figure is what a reader looks for first. */
.hawza-stat-visual:has(> .hawza-parts, > .hawza-stat-chips) {
    flex: 1 1 100%;
    order: 1;
}

/* The tiles of a row are as tall as the tallest. */
.hawza-stats > .hawza-stat {
    block-size: 100%;
    box-sizing: border-box;
}

/* The term's attendance: a meter for each course, its name over its class,
   the figure at the end; on a wide screen the latest lessons stand beside. */
.hawza-term-attendance {
    display: grid;
    gap: 24px;
}

@media (min-width: 1280px) {
    .hawza-term-attendance:has(> .hawza-course-meters + .hawza-term-dots) {
        grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    }
}

.hawza-course-meters {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hawza-course-meter {
    display: grid;
    grid-template-columns: minmax(7rem, 1.1fr) minmax(4rem, 2fr) 5.5rem;
    align-items: center;
    gap: 4px 16px;
}

.hawza-course-meter-name {
    display: flex;
    flex-direction: column;
    min-inline-size: 0;
    line-height: 1.3;
}

.hawza-course-meter-name > span {
    overflow-wrap: anywhere;
}

.hawza-course-meter-figure {
    font-weight: 600;
    text-align: end;
    font-variant-numeric: tabular-nums;
}

.hawza-course-meter-figure.hawza-sub {
    font-weight: 400;
    font-size: 0.8125rem;
}

/* A course's «التقدم» tab: the term's name on its hairline with «تعديل المستهدف» at its end, and under the tiles the
   achievement as one meter — its word, the bar, the figure, and «تجاوز المستهدف» when it is passed. */
.hawza-progress-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-block-end: 12px;
}

.hawza-progress-head .hawza-overview-role {
    flex: 1 1 auto;
    margin-block-end: 0;
}

/* An hours course has five tiles: one row of five on a desk, and on a narrower screen the fifth takes the whole row
   rather than standing alone in half of it. */
@media (min-width: 960px) {
    .hawza-stats.hawza-stats--five { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (max-width: 959.98px) {
    .hawza-stats.hawza-stats--five > :last-child { grid-column: 1 / -1; }
}

/* «المنجز» over «المتوقع»: one grid for both, so the two bars start and end together whatever their words. */
.hawza-progress-meters {
    display: grid;
    grid-template-columns: auto minmax(4rem, 1fr) auto minmax(0, auto);
    align-items: center;
    gap: 12px 16px;
    margin-block-start: 16px;
}

.hawza-progress-meter {
    display: contents;
}

@media (max-width: 599.98px) {
    /* On a phone the chip or the label beside a meter takes a line of its own under it. */
    .hawza-progress-meters { grid-template-columns: auto minmax(3rem, 1fr) auto; }
    .hawza-progress-meter-note { grid-column: 2 / -1; }
    .hawza-progress-meter-note:not(:has(*)) { display: none; }
}

/* A course's achievement in a row of «تقدّم المقررات»: the bar, its figure at the end. */
.hawza-row-meter {
    display: grid;
    grid-template-columns: minmax(5rem, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-inline-size: 9rem;
}

/* One tile across a sheet («حد التعثر»), or a row of tiles above a list («المقررات المتعثرة»). */
.hawza-stats.hawza-stats--one { grid-template-columns: minmax(0, 1fr); }

/* Six tiles (an hours course with its gap): two rows of three on a desk. */
@media (min-width: 960px) {
    .hawza-stats.hawza-stats--six { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.hawza-term-dots .hawza-dot-strip {
    gap: 6px;
}

.hawza-term-dots .hawza-dot-strip > .hawza-dot {
    inline-size: 20px;
    block-size: 20px;
}

@media (max-width: 599.98px) {
    /* On a phone the name takes its own line and the meter runs the width
       under it, with the figure at its end. */
    .hawza-course-meter {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .hawza-course-meter-name {
        grid-column: 1 / -1;
    }
}

/* Who he is beside what has happened, on a screen wide enough for both. */
.hawza-overview-columns {
    display: grid;
    gap: 24px;
    align-items: start;
}

@media (min-width: 1200px) {
    .hawza-overview-columns {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
}

.hawza-overview-columns > * {
    min-inline-size: 0;
}

/* The card: the opening sentence, then each answer under its icon. */
.hawza-identity-opening {
    margin: 0 0 20px;
    font-size: 1.0625rem;
    font-weight: 600;
    line-height: 1.6;
    color: var(--mud-palette-text-primary);
}

.hawza-identity-facts {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
    gap: 16px 24px;
    margin: 0;
}

.hawza-identity-fact {
    min-inline-size: 0;
}

.hawza-identity-fact dt {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--mud-palette-text-secondary);
}

.hawza-identity-fact dt .mud-icon-root {
    font-size: 1rem;
    color: var(--mud-palette-primary);
}

.hawza-identity-fact dd {
    margin: 2px 0 0;
    padding-inline-start: 22px;
    font-size: 0.875rem;
    color: var(--mud-palette-text-primary);
    overflow-wrap: anywhere;
}

/* A Latin fact keeps its own direction but lines up with the Arabic ones. */
.hawza-identity-fact dd[dir="ltr"] {
    text-align: end;
}

.hawza-identity-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
    margin-block-start: 20px;
    padding-block-start: 16px;
    border-block-start: 1px solid var(--mud-palette-lines-default);
}

.hawza-identity-complete {
    display: flex;
    flex: 1 1 12rem;
    flex-direction: column;
    gap: 6px;
    max-inline-size: 20rem;
}

/* The timeline's own parts: the filters over it, «كان ← صار» along a line
   that wraps whole, and «عرض الكل» under it. */
.hawza-timeline-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px 16px;
    margin-block-end: 20px;
}

.hawza-timeline-kinds {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.hawza-timeline-kinds .mud-chip {
    margin: 0;
}

.hawza-timeline-year {
    flex: 0 1 12rem;
    min-inline-size: 9rem;
}

.hawza-timeline-change {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 2px 8px;
}

/* Each line hugs the inline start, a line of figures too, which is set left
   to right inside its own isolate. */
.hawza-timeline-was,
.hawza-timeline-became {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    min-inline-size: 0;
}

.hawza-timeline-arrow {
    color: var(--mud-palette-text-secondary);
}

.hawza-timeline-reason {
    font-size: 0.875rem;
    color: var(--mud-palette-text-secondary);
}

.hawza-timeline-none {
    margin: 0;
    color: var(--mud-palette-text-secondary);
}

.hawza-timeline-more {
    display: flex;
    justify-content: center;
    padding-block-start: 8px;
    border-block-start: 1px dashed var(--mud-palette-lines-default);
}

/* A state chip that opens what it names (a class request waiting): the chip, not an underlined link. */
.hawza-chip-link {
    text-decoration: none;
    border-radius: 16px;
}

.hawza-chip-link:focus-visible {
    outline: 2px solid var(--mud-palette-primary);
    outline-offset: 2px;
}

/* ── THE CALENDAR AS A MONTH, A WEEK AND A LIST (spec:655) ──────────────────
   Drawn in-house (D10): seven columns Saturday to Friday, a day of the weeks
   around the month drawn faint, a weekend nobody teaches on drawn quiet. What a
   waiting request would put there is drawn DASHED — never like what stands. */
.hawza-cal-month {
    display: grid;
    gap: 1px;
    overflow-x: auto;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 10px;
    background: var(--mud-palette-lines-default);
}

.hawza-cal-row {
    display: grid;
    grid-template-columns: repeat(7, minmax(96px, 1fr));
    gap: 1px;
}

.hawza-cal-head {
    padding: 6px 8px;
    background: var(--mud-palette-background-gray);
    font-weight: 600;
    text-align: center;
}

.hawza-cal-day {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-height: 96px;
    padding: 6px;
    background: var(--mud-palette-surface);
}

.hawza-cal-out {
    opacity: 0.55;
}

.hawza-cal-rest {
    background: var(--mud-palette-background-gray);
}

/* Today, ringed in the primary colour inside its cell: a mark, not a fill, so a
   quiet weekend stays quiet. */
.hawza-cal-today {
    box-shadow: inset 0 0 0 2px var(--mud-palette-primary);
}

.hawza-cal-date {
    font-weight: 600;
}

.hawza-cal-marker {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--mud-palette-primary);
}

.hawza-cal-line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    padding: 2px 4px;
    border: 1px solid transparent;
    border-radius: 6px;
}

.hawza-cal-pending {
    border-color: var(--mud-palette-text-secondary);
    border-style: dashed;
}

.hawza-cal-title {
    min-width: 0;
    overflow-wrap: anywhere;
}

.hawza-cal-week {
    display: grid;
    gap: 1px;
    border: 1px solid var(--mud-palette-lines-default);
    border-radius: 10px;
    overflow: hidden;
    background: var(--mud-palette-lines-default);
}

.hawza-cal-weekday {
    display: grid;
    grid-template-columns: minmax(120px, 160px) 1fr;
    gap: 12px;
    padding: 8px 12px;
    background: var(--mud-palette-surface);
}

.hawza-cal-weekday.hawza-cal-rest {
    background: var(--mud-palette-background-gray);
}

.hawza-cal-weekday-name {
    display: flex;
    flex-direction: column;
}

.hawza-cal-agenda {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding-block: 6px;
    border-block-end: 1px solid var(--mud-palette-lines-default);
}

.hawza-cal-agenda-dates {
    min-width: 11rem;
}

/* With no view in the address the page opens on the month — and on a phone on
   the list: both are drawn, and the width decides which is seen. */
.hawza-cal-narrow {
    display: none;
}

@media (max-width: 599.98px) {
    .hawza-cal-wide {
        display: none;
    }

    .hawza-cal-narrow {
        display: block;
    }

    .hawza-cal-weekday {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}

/* One clear button in a search box: a field marked Clearable draws its own, so the
   browser's native one beside it is hidden (the register's search showed both). */
.mud-input input[type="search"]::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
    display: none;
}

/* ── THE RECONNECT BOX (ReconnectModal, in the kit) ─────────────────────────────────
   The box a dropped circuit shows, on the main site and on the عريف's app's first visit. Here and not in a scoped
   .razor.css: this sheet is the one both documents link and the app's worker keeps (ArifShellFiles), while a scoped
   sheet in the kit would make the app's build list a bundle the host does not serve. Every selector is the modal's
   own id or blazor.web.js's class names, so nothing else on a page is touched. */
.components-reconnect-first-attempt-visible,
.components-reconnect-repeated-attempt-visible,
.components-reconnect-failed-visible,
.components-pause-visible,
.components-resume-failed-visible,
.components-rejoining-animation {
    display: none;
}

#components-reconnect-modal.components-reconnect-show .components-reconnect-first-attempt-visible,
#components-reconnect-modal.components-reconnect-show .components-rejoining-animation,
#components-reconnect-modal.components-reconnect-paused .components-pause-visible,
#components-reconnect-modal.components-reconnect-resume-failed .components-resume-failed-visible,
#components-reconnect-modal.components-reconnect-retrying,
#components-reconnect-modal.components-reconnect-retrying .components-reconnect-repeated-attempt-visible,
#components-reconnect-modal.components-reconnect-retrying .components-rejoining-animation,
#components-reconnect-modal.components-reconnect-failed,
#components-reconnect-modal.components-reconnect-failed .components-reconnect-failed-visible {
    display: block;
}


#components-reconnect-modal {
    background-color: white;
    width: 20rem;
    margin: 20vh auto;
    padding: 2rem;
    border: 0;
    border-radius: 0.5rem;
    box-shadow: 0 3px 6px 2px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: display 0.5s allow-discrete, overlay 0.5s allow-discrete;
    animation: components-reconnect-modal-fadeOutOpacity 0.5s both;
    &[open]

{
    animation: components-reconnect-modal-slideUp 1.5s cubic-bezier(.05, .89, .25, 1.02) 0.3s, components-reconnect-modal-fadeInOpacity 0.5s ease-in-out 0.3s;
    animation-fill-mode: both;
}

}

#components-reconnect-modal::backdrop {
    background-color: rgba(0, 0, 0, 0.4);
    animation: components-reconnect-modal-fadeInOpacity 0.5s ease-in-out;
    opacity: 1;
}

@keyframes components-reconnect-modal-slideUp {
    0% {
        transform: translateY(30px) scale(0.95);
    }

    100% {
        transform: translateY(0);
    }
}

@keyframes components-reconnect-modal-fadeInOpacity {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes components-reconnect-modal-fadeOutOpacity {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

.components-reconnect-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

#components-reconnect-modal p {
    margin: 0;
    text-align: center;
}

#components-reconnect-modal button {
    border: 0;
    background-color: #6b9ed2;
    color: white;
    padding: 4px 24px;
    border-radius: 4px;
}

    #components-reconnect-modal button:hover {
        background-color: #3b6ea2;
    }

    #components-reconnect-modal button:active {
        background-color: #6b9ed2;
    }

.components-rejoining-animation {
    position: relative;
    width: 80px;
    height: 80px;
}

    .components-rejoining-animation div {
        position: absolute;
        border: 3px solid #0087ff;
        opacity: 1;
        border-radius: 50%;
        animation: components-rejoining-animation 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
    }

        .components-rejoining-animation div:nth-child(2) {
            animation-delay: -0.5s;
        }

@keyframes components-rejoining-animation {
    0% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    4.9% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    5% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 1;
    }

    100% {
        top: 0px;
        left: 0px;
        width: 80px;
        height: 80px;
        opacity: 0;
    }
}
