:root {
  --bg: #ffffff;
  --bg-soft: #f6f8fb;
  --bg-tint: #eef4ff;
  --border: #e5e9f0;
  --border-strong: #d5dbe5;
  --text: #0f172a;
  --text-soft: #334155;
  --muted: #64748b;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-soft: #eff4ff;
  --green: #16a34a;
  --green-soft: #ecfdf3;
  --amber: #d97706;
  --amber-soft: #fffaeb;
  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.18);
  --radius: 14px;
  --radius-sm: 10px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -0.02em; }
h1 { font-size: 2.25rem; font-weight: 700; }
h2 { font-size: 1.35rem; font-weight: 650; }
h3 { font-size: 1.05rem; font-weight: 650; }
p { margin: 0; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); }
img, svg { display: block; }
input, button, select, textarea { font: inherit; color: inherit; }

.icon { width: 18px; height: 18px; flex: 0 0 auto; }
.muted { color: var(--muted); }
.small { font-size: 0.82rem; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 24px; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  letter-spacing: -0.02em;
}
.brand:hover { color: var(--text); }
.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: #fff;
  box-shadow: 0 6px 14px -6px rgba(37, 99, 235, 0.7);
}
.logo-mark .icon { width: 20px; height: 20px; }
.brand-sm { font-size: 1rem; }
.brand-sm .logo-mark { width: 28px; height: 28px; border-radius: 8px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s, box-shadow 0.15s;
  box-shadow: 0 6px 16px -8px rgba(37, 99, 235, 0.8);
  white-space: nowrap;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-lg { padding: 13px 24px; font-size: 1rem; border-radius: 12px; }
.btn-sm { padding: 7px 13px; font-size: 0.85rem; }
.btn-block { width: 100%; }
.btn-ghost {
  background: #fff;
  color: var(--text-soft);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}
.btn-ghost:hover { background: var(--bg-soft); color: var(--text); border-color: #c3cbd8; }
.btn-danger {
  background: #fff;
  color: var(--danger);
  border-color: #f3c6c6;
  box-shadow: var(--shadow-sm);
}
.btn-danger:hover { background: var(--danger-soft); color: var(--danger); border-color: #eab0b0; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  border: 1px solid #dbe6ff;
  font-size: 0.8rem;
  font-weight: 600;
}
.pill .icon { width: 14px; height: 14px; }
.pill-soft { background: #fff; border-color: var(--border); color: var(--text-soft); }

/* ------------------------------------------------------------- marketing */

.marketing { background: var(--bg); }

.mnav {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.mnav-in {
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.mnav-links { display: flex; align-items: center; gap: 22px; }
.mnav-link { color: var(--text-soft); font-size: 0.92rem; font-weight: 500; }
.mnav-link:hover { color: var(--text); }

.hero { position: relative; overflow: hidden; padding: 72px 0 88px; }
.hero-glow {
  position: absolute;
  inset: -20% -10% auto -10%;
  height: 620px;
  background:
    radial-gradient(60% 60% at 20% 20%, rgba(59, 130, 246, 0.16), transparent 70%),
    radial-gradient(50% 50% at 85% 30%, rgba(37, 99, 235, 0.12), transparent 70%),
    radial-gradient(40% 40% at 60% 80%, rgba(22, 163, 74, 0.07), transparent 70%);
  pointer-events: none;
}
.hero-in {
  position: relative;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
.hero-copy h1 { font-size: clamp(2.3rem, 4.4vw, 3.4rem); margin: 18px 0 16px; }
.lead { font-size: 1.08rem; color: var(--text-soft); max-width: 540px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 24px; }
.hero-points { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.hero-points li { display: flex; align-items: center; gap: 9px; color: var(--text-soft); font-size: 0.92rem; }
.hero-points .icon { color: var(--green); width: 16px; height: 16px; }

.hero-art { position: relative; min-height: 380px; display: grid; place-items: center; }
.art-card {
  position: relative;
  width: min(100%, 390px);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 30px 60px -30px rgba(15, 23, 42, 0.35), var(--shadow-sm);
  z-index: 2;
}
.art-head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.art-head > .icon { width: 40px; height: 40px; padding: 9px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.art-head div { display: grid; gap: 1px; }
.art-bar { height: 8px; border-radius: 99px; background: #eef1f6; overflow: hidden; margin-bottom: 18px; }
.art-bar span { display: block; height: 100%; background: linear-gradient(90deg, #60a5fa, #2563eb); border-radius: 99px; }
.art-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  margin-bottom: 9px;
  font-size: 0.88rem;
  color: var(--text-soft);
  background: #fcfdff;
}
.art-row .icon { color: var(--amber); }
.art-row span { flex: 1; }
.art-row em { font-style: normal; color: var(--muted); font-size: 0.8rem; }
.art-foot { display: flex; align-items: center; gap: 8px; margin-top: 14px; font-size: 0.8rem; color: var(--muted); }
.art-foot .icon { width: 15px; height: 15px; color: var(--green); }
.art-float {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
  font-size: 0.82rem;
  font-weight: 600;
  z-index: 3;
}
.art-float .icon { width: 16px; height: 16px; }
.art-float-a { top: 22px; left: 0; color: var(--accent); }
.art-float-b { bottom: 26px; right: 0; color: var(--green); }

.section { padding: 78px 24px; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 42px; display: grid; gap: 10px; }
.section-head h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s, box-shadow 0.18s;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.feature-icon .icon { width: 22px; height: 22px; }
.feature-icon.blue { background: var(--accent-soft); color: var(--accent); }
.feature-icon.green { background: var(--green-soft); color: var(--green); }
.feature-icon.amber { background: var(--amber-soft); color: var(--amber); }
.feature p { color: var(--muted); font-size: 0.92rem; margin-top: 8px; }

.price-card {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #fff;
  max-width: 900px;
  margin: 0 auto;
}
.price-main { padding: 38px; }
.price { display: flex; align-items: baseline; gap: 8px; margin: 16px 0 6px; }
.price strong { font-size: 3rem; letter-spacing: -0.04em; }
.price span { color: var(--muted); }
.check-list { list-style: none; padding: 0; margin: 22px 0; display: grid; gap: 11px; }
.check-list li { display: flex; align-items: center; gap: 10px; font-size: 0.93rem; color: var(--text-soft); }
.check-list .icon { width: 17px; height: 17px; color: var(--green); }
.price-side {
  background: linear-gradient(160deg, #f5f9ff, #eef4ff);
  border-left: 1px solid var(--border);
  padding: 38px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: center;
}
.price-side p { color: var(--text-soft); font-size: 0.92rem; }
.price-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid #dce7fb;
  border-radius: 10px;
  font-size: 0.83rem;
  color: var(--text-soft);
}
.price-note .icon { color: var(--accent); width: 16px; height: 16px; }

.footer { border-top: 1px solid var(--border); background: var(--bg-soft); padding: 34px 0; }
.footer-in { display: grid; gap: 6px; justify-items: start; }

/* ------------------------------------------------------------------ auth */

.auth-wrap { min-height: calc(100vh - 66px); display: grid; place-items: center; padding: 56px 20px; background: linear-gradient(180deg, #fbfdff, #f4f7fc); }
.auth-card {
  width: 100%;
  max-width: 430px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 34px;
  box-shadow: var(--shadow);
}
.auth-brand { margin-bottom: 22px; }
.auth-card h1 { font-size: 1.6rem; margin-bottom: 4px; }
.auth-card > .muted { font-size: 0.9rem; }
.auth-alt { margin-top: 18px; font-size: 0.88rem; text-align: center; }

.form { display: grid; gap: 15px; margin-top: 22px; }
.form-grid { grid-template-columns: 1fr 1fr auto auto; align-items: end; margin-top: 8px; }
.field { display: grid; gap: 6px; }
.field > span { font-size: 0.82rem; font-weight: 600; color: var(--text-soft); }
.field input {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: #fff;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14); }
.field input:disabled { background: var(--bg-soft); color: var(--muted); }
.field-inline { gap: 4px; }
.field-inline input { padding: 8px 11px; font-size: 0.88rem; }

.alert { padding: 11px 14px; border-radius: 10px; font-size: 0.88rem; margin-top: 16px; }
.alert-err { background: var(--danger-soft); border: 1px solid #f6cccc; color: #b91c1c; }

/* --------------------------------------------------------------- app shell */

body.app { background: var(--bg-soft); }
.shell { display: flex; min-height: 100vh; }
.sidebar {
  width: 264px;
  flex: 0 0 264px;
  background: #fff;
  border-right: 1px solid var(--border);
  padding: 22px 18px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.sidebar .brand { padding: 0 6px; }

.storage { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; }
.storage-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 0.78rem; color: var(--muted); }
.storage-top strong { color: var(--text-soft); font-size: 0.8rem; }
.bar { height: 7px; border-radius: 99px; background: #e6ebf3; overflow: hidden; margin: 8px 0 6px; }
.bar span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #60a5fa, #2563eb); transition: width 0.3s; }
.bar-warn span { background: linear-gradient(90deg, #f59e0b, #dc2626); }
.storage-note { font-size: 0.74rem; margin: 0; }

.side-nav { display: grid; gap: 3px; }
.side-link {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 12px;
  border-radius: 9px;
  color: var(--text-soft);
  font-size: 0.9rem;
  font-weight: 500;
  border: none;
  background: none;
  cursor: pointer;
  width: 100%;
  text-align: left;
}
.side-link .icon { color: var(--muted); }
.side-link:hover { background: var(--bg-soft); color: var(--text); }
.side-link.active { background: var(--accent-soft); color: var(--accent-dark); font-weight: 600; }
.side-link.active .icon { color: var(--accent); }

.side-foot { margin-top: auto; display: grid; gap: 10px; border-top: 1px solid var(--border); padding-top: 16px; }
.side-user { display: flex; align-items: center; gap: 10px; padding: 0 4px; min-width: 0; }
.avatar {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 10px;
  background: linear-gradient(135deg, #dbeafe, #c7ddff);
  color: var(--accent-dark);
  font-weight: 700;
  font-size: 0.9rem;
}
.avatar-sm { width: 30px; height: 30px; border-radius: 8px; font-size: 0.8rem; }
.side-user-meta { display: grid; min-width: 0; }
.side-user-meta strong { font-size: 0.85rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-user-meta .muted { font-size: 0.74rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-logout { color: var(--muted); }

.main { flex: 1; min-width: 0; }
.main-in { max-width: 1060px; margin: 0 auto; padding: 40px 32px 72px; display: grid; gap: 22px; }

.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.page-head h1 { font-size: 1.85rem; margin-bottom: 5px; }
.page-head .muted { font-size: 0.93rem; }
.page-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.back-link { display: inline-flex; align-items: center; gap: 7px; font-size: 0.82rem; font-weight: 600; color: var(--muted); margin-bottom: 10px; }
.back-link .icon { width: 14px; height: 14px; transform: rotate(180deg); }
.back-link:hover { color: var(--accent); }

.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow-sm);
}
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.card-head h2 { font-size: 1.1rem; }
.card-head > div { display: grid; gap: 2px; }

.upload-card { display: grid; gap: 14px; }
.dropzone {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  border: 1.5px dashed var(--border-strong);
  border-radius: 12px;
  background: linear-gradient(180deg, #fbfdff, #f8fafd);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  outline: none;
}
.dropzone:hover, .dropzone:focus-visible { border-color: #9dbcf7; background: var(--accent-soft); }
.dropzone.dragging { border-color: var(--accent); background: var(--accent-soft); }
.dropzone.busy { opacity: 0.7; pointer-events: none; }
.drop-icon {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--accent);
  box-shadow: var(--shadow-sm);
}
.drop-icon .icon { width: 22px; height: 22px; }
.drop-copy { display: grid; gap: 2px; flex: 1; min-width: 0; }
.drop-copy strong { font-size: 0.96rem; }
.upload-extra { display: flex; gap: 12px; }
.upload-extra .field { flex: 1; }
.upload-progress { display: grid; gap: 6px; }
.upload-progress-top { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--muted); }
.upload-pct { font-weight: 600; color: var(--text-soft); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.chip {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: #fff;
  color: var(--text-soft);
  font-size: 0.8rem;
  font-weight: 500;
}
.chip:hover { border-color: #b9c6da; color: var(--text); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }

.toolbar { margin-bottom: 16px; }
.searchbar {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 6px 6px 12px; border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm); background: #fff; max-width: 560px;
}
.searchbar:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12); }
.searchbar-ico { display: inline-flex; color: var(--muted); }
.searchbar-ico .icon { width: 17px; height: 17px; }
.searchbar input[type="search"] { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; padding: 6px 0; }

.alert-ok { background: var(--green-soft); border: 1px solid #bbf7d0; color: #15803d; }
.center { text-align: center; }

.table-wrap { overflow-x: auto; margin: 0 -4px; }
table.files { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
table.files th.cell-check, table.files td.cell-check { width: 34px; padding-right: 0; }
table.files .cell-check input { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; }
table.files th {
  text-align: left;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  font-weight: 600;
  padding: 0 12px 10px;
  border-bottom: 1px solid var(--border);
}
table.files td { padding: 12px; border-bottom: 1px solid #f0f3f8; vertical-align: middle; }
table.files tr:last-child td { border-bottom: none; }
table.files tbody tr { transition: background 0.12s; }
table.files tbody tr:hover { background: #fafcff; }
.cell-name { display: flex; align-items: center; gap: 11px; min-width: 220px; }
.file-ico {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  color: var(--muted);
}
.file-ico .icon { width: 17px; height: 17px; }
.file-ico.has-thumb { position: relative; padding: 0; overflow: hidden; background: #eef2f7; }
.file-ico.has-thumb .icon { position: absolute; inset: 0; margin: auto; }
.file-ico.has-thumb img.thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 1;
}
.file-ico.has-thumb img.thumb.broken { display: none; }
.file-meta { display: grid; gap: 1px; min-width: 0; }
.file-name { font-weight: 550; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 340px; display: block; }
.file-meta .small { font-size: 0.76rem; }
.cell-actions { display: flex; gap: 4px; justify-content: flex-end; }
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.icon-btn:hover { background: var(--bg-soft); border-color: var(--border); color: var(--text); }
.icon-btn.danger:hover { background: var(--danger-soft); border-color: #f6cccc; color: var(--danger); }
.icon-btn:disabled { opacity: 0.4; cursor: wait; }

.empty { display: grid; justify-items: center; gap: 6px; padding: 42px 16px; text-align: center; color: var(--muted); }
.empty .icon { width: 34px; height: 34px; color: #c3cddd; }
.empty p { font-weight: 600; color: var(--text-soft); }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stat { display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow-sm); }
.stat-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 11px; background: var(--accent-soft); color: var(--accent); }
.stat-icon .icon { width: 20px; height: 20px; }
.stat strong { display: block; font-size: 1.25rem; letter-spacing: -0.02em; }
.stat div { display: grid; }

.mini-bar { height: 6px; border-radius: 99px; background: #e6ebf3; overflow: hidden; margin-bottom: 5px; }
.mini-bar span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, #60a5fa, #2563eb); }

.badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  vertical-align: middle;
}

.settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; align-items: start; }
.settings-grid .form { margin-top: 0; }

/* ---------------------------------------------------------------- shares */

.share-wrap { min-height: calc(100vh - 66px); display: grid; place-items: center; padding: 60px 20px; background: linear-gradient(180deg, #fbfdff, #f4f7fc); }
.share-card {
  width: 100%;
  max-width: 440px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 34px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 10px;
  justify-items: center;
  text-align: center;
}
.share-card .auth-brand { justify-self: start; margin-bottom: 8px; }
.share-icon {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--accent-soft);
  color: var(--accent);
  margin: 6px 0;
}
.share-icon .icon { width: 30px; height: 30px; }
.share-name { font-size: 1.25rem; word-break: break-word; }
.share-card .btn { margin-top: 9px; }
.share-card .small { margin-top: 4px; }

.share-card-lg { max-width: 760px; }
.share-preview { width: 100%; display: grid; place-items: center; }
.share-img {
  max-width: 100%;
  max-height: 60vh;
  border-radius: 12px;
  border: 1px solid var(--border);
  object-fit: contain;
  background: #f8fafc;
}
.share-video { width: 100%; max-height: 60vh; border-radius: 12px; background: #000; }
.share-audio {
  width: 100%;
  display: grid;
  gap: 10px;
  justify-items: center;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #f8fafc;
}
.share-audio .icon { width: 34px; height: 34px; color: var(--accent); }
.share-audio audio { width: 100%; }
.share-pdf { width: 100%; height: 60vh; border: 1px solid var(--border); border-radius: 12px; background: #fff; }
.share-text {
  width: 100%;
  max-height: 40vh;
  overflow: auto;
  text-align: left;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.share-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; width: 100%; }
.share-card .share-actions .btn { margin-top: 0; }

/* ----------------------------------------------------------------- toast */

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translate(-50%, 16px);
  background: #0f172a;
  color: #fff;
  padding: 11px 18px;
  border-radius: 10px;
  font-size: 0.88rem;
  font-weight: 500;
  box-shadow: 0 20px 40px -18px rgba(15, 23, 42, 0.6);
  opacity: 0;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 100;
  max-width: calc(100vw - 40px);
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast-ok { background: #14532d; }
.toast-err { background: #7f1d1d; }

/* ------------------------------------------------------- breadcrumbs */

.crumbs { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 0.88rem; margin: 8px 0 0; color: var(--muted); }
.crumbs .crumb { display: inline-flex; align-items: center; gap: 6px; color: var(--text-soft); font-weight: 550; }
.crumbs .crumb:hover { color: var(--accent); }
.crumbs .crumb.current { color: var(--text); font-weight: 600; }
.crumbs .crumb .icon { width: 16px; height: 16px; }
.crumbs .crumb-sep { display: inline-flex; color: #c3cddd; }
.crumbs .crumb-sep .icon { width: 14px; height: 14px; }

/* --------------------------------------------------------- subfolders */

.subfolders { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin-bottom: 16px; }
.subfolder {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--bg); transition: border-color 0.15s, background 0.15s;
}
.subfolder:hover { border-color: #b9c6da; background: var(--bg-soft); }
.subfolder-link { display: flex; align-items: center; gap: 9px; flex: 1; min-width: 0; color: var(--text); font-weight: 600; }
.subfolder-link:hover { color: var(--text); }
.subfolder-link .icon { color: var(--accent); }
.subfolder-link span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.subfolder-actions { display: flex; gap: 4px; }
.subfolder-actions .icon-btn { width: 30px; height: 30px; }

/* ------------------------------------------------------------ gallery */

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 14px; }
.gtile {
  position: relative; margin: 0; border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; background: var(--bg); display: flex; flex-direction: column;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.gtile:hover { border-color: #b9c6da; box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.gtile-open {
  position: relative; display: grid; place-items: center; width: 100%;
  aspect-ratio: 4 / 3; border: 0; padding: 0; cursor: pointer; background: #eef2f7; overflow: hidden;
}
.gtile-img { width: 100%; height: 100%; object-fit: cover; }
.gtile-placeholder { display: grid; place-items: center; width: 100%; height: 100%; color: #a9b6c9; }
.gtile-placeholder .icon { width: 42px; height: 42px; }
.gtile-check { position: absolute; top: 8px; left: 8px; z-index: 2; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: rgba(255, 255, 255, 0.9); box-shadow: var(--shadow-sm); }
.gtile-check input { width: 16px; height: 16px; cursor: pointer; accent-color: var(--accent); }
.gtile-meta { padding: 10px 12px 4px; display: grid; gap: 2px; min-width: 0; }
.gtile-name { font-weight: 600; font-size: 0.86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gtile-actions { display: flex; gap: 4px; padding: 4px 10px 10px; }
.gtile-actions .icon-btn { width: 30px; height: 30px; }

/* ------------------------------------------------------------ bulkbar */

.bulkbar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-bottom: 16px; padding: 10px 14px;
  background: var(--text); color: #fff; border-radius: var(--radius);
}
.bulkbar-all { display: inline-flex; align-items: center; gap: 8px; font-weight: 650; font-size: 0.9rem; cursor: pointer; }
.bulkbar-all input { width: 16px; height: 16px; accent-color: var(--accent); }
.bulkbar-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.bulkbar .btn { border-color: rgba(255, 255, 255, 0.25); }
.bulkbar .btn-ghost { color: #fff; background: rgba(255, 255, 255, 0.08); }
.bulkbar .btn-ghost:hover { background: rgba(255, 255, 255, 0.18); color: #fff; border-color: rgba(255, 255, 255, 0.4); }

/* ---------------------------------------------------- segmented control */

.seg { display: inline-flex; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: var(--bg); }
.seg-btn { padding: 7px 12px; color: var(--text-soft); display: inline-flex; align-items: center; justify-content: center; }
.seg-btn + .seg-btn { border-left: 1px solid var(--border); }
.seg-btn:hover { background: var(--bg-soft); color: var(--text); }
.seg-btn.active { background: var(--accent); color: #fff; }
.seg-btn.active:hover { color: #fff; }
.seg-btn .icon { width: 17px; height: 17px; }

/* --------------------------------------------------------------- plans */

.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; }
.plan { border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; background: var(--bg); display: grid; gap: 10px; align-content: start; }
.plan-current { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12); }
.plan-hot { border-color: var(--accent-dark); }
.plan h3 { font-size: 1.05rem; }
.plan .price { display: flex; align-items: baseline; gap: 6px; }
.plan .price strong { font-size: 1.9rem; font-weight: 700; letter-spacing: -0.03em; }
.plan .price span { font-size: 0.85rem; color: var(--muted); }
.plan .check-list { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 6px; font-size: 0.88rem; color: var(--text-soft); }
.plan .check-list li { display: flex; gap: 8px; align-items: flex-start; }
.plan .check-list li .icon { width: 16px; height: 16px; color: var(--green); margin-top: 3px; }
.plan-flag {
  justify-self: start; font-size: 0.72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.04em; padding: 3px 9px; border-radius: 999px; background: var(--accent); color: #fff;
}
.plan-flag-cur { background: var(--green); }

/* ------------------------------------------------------------- dialogs */

.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(15, 23, 42, 0.55);
  display: grid; place-items: center; padding: 20px;
  animation: fade-in 0.15s ease-out;
}
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
.modal {
  width: 100%; max-width: 430px; background: var(--bg);
  border-radius: var(--radius); padding: 22px;
  box-shadow: 0 30px 60px -20px rgba(15, 23, 42, 0.5);
  display: grid; gap: 14px;
}
.modal h2 { font-size: 1.15rem; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 4px; }
.modal .field select, .modal .field input {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm); background: var(--bg);
}
.modal .field select:focus, .modal .field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14); }
.modal .form { display: grid; gap: 14px; }

/* ----------------------------------------------------------- preview */

.preview-overlay { z-index: 300; }
.preview-box { width: 100%; max-width: 920px; background: var(--bg); border-radius: var(--radius); overflow: hidden; display: grid; box-shadow: 0 30px 60px -20px rgba(15, 23, 42, 0.6); }
.preview-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.preview-head strong { font-size: 0.9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.preview-body { display: grid; place-items: center; max-height: 78vh; overflow: auto; background: #0b1220; }
.preview-media { max-width: 100%; max-height: 78vh; display: block; }
.preview-frame { width: 100%; height: 78vh; border: 0; background: #fff; }
.preview-none { padding: 60px 20px; color: #94a3b8; }

/* ------------------------------------------------------------- lead */

.lead { font-size: 1.15rem; color: var(--text-soft); max-width: 620px; }

/* ------------------------------------------------------------- responsive */

@media (max-width: 960px) {
  .hero { padding: 48px 0 64px; }
  .hero-in { grid-template-columns: 1fr; gap: 40px; }
  .hero-art { min-height: 320px; }
  .grid-3 { grid-template-columns: 1fr; }
  .price-card { grid-template-columns: 1fr; }
  .price-side { border-left: none; border-top: 1px solid var(--border); }
  .form-grid { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: 1fr; }
}

@media (max-width: 780px) {
  .shell { flex-direction: column; }
  .sidebar {
    width: 100%;
    flex: none;
    height: auto;
    position: static;
    padding: 14px 16px;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .sidebar .storage { display: none; }
  .side-nav { display: flex; gap: 4px; flex: 1; }
  .side-link span { display: none; }
  .side-link { width: auto; padding: 9px; }
  .side-foot { margin: 0; border: none; padding: 0; }
  .side-user-meta { display: none; }
  .side-logout span { display: none; }
  .main-in { padding: 26px 18px 60px; }
  .mnav-link { display: none; }
  .form-grid { grid-template-columns: 1fr; }
  .dropzone { flex-wrap: wrap; }
  .dropzone .btn { width: 100%; }
  .file-name { max-width: 180px; }
  table.files th:nth-child(3), table.files td:nth-child(3) { display: none; }
  .gallery { grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 10px; }
  .subfolders { grid-template-columns: 1fr 1fr; }
  .bulkbar { flex-wrap: wrap; }
  .bulkbar .bulk-count { width: 100%; margin-bottom: 2px; }
}
