:root {
  color-scheme: light;
  --ink: #101828;
  --ink-soft: #475467;
  --muted: #667085;
  --faint: #98a2b3;
  --canvas: #f5f7fb;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --line: #e4e7ec;
  --line-strong: #d0d5dd;
  --brand: #2563eb;
  --brand-deep: #1d4ed8;
  --brand-soft: #eff4ff;
  --navy: #101827;
  --navy-soft: #1b263b;
  --mint: #12b76a;
  --mint-soft: #ecfdf3;
  --amber: #f79009;
  --amber-soft: #fffaeb;
  --danger: #d92d20;
  --danger-soft: #fef3f2;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.05);
  --shadow-md: 0 10px 30px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 24px 70px rgba(15, 23, 42, 0.18);
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --sidebar-width: 272px;
  --font: "Segoe UI Variable", "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: var(--canvas);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea,
select {
  color: inherit;
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
}

svg {
  width: 1.25rem;
  height: 1.25rem;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  letter-spacing: -0.025em;
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.is-hidden {
  display: none !important;
}

:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.3);
  outline-offset: 2px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.brand-mark {
  display: grid;
  flex: 0 0 auto;
  width: 39px;
  height: 39px;
  place-items: center;
  color: #fff;
  border-radius: 12px;
  background: linear-gradient(145deg, #3478f6 0%, #1d4ed8 100%);
  box-shadow: 0 7px 18px rgba(37, 99, 235, 0.28);
}

.brand-mark svg {
  width: 25px;
  height: 25px;
}

.brand-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  line-height: 1.15;
}

.brand-copy strong {
  color: #fff;
  font-size: 18px;
  letter-spacing: -0.03em;
}

.brand-copy small {
  margin-top: 3px;
  color: #98a2b3;
  font-size: 11px;
  letter-spacing: 0.02em;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--brand);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eyebrow.light {
  color: #93c5fd;
}

.button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 16px;
  border: 1px solid transparent;
  border-radius: 11px;
  background: transparent;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.2;
  white-space: nowrap;
  transition: transform 160ms ease, background 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.button svg {
  width: 18px;
  height: 18px;
}

.button:hover {
  transform: translateY(-1px);
}

.button:active {
  transform: translateY(0);
}

.button-primary {
  color: #fff;
  background: var(--brand);
  box-shadow: 0 5px 14px rgba(37, 99, 235, 0.22);
}

.button-primary:hover {
  background: var(--brand-deep);
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.28);
}

.button-ghost {
  color: var(--ink-soft);
  border-color: var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.button-ghost:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  background: var(--surface-soft);
}

.button-danger-ghost {
  color: var(--danger);
  border-color: #fecdca;
  background: #fff;
}

.button-danger-ghost:hover {
  background: var(--danger-soft);
}

.button-small {
  min-height: 34px;
  padding: 6px 11px;
  border-radius: 9px;
  font-size: 12px;
}

.button-small svg {
  width: 15px;
  height: 15px;
}

.button-large {
  min-height: 50px;
  border-radius: 12px;
}

.button-block {
  width: 100%;
}

.text-button {
  padding: 0;
  color: var(--brand);
  border: 0;
  background: none;
  font-size: 12px;
  font-weight: 650;
}

.icon-button {
  display: inline-grid;
  width: 36px;
  height: 36px;
  place-items: center;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  transition: color 150ms ease, background 150ms ease, border-color 150ms ease;
}

.icon-button svg {
  width: 18px;
  height: 18px;
}

.icon-button.subtle {
  color: var(--muted);
}

.icon-button.subtle:hover {
  color: var(--ink);
  border-color: var(--line);
  background: var(--surface-soft);
}

.icon-button.danger {
  color: #b42318;
}

.icon-button.danger:hover {
  background: var(--danger-soft);
}

.app-shell {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  z-index: 20;
  top: 0;
  bottom: 0;
  left: 0;
  display: flex;
  width: var(--sidebar-width);
  flex-direction: column;
  padding: 28px 20px 20px;
  color: #cbd5e1;
  background:
    radial-gradient(circle at -20% 12%, rgba(59, 130, 246, 0.19), transparent 34%),
    linear-gradient(175deg, #111c2e 0%, #0b1220 75%);
}

.sidebar > .brand {
  margin: 0 10px 42px;
}

.primary-nav {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.nav-label {
  padding: 0 12px 10px;
  color: #64748b;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 13px;
  color: #94a3b8;
  border: 1px solid transparent;
  border-radius: 11px;
  font-size: 14px;
  font-weight: 550;
  transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.nav-link:hover {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.045);
}

.nav-link.active {
  color: #fff;
  border-color: rgba(96, 165, 250, 0.16);
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.23), rgba(37, 99, 235, 0.08));
  box-shadow: inset 3px 0 #3b82f6;
}

