/*
  Srawung landing: page CSS only (taste-skill: inside a visual, the app-frame recipe, one --p-h per card group).
  Everything else comes from the kit in /assets.
*/

/* ---- the hero's window: Srawung's own pengantar screen for a Ketua RT, as live HTML ---- */
.pgw { background: #fff; color: #0a0a0a; border-radius: 12px; overflow: hidden; font: 400 13px/1.45 var(--font-text); text-align: left;
       box-shadow: 0 0 0 1px rgb(10 10 10 / .08), 0 24px 60px -28px rgb(10 10 10 / .45); }
.pgw__bar { display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 14px; border-bottom: 1px solid rgb(10 10 10 / .08); color: #5c5c5c; white-space: nowrap; }
.pgw__dots { display: flex; gap: 6px; } .pgw__dots i { width: 10px; height: 10px; border-radius: 50%; background: #dcdcdc; }
.pgw__bar b { font-weight: 500; color: #0a0a0a; }
.pgw__sp { flex: 1; }
.pgw__body { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 380px; }
.pgw__list { border-right: 1px solid rgb(10 10 10 / .08); padding: 8px; display: grid; align-content: start; gap: 2px; }
.pgw__head { font-size: 12px; color: #6a6a6a; padding: 6px 8px 6px; }
.pgw__t { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 1px 10px; padding: 8px; border-radius: 9px; }
.pgw__t.is-on { background: rgb(10 10 10 / .05); }
.pgw__t.is-on::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 2px; border-radius: 2px; background: #0a0a0a; }
.pgw__t i { grid-row: 1 / span 2; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font: 500 12px/1 var(--font-text); font-style: normal; color: #0a0a0a; background: #e4e8ec; }
.pgw__t i[data-tone="2"] { background: #ece6db; } .pgw__t i[data-tone="3"] { background: #e2eae3; }
.pgw__t b { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pgw__t time { color: #6a6a6a; font-size: 12px; }
.pgw__t span { grid-column: 2 / -1; color: #5c5c5c; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pgw__open { padding: 14px 20px; display: grid; align-content: start; gap: 12px; min-width: 0; }
.pgw__who { display: flex; justify-content: space-between; align-items: start; gap: 12px; }
.pgw__who b { display: block; font-size: 15px; font-weight: 500; line-height: 1.3; }
.pgw__who small { color: #5c5c5c; font-size: 13px; }
.pgw__chip { height: 22px; padding: 0 8px; border-radius: 99px; display: inline-flex; align-items: center; font-size: 12px; font-weight: 500; background: rgb(10 10 10 / .06); white-space: nowrap; }
.pgw__dl { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 4px 12px; margin: 0; }
.pgw__dl dt { color: #6a6a6a; } .pgw__dl dd { margin: 0; min-width: 0; }
.pgw__note { border: 1px solid rgb(10 10 10 / .16); border-radius: 8px; padding: 6px 10px; }
.pgw__note small { display: block; color: #6a6a6a; font-size: 12px; }
/* the mock's actions take the page's own two looks (the filled action, the underlined text link), so no
   screen shows a third button style; the filled one is the window's one accent */
.pgw__acts { display: flex; align-items: center; gap: 14px; }
.pgw__acts span { height: 30px; display: inline-flex; align-items: center; font-weight: 500; }
.pgw__acts span:first-child { padding: 0 14px; border-radius: var(--r-btn, 8px); background: var(--action); color: var(--action-ink); }
.pgw__acts span + span { text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgb(10 10 10 / .3); }
/* a shorter frame (1279 and under): the exchange keeps to the request, the note and the actions, so it ends
   above the frame's fade at every width */
@media (max-width: 1279px) { .pgw__dl, .pgw__note small { display: none; } .pgw__open { gap: 10px; } }
@media (max-width: 1023px) { .pgw__body { grid-template-columns: 220px minmax(0, 1fr); } }
@media (max-width: 639px) {
  .pgw__body { grid-template-columns: minmax(0, 1fr); min-height: 260px; }
  .pgw__list, .pgw__bar .pgw__right { display: none; }
  .pgw__open { padding: 12px 14px; }
}

/* ---- app-frame (sections-library.md: the whole recipe) ---- */
.app.ui { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); margin-top: var(--s-7); background: var(--u-bg); border: 1px solid var(--u-border); border-radius: var(--u-r); box-shadow: var(--u-shadow); }
.app > .app__pane { position: relative; min-width: 0; min-height: 0; overflow: hidden; }
.app > .app__pane + .app__pane { border-left: 1px solid var(--u-line); }
.app > .app__pane > .ui-panel { width: 100%; border: 0; border-radius: 0; box-shadow: none; }
.app > .app__pane::after { content: ""; position: absolute; inset: auto 0 0 0; height: 64px; background: linear-gradient(transparent, var(--u-bg)); pointer-events: none; }
@media (min-width: 1024px) and (max-width: 1279px) { .app.ui { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); } }
@media (max-width: 1023px) {
  .app.ui { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .app > .app__pane--list { max-height: 252px; }
  .app > .app__pane--list::after { display: none; }
  .app .ui-win__side { display: none; }
  .app .ui-win__body { grid-template-columns: minmax(0, 1fr); }
  .app > .app__pane + .app__pane { border-left: 0; border-top: 1px solid var(--u-line); }
}
@media (max-width: 639px) {
  .app.ui { grid-template-rows: minmax(0, 1fr); }
  .app > .app__pane--list { display: none; }
  .app > .app__pane + .app__pane { border-top: 0; }
}
/* the open letter: the doc fragment at its own width, its page cut by the pane's foot */
.app > .app__pane--open { padding: var(--s-6) 0 0 var(--s-7); }
.app__pane--open .ui-doc { width: min(560px, 100%); }
@media (max-width: 1279px) { .app > .app__pane--open { padding: var(--s-5) 0 0 var(--s-5); } }
@media (max-width: 639px) { .app > .app__pane--open { padding: var(--s-4) var(--s-4) 0; } .app__pane--open .ui-doc { width: 100%; padding-right: 0; } .app__pane--open .ui-doc__note { display: none; } }

/* ---- feature cards: one panel height for the group ---- */
#fitur .panel { --p-h: 336px; }
@media (max-width: 1279px) { #fitur .panel { --p-h: 288px; } }
/* the tablet: a card with a panel takes the full row (cards.md), so each screen holds two stacked cards */
@media (min-width: 640px) and (max-width: 1023px) {
  #fitur .grid > .card { grid-column: 1 / -1; }
  #fitur .panel { --p-h: 220px; }
  /* as system.css does from 1024: each screen's card row runs down to that screen's foot, the panels grow */
  #fitur > .wrap > .grid:last-child, #fitur > .wrap > .group > .grid:last-child { align-self: stretch; flex: 1 1 auto; min-height: 0; }
}
@media (max-width: 639px) {
  #fitur .panel { --p-h: 160px; }
  /* a phone (.g2m): one group a screen, each group's cards run down to that screen's foot */
  #fitur > .wrap > .grid:last-child, #fitur > .wrap > .group > .grid:last-child { align-self: stretch; flex: 1 1 auto; min-height: 0; }
  #fitur > .wrap > .group { align-self: stretch; }
}

/* ---- the questions: the side column's frame (the resident's request form, Srawung's own screen) takes
   what the screen leaves, so the section always ends on its padding; the answers stay open ---- */
#tanya .tanya__frame { --ratio: 0px; padding: 0; }
@media (min-width: 1024px) {
  #tanya > .wrap.grid { align-content: stretch; }
  #tanya .tanya__side { display: flex; flex-direction: column; gap: var(--s-4); min-height: 0; }
  #tanya .tanya__frame { flex: 1 1 0; min-height: 0; margin-top: var(--s-4); }
  #tanya .faq { align-self: start; }
}
@media (min-width: 640px) and (max-width: 1023px) {
  #tanya > .wrap.grid { display: flex; flex-direction: column; gap: var(--s-5); }
  #tanya .tanya__side { display: contents; }
  #tanya .tanya__frame { order: 9; flex: 1 1 0; min-height: 160px; }
}
@media (max-width: 639px) { #tanya .tanya__frame { display: none; } }
.frm { width: 100%; padding: 18px 18px 20px; display: grid; gap: 12px; font: 400 13px/1.4 var(--font-text); }
.frm__head b { display: block; font-size: 15px; font-weight: 500; }
.frm__head small { color: var(--u-muted); font-size: 12px; }
.frm__f { display: grid; gap: 4px; min-width: 0; }
.frm__f span { font-size: 12px; color: var(--u-muted); }
.frm__f i { font-style: normal; height: 34px; display: flex; align-items: center; padding: 0 10px; border: 1px solid var(--u-line-2); border-radius: 8px; white-space: nowrap; overflow: hidden; }
.frm__f.is-on i { border-color: var(--u-accent); box-shadow: 0 0 0 3px var(--u-tint); }
.frm__row { display: grid; grid-template-columns: minmax(0, 1fr) 92px; gap: 10px; }
.frm__btn { height: 36px; border-radius: 8px; background: var(--u-ink); color: var(--u-bg); display: flex; align-items: center; justify-content: center; font-weight: 500; }

/* ---- the footer's three link columns on a tablet: a full row of three ---- */
@media (min-width: 640px) and (max-width: 1023px) { .footer .closing__links .footer__col { grid-column: auto / span 4; } }

/* ---- text the kit sets grey that is read as body text: ink at 7:1 or more ---- */
.hero--centred .hero__lead { color: color-mix(in oklab, var(--ink) 80%, var(--bg)); }
/* a phone: the pill keeps its first word, so the centred box stays under half the column */
@media (max-width: 639px) { .hero--centred .pill > .muted { display: none; } }

/* ---- the name across the close: Outfit's ascender and descender need more than the kit's .86 line ---- */
.close__word { line-height: 1.16; }
