/* DS-01 — MTsN 1 Tana Toraja. Presentation-only, additive across all seven layouts.
   No replacement of business logic, settings, URLs, fields or custom theme preferences. */
:root {
 --ds01-brand:#176B5C; --ds01-brand-strong:#104B42;
 --ds01-text:#162B2D; --ds01-muted:#53656A;
 --ds01-bg:#F6F9F8; --ds01-surface:#fff; --ds01-subtle:#F1F6F5;
 --ds01-border:#CBD9D8; --ds01-success:#16683B; --ds01-danger:#A32222;
 --ds01-warning:#A85A00; --ds01-focus:#A85A00;
 --ds01-radius-field:11px; --ds01-radius-card:16px;
 --ds01-shadow:0 3px 16px rgba(20,62,54,.055);
 --ds01-ease:cubic-bezier(.22,.76,.25,1);
}
html[data-theme="dark"] {
 --ds01-text:#E9F3F1; --ds01-muted:#B3C9C4;
 --ds01-bg:#102321; --ds01-surface:#19312E;
 --ds01-subtle:#203D39; --ds01-border:#42635C;
 --ds01-focus:#EAA64A; --ds01-brand:#7FD4BE; --ds01-brand-strong:#A5E5D5;
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body) {
 font-family:system-ui,-apple-system,'Segoe UI',sans-serif;
 -webkit-font-smoothing:antialiased;
 text-rendering:optimizeLegibility;
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(.button,.btn,button,select,input,textarea) { font-family:inherit; }
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(a,button,summary,input,textarea,select,[role="button"],[tabindex="0"]):focus-visible {
 outline:3px solid var(--ds01-focus) !important; outline-offset:3px;
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(.button,.btn,button[type="submit"],.icon-button) { touch-action:manipulation; }
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(.button,.btn,button[type="submit"]) {
 border-radius:var(--ds01-radius-field); min-height:44px;
 transition:background-color .14s var(--ds01-ease),border-color .14s var(--ds01-ease),box-shadow .14s var(--ds01-ease),color .14s var(--ds01-ease);
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(.button-primary,.button-accent,.btn-primary) {
 background-color:var(--ds01-brand); color:var(--ds01-surface); border-color:var(--ds01-brand);
}
html:not([data-theme="dark"]) :where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.button-primary,.button-accent,.btn-primary):hover { background-color:var(--ds01-brand-strong);border-color:var(--ds01-brand-strong);color:#fff; }
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea) {
 min-width:0; max-width:100%; box-sizing:border-box;
 border-radius:var(--ds01-radius-field);
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body)
 :is(input:not([type=checkbox]):not([type=radio]):not([type=hidden]),select,textarea):not([type=range]) {
 min-height:44px;
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(input,textarea,select):focus { transform:none; }
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.admin-card,.content-panel,.portal-card,.prose-card,.document-card,.content-card,.service-card,.auth-form-card) {
 min-width:0; border-radius:var(--ds01-radius-card);
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.admin-card,.content-panel,.portal-card,.prose-card,.document-card,.service-card) {
 box-shadow:var(--ds01-shadow);
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.admin-card-head,.admin-page-head,.section-heading,.admin-welcome,.form-actions,.hero-actions) {
 gap:clamp(10px,1.7vw,20px);min-width:0;flex-wrap:wrap;
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.admin-card-head,.admin-page-head,.section-heading,.admin-welcome) :is(h1,h2,h3) {
 letter-spacing:-.025em;line-height:1.24;overflow-wrap:break-word;
}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.admin-card-head,.admin-page-head,.section-heading,.admin-welcome) p { line-height:1.53;max-width:76ch; }
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.empty-state,.empty-note,.no-results) {color:var(--ds01-muted);line-height:1.55;}
:where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.status-pill,.status-chip,.chip) {font-weight:650;letter-spacing:0;white-space:normal;}
/* Admin: single, compact header, fixed desktop rail aligned to the DS-01 grid. */
@media (min-width:1024px) {
 body.admin-body .admin-shell:not(.is-collapsed) {grid-template-columns:248px minmax(0,1fr);}
 body.admin-body .admin-shell:not(.is-collapsed) #admin-sidebar.admin-sidebar {width:248px;}
 body.admin-body .admin-shell.is-collapsed {grid-template-columns:72px minmax(0,1fr);}
 body.admin-body .admin-shell.is-collapsed #admin-sidebar.admin-sidebar {width:72px;}
}
body.admin-body .admin-topbar {min-height:64px;height:auto;padding-block:8px;}
body.admin-body .admin-content {max-width:1360px;width:100%;min-width:0;margin-inline:auto;}
body.admin-body .admin-content :is(.admin-page-head,.admin-welcome) {min-width:0;}
body.admin-body #admin-sidebar .admin-nav a[aria-current="page"] {font-weight:750;}
body.admin-body .admin-content :is(.responsive-table,.table-responsive,.table-scroll,.table-wrapper,.admin-table-wrap) {max-width:100%;overflow-x:auto;overscroll-behavior-x:contain;}
body.admin-body .admin-content :is(.responsive-table,.table-responsive,.table-scroll,.table-wrapper,.admin-table-wrap) table {border-collapse:separate;border-spacing:0;min-width:100%;}
body.admin-body .admin-content :is(.responsive-table,.table-responsive,.table-scroll,.table-wrapper,.admin-table-wrap) thead th {position:sticky;top:0;z-index:2;}
body.admin-body .admin-content :is(.form-grid,.admin-grid-2,.admin-grid-3,.ppid-queue-filter) > * {min-width:0;}
body.admin-body .admin-content :is(.admin-form-card form,.admin-card form:not(.inline-form)) {max-width:100%;}
body.admin-body .admin-topbar :is(.icon-button,.accessibility-header-button) {min-height:44px;min-width:44px;}
/* PPID & Humas: much smaller masthead on detail pages, but full hero preserved on home. */
body.portal-shell .portal-header-row {min-height:60px;gap:12px;}
body.portal-shell .portal-header .portal-brand {min-width:0;}
body.portal-shell .portal-header-actions {gap:8px;flex-wrap:nowrap;}
body.portal-shell .portal-nav-group > summary {cursor:pointer;min-height:44px;}
body.portal-shell .portal-nav-group a[aria-current="page"] {background:var(--ds01-subtle);color:var(--ds01-brand-strong);font-weight:700;}
body.portal-shell :is(.module-content,.form-layout,.module-hero-grid,.document-list,.tracking-layout,.section-heading) {min-width:0;}
body.portal-shell :is(.prose-card,.content-panel,.tracking-form,.public-form,.filter-bar,.document-card,.event-list article) {border-radius:var(--ds01-radius-card);}
body.portal-shell .ds01-inner-hero {padding-block:clamp(18px,3vw,34px) !important;min-height:0;}
body.portal-shell .ds01-inner-hero .module-hero-grid {gap:12px;}
body.portal-shell .ds01-inner-hero .module-hero-card {max-width:410px;}
body.portal-shell .ds01-inner-hero h1 {font-size:clamp(1.65rem,3vw,2.3rem);line-height:1.2;}
body.portal-shell .ds01-inner-hero .eyebrow {margin-bottom:4px;}
body.portal-shell .ds01-inner-hero p {max-width:68ch;font-size:.94rem;line-height:1.5;}
body.portal-shell .ds01-inner-hero .hero-actions {margin-top:12px;}
body.portal-shell .module-content {padding-block-start:clamp(18px,3vw,30px);}
/* Humas Jejak Berita: progressive enhancement, never hide form controls without JS. */
body.humas-portal .ds01-filter-toggle {display:inline-flex;align-items:center;gap:7px;margin:0 0 10px auto;min-height:44px;}
body.humas-portal .external-news-filter.ds01-filter-collapsed > label:not(.filter-search) {display:none;}
body.humas-portal .external-news-filter.ds01-filter-collapsed {display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:end;gap:12px;}
body.humas-portal .external-news-filter.ds01-filter-collapsed .external-news-filter-actions {grid-column:auto;align-self:end;margin:0;}
/* Humas workflow: quick, role-preserving tabs linking to existing routes only. */
body.admin-body .ds01-workflow-nav {display:flex;gap:7px;flex-wrap:wrap;overflow:visible;margin:0 0 16px;padding:8px;background:var(--ds01-subtle);border:1px solid var(--ds01-border);border-radius:15px;}
body.admin-body .ds01-workflow-nav a {display:inline-flex;align-items:center;min-height:44px;gap:5px;padding:8px 12px;border-radius:10px;color:var(--ds01-text);font-size:.84rem;font-weight:650;text-decoration:none;transition:background-color .15s ease,color .15s ease;}
body.admin-body .ds01-workflow-nav a:is(:hover,[aria-current="page"]) {background:var(--ds01-surface);color:var(--ds01-brand-strong);box-shadow:0 1px 5px rgba(0,0,0,.04);}
body.admin-body .ds01-workflow-nav a[aria-current="page"] {outline:1px solid var(--ds01-border);}
/* Responsive without body-level horizontal scroll traps. */
@media (max-width:1023px) {
 body.admin-body .admin-topbar {min-height:58px;gap:8px;}
 body.admin-body .admin-content {width:100%;}
 body.portal-shell .portal-header-actions > a.button {display:none;}
}
@media (max-width:700px) {
 body.portal-shell .ds01-inner-hero {padding-block:16px!important;}
 body.portal-shell .ds01-inner-hero .hero-actions {display:flex;flex-wrap:wrap;gap:8px;}
 body.portal-shell .ds01-inner-hero .hero-actions a {min-width:0;flex:1 1 auto;}
 body.humas-portal .external-news-filter.ds01-filter-collapsed {grid-template-columns:minmax(0,1fr);}
 body.humas-portal .external-news-filter.ds01-filter-collapsed .external-news-filter-actions {grid-column:1;display:flex;flex-wrap:wrap;}
 body.humas-portal .external-news-filter.ds01-filter-collapsed .external-news-filter-actions .button {flex:1 1 120px;min-width:0;}
 body.admin-body .ds01-workflow-nav {flex-wrap:nowrap;overflow-x:auto;scrollbar-width:thin;-webkit-overflow-scrolling:touch;overscroll-behavior-inline:contain;}
 body.admin-body .ds01-workflow-nav a {flex:0 0 auto;white-space:nowrap;}
 body.admin-body .admin-topbar .admin-user > div {display:none;}
}
@media (prefers-reduced-motion:reduce) {
 :where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body,body.tinta-site-body) * {scroll-behavior:auto!important;animation-duration:.01ms!important;transition-duration:.01ms!important;}
}
html.reduce-motion :where(.ds01-workflow-nav a,.ds01-filter-toggle,.button,.btn) {transition:none!important;}

/* PPID works like Humas: one active work area, with all legacy links reachable. */
body.admin-body .ds01-ppid-nav {margin-bottom:16px;}
html[data-theme="dark"] :where(body.admin-body,body.public-site-body,body.portal-shell,body.auth-body,body.contrib-body)
 :is(.button-primary,.button-accent,.btn-primary) {color:#102321;}