.nav-link svg {
  width: 19px;
  height: 19px;
}

.sidebar-spacer {
  flex: 1;
}

.sidebar-tip {
  margin: 24px 2px 18px;
  padding: 16px;
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.13);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.sidebar-tip .tip-icon {
  display: grid;
  width: 31px;
  height: 31px;
  margin-bottom: 12px;
  place-items: center;
  color: #93c5fd;
  border-radius: 9px;
  background: rgba(59, 130, 246, 0.13);
}

.sidebar-tip strong {
  display: block;
  color: #f8fafc;
  font-size: 12px;
}

.sidebar-tip p {
  margin: 5px 0 0;
  color: #7f8ea5;
  font-size: 11px;
  line-height: 1.55;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 8px 2px;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.avatar {
  display: inline-grid;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  place-items: center;
  color: #1d4ed8;
  border-radius: 50%;
  background: linear-gradient(135deg, #dbeafe, #eff6ff);
  font-size: 14px;
  font-weight: 750;
  letter-spacing: -0.02em;
}

.avatar-small {
  width: 34px;
  height: 34px;
  font-size: 11px;
}

.avatar-hero {
  width: 74px;
  height: 74px;
  font-size: 22px;
}

.user-chip .avatar {
  color: #dbeafe;
  background: rgba(59, 130, 246, 0.2);
}

.user-chip-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  line-height: 1.25;
}

.user-chip-copy strong {
  overflow: hidden;
  color: #f1f5f9;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-chip-copy small {
  margin-top: 3px;
  color: #7f8ea5;
  font-size: 10px;
}

.user-chip .icon-button {
  width: 31px;
  height: 31px;
  color: #7f8ea5;
}

.user-chip .icon-button:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
}

.workspace {
  display: flex;
  min-height: 100vh;
  margin-left: var(--sidebar-width);
  flex-direction: column;
}

.app-topbar {
  display: flex;
  width: 100%;
  max-width: 1440px;
  min-height: 62px;
  align-items: center;
  justify-content: flex-end;
  margin: 0 auto;
  padding: 12px clamp(26px, 4vw, 64px) 0;
}

.mobile-header,
.mobile-nav {
  display: none;
}

.language-picker {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.language-picker .language-icon {
  position: absolute;
  left: 10px;
  z-index: 1;
  display: grid;
  place-items: center;
  color: var(--muted);
  pointer-events: none;
}

.language-picker .language-icon svg {
  width: 16px;
  height: 16px;
}

.language-picker select {
  min-height: 36px;
  max-width: 174px;
  padding: 6px 28px 6px 32px;
  color: var(--ink-soft);
  border: 1px solid var(--line);
  border-radius: 9px;
  outline: none;
  background-color: var(--surface);
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 14px) 15px, calc(100% - 10px) 15px;
  background-repeat: no-repeat;
  background-size: 4px 4px, 4px 4px;
  box-shadow: var(--shadow-sm);
  font-size: 11px;
  font-weight: 600;
  appearance: none;
}

.language-picker select:focus {
  border-color: #84adff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.11);
}

.language-submit {
  margin-left: 6px;
  padding: 6px 8px;
  color: var(--brand);
  border: 0;
  border-radius: 7px;
  background: var(--brand-soft);
  font-size: 10px;
}

.mobile-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.main-content {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 28px clamp(26px, 4vw, 64px) 56px;
}

.app-footer {
  display: flex;
  max-width: 1440px;
  width: 100%;
  margin: auto auto 0;
  justify-content: space-between;
  padding: 18px clamp(26px, 4vw, 64px) 30px;
  color: var(--faint);
  font-size: 11px;
}

.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}

.page-heading h1 {
  margin: 0;
  font-size: clamp(30px, 3vw, 43px);
  font-weight: 710;
  letter-spacing: -0.045em;
  line-height: 1.08;
}

.page-heading p {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.page-heading > .button {
  margin-bottom: 4px;
}

.stat-grid {
  display: grid;
  margin-bottom: 36px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow-sm);
}

.stat-icon {
  display: grid;
  width: 43px;
  height: 43px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 12px;
}

.stat-icon svg {
  width: 20px;
  height: 20px;
}

.stat-icon-blue {
  color: #2563eb;
  background: var(--brand-soft);
}

.stat-icon-mint {
  color: #059669;
  background: var(--mint-soft);
}

.stat-icon-amber {
  color: #dc6803;
  background: var(--amber-soft);
}

