/* Adaptive layout for the section list and the reading view. */
.topbar{padding-inline:clamp(1.25rem,3vw,3rem)}
.content{width:100%;max-width:1180px;margin-inline:auto;padding:clamp(2.5rem,5vw,4.5rem) clamp(1.5rem,4vw,3.5rem) 6rem}
.page-heading h1,.reading h1{max-width:none;overflow-wrap:anywhere}
.reading{max-width:92ch}
.reading h1{font-size:clamp(1.5rem,2.1vw,2.15rem);line-height:1.3;text-wrap:pretty}
.markdown{max-width:78ch}
.question-row>span:nth-child(2),.section-row>span:first-child{min-width:0;overflow-wrap:anywhere}
.section-row,.question-row{min-height:68px}
.question-row strong,.section-row strong{font-weight:600}
.tabs button,.back{min-height:44px}
.pagination{padding-bottom:env(safe-area-inset-bottom)}

/* Large screens have enough room to compare sections side by side. */
@media(min-width:1200px){
  .section-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:2.5rem}
  .section-row{align-items:start;padding-block:1.15rem}
}

/* Keep navigation and reading controls reachable without crowding the text. */
@media(max-width:850px){
  .topbar{padding-left:max(1rem,env(safe-area-inset-left));padding-right:max(1rem,env(safe-area-inset-right))}
  .brand,.logout{min-height:44px}
  .content{padding:2.5rem max(1.5rem,env(safe-area-inset-right)) 4rem max(1.5rem,env(safe-area-inset-left))}
  .page-heading{margin-bottom:1.75rem}
  .reading h1{font-size:clamp(1.45rem,3.3vw,1.8rem);line-height:1.32}
  .question-heading{margin:1.25rem 0 1rem}
  .markdown{line-height:1.75}
}
@media(max-width:480px){
  .content{padding:1.8rem max(1rem,env(safe-area-inset-right)) 3.5rem max(1rem,env(safe-area-inset-left))}
  .brand{font-size:.95rem}
  .topbar{font-size:.86rem}
  h1{font-size:1.7rem}
  .reading h1{font-size:1.45rem}
  .question-row{grid-template-columns:1.8rem minmax(0,1fr) auto;gap:.45rem;padding-block:.85rem}
  .question-row strong,.section-row strong{font-size:.94rem}
  .tabs{margin:1.35rem 0 1.5rem}
  .markdown{line-height:1.72}
  .login-page{padding:1.5rem;align-items:center}
  .login-brand{margin-bottom:2.25rem}
}
@media(max-height:500px){
  .login-page{align-items:start;padding-block:1.25rem}
  .login-brand{margin-bottom:1rem}
}

/* Demo mode, account name in the top bar, podcasts, tables and code spans in cards. */
.demo-notice{border-left:3px solid #b0892b;margin-bottom:2rem}
.link-button{border:0;background:none;padding:0;color:#292929;text-decoration:underline;text-underline-offset:3px;font:inherit}
/* Where to ask for access: a row of contact links with the brands' marks (Simple Icons, CC0). */
.contacts{display:flex;flex-wrap:wrap;gap:.5rem;margin-top:.65rem}
.contact{display:inline-flex;align-items:center;gap:.45rem;border:1px solid #dededb;border-radius:999px;background:#fff;color:#292929;padding:.35rem .9rem .35rem .65rem;font-size:.88rem;line-height:1.2;text-decoration:none;min-height:40px}
.contact:hover{background:#f3f3f1;border-color:#b3b2ae}
.contact svg{display:block;flex:0 0 auto;fill:#6f6e6a}
.notice-tail{display:block;margin-top:.6rem}
.login-contacts .contacts{justify-content:center}
/* The owner's panel: creation form, the credentials issued once, tables of accounts and of the log. */
.admin-form{display:flex;flex-wrap:wrap;gap:.7rem 1rem;align-items:flex-end;margin:0 0 2rem}
.admin-form label{display:flex;flex-direction:column;gap:.25rem;font-size:.85rem;font-weight:600}
.admin-form input{min-width:min(240px,60vw)}
.admin-form select{padding:.6rem .75rem;border:1px solid #dededb;border-radius:5px;background:#fff;font:inherit;min-height:44px;color:#292929}
.issued{border:1px solid #b5d6b8;background:#f3f9f4;border-radius:6px;padding:1rem 1.2rem;margin:0 0 2rem}
.issued h2{font-size:1.1rem;margin:0 0 .6rem}
.issued-field{display:flex;flex-direction:column;gap:.25rem;font-size:.85rem;font-weight:600;margin:.6rem 0}
.issued .btn{margin:.4rem .5rem 0 0}
.admin-table-wrap{overflow-x:auto}
table.admin{width:100%;border-collapse:collapse;font-size:.88rem;margin:0 0 2rem}
table.admin th,table.admin td{text-align:left;padding:.6rem .7rem;border-bottom:1px solid #ebebe9;vertical-align:top}
table.admin th{font-size:.8rem;color:#73716d;font-weight:600;white-space:nowrap}
.admin-actions{min-width:11rem}
.admin-actions .btn{padding:.4rem .7rem;font-size:.82rem;margin:.15rem .3rem .15rem 0;min-height:0}
table.admin td:first-child{min-width:9rem}
.admin-list li{margin:.5rem 0}
.admin-log td:nth-child(4){min-width:16rem}
.who{color:#73716d;font-size:.88rem;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.podcast-card{margin-bottom:1rem}
.podcast-card h2{font-size:1.2rem;margin:0 0 .3rem}
.podcast-card audio,.podcast-row audio{display:block;width:100%;max-width:560px;margin:1rem 0}
.podcast-actions{margin:.2rem 0 1.4rem}
.podcast-row{display:grid;grid-template-columns:2.25rem minmax(0,1fr) auto;gap:1rem;align-items:start;padding:1.1rem .5rem;border-bottom:1px solid #ebebe9}
.podcast-row strong,.podcast-row small{display:block}
.podcast-row strong{font-size:.97rem;font-weight:600;line-height:1.5}
.podcast-row small{font-size:.8rem;color:#85837e;margin-top:.2rem}
.podcast-row .btn{align-self:center;white-space:nowrap}
a.btn{text-decoration:none;display:inline-block}
.transcript{margin-top:.75rem}
.transcript summary{cursor:pointer;color:#466ca8;min-height:32px;display:list-item}
.transcript .small{font-size:.82rem}
.transcript-text{white-space:pre-wrap;overflow-wrap:anywhere;font-size:.92rem;line-height:1.6;max-height:26rem;overflow:auto;background:#f7f7f5;border-radius:5px;padding:.9rem 1rem;margin:.5rem 0 0}
.markdown table{border-collapse:collapse;width:100%;margin:1rem 0 1.4rem;font-size:.92rem}
.markdown th,.markdown td{border:1px solid #dededb;padding:.45rem .6rem;text-align:left;vertical-align:top}
.markdown th{background:#f7f7f5}
.markdown code{font-size:.9em;background:#f3f3f1;border-radius:3px;padding:.05em .3em}
@media(max-width:850px){
  .podcast-row{grid-template-columns:1.8rem minmax(0,1fr)}
  .podcast-row .btn{grid-column:2;justify-self:start}
}
