:root {
  --ink: #202a33;
  --muted: #667784;
  --line: #d8e7f0;
  --paper: #ffffff;
  --canvas: #f3f8fb;
  --brand: #176fae;
  --brand-2: #4db2ec;
  --accent: #73c7e3;
  --soft: #eaf5fc;
  --danger: #a83f45;
  --shadow: 0 18px 55px rgba(23, 111, 174, .12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Calendrier des échéances client */
.calendar-hero { align-items: flex-end; justify-content: space-between; }
.calendar-summary-card { min-width: 190px; padding: 18px 22px; display: grid; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.78); box-shadow: 0 12px 30px rgba(19,73,112,.08); }
.calendar-summary-card strong { color: var(--brand); font-size: 34px; line-height: 1; }
.calendar-summary-card span { margin-top: 7px; color: var(--muted); font-size: 13px; font-weight: 750; }
.calendar-page-grid { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(300px, .8fr); align-items: start; gap: 20px; }
.deadline-calendar, .calendar-upcoming-panel, .calendar-subscription-panel { padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: white; }
.calendar-toolbar { min-height: 88px; padding: 18px 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); }
.calendar-toolbar h2, .calendar-side-column h2 { margin: 4px 0 0; }
.calendar-navigation { display: flex; align-items: center; gap: 7px; }
.button.compact { min-width: 40px; padding: 9px 12px; }
.calendar-scroll { overflow-x: auto; }
.calendar-weekdays, .calendar-month-grid { min-width: 595px; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.calendar-weekdays { border-bottom: 1px solid var(--line); background: #f4f9fc; }
.calendar-weekdays span { padding: 10px 8px; color: var(--muted); font-size: 10px; font-weight: 900; letter-spacing: .08em; text-align: center; text-transform: uppercase; }
.calendar-day { min-height: 124px; padding: 8px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: white; }
.calendar-day:nth-child(7n) { border-right: 0; }
.calendar-day > time { width: 28px; height: 28px; display: inline-grid; place-items: center; border-radius: 999px; color: #355269; font-size: 12px; font-weight: 850; }
.calendar-day.outside-month { background: #f8fafb; }
.calendar-day.outside-month > time { color: #a9bac6; }
.calendar-day.today > time { background: var(--brand); color: white; }
.calendar-event-chip { margin-top: 5px; padding: 7px 8px; display: block; overflow: hidden; border-left: 3px solid var(--brand); border-radius: 7px; background: #eaf5fc; color: #123b59; text-decoration: none; }
.calendar-event-chip:hover { background: #d9eefb; }
.calendar-event-chip strong, .calendar-event-chip small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.calendar-event-chip strong { font-size: 11px; }
.calendar-event-chip small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.calendar-empty { margin: 0; padding: 13px 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.calendar-side-column { display: grid; gap: 20px; }
.calendar-upcoming-panel, .calendar-subscription-panel { padding: 20px; }
.calendar-upcoming-list { margin: 16px -20px -20px; }
.calendar-upcoming-item { padding: 13px 18px; display: grid; grid-template-columns: 74px minmax(0, 1fr) auto; align-items: center; gap: 10px; border-top: 1px solid var(--line); color: inherit; text-decoration: none; }
.calendar-upcoming-item:hover { background: #f4f9fc; }
.calendar-upcoming-item time { color: var(--brand); font-size: 11px; font-weight: 900; }
.calendar-upcoming-item span, .calendar-upcoming-item strong, .calendar-upcoming-item small { min-width: 0; display: block; }
.calendar-upcoming-item strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.calendar-upcoming-item small { margin-top: 3px; color: var(--muted); font-size: 10px; }
.calendar-subscription-panel > p { color: var(--muted); font-size: 13px; line-height: 1.55; }
.calendar-subscription-panel label { display: block; margin: 16px 0 6px; font-size: 11px; font-weight: 900; }
.calendar-subscription-copy { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.calendar-subscription-copy input { min-width: 0; font-size: 11px; }
.calendar-copy-status { min-height: 20px; margin: 5px 0 0 !important; color: #138469 !important; font-weight: 800; }
.email-outbox-layout { display: grid; grid-template-columns: minmax(300px, .85fr) minmax(0, 1.4fr); gap: 18px; align-items: start; }
.email-log-row { text-decoration: none; color: inherit; }
.email-log-row.active, .email-log-row:hover { background: #edf7ff; }
.email-status-preview { color: #855b00; background: #fff3cf; }
.email-status-sent { color: #08745d; background: #dcf7ef; }
.email-status-failed { color: #a5222b; background: #ffe5e8; }
.email-log-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; margin: 18px 0; padding: 1px; background: var(--line); border-radius: 14px; overflow: hidden; }
.email-log-meta div { padding: 13px; background: #fff; }
.email-log-meta dt { color: var(--muted); font-size: 10px; font-weight: 900; text-transform: uppercase; letter-spacing: .06em; }
.email-log-meta dd { margin: 5px 0 0; overflow-wrap: anywhere; }
.email-body-preview { max-height: 430px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: #f8fbfd; font: inherit; font-size: 13px; }
.email-detail-empty { min-height: 180px; display: grid; place-items: center; text-align: center; }
.invitation-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.invitation-row-link { text-decoration: none; color: inherit; }
.invitation-open-hint { display: block; margin-top: 5px; color: var(--blue); font-size: 11px; font-weight: 800; }
.invitation-link-copy { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; margin: 18px 0; }
.invitation-link-copy input { min-width: 0; }
.invitation-email-preview { border-bottom: 1px solid var(--line); }
.invitation-email-preview summary { cursor: pointer; list-style: none; }
.invitation-email-preview summary::-webkit-details-marker { display: none; }
.invitation-email-preview .email-body-preview { margin: 10px; }
.calendar-download-link { width: 100%; justify-content: center; }
.calendar-help { margin: 16px 0; padding: 12px 14px; border-radius: 10px; background: #f4f9fc; font-size: 12px; }
.calendar-help summary { color: var(--brand); font-weight: 850; cursor: pointer; }
.calendar-help p { margin: 9px 0 0; color: var(--muted); line-height: 1.5; }
.danger-link { color: #a63648; font-size: 11px; }

@media (max-width: 1100px) {
  .calendar-page-grid { grid-template-columns: 1fr; }
  .calendar-side-column { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
  .calendar-hero { align-items: stretch; }
  .calendar-summary-card { width: 100%; min-width: 0; }
  .calendar-toolbar { align-items: flex-start; flex-direction: column; }
  .calendar-navigation { width: 100%; display: grid; grid-template-columns: auto 1fr auto; }
  .calendar-navigation .button { justify-content: center; }
  .calendar-weekdays, .calendar-month-grid { min-width: 595px; }
  .calendar-day { min-height: 112px; }
  .calendar-side-column { grid-template-columns: 1fr; }
  .calendar-subscription-copy { grid-template-columns: 1fr; }
  .email-outbox-layout { grid-template-columns: 1fr; }
  .email-log-meta { grid-template-columns: 1fr; }
  .invitation-link-copy { grid-template-columns: 1fr; }
  .invitation-link-copy .button { width: 100%; }
  .calendar-subscription-copy .button { width: 100%; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--canvas); color: var(--ink); min-height: 100vh; overflow-x: hidden; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
.shell { --sidebar-top: #2787c3; --sidebar-middle: var(--brand); --sidebar-bottom: #125f96; display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100vh; }
.shell.role-broker { --sidebar-top: #192b3d; --sidebar-middle: #0e1e2d; --sidebar-bottom: #08131e; }
.shell.role-company_admin, .shell.role-developer { --sidebar-top: #8b3fd0; --sidebar-middle: #6725aa; --sidebar-bottom: #3e176d; }
.sidebar { background: linear-gradient(180deg, var(--sidebar-top) 0%, var(--sidebar-middle) 52%, var(--sidebar-bottom) 100%); color: white; padding: 30px 22px; display: flex; flex-direction: column; gap: 32px; transition: background .2s ease; }
.brand { width: 100%; max-width: 205px; padding: 12px 14px 10px; display: block; border-radius: 13px; background: white; box-shadow: 0 8px 24px rgba(13, 74, 115, .16); text-decoration: none; }
.brand img { display: block; width: 100%; height: auto; }
.brand small { display: block; margin-top: 5px; color: var(--brand); font-size: 10px; font-weight: 850; text-transform: uppercase; letter-spacing: .18em; }
.nav { display: grid; gap: 7px; }
.mobile-nav-toggle { display: none; }
.mobile-nav-unread-badge { display: none; }
.nav a { color: #e6f4fd; text-decoration: none; border-radius: 10px; padding: 11px 12px; }
.nav-with-badge { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.nav-unread-badge { min-width: 22px; height: 22px; padding: 0 6px; display: inline-grid; place-items: center; border-radius: 999px; background: #e1263d; color: white; font-size: 10px; line-height: 1; box-shadow: 0 3px 10px rgba(90,0,18,.22); }
.nav-unread-badge[hidden] { display: none; }
.nav a:hover, .nav a.active { background: rgba(255,255,255,.16); color: white; }
.sidebar-footer { margin-top: auto; color: #e6f4fd; font-size: 13px; }
.sidebar-footer strong { color: white; display: block; }
.sidebar-account { display: flex; align-items: center; gap: 10px; }
.sidebar-account img, .account-initials { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; flex: none; }
.account-initials { display: grid; place-items: center; background: rgba(255,255,255,.14); color: white; font-weight: 850; text-transform: uppercase; }
.link-button { border: 0; background: none; color: inherit; padding: 0; cursor: pointer; text-decoration: underline; }
.main { min-width: 0; }
.topbar { min-height: 78px; padding: 18px 34px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.82); backdrop-filter: blur(10px); }
.eyebrow { color: var(--brand-2); font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.topbar strong { display: block; margin-top: 3px; }
.content { padding: 36px; max-width: 1440px; margin: auto; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(30px, 4vw, 46px); letter-spacing: -.045em; line-height: 1.04; }
h2 { font-size: 22px; letter-spacing: -.025em; }
h3 { font-size: 16px; }
.lead { color: var(--muted); max-width: 720px; font-size: 17px; }
.hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; margin-bottom: 28px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; background: var(--brand); color: white; border: 0; border-radius: 10px; padding: 11px 16px; text-decoration: none; cursor: pointer; font-weight: 700; }
.button:hover { background: var(--brand-2); }
.button.secondary { color: var(--brand); background: var(--soft); }
.button.ghost { color: var(--brand); background: white; border: 1px solid var(--line); }
.button.danger { color: white; background: var(--danger); }
.button.danger:hover { background: #852f34; }
.button:disabled { opacity: .55; cursor: not-allowed; }
.button.small { padding: 8px 11px; font-size: 13px; }
.grid { display: grid; gap: 18px; }
.grid.cards { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: 17px; padding: 22px; box-shadow: 0 1px 0 rgba(24,40,32,.02); }
.card.interactive { text-decoration: none; transition: transform .16s, box-shadow .16s; }
.card.interactive:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.metric { color: var(--muted); font-size: 13px; }
.metric strong { color: var(--ink); display: block; font-size: 30px; margin-top: 7px; }
.client-home-hero { align-items: center; }
.client-home-identity { display: flex; align-items: center; gap: 12px; padding: 12px 15px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.client-home-identity img, .client-home-identity > span { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex: none; }
.client-home-identity > span { display: grid; place-items: center; background: var(--soft); color: var(--brand); font-weight: 900; }
.client-home-identity strong, .client-home-identity small { display: block; }
.client-home-identity small { color: var(--muted); margin-top: 3px; }
.home-service-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.service-tile { min-height: 285px; padding: 24px; border: 1px solid var(--line); border-radius: 18px; background: white; color: inherit; text-decoration: none; display: flex; flex-direction: column; position: relative; overflow: hidden; transition: transform .16s, box-shadow .16s, border-color .16s; }
a.service-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: #afd6ee; }
.service-tile::after { content: ""; position: absolute; width: 150px; height: 150px; right: -65px; top: -65px; border-radius: 50%; background: var(--soft); opacity: .65; }
.service-icon { width: 48px; height: 48px; margin-bottom: 24px; border-radius: 14px; display: grid; place-items: center; background: var(--soft); color: var(--brand); font-size: 23px; font-weight: 900; position: relative; z-index: 1; }
.service-tile h2 { margin: 5px 0 8px; font-size: 27px; }
.service-tile p { color: var(--muted); line-height: 1.55; }
.service-status { margin-top: auto; color: var(--brand); font-size: 13px; }
.service-arrow { margin-top: 17px; color: var(--brand-2); font-weight: 850; }
.discussions-tile .service-icon { background: #e9f5fc; }
.documents-tile .service-icon { background: #dcedf8; color: var(--brand); }
.account-tile .service-icon { background: #e5edf6; color: #315a88; }
.settings-tile .service-icon { background: #edf4fb; color: #3566a8; }
.tag, .reference { display: inline-flex; align-items: center; border-radius: 999px; padding: 5px 9px; background: var(--soft); color: var(--brand-2); font-size: 12px; font-weight: 800; }
.reference { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; background: #e7f2f9; color: #2c6f98; }
.meta { color: var(--muted); font-size: 13px; }
.section { margin-top: 30px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.section-head h2 { margin: 0; }
.browser-title-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.browser-title-actions h2 { margin-right: 2px; }
.list { display: grid; gap: 10px; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 15px 17px; background: white; border: 1px solid var(--line); border-radius: 12px; }
.row-main { min-width: 0; }
.row-main strong { display: block; overflow: hidden; text-overflow: ellipsis; }
.row-actions { display: flex; flex-wrap: wrap; gap: 7px; flex: none; }
.empty { padding: 32px; text-align: center; color: var(--muted); border: 1px dashed #bdc9c3; border-radius: 14px; }
.messages { display: grid; gap: 8px; margin-bottom: 18px; }
.flash { padding: 12px 15px; background: var(--soft); border-left: 4px solid var(--brand-2); border-radius: 8px; }
.flash.error { background: #fae9e9; border-color: var(--danger); }
form.fields, .fields { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 13px; font-weight: 750; }
input, select, textarea { width: 100%; border: 1px solid #cfd9d4; border-radius: 10px; padding: 11px 12px; background: white; color: var(--ink); }
input:focus, select:focus, textarea:focus { outline: 3px solid rgba(77,178,236,.18); border-color: var(--brand-2); }
.errorlist { color: var(--danger); font-size: 13px; margin: 0; padding-left: 18px; }
.form-card details > summary, details.form-card > summary { cursor: pointer; font-weight: 800; list-style: none; }
details.form-card[open] > summary { margin-bottom: 18px; }
.tabs { display: flex; gap: 8px; overflow-x: auto; border-bottom: 1px solid var(--line); margin: 26px 0 20px; }
.tabs a { padding: 10px 13px; text-decoration: none; font-weight: 700; color: var(--muted); white-space: nowrap; }
.tabs a:hover { color: var(--brand); border-bottom: 2px solid var(--brand); }
.policy { border-left: 4px solid var(--accent); }
.document-icon { width: 42px; height: 48px; border-radius: 8px; background: var(--soft); color: var(--brand); display: grid; place-items: center; font-weight: 900; flex: none; }
.document-row { justify-content: flex-start; }
.document-row .row-main { flex: 1; }
.chat-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 18px; }
.chat { min-height: 480px; display: flex; flex-direction: column; }
.bubbles { display: flex; flex-direction: column; gap: 12px; flex: 1; max-height: 590px; overflow-y: auto; padding: 5px; }
.bubble { align-self: flex-start; max-width: min(76%, 560px); background: #eef2f0; border-radius: 4px 15px 15px 15px; padding: 11px 13px; }
.bubble.mine { align-self: flex-end; background: #dceee7; border-radius: 15px 4px 15px 15px; }
.bubble-head { font-size: 11px; color: var(--muted); margin-bottom: 5px; }
.bubble p { white-space: pre-wrap; margin: 0; }
.bubble-doc { display: block; margin-top: 9px; padding: 8px 10px; background: rgba(255,255,255,.65); border-radius: 8px; text-decoration: none; font-size: 13px; font-weight: 750; }
.composer { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 15px; display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.composer .document-select { grid-column: 1 / -1; }
.login-page { min-height: 100vh; display: grid; grid-template-columns: minmax(320px, 1.1fr) minmax(360px, .9fr); background: var(--brand); }
.login-story { padding: clamp(40px, 8vw, 100px); color: white; display: flex; flex-direction: column; justify-content: space-between; }
.login-story h1 { font-size: clamp(44px, 7vw, 82px); max-width: 780px; }
.login-story p { color: #e6f4fd; max-width: 620px; }
.login-story .brand { align-self: flex-start; }
.login-eyebrow { color: #d9effb; }
.login-panel { background: #f8faf9; padding: clamp(32px, 7vw, 92px); display: grid; place-items: center; }
.login-box { width: min(100%, 430px); }
.auth-secondary-link { margin: 16px 0 0; text-align: center; }
.auth-secondary-link a { color: var(--brand); font-weight: 800; }
.auth-card { width: min(100%, 540px); padding: clamp(26px, 5vw, 48px); border: 1px solid var(--line); border-radius: 20px; background: white; box-shadow: var(--shadow); }
.auth-card h1 { margin: 8px 0 12px; }
.auth-card .button { width: 100%; }
.dashboard-actions { margin: -12px 0 24px; display: flex; flex-wrap: wrap; gap: 10px; }
.portfolio-toolbar { margin: 0 0 22px; padding: 16px; display: grid; grid-template-columns: minmax(240px, 1fr) minmax(180px, 240px) auto auto; gap: 10px; align-items: end; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.8); }
.portfolio-toolbar label { min-width: 0; display: grid; gap: 6px; color: var(--muted); font-size: 11px; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.portfolio-toolbar input, .portfolio-toolbar select { width: 100%; min-width: 0; }
.portfolio-result-count { grid-column: 1 / -1; margin: 0; color: var(--muted); font-size: 12px; }
.portfolio-pagination { margin-top: 22px; display: flex; justify-content: center; align-items: center; gap: 12px; color: var(--muted); font-weight: 750; }
@media (max-width: 720px) {
  .portfolio-toolbar { grid-template-columns: 1fr 1fr; }
  .portfolio-search-field { grid-column: 1 / -1; }
  .portfolio-sort-field { grid-column: 1 / -1; }
  .portfolio-pagination { flex-wrap: wrap; }
}
.invitation-history { margin-top: 24px; }
.invitation-row { gap: 10px; }
.button.compact { min-height: 34px; padding: 7px 11px; font-size: 12px; }
.button.ghost { border: 1px solid var(--line); background: white; color: var(--muted); }
.demo-note { margin-top: 22px; padding: 14px; background: var(--soft); border-radius: 10px; color: var(--muted); font-size: 13px; }
.permission { display: inline-flex; gap: 5px; color: var(--brand-2); font-size: 12px; }
.hero-actions { display: flex; gap: 9px; flex-wrap: wrap; }
.browser-heading { align-items: end; }
.folder-breadcrumbs { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: -2px 0 16px; color: var(--muted); font-size: 13px; }
.folder-breadcrumbs a { color: var(--brand-2); font-weight: 750; text-decoration: none; }
.folder-breadcrumbs strong { color: var(--ink); }
.document-toolbar { display: grid; grid-template-columns: minmax(260px, 1fr) 220px auto; gap: 10px; margin-bottom: 16px; }
.search-field { position: relative; display: flex; align-items: center; }
.search-field span { position: absolute; left: 14px; color: var(--muted); font-size: 20px; }
.search-field input { padding-left: 42px; }
.view-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: white; }
.view-switch button { min-width: 44px; border: 0; background: white; color: var(--muted); cursor: pointer; font-size: 20px; }
.view-switch button[aria-pressed="true"] { background: var(--brand); color: white; }
.document-explorer { display: grid; gap: 14px; }
.document-explorer.grid-view { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); align-items: start; }
.file-card { background: white; border: 1px solid var(--line); border-radius: 15px; padding: 17px; min-width: 0; position: relative; transition: box-shadow .16s, transform .16s; }
.file-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.folder-card { border-color: #cbded6; background: #fbfdfc; }
.folder-card-link { color: inherit; text-decoration: none; display: flex; flex: 1; min-width: 0; flex-direction: column; }
.folder-visual { width: 70px; height: 53px; border-radius: 8px 10px 10px 10px; background: #dcedf8; color: var(--brand); display: grid; place-items: center; font-size: 32px; margin-bottom: 32px; position: relative; }
.folder-visual::before { content: ""; position: absolute; width: 34px; height: 10px; top: -7px; left: 0; border-radius: 6px 6px 0 0; background: #b9def1; }
.folder-file-count { color: var(--brand); }
.grid-view .file-card { display: flex; flex-direction: column; min-height: 245px; }
.file-visual { width: 54px; height: 64px; border-radius: 9px; display: grid; place-items: center; color: white; font-size: 12px; font-weight: 900; letter-spacing: .06em; margin-bottom: 22px; position: relative; overflow: hidden; }
.file-visual::after { content: ""; position: absolute; top: 0; right: 0; border-style: solid; border-width: 0 15px 15px 0; border-color: transparent rgba(255,255,255,.45) transparent transparent; }
.file-visual.pdf { background: #b55256; }
.file-visual.image { background: var(--brand-2); }
.file-info { min-width: 0; flex: 1; }
.file-title-line { display: flex; gap: 8px; align-items: flex-start; justify-content: space-between; }
.file-title-line strong { overflow-wrap: anywhere; }
.file-title-line .reference { flex: none; font-size: 10px; }
.file-properties { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; }
.file-properties span { background: #f4f6f5; color: #52605a; border-radius: 6px; padding: 5px 7px; font-size: 11px; }
.file-actions { display: flex; gap: 7px; align-items: center; margin-top: 18px; }
.file-menu { position: relative; }
.file-menu summary { list-style: none; cursor: pointer; }
.file-menu summary::-webkit-details-marker { display: none; }
.move-document-form { position: absolute; z-index: 8; right: 0; bottom: calc(100% + 7px); width: min(300px, calc(100vw - 56px)); padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: white; box-shadow: var(--shadow); display: grid; gap: 8px; }
.move-document-form label { color: var(--muted); font-size: 12px; font-weight: 750; }
.icon-button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 9px; display: grid; place-items: center; text-decoration: none; color: var(--brand); font-weight: 900; }
.list-view { grid-template-columns: 1fr; }
.list-view .file-card { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto; gap: 14px; align-items: center; }
.list-view .file-visual { width: 42px; height: 49px; margin: 0; }
.list-view .file-actions { margin: 0; }
.list-view .folder-card { grid-template-columns: minmax(0, 1fr) auto; }
.list-view .folder-card-link { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 14px; align-items: center; }
.list-view .folder-visual { width: 44px; height: 34px; margin: 0; font-size: 20px; }
.list-view .folder-visual::before { width: 22px; height: 7px; top: -5px; }
.list-view .folder-card .file-actions { grid-column: 2; }
.explorer-empty { grid-column: 1 / -1; }
.modal { width: min(720px, calc(100vw - 30px)); max-height: calc(100dvh - 30px); border: 0; border-radius: 18px; padding: 0; box-shadow: 0 26px 90px rgba(10,28,21,.28); }
.modal::backdrop { background: rgba(14,32,25,.55); backdrop-filter: blur(3px); }
.modal-card { padding: 25px; overflow-y: auto; max-height: calc(100dvh - 30px); }
.modal-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.modal-head h2 { margin-top: 5px; font-size: 29px; }
.modal-close { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: white; color: var(--ink); font-size: 25px; line-height: 1; cursor: pointer; }
.document-form { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 20px; }
.document-form .full { grid-column: 1 / -1; }
.field small { color: var(--muted); }
.policy-properties[hidden] { display: none; }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 8px; }
.account-hero { align-items: center; }
.account-summary { display: flex; align-items: center; gap: 13px; padding: 12px 15px; background: white; border: 1px solid var(--line); border-radius: 15px; min-width: min(100%, 310px); }
.account-summary img, .account-avatar-placeholder { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex: none; }
.account-avatar-placeholder { display: grid; place-items: center; background: var(--soft); color: var(--brand); font-size: 20px; font-weight: 900; text-transform: uppercase; }
.account-summary strong, .account-summary span { display: block; }
.account-summary span { margin-top: 4px; color: var(--muted); font-size: 12px; }
.settings-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(320px, .85fr); gap: 22px; align-items: start; }
.settings-card { margin-top: 0; padding: 24px; background: white; border: 1px solid var(--line); border-radius: 17px; }
.account-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.account-form .full, .password-form .full { grid-column: 1 / -1; }
.profile-photo-field input { padding: 8px; }
.checkbox-line { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 13px; }
.checkbox-line input { width: auto; }
.form-actions { display: flex; justify-content: flex-end; padding-top: 5px; }
.password-form small, .password-form small ul { color: var(--muted); font-size: 11px; }
.password-form small ul { margin: 4px 0 0; padding-left: 18px; }
.chat-fab { position: fixed; right: 24px; bottom: 24px; z-index: 40; border: 0; border-radius: 999px; background: var(--brand); color: white; box-shadow: 0 14px 40px rgba(23,111,174,.3); padding: 13px 18px; display: flex; align-items: center; gap: 8px; font-weight: 800; cursor: pointer; }
.chat-fab:hover { background: var(--brand-2); transform: translateY(-1px); }
.chat-unread-badge { position: absolute; top: -8px; right: -7px; min-width: 24px; height: 24px; padding: 0 6px; display: grid; place-items: center; border: 3px solid var(--canvas); border-radius: 999px; background: #df2638; color: white; font-size: 11px; line-height: 1; box-shadow: 0 4px 12px rgba(150,20,35,.28); }
.chat-unread-badge[hidden] { display: none; }
.chat-toast { position: fixed; right: 24px; bottom: 84px; z-index: 48; width: min(330px, calc(100vw - 30px)); padding: 14px 16px; border: 1px solid var(--line); border-left: 4px solid var(--brand-2); border-radius: 12px; background: white; box-shadow: var(--shadow); cursor: pointer; animation: chat-toast-in .18s ease-out; }
.chat-toast[hidden] { display: none; }
.chat-toast strong, .chat-toast span { display: block; }
.chat-toast span { margin-top: 3px; color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@keyframes chat-toast-in { from { opacity: 0; transform: translateY(8px); } }
.chat-backdrop { position: fixed; inset: 0; z-index: 49; border: 0; background: rgba(14,32,25,.3); backdrop-filter: blur(2px); }
.chat-drawer { position: fixed; z-index: 50; top: 0; right: 0; width: min(440px, 100vw); height: 100dvh; background: #f7f9f8; border-left: 1px solid var(--line); box-shadow: -22px 0 60px rgba(15,35,27,.16); transform: translateX(105%); transition: transform .22s ease; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.chat-drawer.has-subject-bar { grid-template-rows: auto auto minmax(0, 1fr) auto; }
.chat-drawer.has-subject-bar.has-group-creator { grid-template-rows: auto auto auto minmax(0, 1fr) auto; }
.chat-drawer.open { transform: translateX(0); }
.chat-head { padding: 20px 21px 15px; background: white; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: flex-start; }
.chat-head h2 { margin: 4px 0 0; }
.chat-head-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; justify-content: flex-end; }
.chat-client-name { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; }
.chat-client-switch { display: grid; gap: 4px; margin-top: 10px; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .05em; }
.chat-client-switch select { padding: 6px 28px 6px 8px; font-size: 12px; text-transform: none; letter-spacing: 0; }
.chat-subject-bar { padding: 11px 14px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; align-items: center; border-bottom: 1px solid var(--line); }
.chat-subject-current span, .chat-subject-current strong { display: block; }
.chat-subject-current span { color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.chat-subject-current strong { margin-top: 2px; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.subject-close { width: 30px; height: 30px; border: 1px solid rgba(23,111,174,.16); border-radius: 50%; background: rgba(255,255,255,.72); color: var(--brand); cursor: pointer; font-size: 19px; }
.subject-close[hidden], .chat-switch-subject[hidden] { display: none; }
.chat-switch-subject { grid-column: 1 / -1; padding: 8px 10px; display: flex; gap: 5px; align-items: baseline; border: 1px solid rgba(23,111,174,.15); border-radius: 9px; background: rgba(255,255,255,.72); color: var(--brand); cursor: pointer; text-align: left; }
.chat-switch-subject span { color: var(--muted); font-size: 11px; }
.chat-switch-subject strong { font-size: 12px; }
.chat-drawer .bubbles { padding: 0; gap: 0; max-height: none; overflow-y: auto; }
.chat-message-assignment-toolbar { position: sticky; top: 0; z-index: 24; padding: 10px 12px; display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); box-shadow: 0 5px 14px rgba(13,74,115,.08); }
.chat-message-assignment-toolbar[hidden] { display: none; }
.chat-message-assignment-toolbar > strong { flex: none; color: var(--brand); font-size: 12px; }
.chat-message-assignment-actions { min-width: 0; display: flex; align-items: end; justify-content: flex-end; gap: 7px; flex-wrap: wrap; }
.chat-message-subject-picker { min-width: 150px; display: grid; gap: 2px; color: var(--muted); font-size: 10px; font-weight: 800; }
.chat-message-subject-picker select { min-width: 0; width: 100%; padding: 7px 8px; }
.chat-message-selector { float: right; margin: -2px -3px 5px 9px; display: grid; place-items: center; cursor: pointer; }
.chat-message-selector input { width: 18px; height: 18px; margin: 0; accent-color: var(--brand); cursor: pointer; }
.chat-message-selector span { display: none; }
.chat-reply-last-client { margin-top: 10px; padding: 9px 10px; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 9px; background: var(--soft); color: var(--ink); font-size: 12px; font-weight: 800; cursor: pointer; }
.chat-reply-last-client[hidden] { display: none; }
.chat-reply-last-client input { width: 17px; height: 17px; margin: 0; accent-color: var(--brand); }
.chat-subject-segment { width: 100%; border: 0; border-radius: 0; overflow: visible; }
.chat-subject-divider { width: 100%; min-height: 43px; padding: 8px 20px; display: grid; gap: 4px; color: var(--muted); border-top: 1px solid rgba(23,111,174,.16); border-bottom: 1px solid rgba(23,111,174,.11); font-size: 10px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.system-notification-segment { padding: 0 14px; background: #fff8f8; border-top: 2px solid #db2f43; border-bottom: 2px solid #db2f43; }
.system-notification-divider { min-height: 34px; display: flex; align-items: center; justify-content: center; color: #b3182f; font-size: 10px; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.system-notification-divider span { padding: 0 10px; background: #fff8f8; }
.system-notification-bubble { width: 100%; max-width: none; margin: 0 0 4px; border: 1px solid rgba(197,31,58,.25); background: #fff; box-shadow: 0 8px 22px rgba(146,20,40,.08); }
.system-notification-bubble .bubble-head { color: #b3182f; }
.system-notification-action { width: 100%; margin-top: 10px; text-align: center; }
.notification-avatar { background: #fce8eb !important; color: #bf2038 !important; }
.notification-conversation-banner { padding: 11px 16px; border-block: 1px solid rgba(197,31,58,.2); background: #fff2f4; color: #b3182f; font-size: 11px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.notification-conversation-readonly { padding: 14px 18px; border-top: 1px solid var(--line); background: #f7f8f9; color: var(--muted); font-size: 12px; text-align: center; }
.chat-subject-path-row { min-width: 0; padding-left: calc(var(--subject-depth, 0) * 15px); display: flex; gap: 7px; align-items: center; }
.chat-subject-path-row::before { content: ""; height: 1px; min-width: 12px; flex: 1; background: currentColor; opacity: .35; }
.chat-subject-path-row span { flex: none; }
.chat-subject-path-row a, .chat-subject-path-row strong { min-width: 0; max-width: 62%; color: var(--brand); overflow: hidden; text-overflow: ellipsis; text-transform: none; white-space: nowrap; letter-spacing: 0; }
.chat-segment-messages { padding: 13px 20px 17px; display: flex; flex-direction: column; gap: 9px; }
.chat-segment-messages:empty { display: none; }
.chat-drawer .bubble { max-width: 87%; box-shadow: 0 1px 0 rgba(0,0,0,.03); }
.subject-tone-0 { background: #f8faf9; }
.subject-tone-1 { background: #edf4fb; }
.subject-tone-2 { background: #edf7f2; }
.subject-tone-3 { background: #fbf5e9; }
.subject-tone-4 { background: #f4f0fa; }
.subject-tone-5 { background: #faeff1; }
.chat-subject-segment.subject-tone-1 .bubble { background: #e1edf8; }
.chat-subject-segment.subject-tone-2 .bubble { background: #dff0e7; }
.chat-subject-segment.subject-tone-3 .bubble { background: #f5ead3; }
.chat-subject-segment.subject-tone-4 .bubble { background: #eae2f5; }
.chat-subject-segment.subject-tone-5 .bubble { background: #f4dfe3; }
.chat-subject-segment .bubble.mine { filter: saturate(1.08) brightness(.98); }
.bubble-doc { display: flex; align-items: center; gap: 9px; }
.bubble-doc span:nth-child(2) { flex: 1; min-width: 0; }
.bubble-doc strong, .bubble-doc small { display: block; }
.bubble-doc small { color: var(--muted); font-weight: 500; margin-top: 2px; }
.drawer-composer { background: white; border-top: 1px solid var(--line); padding: 13px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 8px; align-items: end; position: relative; }
.chat-form-error { grid-column: 1 / -1; padding: 8px 10px; border-radius: 8px; background: #fae9e9; color: var(--danger); font-size: 12px; }
.chat-form-error[hidden] { display: none; }
.drawer-composer textarea { min-height: 47px; max-height: 130px; resize: vertical; }
.attachment-menu { position: relative; }
.attachment-menu summary { list-style: none; width: 44px; height: 44px; border-radius: 50%; background: var(--soft); color: var(--brand); display: grid; place-items: center; cursor: pointer; font-size: 24px; font-weight: 400; }
.attachment-menu summary::-webkit-details-marker { display: none; }
.attachment-popover { position: absolute; z-index: 35; left: 0; bottom: 54px; width: min(360px, calc(100vw - 30px)); padding: 15px; border: 1px solid var(--line); border-radius: 13px; background: white; box-shadow: var(--shadow); }
.hierarchy-panel { min-width: 0; }
.hierarchy-breadcrumb { margin: 4px 0 9px; padding: 8px 10px; border-radius: 8px; background: var(--soft); color: var(--brand); font-size: 12px; font-weight: 750; overflow-wrap: anywhere; }
.hierarchy-levels { display: grid; gap: 8px; }
.hierarchy-level { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 8px; align-items: center; }
.hierarchy-level label { margin: 0; color: var(--muted); font-size: 11px; font-weight: 750; }
.hierarchy-level select { min-width: 0; width: 100%; }
.attachment-kind-field { margin-bottom: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.attachment-kind-field select, .attachment-panel select { width: 100%; min-width: 0; }
.attachment-panel[hidden] { display: none; }
.chat-upload-field { margin-top: 0; }
.chat-upload-field small { display: block; margin-top: 6px; color: var(--muted); font-size: 11px; line-height: 1.35; }
.chat-drop-zone { min-height: 112px; padding: 16px; display: grid; place-items: center; align-content: center; gap: 5px; border: 1px dashed #8dc4df; border-radius: 11px; background: var(--soft); color: var(--brand); text-align: center; cursor: pointer; transition: border-color .16s, background .16s; }
.chat-drop-zone.drag-over { border-color: var(--brand); background: #dff1fb; }
.chat-drop-zone span { color: var(--muted); font-size: 12px; }
.chat-drop-zone input[type="file"] { width: 100%; margin-top: 8px; font-size: 12px; }
.attachment-coming-soon { min-height: 88px; padding: 14px; display: grid; align-content: center; gap: 5px; border-radius: 10px; background: #f3f5f6; color: var(--muted); }
.attachment-coming-soon small { line-height: 1.35; }
.chat-import-status { min-height: 44px; padding: 9px 12px; display: flex; align-items: center; border: 1px dashed rgba(23,111,174,.24); border-radius: 10px; background: var(--soft); color: var(--brand); font-size: 12px; font-weight: 750; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.chat-import-status[hidden] { display: none; }
.send-button { width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--brand); color: white; cursor: pointer; }
.send-button:disabled { cursor: not-allowed; opacity: .45; }
.discussion-workspace { width: min(100%, 1080px); margin: 0 auto; }
.discussion-page-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 22px; }
.discussion-page-head h1 { margin-top: 6px; }
.discussion-page-head .lead { margin-bottom: 0; }
.discussion-client-picker { width: min(290px, 100%); display: grid; gap: 6px; flex: none; }
.discussion-client-picker span, .discussion-filter-field > span, .discussion-filters > label > span { color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.discussion-filters { display: grid; grid-template-columns: minmax(190px, 1.5fr) minmax(135px, .8fr) minmax(135px, .8fr) minmax(190px, 1.2fr) auto; gap: 10px; align-items: end; padding: 15px; border: 1px solid var(--line); border-radius: 14px 14px 0 0; background: white; }
.discussion-filters.contacts-disabled { grid-template-columns: minmax(220px, 1.5fr) minmax(145px, .8fr) minmax(145px, .8fr) auto; }
.discussion-filters label { display: grid; gap: 6px; }
.discussion-filter-field { position: relative; min-width: 0; display: grid; gap: 6px; }
.multi-filter { position: relative; }
.multi-filter > summary { min-height: 41px; padding: 9px 10px; display: flex; justify-content: space-between; gap: 10px; align-items: center; border: 1px solid #cfd9d4; border-radius: 10px; background: white; cursor: pointer; list-style: none; }
.multi-filter > summary::-webkit-details-marker { display: none; }
.multi-filter > summary span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.multi-filter > summary b { color: var(--muted); font-size: 14px; }
.multi-filter[open] > summary { border-color: var(--brand-2); outline: 3px solid rgba(77,178,236,.18); }
.multi-filter-popover { position: absolute; z-index: 20; top: calc(100% + 7px); left: 0; width: max(100%, 250px); max-height: 260px; padding: 8px; overflow-y: auto; border: 1px solid var(--line); border-radius: 11px; background: white; box-shadow: var(--shadow); }
.multi-filter-popover label { padding: 8px 9px; display: flex; grid-template-columns: none; gap: 9px; align-items: center; border-radius: 8px; cursor: pointer; }
.multi-filter-popover label:hover { background: var(--soft); }
.multi-filter-popover input { width: 17px; height: 17px; margin: 0; padding: 0; flex: none; accent-color: var(--brand-2); }
.multi-filter-popover label span { min-width: 0; overflow-wrap: anywhere; font-size: 13px; font-weight: 650; }
.multi-filter-popover .tree-filter-option { padding-left: calc(9px + var(--tree-depth, 0) * 17px); }
.tree-filter-option span { display: grid; gap: 1px; }
.tree-filter-option span small { color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.discussion-filters input, .discussion-filters select { padding: 9px 10px; }
.discussion-result-bar { min-height: 42px; padding: 10px 15px; display: flex; justify-content: space-between; gap: 15px; align-items: center; border: solid var(--line); border-width: 0 1px 1px; background: #f8faf9; color: var(--muted); font-size: 12px; }
.discussion-result-bar strong { color: var(--brand); }
.chat-drawer.chat-page-panel { position: relative; z-index: 1; top: auto; right: auto; width: 100%; height: 720px; min-height: 620px; max-height: calc(100dvh - 150px); border: 1px solid var(--line); border-top: 0; border-radius: 0 0 18px 18px; box-shadow: var(--shadow); transform: none; transition: none; overflow: visible; }
.chat-page-panel .chat-head { border-radius: 0; }
.chat-page-panel .bubbles { min-height: 0; }
.chat-page-panel .bubble { max-width: min(76%, 640px); }
.discussion-chat-head { align-items: center; }
.realtime-indicator { display: inline-flex; gap: 7px; align-items: center; padding: 6px 9px; border-radius: 999px; background: var(--soft); color: var(--brand-2); font-size: 11px; font-weight: 800; }
.realtime-indicator i { width: 7px; height: 7px; border-radius: 50%; background: #2c9a72; box-shadow: 0 0 0 4px rgba(44,154,114,.13); }
.discussion-no-results { position: absolute; z-index: 3; left: 50%; top: 52%; transform: translate(-50%, -50%); width: min(360px, calc(100% - 30px)); padding: 18px; border: 1px dashed #bdc9c3; border-radius: 12px; background: rgba(255,255,255,.94); color: var(--muted); text-align: center; box-shadow: var(--shadow); }
.discussion-no-results[hidden] { display: none; }
.chat-disabled { margin: 14px; padding: 14px; border-radius: 10px; background: #f1e8e8; color: #7b3a3e; }
body.chat-open { overflow: hidden; }
.document-banner { background: white; border: 1px solid var(--line); border-radius: 18px 18px 0 0; padding: 24px; display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; }
.document-identity { min-width: 0; }
.page-back-button { position: fixed; left: 274px; top: 94px; z-index: 40; width: fit-content; min-height: 38px; margin: 0; padding: 8px 13px 8px 10px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid rgba(20, 76, 112, .13); border-radius: 999px; background: rgba(255, 255, 255, .28); color: var(--brand); box-shadow: 0 6px 18px rgba(17, 55, 78, .06); backdrop-filter: none; -webkit-backdrop-filter: none; font-size: 12px; font-weight: 800; line-height: 1.2; text-decoration: none; text-shadow: 0 1px 2px rgba(255, 255, 255, .75); transition: transform .16s ease, background .16s ease, border-color .16s ease, box-shadow .16s ease; }
.page-back-button::before { content: "‹"; font-size: 20px; font-weight: 900; line-height: .8; }
.page-back-button:hover { transform: translateX(-2px); border-color: rgba(20, 76, 112, .24); background: rgba(255, 255, 255, .68); box-shadow: 0 8px 22px rgba(17, 55, 78, .08); }
.page-back-button:focus-visible { outline: 3px solid rgba(46, 167, 235, .28); outline-offset: 2px; }
.page-back-button + .eyebrow { display: block; }
.hero-actions .page-back-button { margin: 0; }
.document-title-wrap { display: flex; gap: 16px; align-items: center; }
.document-title-wrap h1 { font-size: clamp(28px, 4vw, 42px); margin: 4px 0 9px; overflow-wrap: anywhere; }
.file-visual.large { width: 64px; height: 76px; margin: 0; flex: none; }
.file-visual.docx { background: #3566a8; }
.document-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.document-properties { background: #f8faf9; border: solid var(--line); border-width: 0 1px 1px; border-radius: 0 0 18px 18px; padding: 16px 24px; display: grid; grid-template-columns: repeat(auto-fit, minmax(145px, 1fr)); gap: 15px; }
.document-properties > div { min-width: 0; }
.document-properties span { display: block; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.document-properties strong { display: block; margin-top: 4px; font-size: 13px; overflow-wrap: anywhere; }
.technical-value { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-weight: 500; font-size: 11px !important; }
.viewer-shell { margin-top: 20px; border: 1px solid var(--line); border-radius: 17px; background: #dfe4e1; overflow: hidden; }
.viewer-toolbar { min-height: 66px; padding: 12px 16px; background: white; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.viewer-toolbar strong { display: block; margin-top: 3px; font-size: 13px; }
.pdf-controls { display: flex; gap: 5px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.pdf-controls button, .viewer-toolbar > .icon-button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 8px; background: white; color: var(--brand); cursor: pointer; display: grid; place-items: center; }
.pdf-controls span { min-width: 48px; text-align: center; font-size: 12px; }
.secure-viewer { min-height: 620px; max-height: calc(100dvh - 150px); overflow: auto; display: grid; place-items: start center; padding: 28px; position: relative; }
.secure-viewer:fullscreen { max-height: none; height: 100vh; background: #dfe4e1; }
.secure-viewer canvas { display: block; background: white; box-shadow: 0 12px 36px rgba(20,35,29,.18); max-width: none; }
.viewer-loading { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); background: #edf0ee; z-index: 2; }
.viewer-loading[hidden] { display: none; }
.viewer-loading.error { color: var(--danger); padding: 30px; text-align: center; }
.image-viewer img { display: block; max-width: none; height: auto; margin: auto; box-shadow: 0 12px 36px rgba(20,35,29,.18); transform-origin: center center; transition: width .14s ease, transform .14s ease; }
.docx-container { width: 100%; min-width: 0; }
.docx-container .docx-wrapper { background: transparent !important; padding: 0 !important; }
.docx-container .docx-wrapper > section.docx { margin: 0 auto 20px !important; box-shadow: 0 12px 36px rgba(20,35,29,.18); }
.document-footer-meta { display: flex; justify-content: space-between; gap: 18px; color: var(--muted); font-size: 11px; padding: 12px 3px; }
.document-footer-meta code { overflow-wrap: anywhere; }
.document-footer-meta a { color: var(--brand-2); font-weight: 700; }
.compact-modal { width: min(520px, calc(100vw - 30px)); }
.danger-text { color: var(--danger); }
.primary-contact-banner { min-width: 260px; max-width: 330px; padding: 15px 17px; border: 1px solid #b9dced; border-radius: 15px; background: linear-gradient(135deg, #fff, #eaf5fc); }
.primary-contact-banner strong, .primary-contact-banner small { display: block; }
.primary-contact-banner strong { margin-top: 5px; font-size: 16px; }
.primary-contact-banner small { margin-top: 4px; color: var(--muted); line-height: 1.35; }
.item-contacts { position: absolute; top: 15px; right: 15px; max-width: calc(100% - 105px); text-align: right; z-index: 2; }
.item-contacts span, .item-contacts strong, .item-contacts small { display: block; }
.item-contacts span { color: var(--muted); font-size: 9px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.item-contacts strong { margin-top: 3px; color: var(--brand); font-size: 12px; overflow-wrap: anywhere; }
.item-contacts small { margin-top: 2px; color: var(--muted); font-size: 10px; overflow-wrap: anywhere; }
.scope-manager { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.scope-manager > summary { cursor: pointer; color: var(--brand); font-size: 12px; font-weight: 800; }
.scope-manager[open] > summary { margin-bottom: 10px; }
.scope-access-row { display: flex; justify-content: space-between; gap: 8px; margin: 6px 0; padding: 7px 8px; border-radius: 7px; background: var(--soft); font-size: 11px; }
.scope-access-row form { flex: none; }
.scope-access-row button { border: 0; background: none; color: var(--danger); cursor: pointer; font-weight: 750; }
.scope-form { display: grid; gap: 8px; margin-top: 10px; }
.scope-form label { color: var(--muted); font-size: 11px; font-weight: 750; }
.scope-form select { margin-top: 4px; padding: 8px; }
.scope-form .check { display: flex; align-items: center; gap: 7px; }
.scope-form .check input { width: auto; }
.client-assignment-row { align-items: flex-start; }
.inline-assignment-form { min-width: min(100%, 280px); display: grid; grid-template-columns: 1fr auto; gap: 7px; }
.inline-assignment-form label { grid-column: 1 / -1; color: var(--muted); font-size: 11px; font-weight: 800; }
.inline-assignment-form select { padding: 8px; }
.text-link { display: inline-block; margin-top: 7px; color: var(--brand); font-size: 12px; font-weight: 750; text-decoration: none; }
.document-contact-bar { padding: 14px 24px; display: flex; justify-content: space-between; gap: 20px; border: solid var(--line); border-width: 0 1px 1px; background: #eef7fc; }
.document-contact-bar strong, .document-contact-bar span { display: block; }
.document-contact-bar strong { margin-top: 3px; font-size: 13px; }
.primary-contact-card { display: flex; align-items: center; gap: 18px; padding: 23px; border: 1px solid #b9dced; border-radius: 18px; background: linear-gradient(135deg, #fff 45%, #e6f4fc); }
.primary-contact-card h2 { margin: 4px 0 6px; }
.primary-contact-card p { margin: 0; color: var(--muted); }
.contact-avatar { width: 66px; height: 66px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--brand); color: white; font-size: 20px; font-weight: 900; text-transform: uppercase; }
.contact-avatar.small { width: 46px; height: 46px; font-size: 14px; }
.contacts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 15px; }
.contact-card { padding: 19px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.contact-card header { display: flex; align-items: center; gap: 12px; }
.contact-card h3 { margin: 0 0 5px; }
.contact-scopes { display: grid; gap: 7px; margin-top: 16px; }
.scope-line { padding: 10px 11px; border-radius: 9px; background: var(--soft); }
.scope-line strong, .scope-line span { display: block; }
.scope-line strong { font-size: 12px; }
.scope-line span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.chat-conversation-switch { display: grid; gap: 4px; margin-top: 9px; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.chat-conversation-switch select { padding: 7px 9px; font-size: 12px; text-transform: none; letter-spacing: 0; }
.chat-group-creator { padding: 10px 16px; border-bottom: 1px solid var(--line); background: #f8fbfd; }
.chat-group-creator > summary, .scope-group-builder > summary { cursor: pointer; color: var(--brand); font-size: 12px; font-weight: 850; }
.chat-group-creator form { display: grid; gap: 9px; margin-top: 10px; }
.chat-group-creator fieldset, .new-group-card fieldset, .scope-group-builder fieldset { margin: 0; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; }
.chat-group-creator fieldset ul, .new-group-card fieldset ul { margin: 4px 0 0; padding: 0; display: grid; gap: 5px; list-style: none; }
.chat-group-creator fieldset label, .new-group-card fieldset label { display: flex; align-items: center; gap: 7px; font-size: 12px; }
.chat-group-creator input[type="checkbox"], .new-group-card input[type="checkbox"] { width: auto; }
.new-group-card { position: relative; }
.new-group-card > summary { list-style: none; }
.new-group-card > form { position: absolute; z-index: 12; top: calc(100% + 8px); right: 0; width: min(340px, calc(100vw - 36px)); padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: white; box-shadow: var(--shadow); }
.whatsapp-layout { display: grid; grid-template-columns: 310px minmax(0, 1fr); grid-template-areas: "filters filters" "conversations discussion"; gap: 0; border: 1px solid var(--line); border-radius: 18px; background: white; overflow: hidden; box-shadow: var(--shadow); }
.conversation-list { grid-area: conversations; min-height: 680px; max-height: 76dvh; overflow-y: auto; border-right: 1px solid var(--line); background: #f8fbfd; }
.conversation-list > header { min-height: 66px; padding: 18px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); background: white; }
.conversation-list > header span { min-width: 27px; height: 27px; display: grid; place-items: center; border-radius: 999px; background: var(--soft); color: var(--brand); font-size: 11px; font-weight: 850; }
.conversation-list-item { min-height: 78px; padding: 13px 14px; display: grid; grid-template-columns: 45px minmax(0, 1fr) auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.conversation-list-item:hover, .conversation-list-item.active { background: #eaf5fc; }
.conversation-avatar { width: 45px; height: 45px; display: grid; place-items: center; border-radius: 50%; background: var(--brand); color: white; font-size: 13px; font-weight: 900; text-transform: uppercase; }
.conversation-list-copy { min-width: 0; }
.conversation-list-copy strong, .conversation-list-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conversation-list-copy strong { font-size: 13px; }
.conversation-list-copy small { margin-top: 5px; color: var(--muted); font-size: 10px; }
.conversation-unread { min-width: 22px; height: 22px; padding: 0 5px; display: grid; place-items: center; border-radius: 999px; background: #df2638; color: white; font-size: 10px; }
.discussion-main-column { grid-area: discussion; min-width: 0; background: var(--canvas); container-type: inline-size; }
.mobile-chat-toolbar { display: none; }
.whatsapp-layout .discussion-filters { grid-area: filters; margin: 0; border-width: 0 0 1px; border-radius: 0; grid-template-columns: minmax(180px, 1fr) minmax(125px, .65fr) minmax(125px, .65fr) auto; }
.whatsapp-layout .discussion-filters > label,
.whatsapp-layout .discussion-filters .discussion-filter-field,
.whatsapp-layout .discussion-filters input,
.whatsapp-layout .discussion-filters select { min-width: 0; }
@container (max-width: 620px) {
  .whatsapp-layout .discussion-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .whatsapp-layout .discussion-filters .discussion-filter-field,
  .whatsapp-layout .discussion-filters .button { grid-column: 1 / -1; width: 100%; }
}
@container (max-width: 420px) {
  .whatsapp-layout .discussion-filters { grid-template-columns: minmax(0, 1fr); }
  .whatsapp-layout .discussion-filters > label,
  .whatsapp-layout .discussion-filters .discussion-filter-field,
  .whatsapp-layout .discussion-filters .button { grid-column: 1; width: 100%; }
}
.whatsapp-layout .discussion-result-bar { min-height: 66px; margin: 0; border-radius: 0; }
.whatsapp-layout .chat-page-panel { border: 0; border-radius: 0; box-shadow: none; }
.default-conversation-form { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line); }
.scope-group-builder { margin-top: 10px; }
.scope-group-builder[open] > summary { margin-bottom: 9px; }
.document-workflows { margin: 16px 0; padding: 17px 19px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border: 1px solid #cfe4ef; border-radius: 15px; background: linear-gradient(135deg, #fff, #eef8fd); }
.document-workflows strong { display: block; margin-top: 3px; }
.document-workflow-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 9px; }
.document-related-objects { margin: 16px 0; padding: 17px 19px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.related-object-links { margin-top: 10px; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 9px; }
.related-object-links a { padding: 12px 14px; display: grid; gap: 4px; border: 1px solid var(--line); border-radius: 11px; background: var(--canvas); text-decoration: none; }
.related-object-links small { color: var(--muted); }
.claim-list { display: grid; gap: 10px; }
.claim-card { min-width: 0; padding: 16px 18px; display: grid; grid-template-columns: 48px minmax(0, 1fr) auto 24px; align-items: center; gap: 14px; border: 1px solid var(--line); border-radius: 15px; background: white; color: inherit; text-decoration: none; transition: transform .16s, box-shadow .16s; }
.claim-card:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.claim-card-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 13px; background: #fff0e8; color: #d45b28; font-size: 22px; }
.claim-card-main { min-width: 0; display: grid; gap: 4px; }
.claim-card-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; }
.claim-card-main small { color: var(--muted); overflow-wrap: anywhere; }
.claim-status { width: fit-content; padding: 6px 9px; border-radius: 999px; background: var(--soft); color: var(--brand); font-size: 11px; font-weight: 850; white-space: nowrap; }
.claim-status.status-information_required { background: #fff2d8; color: #9a6510; }
.claim-status.status-completed { background: #e7f7ef; color: #20784e; }
.claim-status.status-draft { background: #eef1f3; color: var(--muted); }
.claim-empty { min-height: 220px; display: grid; place-content: center; gap: 6px; text-align: center; }
.claim-banner { margin-bottom: 16px; padding: 24px; display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; border: 1px solid var(--line); border-radius: 17px; background: white; }
.claim-banner h1 { margin: 7px 0 9px; }
.claim-banner-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 9px; }
.claim-metadata { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: solid var(--line); border-width: 1px 1px 0; border-radius: 15px 15px 0 0; overflow: hidden; }
.claim-metadata > div { min-width: 0; padding: 15px 17px; display: grid; gap: 5px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: white; }
.claim-metadata > div > span, .claim-linked-document > span { color: var(--muted); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.claim-linked-document { grid-column: span 2; }
.claim-linked-document a { display: grid; gap: 3px; color: var(--brand); text-decoration: none; }
.claim-linked-document small { color: var(--muted); }
.claim-status-editor { margin: 16px 0; display: flex; align-items: end; justify-content: space-between; gap: 18px; }
.claim-status-editor h2 { margin: 5px 0 0; }
.inline-status-form { display: flex; align-items: center; gap: 8px; }
.inline-status-form select { min-height: 42px; padding: 9px 12px; border: 1px solid #cfd9d4; border-radius: 10px; background: white; }
.claim-content-shell { overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: white; }
.claim-content-shell > header { padding: 17px 19px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.claim-content-shell h2 { margin: 4px 0 0; }
.claim-content-count { color: var(--muted); font-size: 12px; }
.claim-content-placeholder { min-height: 260px; display: grid; place-content: center; gap: 6px; text-align: center; }
.claim-content-placeholder span { max-width: 560px; color: var(--muted); }
.business-object-link { border-color: #f1cfbd; background: #fff8f3; }
.business-object-card { border-color: #d8cbe8; }
.business-object-visual { background: #f1ebf8; color: #654290; }
.proposal-choice-shell { margin: 16px 0; padding: 20px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border: 1px solid #cfdce8; border-radius: 16px; background: #f5f9fd; }
.proposal-choice-shell.has-selection { border-color: #74b8e8; background: linear-gradient(135deg, #eef8ff, #f7fbff); box-shadow: 0 10px 30px rgba(23,111,174,.09); }
.proposal-choice-shell h2 { margin: 5px 0; }
.proposal-choice-shell p { margin: 0 0 5px; color: var(--muted); }
.proposal-choice-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.proposal-option-grid { padding: 16px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.proposal-option-card { min-width: 0; padding: 16px; position: relative; display: grid; grid-template-columns: 42px minmax(0, 1fr); gap: 12px; border: 1px solid var(--line); border-radius: 14px; background: #fbfcfd; }
.proposal-option-card.selected { border: 2px solid var(--brand-2); background: #f0f8fe; }
.proposal-option-number { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; background: var(--brand); color: white; font-size: 17px; font-weight: 850; }
.proposal-option-copy { min-width: 0; }
.proposal-option-copy h3 { margin: 3px 0 5px; overflow-wrap: anywhere; }
.proposal-option-copy p, .proposal-option-copy small { color: var(--muted); }
.proposal-selected-badge { grid-column: 1 / -1; width: fit-content; padding: 6px 9px; border-radius: 999px; background: #dff3ff; color: var(--brand); font-size: 11px; font-weight: 850; }
.proposal-option-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
.proposal-option-actions form { margin: 0; }
.proposal-add-card { margin-top: 16px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.proposal-add-card h2 { margin: 4px 0; }
.proposal-add-form { display: flex; align-items: center; gap: 9px; }
.proposal-add-form input[type="file"] { max-width: 310px; }
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: static; padding: 18px; gap: 18px; }
  .nav { grid-template-columns: repeat(3, auto); overflow-x: auto; }
  .sidebar-footer { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 0; }
  .topbar, .content { padding: 22px; }
  .page-back-button { left: 22px; top: 188px; }
  .grid.two, .chat-layout, .login-page { grid-template-columns: 1fr; }
  .login-story { min-height: 42vh; padding: 38px; }
  .hero { align-items: flex-start; flex-direction: column; }
  .document-toolbar { grid-template-columns: 1fr 190px auto; }
  .document-banner { align-items: flex-start; flex-direction: column; }
  .document-actions { justify-content: flex-start; }
  .secure-viewer { min-height: 520px; }
  .settings-grid { grid-template-columns: 1fr; }
  .home-service-grid { grid-template-columns: 1fr 1fr; }
  .document-workflows, .claim-banner, .claim-status-editor { align-items: stretch; flex-direction: column; }
  .document-workflow-actions, .claim-banner-actions { justify-content: flex-start; }
  .claim-metadata { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .proposal-choice-shell, .proposal-add-card { align-items: stretch; flex-direction: column; }
  .proposal-choice-actions { justify-content: flex-start; }
  .discussion-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .discussion-filters.contacts-disabled { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .discussion-filters .button { width: 100%; }
  .whatsapp-layout { grid-template-columns: 1fr; grid-template-areas: "filters" "conversations" "discussion"; }
  .conversation-list { min-height: 0; max-height: 260px; border-right: 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 768px) {
  .sidebar { position: sticky; top: 0; z-index: 45; min-height: 68px; padding: 10px 14px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px 12px; }
  .sidebar .brand { width: fit-content; min-width: 0; display: flex; align-items: center; gap: 9px; }
  .sidebar .brand img { width: 126px; max-height: 48px; object-fit: contain; }
  .sidebar .brand small { display: none; }
  .mobile-nav-toggle { position: relative; width: 46px; height: 42px; padding: 9px 10px; display: grid; align-content: center; gap: 5px; border: 1px solid rgba(255,255,255,.24); border-radius: 10px; background: rgba(255,255,255,.12); cursor: pointer; }
  .mobile-nav-unread-badge { position: absolute; top: -8px; right: -8px; min-width: 23px; height: 23px; padding: 0 6px; display: inline-grid; place-items: center; border: 2px solid white; border-radius: 999px; background: #e1263d; color: white; font-size: 10px; font-weight: 900; line-height: 1; box-shadow: 0 4px 12px rgba(90,0,18,.3); }
  .mobile-nav-unread-badge[hidden] { display: none; }
  .mobile-nav-toggle span { width: 100%; height: 2px; display: block; border-radius: 999px; background: white; transition: transform .18s, opacity .18s; }
  .mobile-nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .mobile-nav-toggle.open span:nth-child(2) { opacity: 0; }
  .mobile-nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .sidebar .nav { grid-column: 1 / -1; display: none; grid-template-columns: 1fr; gap: 5px; overflow: visible; padding: 6px 0 4px; border-top: 1px solid rgba(255,255,255,.16); }
  .sidebar .nav.mobile-open { display: grid; }
  .sidebar .nav a { padding: 11px 12px; }
  .sidebar .sidebar-footer { display: none; grid-column: 1 / -1; margin: 0; padding: 12px; border-top: 1px solid rgba(255,255,255,.16); }
  .sidebar .nav.mobile-open + .sidebar-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .sidebar .sidebar-footer form { margin-top: 0 !important; }
  .sidebar .sidebar-footer .link-button { padding: 9px 11px; border-radius: 9px; background: rgba(255,255,255,.14); text-decoration: none; font-weight: 800; }
  .content { padding: 18px; }
  .page-back-button { left: 12px; top: 80px; max-width: calc(100vw - 76px); min-height: 34px; padding: 6px 10px 6px 8px; gap: 3px; overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
  .page-back-button::before { font-size: 17px; }
  .topbar { padding: 15px 18px; }
  .row { align-items: flex-start; flex-wrap: wrap; }
  .bubble { max-width: 90%; }
  .discussion-page-head { align-items: stretch; flex-direction: column; margin-bottom: 12px; }
  .discussion-page-head.mobile-chat-active { display: none; }
  .discussion-page-head .lead { display: none; }
  .discussion-client-picker { width: 100%; }
  .discussion-filters { grid-template-columns: 1fr 1fr; padding: 12px; }
  .discussion-filters .discussion-filter-field, .discussion-filters .button { grid-column: 1 / -1; }
  .multi-filter-popover { width: 100%; }
  .discussion-result-bar { align-items: flex-start; flex-direction: column; gap: 3px; }
  .chat-drawer.chat-page-panel { height: calc(100dvh - 175px); min-height: 520px; max-height: none; }
  .chat-page-panel .bubble { max-width: 90%; }
  .composer { grid-template-columns: 1fr; }
  .document-hero .hero-actions, .document-hero .hero-actions .button { width: 100%; }
  .document-toolbar { grid-template-columns: 1fr auto; }
  .document-toolbar .search-field { grid-column: 1 / -1; }
  .document-toolbar select { min-width: 0; }
  .document-explorer.grid-view { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .grid-view .file-card { min-height: 230px; padding: 13px; }
  .grid-view .file-title-line { display: block; }
  .grid-view .file-title-line .reference { margin-top: 6px; }
  .grid-view .file-properties { display: none; }
  .list-view .file-card { grid-template-columns: 48px minmax(0, 1fr); }
  .list-view .file-actions { grid-column: 1 / -1; }
  .list-view .folder-card { grid-template-columns: 1fr; }
  .list-view .folder-card-link { grid-template-columns: 48px minmax(0, 1fr); gap: 14px; }
  .list-view .folder-card .file-actions { grid-column: 1; }
  .move-document-form { position: fixed; left: 16px; right: 16px; bottom: 16px; width: auto; }
  .document-form { grid-template-columns: 1fr; }
  .document-form .full { grid-column: auto; }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions .button { width: 100%; }
  .chat-fab { right: 15px; bottom: 15px; }
  .chat-fab > span:nth-child(2) { display: none; }
  .chat-fab { width: 52px; height: 52px; padding: 0; justify-content: center; }
  .chat-toast { right: 15px; bottom: 78px; }
  .chat-drawer { width: 100vw; }
  .chat-message-assignment-toolbar { position: static; align-items: stretch; flex-direction: column; }
  .chat-message-assignment-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .chat-message-subject-picker { grid-column: 1 / -1; }
  .chat-message-assignment-actions .button { width: 100%; }
  .document-banner { padding: 18px; }
  .document-title-wrap { align-items: flex-start; }
  .file-visual.large { width: 48px; height: 58px; }
  .document-actions, .document-actions .button { width: 100%; }
  .document-properties { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 15px 18px; }
  .viewer-toolbar { align-items: flex-start; flex-direction: column; }
  .pdf-controls { justify-content: flex-start; }
  .secure-viewer { min-height: 430px; padding: 12px; max-height: calc(100dvh - 210px); }
  .document-footer-meta { flex-direction: column; }
  .account-summary { width: 100%; }
  .account-form { grid-template-columns: 1fr; }
  .account-form .full { grid-column: auto; }
  .form-actions .button { width: 100%; }
  .client-home-identity { width: 100%; }
  .primary-contact-banner { width: 100%; max-width: none; }
  .item-contacts { max-width: calc(100% - 82px); top: 12px; right: 12px; }
  .item-contacts small { font-size: 8px; line-height: 1.2; }
  .document-contact-bar { padding: 13px 18px; flex-direction: column; gap: 8px; }
  .inline-assignment-form { width: 100%; }
  .home-service-grid { grid-template-columns: 1fr; }
  .document-workflow-actions, .document-workflow-actions .button, .claim-banner-actions, .claim-banner-actions .button { width: 100%; }
  .claim-card { grid-template-columns: 42px minmax(0, 1fr); gap: 11px; }
  .claim-card-icon { width: 42px; height: 42px; }
  .claim-card .claim-status { grid-column: 2; }
  .claim-card-arrow { display: none; }
  .claim-metadata { grid-template-columns: 1fr; }
  .claim-linked-document { grid-column: auto; }
  .inline-status-form { align-items: stretch; flex-direction: column; }
  .inline-status-form .button { width: 100%; }
  .proposal-option-grid { grid-template-columns: 1fr; padding: 12px; }
  .proposal-choice-actions, .proposal-choice-actions .button, .proposal-choice-actions form { width: 100%; }
  .proposal-add-form { align-items: stretch; flex-direction: column; }
  .proposal-add-form input[type="file"], .proposal-add-form .button { width: 100%; max-width: none; }
  .service-tile { min-height: 245px; }
  .whatsapp-layout { display: block; border-radius: 13px; }
  .conversation-list { display: block; min-height: 62dvh; max-height: none; overflow: visible; border: 0; }
  .conversation-list > header { min-width: 0; }
  .conversation-list-item { min-width: 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .discussion-main-column { display: none; }
  .whatsapp-layout.mobile-chat-open .conversation-list { display: none; }
  .whatsapp-layout.mobile-chat-open .discussion-main-column { display: block; }
  .mobile-chat-toolbar { min-height: 48px; padding: 8px 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); background: white; }
  .mobile-chat-toolbar a, .mobile-chat-toolbar button { border: 0; background: none; color: var(--brand); font-size: 13px; font-weight: 850; text-decoration: none; cursor: pointer; }
  .whatsapp-layout .discussion-filters { display: none; grid-template-columns: 1fr; gap: 11px; padding: 14px; border-radius: 0; }
  .whatsapp-layout .discussion-filters > label, .whatsapp-layout .discussion-filters .discussion-filter-field, .whatsapp-layout .discussion-filters .button { grid-column: 1; width: 100%; min-width: 0; }
  .whatsapp-layout .discussion-filters input:not([type="checkbox"]), .whatsapp-layout .discussion-filters select { width: 100%; min-width: 0; }
  .whatsapp-layout .multi-filter-popover input[type="checkbox"] { width: 17px; min-width: 17px; height: 17px; flex: 0 0 17px; }
  .whatsapp-layout .discussion-filters.mobile-open { display: grid; }
  .whatsapp-layout .discussion-result-bar { min-height: 36px; padding: 7px 12px; }
  .discussion-chat-head { padding: 14px 16px 12px; }
  .discussion-chat-head h2 { font-size: 22px; }
}