.stat-card > div {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.stat-card strong {
  font-size: 20px;
  font-weight: 720;
  letter-spacing: -0.03em;
}

.stat-card span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.content-section {
  width: 100%;
}

.section-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.section-toolbar h2 {
  margin: 0;
  font-size: 21px;
  font-weight: 680;
}

.section-toolbar p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.search-field {
  position: relative;
  display: flex;
  width: min(260px, 36vw);
  align-items: center;
}

.search-field svg {
  position: absolute;
  left: 12px;
  z-index: 1;
  width: 17px;
  height: 17px;
  color: var(--faint);
  pointer-events: none;
}

.search-field input {
  width: 100%;
  min-height: 39px;
  padding: 8px 13px 8px 37px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.search-field input::placeholder {
  color: var(--faint);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.project-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.project-card:hover {
  transform: translateY(-3px);
  border-color: #cdd7e8;
  box-shadow: var(--shadow-md);
}

.project-card-main {
  display: block;
  min-height: 194px;
  padding: 20px 20px 16px;
}

.project-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 22px;
}

.folder-tile {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: #2563eb;
  border-radius: 12px;
  background: #eff4ff;
}

.folder-tile svg {
  width: 22px;
  height: 22px;
}

.folder-tile.large {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  background: #eaf1ff;
}

.folder-tile.large svg {
  width: 28px;
  height: 28px;
}

.card-arrow {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  color: var(--faint);
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 14px;
  transition: color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.project-card:hover .card-arrow {
  color: var(--brand);
  border-color: #bfdbfe;
  transform: rotate(8deg);
}

.project-card h3 {
  overflow: hidden;
  margin: 0 0 7px;
  font-size: 17px;
  font-weight: 680;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-card p {
  display: -webkit-box;
  overflow: hidden;
  min-height: 40px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.project-card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 20px;
  color: var(--muted);
  border-top: 1px solid #f0f2f5;
  font-size: 10px;
}

.project-card-meta span:last-child {
  flex: 0 0 auto;
}

.project-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 8px 17px;
  border-top: 1px solid #f0f2f5;
  background: #fcfcfd;
}

.project-card-actions form {
  display: flex;
}

.empty-state {
  display: flex;
  min-height: 280px;
  align-items: center;
  justify-content: center;
  padding: 32px;
  flex-direction: column;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.6);
}

.empty-icon {
  display: grid;
  width: 58px;
  height: 58px;
  margin-bottom: 18px;
  place-items: center;
  color: var(--brand);
  border-radius: 17px;
  background: var(--brand-soft);
}

.empty-icon svg {
  width: 27px;
  height: 27px;
}

.empty-state h3 {
  margin: 0 0 7px;
  font-size: 18px;
}

.empty-state p {
  max-width: 420px;
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 12px;
}

.flash {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 20px;
  padding: 12px 13px;
  border: 1px solid;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 550;
}

.flash-success {
  color: #067647;
  border-color: #abefc6;
  background: var(--mint-soft);
}

.flash-error {
  color: #b42318;
  border-color: #fecdca;
  background: var(--danger-soft);
}

.flash-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: currentColor;
}

.flash-close {
  display: grid;
  width: 25px;
  height: 25px;
  margin-left: auto;
  padding: 0;
  place-items: center;
  color: currentColor;
  border: 0;
  border-radius: 6px;
  background: transparent;
  opacity: 0.65;
}

.flash-close:hover {
  background: rgba(0, 0, 0, 0.05);
  opacity: 1;
}

.flash-close svg {
  width: 15px;
  height: 15px;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 25px;
  color: var(--faint);
  font-size: 11px;
}

.breadcrumbs a {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--muted);
  font-weight: 600;
}

.breadcrumbs a:hover {
  color: var(--brand);
}

.breadcrumbs svg {
  width: 15px;
  height: 15px;
}

.project-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 25px;
}

.project-hero-copy {
  display: flex;
  max-width: 850px;
  align-items: flex-start;
  gap: 18px;
}

.project-hero h1 {
  margin: 0 0 7px;
  font-size: clamp(28px, 3.2vw, 42px);
  font-weight: 720;
  letter-spacing: -0.045em;
  line-height: 1.1;
}

.project-hero p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 8px;
  padding-top: 14px;
}

.hero-actions form {
  display: flex;
}

.project-stats {
  display: flex;
  gap: 0;
  margin-bottom: 23px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.76);
}

.project-stats > div {
  display: flex;
  min-width: 130px;
  padding: 12px 18px;
  flex-direction: column;
  border-right: 1px solid var(--line);
}

.project-stats > div:last-child {
  border-right: 0;
}

.project-stats strong {
  font-size: 14px;
  font-weight: 680;
}

.project-stats span {
  color: var(--muted);
  font-size: 10px;
}

.capture-panel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 15px;
  padding: 23px 25px;
  overflow: hidden;
  color: #dbeafe;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 88% 40%, rgba(96, 165, 250, 0.23), transparent 27%),
    linear-gradient(115deg, #111c30, #162b50 78%, #19345f);
  box-shadow: 0 16px 35px rgba(15, 23, 42, 0.13);
}

