/* Taurus Cloud. Taurus colours: near-black, brand yellow, the logo's maroon. */
:root {
  --page: #f4f4f1; --surface: #ffffff; --surface-2: #f8f8f6; --ink: #1d1d1f; --muted: #6b6b70; --line: #e4e4de;
  --hover: #f0efe9; --sel: #fff4cf; --sel-line: #f2c94c;
  --brand: #ffc72c; --brand-ink: #1d1d1f; --maroon: #8a1c2b;
  --side: #151517; --side-ink: #d8d8d8; --side-muted: #8d8d92; --side-hover: #232327;
  --ok: #1f8a4c; --bad: #c0392b;
  --radius: 12px; --shadow: 0 10px 30px rgba(0,0,0,.12);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root { --page: #0f0f11; --surface: #1a1a1d; --surface-2: #202024; --ink: #ececec; --muted: #9a9aa0; --line: #2c2c31;
    --hover: #242428; --sel: #3a3218; --sel-line: #9c7f22; --side: #0a0a0b; --side-hover: #1c1c1f;
    --ok: #46c27a; --bad: #ef6b5b; --shadow: 0 10px 30px rgba(0,0,0,.5); color-scheme: dark; }
}
* { box-sizing: border-box; }
html, body, #app { height: 100%; }
body { overflow: hidden; }
.login { overflow-y: auto; height: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
.hidden { display: none !important; }
svg.i { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- sign in ---------- */
.login { min-height: 100%; display: grid; place-items: center; padding: 24px 16px;
  background: radial-gradient(1200px 600px at 20% -10%, #2a2a30 0%, transparent 60%), var(--side); }
.login form { width: min(380px, 100%); background: var(--surface); border-radius: 18px; padding: 30px 26px 24px; box-shadow: 0 30px 80px rgba(0,0,0,.45); display: grid; gap: 14px; }
.login .mark { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.login .mark img { width: 52px; height: 52px; border-radius: 12px; }
.login h1 { margin: 0; font-size: 22px; }
.login p.sub { margin: 0; color: var(--muted); font-size: 14px; }
.login p.small-link { font-size: 13px; text-align: center; }
.field { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
.field input, .field select, .field textarea { font-size: 16px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); color: var(--ink); width: 100%; }
.field input:focus, .field select:focus { outline: 2px solid var(--brand); outline-offset: 0; border-color: transparent; }
.err { color: var(--bad); font-size: 14px; min-height: 1.2em; margin: 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 9px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-size: 14px; font-weight: 500; white-space: nowrap; text-decoration: none; }
.btn:hover { background: var(--hover); }
.btn.main { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); font-weight: 600; }
.btn.main:hover { filter: brightness(.96); }
.btn.big { padding: 12px 16px; font-size: 16px; }
.btn.danger { color: var(--bad); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn:disabled { opacity: .5; cursor: default; }
.icon-btn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; border: 0; background: transparent; color: var(--muted); }
.icon-btn:hover { background: var(--hover); color: var(--ink); }
.icon-btn.on { background: var(--hover); color: var(--ink); }

/* ---------- layout ---------- */
.shell { display: grid; grid-template-columns: 248px 1fr; height: 100%; }
.side { background: var(--side); color: var(--side-ink); display: flex; flex-direction: column; padding: 18px 12px; gap: 6px; overflow-y: auto; }
.side .mark { display: flex; align-items: center; gap: 10px; padding: 4px 8px 16px; color: #fff; font-weight: 700; font-size: 17px; }
.side .mark img { width: 34px; height: 34px; border-radius: 8px; }
.side .new { margin: 0 4px 12px; }
.nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; text-decoration: none; color: var(--side-ink); font-size: 15px; }
.nav a:hover { background: var(--side-hover); }
.nav a.on { background: var(--side-hover); color: #fff; box-shadow: inset 3px 0 0 var(--brand); }
.side .grow { flex: 1; }
.install { display: flex; align-items: center; gap: 10px; margin: 0 4px 6px; padding: 10px 12px; border-radius: 10px; border: 1px solid #34343a; background: transparent; color: var(--side-ink); font-size: 14px; text-align: left; }
.install:hover { background: var(--side-hover); color: #fff; }
.install svg.i { color: var(--brand); }
.storage { padding: 12px; font-size: 13px; color: var(--side-muted); }
.storage .bar { height: 6px; border-radius: 3px; background: #2c2c31; margin: 8px 0 6px; overflow: hidden; }
.storage .bar span { display: block; height: 100%; background: var(--brand); border-radius: 3px; }
.me { display: flex; align-items: center; gap: 10px; padding: 10px 8px; border-top: 1px solid #26262a; margin-top: 6px; }
.me .av { width: 32px; height: 32px; border-radius: 50%; background: var(--maroon); color: #fff; display: grid; place-items: center; font-weight: 700; text-transform: uppercase; }
.me .who { flex: 1; min-width: 0; font-size: 14px; color: #fff; overflow: hidden; text-overflow: ellipsis; }
.me .icon-btn { color: var(--side-muted); }
.me .icon-btn:hover { background: var(--side-hover); color: #fff; }

.pane { display: flex; flex-direction: column; min-width: 0; height: 100%; position: relative; }
.top { display: flex; align-items: center; gap: 10px; padding: 14px 22px; border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 3; }
.menu-btn { display: none; }
.search { flex: 1; max-width: 560px; display: flex; align-items: center; gap: 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; }
.search input { border: 0; background: transparent; padding: 10px 0; flex: 1; min-width: 0; outline: none; font-size: 15px; }
.search:focus-within { border-color: var(--sel-line); }
.top .spacer { flex: 1; }
.bar2 { display: flex; align-items: center; gap: 8px; padding: 12px 22px 4px; flex-wrap: wrap; }
.crumbs { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; font-size: 18px; font-weight: 600; min-width: 0; flex: 1; }
.crumbs a { text-decoration: none; padding: 4px 8px; border-radius: 8px; white-space: nowrap; max-width: 260px; overflow: hidden; text-overflow: ellipsis; }
.crumbs a:hover, .crumbs a.drop { background: var(--hover); }
.crumbs .sep { color: var(--muted); }
.tools { display: flex; gap: 4px; align-items: center; }
.tools select { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 7px 8px; font-size: 14px; }
.content { flex: 1; overflow-y: auto; padding: 8px 22px 120px; }
/* floats over the files so selecting never moves them */
.selbar { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 25; display: flex; align-items: center; gap: 2px; padding: 6px 8px; border-radius: 14px; background: var(--side); color: #fff; box-shadow: 0 12px 34px rgba(0,0,0,.35); max-width: calc(100% - 32px); overflow-x: auto; }
.selbar > div { display: flex; align-items: center; gap: 2px; }
.selbar .n { font-weight: 600; margin: 0 10px 0 2px; white-space: nowrap; }
.selbar .btn { background: transparent; border-color: transparent; padding: 8px 11px; color: #fff; }
.selbar .btn:hover { background: rgba(255,255,255,.12); }
.selbar .btn.danger { color: #ff8a7a; }
.selbar .icon-btn { color: #bbb; } .selbar .icon-btn:hover { background: rgba(255,255,255,.12); color: #fff; }

/* ---------- items ---------- */
.section-h { font-size: 13px; color: var(--muted); font-weight: 600; margin: 18px 0 10px; text-transform: uppercase; letter-spacing: .04em; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; user-select: none; cursor: default; transition: box-shadow .12s, border-color .12s; }
.card:hover { box-shadow: var(--shadow); }
.card.sel { border-color: var(--sel-line); background: var(--sel); }
.card.drop { outline: 3px solid var(--brand); }
.card .thumb { aspect-ratio: 4 / 3; display: grid; place-items: center; background: var(--surface-2); overflow: hidden; }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card .thumb svg.big { width: 56px; height: 56px; }
.card .meta { padding: 10px 12px 12px; display: grid; gap: 2px; }
.card .name { font-size: 14px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card .sub { font-size: 12px; color: var(--muted); }
.card.folder { display: flex; align-items: center; gap: 12px; padding: 14px; }
.card.folder .name { flex: 1 1 auto; }
.card.folder svg.ftype { width: 28px; height: 28px; }
.card .tick, .row .tick { position: absolute; top: 8px; left: 8px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; background: rgba(0,0,0,.28); display: grid; place-items: center; opacity: 0; transition: opacity .1s; }
.card.folder .tick { position: static; flex: none; border-color: var(--line); background: var(--surface); }
.card:hover .tick, .card.sel .tick, .selecting .tick { opacity: 1; }
.sel .tick { background: var(--brand); border-color: var(--brand); }
.tick svg { width: 14px; height: 14px; stroke: var(--brand-ink); stroke-width: 3; opacity: 0; }
.sel .tick svg { opacity: 1; }
.card .more, .row .more { position: absolute; top: 6px; right: 6px; opacity: 0; background: var(--surface); box-shadow: 0 1px 4px rgba(0,0,0,.15); }
.card.folder .more { position: static; opacity: 0; box-shadow: none; }
.card:hover .more, .row:hover .more { opacity: 1; }

.list { width: 100%; border-collapse: separate; border-spacing: 0; }
.list th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--page); cursor: pointer; white-space: nowrap; }
.list td { padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.list tr.row { user-select: none; }
.list tr.row:hover td { background: var(--hover); }
.list tr.row.sel td { background: var(--sel); }
.list tr.row.drop td { background: var(--sel); box-shadow: inset 0 0 0 2px var(--brand); }
.list .nm { display: flex; align-items: center; gap: 10px; min-width: 0; max-width: 52vw; }
.list .nm span { overflow: hidden; text-overflow: ellipsis; }
.list .nm img { width: 32px; height: 32px; object-fit: cover; border-radius: 6px; }
.list td.c { color: var(--muted); font-size: 14px; }
.list .tick { position: static; opacity: 1; border-color: var(--line); background: var(--surface); width: 20px; height: 20px; }
.list .more { position: static; opacity: .4; box-shadow: none; }

.empty { text-align: center; padding: 70px 20px; color: var(--muted); }
.empty > svg { width: 64px; height: 64px; stroke-width: 1.2; color: var(--line); }
.empty h2 { color: var(--ink); margin: 14px 0 6px; font-size: 19px; }

/* type colours */
.t-folder { color: #e0a800; } .t-image { color: #2f80ed; } .t-pdf { color: #d93025; } .t-doc { color: #2b579a; }
.t-sheet { color: #1e7145; } .t-slides { color: #d24726; } .t-video { color: #8e44ad; } .t-audio { color: #e67e22; }
.t-zip { color: #7f6a3a; } .t-lock { color: var(--maroon); }
@media (prefers-color-scheme: dark) { .t-lock { color: #e0a3ad; } }
.card.locked { cursor: pointer; border-style: dashed; }
.card.locked .name .sub { font-weight: 400; }
.card.folder .name { min-width: 0; }
.card.folder.locked .more { width: 30px; }
.crumbs a .t-lock { width: 18px; height: 18px; margin-right: 4px; vertical-align: -3px; }
.lockbtn svg { color: var(--maroon); }
.empty .note svg.i, .content > .note svg.i { width: 16px; height: 16px; vertical-align: -3px; } .t-text { color: #607d8b; } .t-file { color: #8a8a90; }

/* ---------- drop zone, menus, dialogs, preview ---------- */
.dropzone { position: absolute; inset: 10px; border: 3px dashed var(--brand); border-radius: 18px; background: color-mix(in srgb, var(--brand) 12%, transparent); display: grid; place-items: center; z-index: 20; pointer-events: none; }
.dropzone div { background: var(--side); color: #fff; padding: 14px 20px; border-radius: 12px; font-weight: 600; display: flex; gap: 10px; align-items: center; }
.menu { position: fixed; z-index: 60; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 6px; min-width: 210px; }
.menu button { display: flex; width: 100%; align-items: center; gap: 12px; padding: 9px 12px; border: 0; background: none; border-radius: 8px; text-align: left; font-size: 14px; }
.menu button:hover { background: var(--hover); }
.menu button.danger { color: var(--bad); }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 5px 4px; }
.veil { position: fixed; inset: 0; background: rgba(10,10,12,.55); z-index: 50; display: grid; place-items: center; padding: 16px; }
.dialog { background: var(--surface); border-radius: 16px; width: min(480px, 100%); max-height: calc(100vh - 32px); overflow: auto; box-shadow: var(--shadow); }
.dialog.wide { width: min(640px, 100%); }
.dialog form, .dialog .body { padding: 22px; display: grid; gap: 14px; }
.dialog h2 { margin: 0; font-size: 19px; }
.dialog .acts { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.dialog .note { font-size: 14px; color: var(--muted); margin: 0; }
.picker { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.picker .path { padding: 8px 10px; background: var(--surface-2); font-size: 14px; display: flex; gap: 4px; flex-wrap: wrap; align-items: center; }
.picker .path a { text-decoration: none; padding: 2px 6px; border-radius: 6px; } .picker .path a:hover { background: var(--hover); }
.picker ul { list-style: none; margin: 0; padding: 4px; max-height: 280px; overflow: auto; }
.picker li button { display: flex; width: 100%; gap: 10px; align-items: center; padding: 9px 10px; border: 0; background: none; border-radius: 8px; text-align: left; }
.picker li button:hover { background: var(--hover); }
.picker li button:disabled { opacity: .4; }
.copyrow { display: flex; gap: 8px; } .copyrow input { flex: 1; min-width: 0; font-size: 14px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); }
.choice { display: grid; gap: 8px; }
.choice label { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 14px; }
.choice label:has(input:checked) { border-color: var(--sel-line); background: var(--sel); }
.choice small { display: block; color: var(--muted); }

.preview { position: fixed; inset: 0; z-index: 55; background: rgba(8,8,10,.94); color: #fff; display: grid; grid-template-rows: auto 1fr; }
.preview .pbar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; }
.preview .pbar .t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.preview .icon-btn { color: #ddd; } .preview .icon-btn:hover { background: rgba(255,255,255,.1); color: #fff; }
.preview .stage { position: relative; display: grid; place-items: center; overflow: hidden; padding: 0 56px 20px; }
.preview .stage img, .preview .stage video { max-width: 100%; max-height: calc(100vh - 90px); object-fit: contain; border-radius: 6px; }
.preview .stage iframe { width: min(1000px, 100%); height: calc(100vh - 90px); border: 0; border-radius: 6px; background: #fff; }
.preview .stage pre { width: min(1000px, 100%); max-height: calc(100vh - 90px); overflow: auto; background: #1d1d20; padding: 16px; border-radius: 8px; white-space: pre-wrap; word-break: break-word; font-size: 13px; }
.preview .nope { text-align: center; display: grid; gap: 14px; justify-items: center; color: #ccc; }
.preview .nope svg { width: 80px; height: 80px; }
.preview .nav-l, .preview .nav-r { position: absolute; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; border-radius: 50%; background: rgba(255,255,255,.1); }
.preview .nav-l { left: 6px; } .preview .nav-r { right: 6px; }

.uploads { position: fixed; right: 18px; bottom: 18px; width: min(380px, calc(100vw - 32px)); background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); z-index: 40; overflow: hidden; }
.uploads .uh { display: flex; align-items: center; gap: 8px; padding: 12px 14px; background: var(--side); color: #fff; font-weight: 600; font-size: 14px; }
.uploads .uh span { flex: 1; } .uploads .uh .icon-btn { color: #ccc; width: 30px; height: 30px; }
.uploads ul { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow: auto; }
.uploads li { padding: 8px 14px; border-bottom: 1px solid var(--line); font-size: 13px; display: grid; gap: 4px; }
.uploads li .r { display: flex; gap: 8px; justify-content: space-between; } .uploads li .r b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uploads .pb { height: 4px; background: var(--line); border-radius: 2px; overflow: hidden; } .uploads .pb span { display: block; height: 100%; background: var(--brand); width: 0; transition: width .2s; }
.uploads li.done .pb span { background: var(--ok); } .uploads li.fail { color: var(--bad); } .uploads li.fail .pb span { background: var(--bad); }

#toasts { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); display: grid; gap: 8px; z-index: 70; pointer-events: none; }
.toast { background: var(--side); color: #fff; padding: 11px 16px; border-radius: 12px; box-shadow: var(--shadow); font-size: 14px; max-width: calc(100vw - 32px); pointer-events: auto; display: flex; gap: 12px; align-items: center; }
.toast button { background: none; border: 0; color: var(--brand); font-weight: 600; padding: 0; }

.fab { display: none; }
.table-wrap { overflow-x: auto; }
.pill { display: inline-block; font-size: 12px; padding: 2px 8px; border-radius: 99px; background: var(--hover); color: var(--muted); }
.qr { display: block; width: 200px; height: 200px; margin: 0 auto; background: #fff; border-radius: 10px; padding: 8px; }

/* ---------- phones ---------- */
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; inset: 0 auto 0 0; width: 270px; z-index: 45; transform: translateX(-100%); transition: transform .2s; padding-top: max(18px, env(safe-area-inset-top)); }
  .shell.open .side { transform: none; box-shadow: 0 0 0 100vmax rgba(0,0,0,.5); }
  .menu-btn { display: inline-grid; }
  .top { padding: 10px 12px; padding-top: max(10px, env(safe-area-inset-top)); }
  .bar2 { padding: 10px 14px 2px; }
  .crumbs { font-size: 16px; }
  .content { padding: 6px 14px 120px; }
  .selbar { left: 8px; right: 8px; transform: none; bottom: max(10px, env(safe-area-inset-bottom)); max-width: none; }
  .selbar .btn { padding: 8px; font-size: 13px; }
  .selbar .btn svg.i { display: none; }
  .selecting ~ .fab, .pane:has(.selbar:not(.hidden)) .fab { display: none; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
  .card .more, .card .tick { opacity: 1; }
  .side .new { display: none; }
  .fab { display: grid; place-items: center; position: fixed; right: 18px; bottom: max(18px, env(safe-area-inset-bottom)); width: 58px; height: 58px; border-radius: 18px; border: 0; background: var(--brand); color: var(--brand-ink); box-shadow: var(--shadow); z-index: 30; }
  .fab svg { width: 26px; height: 26px; stroke-width: 2.2; }
  .list .c.hide-sm { display: none; }
  .preview .stage { padding: 0 6px 12px; }
  .uploads { bottom: 90px; }
}

/* Full folder and file names (Dan, 16/10/2026: "full names rather than just 3 letters"): names wrap onto more
   lines instead of being cut short, and on a folder the round tick and the ⋯ button only take room when used */
.card .name, .card.folder .name { white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: break-word; word-break: normal; line-height: 1.3; }
.card.folder { align-items: center; gap: 10px; padding: 12px 12px 12px 14px; }
.card.folder .tick { display: none; }
.card.folder:hover .tick, .card.folder.sel .tick, .selecting .card.folder .tick { display: grid; }
.card.folder .more { flex: none; }
.list td.nmc { white-space: normal; }
.list .nm span { overflow: visible; text-overflow: clip; white-space: normal; overflow-wrap: break-word; }
@media (max-width: 600px) { .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; } }
@media (max-width: 600px) { .card.folder { gap: 8px; padding: 12px 10px; } .card.folder svg.ftype { width: 24px; height: 24px; } }

/* the Upload button above the files */
.tools .upbtn { margin-right: 6px; }
@media (max-width: 600px) { .tools .upbtn span { display: none; } .tools .upbtn { padding: 9px 11px; } }

/* Both companies' logos (17/10/2026): side by side above the sign-in, and in the sidebar under the name */
.brands { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.brands img { width: 100%; height: auto; display: block; border-radius: 7px; box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 3px 10px rgba(0,0,0,.25); }
.login .brands { margin-bottom: 8px; }
.side .brands { gap: 8px; padding: 0 6px 14px; }