/* @utumno/ui base: layout, parts and the tokens every theme sets. A theme (themes/*.css) only sets the --u-* variables. */
@font-face { font-family: 'Montserrat'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('../fonts/montserrat-latin-wght-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Montserrat'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('../fonts/montserrat-latin-ext-wght-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --u-font: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --u-radius: 4px;
  --u-sidebar-width: 17rem;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; font-family: var(--u-font); background: var(--u-bg); color: var(--u-text); line-height: 1.5; -webkit-font-smoothing: antialiased; }
h1, h2, h3 { color: var(--u-heading); font-weight: 700; line-height: 1.2; margin: 0 0 .5rem; }
h1 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem); }
h2 { font-size: 1.25rem; }
a { color: var(--u-link); }
:focus-visible { outline: 3px solid var(--u-focus); outline-offset: 2px; }

.u-skip { position: absolute; left: -999px; top: 0; background: var(--u-accent); color: var(--u-accent-text); padding: .5rem 1rem; z-index: 100; }
.u-skip:focus { left: 0; }

/* shell */
.u-shell { display: grid; grid-template-columns: var(--u-sidebar-width) 1fr; min-height: 100%; border-top: 6px solid var(--u-strip); }
.u-sidebar { background: var(--u-nav-bg); color: var(--u-nav-text); display: flex; flex-direction: column; padding: 1.25rem 0 1rem; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.u-brand { padding: 0 1.25rem 1.25rem; }
.u-wordmark { display: inline-flex; flex-direction: column; gap: .15rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; font-size: 1.1rem; line-height: 1.1; }
.u-wordmark-tag { font-size: .65rem; font-weight: 500; letter-spacing: .3em; opacity: .85; }
.u-nav { flex: 1; }
.u-nav ul { list-style: none; margin: 0 0 1rem; padding: 0; }
.u-group { margin: 1rem 1.25rem .35rem; font-size: .7rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--u-nav-muted); }
.u-nav-link { display: flex; align-items: center; gap: .6rem; padding: .65rem 1.25rem; color: var(--u-nav-text); text-decoration: none; font-weight: 500; border-left: 4px solid transparent; }
.u-nav-link:hover { background: var(--u-nav-hover); }
.u-nav-link.active { background: var(--u-accent); color: var(--u-accent-text); border-left-color: var(--u-nav-text); font-weight: 600; }
.u-nav-title { flex: 1; }
.u-sidebar-foot { padding: 1rem 1.25rem 0; border-top: 1px solid var(--u-nav-hover); font-size: .85rem; }
.u-main { display: flex; flex-direction: column; min-width: 0; }
.u-topbar { display: flex; align-items: center; justify-content: space-between; padding: .6rem 2rem; border-bottom: 1px solid var(--u-border); background: var(--u-surface); }
.u-topbar-name { font-weight: 600; color: var(--u-muted); }
.u-content { padding: 2rem; max-width: 80rem; width: 100%; outline: none; }

/* parts */
.u-badge { display: inline-block; padding: .05rem .5rem; border-radius: 999px; background: var(--u-badge-bg); color: var(--u-badge-text); font-size: .68rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.u-card { background: var(--u-surface); border: 1px solid var(--u-border); border-radius: var(--u-radius); padding: 1.5rem; }
.u-card-title { margin-bottom: .75rem; }
.u-page-header { margin-bottom: 1.5rem; }
.u-subtitle { margin: 0; color: var(--u-muted); }
.u-empty { border: 2px dashed var(--u-border); border-radius: var(--u-radius); padding: 3rem 1.5rem; text-align: center; color: var(--u-muted); }
.u-empty-title { margin: 0 0 .25rem; font-size: 1.1rem; font-weight: 600; color: var(--u-heading); }
.u-empty-message { margin: 0; }
.u-btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; font: inherit; font-weight: 600; padding: .6rem 1.2rem; border-radius: var(--u-radius); border: 1px solid transparent; cursor: pointer; text-decoration: none; }
.u-btn-primary { background: var(--u-accent); color: var(--u-accent-text); }
.u-btn-primary:hover { filter: brightness(1.1); }
.u-btn-ghost { background: transparent; color: inherit; border-color: var(--u-border); }
.u-btn-block { width: 100%; }
.u-facts { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1.25rem; margin: 0; }
.u-facts dt { font-weight: 600; color: var(--u-muted); }
.u-facts dd { margin: 0; overflow-wrap: anywhere; }

/* the sign-in page and other frames with no sidebar */
.u-bare { min-height: 100vh; display: grid; place-items: center; background: var(--u-bg); border-top: 6px solid var(--u-strip); padding: 1.5rem; }
.u-bare .u-card { width: min(26rem, 100%); }

/* Blazor's own start-up and error elements */
#blazor-error-ui { display: none; position: fixed; inset: auto 0 0 0; padding: .75rem 1.25rem; background: #fff3cd; color: #3b2f00; z-index: 1000; }
#blazor-error-ui .dismiss { cursor: pointer; margin-left: 1rem; }
.u-loading { min-height: 100vh; display: grid; place-items: center; color: var(--u-muted); font-weight: 600; }

@media (max-width: 52rem) {
  .u-shell { grid-template-columns: 1fr; }
  .u-sidebar { position: static; height: auto; }
  .u-content { padding: 1.25rem; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* the logo in the sidebar */
.u-logo { display: block; max-width: 100%; height: auto; max-height: 3.5rem; }

/* ShareDrive */
.u-visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.u-input { font: inherit; padding: .6rem .8rem; border: 1px solid var(--u-border); border-radius: var(--u-radius); background: var(--u-surface); color: var(--u-text); min-width: 0; flex: 1; }
.u-link { font: inherit; background: none; border: 0; padding: 0; color: var(--u-link); text-decoration: underline; cursor: pointer; text-align: left; }
.u-sd { display: grid; gap: 1.25rem; }
.u-sd-search { display: flex; gap: .5rem; }
.u-sd-heading { margin: 0; }
.u-sd-note { margin: 0; color: var(--u-muted); }
.u-sd-error { border: 1px solid #b3261e; border-left-width: 6px; background: var(--u-surface); color: var(--u-text); padding: 1rem 1.25rem; border-radius: var(--u-radius); }
.u-sd-places, .u-sd-folders { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1rem; }
.u-sd-place, .u-sd-folder { width: 100%; text-align: left; font: inherit; cursor: pointer; display: grid; gap: .25rem; color: var(--u-text); }
.u-sd-place:hover, .u-sd-folder:hover { border-color: var(--u-accent); }
.u-sd-place-name { font-weight: 700; color: var(--u-heading); overflow-wrap: anywhere; }
.u-sd-place-about { color: var(--u-muted); font-size: .9rem; }
.u-sd-crumbs { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.u-sd-scroll { overflow-x: auto; }
.u-sd-table { width: 100%; border-collapse: collapse; }
.u-sd-table th, .u-sd-table td { text-align: left; padding: .6rem .75rem; border-bottom: 1px solid var(--u-border); vertical-align: middle; overflow-wrap: anywhere; }
.u-sd-table th { color: var(--u-muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.u-sd-thumb { display: block; width: 40px; height: 40px; object-fit: cover; border-radius: 2px; background: var(--u-border); }
.u-sd-download { padding: .3rem .8rem; font-size: .9rem; }