.capture-panel::after {
  position: absolute;
  top: -80px;
  right: 13%;
  width: 180px;
  height: 180px;
  content: "";
  border: 1px solid rgba(147, 197, 253, 0.09);
  border-radius: 50%;
}

.capture-copy {
  display: flex;
  min-width: 0;
  flex: 1;
  align-items: center;
  gap: 15px;
}

.capture-icon {
  display: grid;
  width: 50px;
  height: 50px;
  flex: 0 0 auto;
  place-items: center;
  color: #bfdbfe;
  border: 1px solid rgba(147, 197, 253, 0.2);
  border-radius: 14px;
  background: rgba(96, 165, 250, 0.12);
}

.capture-icon svg {
  width: 24px;
  height: 24px;
}

.capture-copy h2 {
  margin: 0 0 4px;
  color: #fff;
  font-size: 17px;
  font-weight: 650;
}

.capture-copy p {
  margin: 0;
  color: #8fa8c6;
  font-size: 11px;
}

.capture-actions {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 8px;
}

.capture-actions .button-ghost {
  color: #dbeafe;
  border-color: rgba(191, 219, 254, 0.17);
  background: rgba(255, 255, 255, 0.055);
  box-shadow: none;
}

.capture-actions .button-ghost:hover {
  border-color: rgba(191, 219, 254, 0.3);
  background: rgba(255, 255, 255, 0.09);
}

.upload-progress {
  position: absolute;
  right: 25px;
  bottom: 12px;
  left: 25px;
}

.upload-progress-copy {
  display: flex;
  justify-content: space-between;
  margin-bottom: 5px;
  color: #dbeafe;
  font-size: 9px;
}

.progress-track {
  height: 3px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.12);
}

.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #60a5fa;
  transition: width 120ms ease;
}

.drop-zone {
  display: flex;
  min-height: 65px;
  align-items: center;
  justify-content: center;
  gap: 11px;
  margin-bottom: 30px;
  color: var(--faint);
  border: 1px dashed #d6dce6;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.42);
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.drop-zone.is-dragging {
  color: var(--brand);
  border-color: #93c5fd;
  background: var(--brand-soft);
}

.drop-zone > span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: var(--surface);
}

.drop-zone p {
  display: flex;
  margin: 0;
  flex-direction: column;
  font-size: 10px;
}

.drop-zone strong {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 600;
}

.files-section {
  padding-top: 2px;
}

.file-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.file-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: transform 170ms ease, box-shadow 170ms ease;
}

.file-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.file-preview {
  position: relative;
  display: flex;
  width: 100%;
  height: 156px;
  align-items: center;
  justify-content: center;
  padding: 0;
  overflow: hidden;
  color: var(--muted);
  border: 0;
  border-bottom: 1px solid #f0f2f5;
  background:
    linear-gradient(135deg, rgba(37, 99, 235, 0.04), rgba(37, 99, 235, 0.01)),
    #f4f6f9;
}

img.file-preview,
.file-preview img {
  object-fit: cover;
  transition: transform 250ms ease;
}

button.file-preview:hover img {
  transform: scale(1.035);
}

.preview-overlay {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 5px 8px;
  color: #fff;
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.64);
  font-size: 9px;
  opacity: 0;
  transform: translateY(3px);
  transition: opacity 160ms ease, transform 160ms ease;
  backdrop-filter: blur(8px);
}

button.file-preview:hover .preview-overlay {
  opacity: 1;
  transform: translateY(0);
}

.document-preview {
  gap: 8px;
  flex-direction: column;
  font-size: 10px;
  font-weight: 600;
}

.file-type {
  display: grid;
  min-width: 56px;
  height: 60px;
  padding: 0 8px;
  place-items: center;
  color: #2563eb;
  border: 1px solid #bfdbfe;
  border-radius: 7px 12px 7px 7px;
  background: #fff;
  box-shadow: 0 5px 12px rgba(37, 99, 235, 0.08);
  font-size: 12px;
  font-weight: 750;
}

.file-info {
  display: flex;
  gap: 8px;
  padding: 12px 11px 11px 14px;
}

.file-title {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.file-title strong {
  overflow: hidden;
  font-size: 11px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-title span {
  margin-top: 3px;
  color: var(--faint);
  font-size: 9px;
}

.file-actions {
  display: flex;
  gap: 1px;
}

.file-actions .icon-button {
  width: 29px;
  height: 29px;
  border-radius: 7px;
}

.file-actions .icon-button svg {
  width: 15px;
  height: 15px;
}

.file-actions form {
  display: flex;
}

.people-list {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.person-row {
  display: grid;
  min-height: 78px;
  align-items: center;
  grid-template-columns: auto minmax(170px, 1.4fr) 110px minmax(120px, 1fr) auto;
  gap: 14px;
  padding: 13px 18px;
  border-bottom: 1px solid #f0f2f5;
}

.person-row:last-child {
  border-bottom: 0;
}

.person-identity {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.person-identity strong {
  display: flex;
  align-items: center;
  gap: 7px;
  overflow: hidden;
  font-size: 13px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.person-identity > span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.you-badge {
  padding: 2px 6px;
  color: #1d4ed8;
  border-radius: 99px;
  background: var(--brand-soft);
  font-size: 8px;
  font-weight: 650;
}

.role-badge {
  display: inline-flex;
  width: max-content;
  align-items: center;
  padding: 4px 8px;
  border-radius: 99px;
  font-size: 9px;
  font-weight: 650;
}

.role-super {
  color: #1d4ed8;
  border: 1px solid #dbe7ff;
  background: var(--brand-soft);
}

.role-member {
  color: #475467;
  border: 1px solid #eaecf0;
  background: #f9fafb;
}

.person-joined {
  color: var(--faint);
  font-size: 10px;
}

.person-actions {
  display: flex;
  align-items: center;
  gap: 5px;
}

.person-actions form {
  display: flex;
}

.account-layout {
  display: grid;
  max-width: 980px;
  grid-template-columns: minmax(240px, 0.75fr) minmax(380px, 1.25fr);
  gap: 18px;
}

.account-card {
  padding: 27px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.profile-card {
  text-align: center;
}

.profile-card .avatar {
  margin: 0 auto 16px;
}

.profile-card h2 {
  margin: 0;
  font-size: 21px;
  font-weight: 680;
}

.profile-card > p {
  margin: 3px 0 12px;
  color: var(--muted);
  font-size: 12px;
}

.profile-card > .role-badge {
  margin: 0 auto;
}

.profile-details {
  margin: 25px 0 0;
  text-align: left;
  border-top: 1px solid var(--line);
}

.profile-details > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid #f2f4f7;
  font-size: 11px;
}

.profile-details dt {
  color: var(--muted);
}

.profile-details dd {
  margin: 0;
  font-weight: 600;
}

.password-card h2 {
  margin: 0 0 6px;
  font-size: 23px;
}

.password-card > p {
  max-width: 570px;
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.stacked-form {
  display: flex;
  flex-direction: column;
  gap: 17px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  padding-top: 3px;
}

.trust-note {
  display: flex;
  max-width: 980px;
  align-items: flex-start;
  gap: 13px;
  margin-top: 18px;
  padding: 17px 20px;
  color: #344054;
  border: 1px solid #d9e7ff;
  border-radius: 13px;
  background: #f6f9ff;
}

.trust-note > svg {
  width: 20px;
  height: 20px;
  margin-top: 1px;
  color: var(--brand);
}

.trust-note strong {
  display: block;
  margin-bottom: 2px;
  font-size: 11px;
}

.trust-note p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
}

.dialog {
  width: min(520px, calc(100vw - 28px));
  max-height: min(88vh, 800px);
  margin: auto;
  padding: 0;
  overflow: auto;
  color: var(--ink);
  border: 0;
  border-radius: 19px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}

.dialog::backdrop {
  background: rgba(8, 15, 28, 0.62);
  backdrop-filter: blur(5px);
}

.dialog[open] {
  animation: dialog-in 180ms ease-out;
}

@keyframes dialog-in {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 23px 25px 16px;
}

.dialog-head h2 {
  margin: 0;
  font-size: 23px;
  font-weight: 700;
}

.dialog-head .eyebrow {
  margin-bottom: 5px;
}

.dialog-body {
  display: flex;
  padding: 2px 25px 23px;
  flex-direction: column;
  gap: 16px;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 25px 20px;
  border-top: 1px solid var(--line);
  background: #fcfcfd;
}

.preview-dialog {
  width: min(880px, calc(100vw - 24px));
}

.preview-dialog-body {
  display: grid;
  min-height: 220px;
  max-height: 65vh;
  padding: 0 25px;
  place-items: center;
  background: #f4f6f9;
}

.preview-dialog-body img {
  max-width: 100%;
  max-height: 65vh;
  object-fit: contain;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.form-grid .field {
  min-width: 0;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.field label {
  color: #344054;
  font-size: 11px;
  font-weight: 650;
}

.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.field-hint {
  color: var(--faint);
  font-size: 9px;
  line-height: 1.45;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  outline: none;
  background: var(--surface);
  font-size: 13px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.field textarea {
  min-height: 88px;
  resize: vertical;
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--faint);
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: #84adff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.11);
}

.form-alert {
  margin: 16px 0 18px;
  padding: 11px 12px;
  color: #b42318;
  border: 1px solid #fecdca;
  border-radius: 9px;
  background: var(--danger-soft);
  font-size: 11px;
  line-height: 1.5;
}

.form-notice {
  margin: 16px 0 18px;
  padding: 11px 12px;
  color: #067647;
  border: 1px solid #abefc6;
  border-radius: 9px;
  background: var(--mint-soft);
  font-size: 11px;
  line-height: 1.5;
}

.login-page {
  color-scheme: dark;
  background: #0b1220;
}

.login-shell {
  display: grid;
  min-height: 100vh;
  grid-template-columns: minmax(0, 1.13fr) minmax(420px, 0.87fr);
}

.login-visual {
  position: relative;
  display: flex;
  min-height: 100vh;
  padding: clamp(30px, 4vw, 58px);
  overflow: hidden;
  flex-direction: column;
  color: #e2e8f0;
  background:
    radial-gradient(circle at 82% 16%, rgba(59, 130, 246, 0.26), transparent 28%),
    radial-gradient(circle at 2% 92%, rgba(20, 184, 166, 0.12), transparent 31%),
    linear-gradient(145deg, #111c30 0%, #0b1322 58%, #0d1a30 100%);
}

.login-visual::before,
.login-visual::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(148, 197, 255, 0.08);
  border-radius: 50%;
  pointer-events: none;
}

.login-visual::before {
  top: -260px;
  right: -190px;
  width: 680px;
  height: 680px;
}

.login-visual::after {
  top: -165px;
  right: -95px;
  width: 490px;
  height: 490px;
}

.login-brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
}

.login-message {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: auto 0 37px;
}

.login-message h1 {
  margin: 0 0 22px;
  color: #f8fafc;
  font-size: clamp(42px, 4.8vw, 70px);
  font-weight: 650;
  letter-spacing: -0.055em;
  line-height: 1.01;
}

.login-message h1 em {
  color: #93c5fd;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
}

.login-message p {
  max-width: 550px;
  margin: 0;
  color: #94a3b8;
  font-size: clamp(13px, 1.2vw, 16px);
  line-height: 1.7;
}

.visual-preview {
  position: relative;
  z-index: 1;
  width: min(590px, 94%);
  height: 180px;
  margin-bottom: 28px;
}

.preview-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px;
  color: #e2e8f0;
  border: 1px solid rgba(148, 197, 255, 0.14);
  border-radius: 15px;
  background: rgba(30, 43, 63, 0.8);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(14px);
}

.preview-card > span:nth-child(2) {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.preview-card strong {
  color: #f1f5f9;
  font-size: 11px;
  font-weight: 650;
}

.preview-card small {
  margin-top: 3px;
  color: #7f91aa;
  font-size: 9px;
}

.preview-project {
  top: 8px;
  left: 0;
  width: 265px;
  transform: rotate(-2deg);
}

.preview-project .preview-icon {
  display: grid;
  width: 37px;
  height: 37px;
  flex: 0 0 auto;
  place-items: center;
  color: #93c5fd;
  border-radius: 10px;
  background: rgba(59, 130, 246, 0.15);
}

.preview-dots {
  margin-left: auto;
  color: #61728a;
}

.preview-dots svg {
  width: 17px;
  height: 17px;
}

.preview-photo {
  top: 38px;
  left: 245px;
  width: 282px;
  transform: rotate(2deg);
}

.preview-photo-art {
  position: relative;
  width: 67px;
  height: 54px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 8px;
  background: linear-gradient(#93c5fd, #dbeafe);
}

.preview-photo-art .sun {
  position: absolute;
  top: 9px;
  right: 11px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #fbbf24;
}

.preview-photo-art .hill {
  position: absolute;
  border-radius: 50%;
  background: #3b82f6;
}

.preview-photo-art .hill-one {
  bottom: -25px;
  left: -13px;
  width: 70px;
  height: 58px;
  transform: rotate(22deg);
}

.preview-photo-art .hill-two {
  right: -20px;
  bottom: -30px;
  width: 75px;
  height: 65px;
  background: #1d4ed8;
  transform: rotate(-19deg);
}

.login-visual-footer {
  position: relative;
  z-index: 1;
  margin: 0;
  color: #5f728e;
  font-size: 10px;
}

.login-panel {
  position: relative;
  display: flex;
  min-height: 100vh;
  padding: clamp(32px, 5vw, 74px);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: var(--ink);
  background: #f9fafc;
}

.login-language {
  position: absolute;
  top: 26px;
  right: 30px;
  z-index: 2;
}

.login-form-wrap {
  width: min(100%, 395px);
}

.login-mobile-brand {
  display: none;
}

.login-form-wrap h2 {
  margin: 0 0 9px;
  font-size: clamp(27px, 2.8vw, 35px);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.15;
}

.login-intro {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.remember-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 1px 0 3px;
  cursor: pointer;
}

.remember-row input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.switch {
  display: flex;
  width: 35px;
  height: 20px;
  flex: 0 0 auto;
  align-items: center;
  padding: 2px;
  border-radius: 99px;
  background: #d0d5dd;
  transition: background 160ms ease;
}

.switch span {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(16, 24, 40, 0.2);
  transition: transform 160ms ease;
}

.remember-row input:checked + .switch {
  background: var(--brand);
}

.remember-row input:checked + .switch span {
  transform: translateX(15px);
}

.remember-row input:focus-visible + .switch {
  outline: 3px solid rgba(37, 99, 235, 0.25);
  outline-offset: 2px;
}

.remember-row > span:last-child {
  display: flex;
  flex-direction: column;
}

.remember-row strong {
  color: #344054;
  font-size: 10px;
  font-weight: 650;
}

.remember-row small {
  margin-top: 2px;
  color: var(--faint);
  font-size: 9px;
}

.login-help {
  margin: 25px 0 0;
  padding-top: 19px;
  color: var(--faint);
  border-top: 1px solid var(--line);
  font-size: 9px;
  line-height: 1.6;
}

.login-copyright {
  width: min(100%, 395px);
  margin: 38px 0 0;
  color: #b0b8c4;
  font-size: 9px;
}

.error-state {
  display: flex;
  min-height: calc(100vh - 210px);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
}

.error-code {
  color: var(--brand);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.error-state h1 {
  margin: 12px 0 8px;
  font-size: clamp(30px, 4vw, 48px);
  letter-spacing: -0.05em;
}

.error-state p {
  max-width: 430px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.error-actions {
  margin-top: 25px;
}

.toast-region {
  position: fixed;
  z-index: 100;
  right: 22px;
  bottom: 22px;
  display: flex;
  max-width: min(390px, calc(100vw - 32px));
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  padding: 12px 15px;
  color: #fff;
  border-radius: 10px;
  background: #182230;
  box-shadow: var(--shadow-lg);
  font-size: 11px;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.toast-error {
  background: #912018;
}

@media (max-width: 1180px) {
  .project-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .file-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .login-shell {
    grid-template-columns: minmax(0, 1fr) minmax(390px, 0.9fr);
  }

  .preview-photo {
    left: 190px;
  }

  .preview-project {
    width: 230px;
  }
}

@media (max-width: 960px) {
  :root {
    --sidebar-width: 236px;
  }

  .sidebar {
    padding-right: 14px;
    padding-left: 14px;
  }

  .sidebar-tip {
    display: none;
  }

  .main-content {
    padding-top: 38px;
  }

  .capture-panel {
    align-items: flex-start;
    flex-direction: column;
    gap: 18px;
  }

  .capture-actions {
    width: 100%;
  }

  .capture-actions .button {
    flex: 1;
  }

  .person-row {
    grid-template-columns: auto minmax(150px, 1.2fr) 100px auto;
  }

  .person-joined {
    display: none;
  }

  .login-visual {
    padding: 38px;
  }

  .preview-card {
    transform: none;
  }

  .preview-photo {
    top: 88px;
    left: 90px;
  }

  .visual-preview {
    height: 220px;
  }
}

@media (max-width: 760px) {
  body {
    padding-bottom: env(safe-area-inset-bottom);
  }

  .sidebar {
    display: none;
  }

  .workspace {
    margin-left: 0;
    padding-bottom: 72px;
  }

  .mobile-header {
    position: sticky;
    z-index: 15;
    top: 0;
    display: flex;
    height: 64px;
    align-items: center;
    justify-content: space-between;
    padding: 0 18px;
    border-bottom: 1px solid rgba(228, 231, 236, 0.8);
    background: rgba(248, 250, 252, 0.9);
    backdrop-filter: blur(14px);
  }

  .app-topbar {
    display: none;
  }

  .mobile-header-actions .language-picker select {
    width: 108px;
    min-height: 32px;
    padding-right: 19px;
    padding-left: 27px;
    background-position: calc(100% - 11px) 13px, calc(100% - 7px) 13px;
    font-size: 10px;
  }

  .mobile-header-actions .language-picker .language-icon {
    left: 8px;
  }

  .mobile-header-actions .language-picker .language-icon svg {
    width: 14px;
    height: 14px;
  }

  .mobile-header .brand-mark {
    width: 32px;
    height: 32px;
    border-radius: 9px;
  }

  .mobile-header .brand-mark svg {
    width: 21px;
    height: 21px;
  }

  .mobile-header .brand-copy strong {
    color: var(--ink);
    font-size: 16px;
  }

  .mobile-nav {
    position: fixed;
    z-index: 30;
    right: 0;
    bottom: 0;
    left: 0;
    display: flex;
    min-height: 64px;
    align-items: stretch;
    justify-content: space-around;
    padding: 6px 12px calc(6px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(16px);
  }

  .mobile-nav a {
    display: flex;
    min-width: 74px;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-direction: column;
    color: var(--muted);
    border-radius: 10px;
    font-size: 9px;
    font-weight: 600;
  }

  .mobile-nav a.active {
    color: var(--brand);
    background: var(--brand-soft);
  }

  .mobile-nav svg {
    width: 19px;
    height: 19px;
  }

  .main-content {
    padding: 25px 16px 38px;
  }

  .app-footer {
    display: none;
  }

  .page-heading {
    align-items: flex-start;
    margin-bottom: 24px;
    flex-direction: column;
    gap: 16px;
  }

  .page-heading h1 {
    font-size: 31px;
  }

  .page-heading p {
    font-size: 12px;
  }

  .page-heading > .button {
    width: 100%;
  }

  .stat-grid {
    margin-bottom: 30px;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .stat-card {
    min-height: 76px;
    padding: 13px;
  }

  .stat-card:last-child {
    grid-column: 1 / -1;
  }

  .stat-icon {
    width: 38px;
    height: 38px;
  }

  .stat-card strong {
    font-size: 17px;
  }

  .section-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .search-field {
    width: 100%;
  }

  .project-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .project-card-main {
    min-height: 177px;
  }

  .project-card:hover,
  .file-card:hover {
    transform: none;
  }

  .breadcrumbs {
    margin-bottom: 18px;
  }

  .project-hero {
    flex-direction: column;
    gap: 18px;
  }

  .project-hero-copy {
    gap: 13px;
  }

  .folder-tile.large {
    width: 46px;
    height: 46px;
    border-radius: 13px;
  }

  .folder-tile.large svg {
    width: 23px;
    height: 23px;
  }

  .project-hero h1 {
    font-size: 30px;
  }

  .hero-actions {
    width: 100%;
    padding-top: 0;
  }

  .hero-actions .button,
  .hero-actions form {
    flex: 1;
  }

  .project-stats {
    width: 100%;
  }

  .project-stats > div {
    min-width: 0;
    padding: 11px;
    flex: 1;
  }

  .project-stats strong {
    overflow: hidden;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .capture-panel {
    padding: 20px;
    border-radius: 18px;
  }

  .capture-copy {
    align-items: flex-start;
  }

  .capture-icon {
    width: 42px;
    height: 42px;
  }

  .capture-copy h2 {
    font-size: 16px;
  }

  .capture-actions {
    flex-direction: column;
  }

  .capture-actions .button {
    width: 100%;
  }

  .upload-progress {
    right: 20px;
    left: 20px;
  }

  .drop-zone {
    display: none;
  }

  .file-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .file-preview {
    height: 138px;
  }

  .preview-overlay {
    display: none;
  }

  .file-info {
    padding: 10px;
  }

  .file-title span {
    font-size: 8px;
  }

  .file-actions .icon-button {
    width: 27px;
    height: 27px;
  }

  .people-list {
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .person-row {
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 10px;
    margin-bottom: 10px;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: #fff;
  }

  .person-row .role-badge {
    display: none;
  }

  .person-actions .button-small {
    width: 35px;
    padding: 0;
    font-size: 0;
  }

  .person-actions .button-small::before {
    content: "•••";
    font-size: 13px;
  }

  .account-layout {
    grid-template-columns: 1fr;
  }

  .account-card {
    padding: 22px;
  }

  .trust-note {
    margin-top: 12px;
  }

  .dialog {
    width: calc(100vw - 20px);
    max-height: calc(100dvh - 24px);
  }

  .dialog-head,
  .dialog-body {
    padding-right: 19px;
    padding-left: 19px;
  }

  .dialog-actions {
    padding-right: 19px;
    padding-left: 19px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .toast-region {
    right: 16px;
    bottom: 82px;
    left: 16px;
    max-width: none;
  }
}

@media (max-width: 680px) {
  .login-page {
    background: #f9fafc;
  }

  .login-shell {
    display: block;
    min-height: 100vh;
  }

  .login-visual {
    display: none;
  }

  .login-panel {
    min-height: 100vh;
    padding: 78px 24px 35px;
    justify-content: flex-start;
    background:
      radial-gradient(circle at 100% 0%, rgba(59, 130, 246, 0.09), transparent 27%),
      #f9fafc;
  }

  .login-language {
    top: 24px;
    right: 24px;
  }

  .login-mobile-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 42px;
  }

  .login-mobile-brand .brand-copy strong {
    color: var(--ink);
  }

  .login-mobile-brand .brand-copy small {
    color: var(--muted);
  }

  .login-form-wrap {
    width: 100%;
    max-width: 420px;
  }

  .login-form-wrap h2 {
    font-size: 30px;
  }

  .login-form-wrap .field input {
    min-height: 49px;
  }

  .login-help {
    text-align: center;
  }

  .login-copyright {
    width: 100%;
    margin-top: auto;
    padding-top: 55px;
    text-align: center;
  }
}

@media (max-width: 390px) {
  .file-grid {
    grid-template-columns: 1fr;
  }

  .file-preview {
    height: 180px;
  }

  .project-stats > div:last-child {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
