:root {
  --blue: #032e61;
  --blue-2: #0a427f;
  --green: #73b629;
  --green-dark: #4d8614;
  --ink: #172234;
  --muted: #667085;
  --line: #dfe5ec;
  --panel: #ffffff;
  --canvas: #f4f7fa;
  --soft-blue: #eaf2fb;
  --soft-green: #eff8e7;
  --soft-amber: #fff6df;
  --soft-purple: #f3edff;
  --danger: #b42318;
  --shadow: 0 16px 38px rgba(3, 46, 97, 0.08);
  --radius: 22px;
  font-family: Lato, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--canvas);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 100% 0%, rgba(115, 182, 41, 0.10), transparent 28rem),
    var(--canvas);
}

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

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

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

.topbar {
  min-height: 92px;
  padding: max(18px, env(safe-area-inset-top)) clamp(20px, 4vw, 54px) 18px;
  color: white;
  background: linear-gradient(110deg, var(--blue), #052653 72%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  box-shadow: 0 10px 30px rgba(3, 46, 97, 0.18);
}

.brand-block,
.topbar-meta,
.header-actions,
.panel-heading,
.drawer-header,
.dialog-heading {
  display: flex;
  align-items: center;
}

.brand-block {
  gap: 14px;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--blue);
  background: white;
  font-weight: 900;
  letter-spacing: -0.04em;
  box-shadow: inset 0 -3px 0 rgba(115, 182, 41, 0.8);
}

.topbar .eyebrow {
  color: rgba(255, 255, 255, 0.72);
}

.topbar h1,
.welcome-row h2,
.panel-heading h2,
.drawer-header h2,
.dialog-heading h2,
.side-card h2 {
  margin: 0;
}

.topbar h1 {
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.2;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--blue-2);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.topbar-meta {
  gap: 20px;
}

.connection-pill {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 9px 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.84rem;
  font-weight: 800;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #9ee45f;
  box-shadow: 0 0 0 5px rgba(158, 228, 95, 0.14);
}

.connection-pill.offline .status-dot {
  background: #fdb022;
  box-shadow: 0 0 0 5px rgba(253, 176, 34, 0.15);
}

.clock-block {
  min-width: 122px;
  text-align: right;
}

.clock-block strong,
.clock-block span {
  display: block;
}

.clock-block strong {
  font-size: 1.35rem;
}

.clock-block span {
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.78rem;
}

main {
  width: min(1560px, 100%);
  margin: 0 auto;
  padding: clamp(24px, 4vw, 48px);
}

.welcome-row {
  margin-bottom: 26px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
}

.welcome-row h2 {
  color: var(--blue);
  font-size: clamp(1.7rem, 4vw, 2.65rem);
  letter-spacing: -0.035em;
}

.subtle {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.header-actions {
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.button,
.text-button,
.icon-button,
.filter-chip,
.notification-card,
.install-tab {
  cursor: pointer;
}

.button {
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: 13px;
  padding: 11px 17px;
  font-weight: 850;
  transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

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

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

.button.primary {
  color: white;
  background: var(--blue);
  box-shadow: 0 10px 22px rgba(3, 46, 97, 0.14);
}

.button.primary:hover {
  background: #042752;
}

.button.secondary {
  color: var(--blue);
  border-color: #cad5e2;
  background: white;
}

.button.full {
  width: 100%;
}

.summary-grid {
  margin-bottom: 26px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.summary-card {
  min-height: 110px;
  border: 1px solid rgba(3, 46, 97, 0.07);
  border-radius: var(--radius);
  padding: 20px;
  background: var(--panel);
  display: flex;
  align-items: center;
  gap: 15px;
  box-shadow: var(--shadow);
}

.summary-icon {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  font-weight: 950;
}

.summary-icon.instructions {
  color: var(--green-dark);
  background: var(--soft-green);
}

.summary-icon.offers {
  color: var(--blue);
  background: var(--soft-blue);
}

.summary-icon.prices {
  color: #9a6700;
  background: var(--soft-amber);
}

.summary-icon.unread {
  color: #6941c6;
  background: var(--soft-purple);
}

.summary-card span,
.summary-card strong {
  display: block;
}

.summary-card span {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.summary-card strong {
  color: var(--blue);
  font-size: 1.85rem;
  line-height: 1;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.1fr) minmax(280px, 0.8fr);
  gap: 22px;
  align-items: start;
}

.feed-panel,
.side-card {
  border: 1px solid rgba(3, 46, 97, 0.07);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.feed-panel {
  min-height: 620px;
  padding: clamp(18px, 3vw, 28px);
}

.panel-heading {
  justify-content: space-between;
  gap: 16px;
}

.panel-heading h2,
.side-card h2 {
  color: var(--blue);
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.panel-heading.compact {
  margin-bottom: 16px;
}

.text-button {
  border: 0;
  padding: 8px 0;
  color: var(--blue-2);
  background: transparent;
  font-size: 0.84rem;
  font-weight: 850;
}

.text-button:hover {
  text-decoration: underline;
}

.filter-bar {
  margin: 22px 0 18px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
}

.filter-chip {
  flex: 0 0 auto;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 13px;
  color: #475467;
  background: white;
  font-size: 0.78rem;
  font-weight: 800;
}

.filter-chip.active {
  color: white;
  border-color: var(--blue);
  background: var(--blue);
}

.notification-list {
  display: grid;
  gap: 11px;
}

.notification-card {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 17px;
  padding: 15px;
  color: inherit;
  background: white;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  text-align: left;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.notification-card:hover {
  border-color: #afbed0;
  box-shadow: 0 10px 24px rgba(3, 46, 97, 0.07);
  transform: translateY(-1px);
}

.notification-card.unread {
  border-left: 5px solid var(--green);
  background: linear-gradient(90deg, rgba(115, 182, 41, 0.055), white 24%);
}

.event-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--blue);
  background: var(--soft-blue);
  font-size: 0.92rem;
  font-weight: 950;
}

.event-icon.instruction {
  color: var(--green-dark);
  background: var(--soft-green);
}

.event-icon.price_change {
  color: #9a6700;
  background: var(--soft-amber);
}

.event-icon.completion {
  color: #6941c6;
  background: var(--soft-purple);
}

.notification-main {
  min-width: 0;
}

.notification-topline {
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.notification-title {
  color: var(--blue);
  font-weight: 900;
}

.notification-badge {
  border-radius: 999px;
  padding: 4px 7px;
  color: var(--blue-2);
  background: var(--soft-blue);
  font-size: 0.63rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.notification-address {
  margin: 0;
  overflow: hidden;
  color: #344054;
  font-size: 0.95rem;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notification-detail {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.45;
}

.notification-time {
  padding-top: 3px;
  color: #98a2b3;
  font-size: 0.75rem;
  font-weight: 800;
  white-space: nowrap;
}

.empty-state {
  padding: 70px 20px;
  text-align: center;
}

.empty-icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 13px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--green-dark);
  background: var(--soft-green);
  font-size: 1.35rem;
  font-weight: 900;
}

.empty-state h3,
.empty-state p {
  margin: 0;
}

.empty-state h3 {
  color: var(--blue);
}

.empty-state p {
  margin-top: 7px;
  color: var(--muted);
}

.side-panel {
  display: grid;
  gap: 16px;
}

.side-card {
  padding: 22px;
}

.pulse-list {
  margin: 0;
}

.pulse-list > div {
  padding: 11px 0;
  border-top: 1px solid #edf0f4;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.pulse-list > div:first-child {
  border-top: 0;
}

.pulse-list dt {
  color: var(--muted);
  font-size: 0.86rem;
}

.pulse-list dd {
  margin: 0;
  color: var(--blue);
  font-weight: 900;
}

.personal-card {
  color: white;
  background: linear-gradient(145deg, var(--blue), #0b4179);
}

.personal-card .eyebrow,
.personal-card .news-label {
  color: rgba(255, 255, 255, 0.68);
}

.personal-card h2 {
  color: white;
}

.personal-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.personal-label,
.personal-row strong {
  display: block;
}

.personal-label {
  margin-bottom: 3px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.78rem;
}

.personal-row strong {
  font-size: 1.8rem;
}

.weather-symbol {
  font-size: 2.2rem;
}

.personal-divider {
  height: 1px;
  margin: 18px 0;
  background: rgba(255, 255, 255, 0.16);
}

.news-label {
  margin: 0 0 7px;
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.news-copy,
.setup-card p {
  margin: 0;
  line-height: 1.5;
}

.news-copy {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.88rem;
}

.setup-card p:not(.eyebrow) {
  margin: 9px 0 16px;
  color: var(--muted);
  font-size: 0.88rem;
}

.scrim {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(17, 34, 52, 0.4);
  backdrop-filter: blur(2px);
}

.detail-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  width: min(470px, 100%);
  padding: max(22px, env(safe-area-inset-top)) 24px max(22px, env(safe-area-inset-bottom));
  background: white;
  display: flex;
  flex-direction: column;
  box-shadow: -20px 0 50px rgba(3, 46, 97, 0.18);
  transform: translateX(102%);
  transition: transform 220ms ease;
}

.detail-drawer.open {
  transform: translateX(0);
}

.drawer-header,
.dialog-heading {
  justify-content: space-between;
  gap: 16px;
}

.drawer-content {
  flex: 1;
  overflow-y: auto;
  padding: 24px 0;
}

.drawer-actions {
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.icon-button {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border: 1px solid var(--line);
  border-radius: 13px;
  color: var(--blue);
  background: white;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  line-height: 1;
}

.detail-hero {
  border-radius: 18px;
  padding: 19px;
  background: var(--soft-blue);
}

.detail-hero h3,
.detail-hero p {
  margin: 0;
}

.detail-hero h3 {
  color: var(--blue);
  font-size: 1.2rem;
}

.detail-hero p {
  margin-top: 7px;
  color: #475467;
  line-height: 1.5;
}

.detail-list {
  margin: 22px 0 0;
}

.detail-list > div {
  padding: 13px 0;
  border-bottom: 1px solid #edf0f4;
}

.detail-list dt {
  margin-bottom: 4px;
  color: #98a2b3;
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-list dd {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
  line-height: 1.45;
}

.install-dialog {
  width: min(540px, calc(100% - 30px));
  border: 0;
  border-radius: 24px;
  padding: 24px;
  color: var(--ink);
  box-shadow: 0 32px 90px rgba(3, 46, 97, 0.3);
}

.install-dialog::backdrop {
  background: rgba(17, 34, 52, 0.42);
  backdrop-filter: blur(3px);
}

.install-tabs {
  margin: 22px 0 16px;
  border-radius: 14px;
  padding: 4px;
  background: #eef2f6;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.install-tab {
  min-height: 40px;
  border: 0;
  border-radius: 10px;
  color: var(--muted);
  background: transparent;
  font-weight: 850;
}

.install-tab.active {
  color: var(--blue);
  background: white;
  box-shadow: 0 4px 10px rgba(3, 46, 97, 0.08);
}

.install-content ol {
  margin: 0;
  padding-left: 22px;
}

.install-content li {
  margin: 11px 0;
  line-height: 1.5;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  z-index: 80;
  max-width: min(420px, calc(100% - 32px));
  border-radius: 999px;
  padding: 12px 18px;
  color: white;
  background: #172234;
  box-shadow: 0 15px 40px rgba(3, 46, 97, 0.22);
  font-size: 0.86rem;
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 18px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

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

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

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

@media (max-width: 760px) {
  .topbar {
    min-height: 80px;
    padding-left: 18px;
    padding-right: 18px;
  }

  .brand-mark {
    width: 45px;
    height: 45px;
    border-radius: 13px;
  }

  .connection-pill,
  .clock-block span {
    display: none;
  }

  .clock-block {
    min-width: auto;
  }

  main {
    padding: 23px 16px 34px;
  }

  .welcome-row {
    align-items: stretch;
    flex-direction: column;
  }

  .header-actions {
    justify-content: stretch;
  }

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

  .side-panel {
    grid-template-columns: 1fr;
  }

  .notification-card {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .notification-time {
    grid-column: 2;
    padding: 0;
  }
}

@media (max-width: 480px) {
  .topbar h1 {
    font-size: 0.95rem;
  }

  .topbar .eyebrow {
    font-size: 0.64rem;
  }

  .clock-block strong {
    font-size: 1.05rem;
  }

  .summary-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .summary-card {
    min-height: 96px;
    padding: 14px;
    gap: 10px;
  }

  .summary-icon {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
    border-radius: 12px;
  }

  .summary-card strong {
    font-size: 1.55rem;
  }

  .summary-card span {
    font-size: 0.7rem;
  }

  .panel-heading {
    align-items: flex-start;
  }

  .drawer-actions {
    grid-template-columns: 1fr;
  }
}

@media (display-mode: standalone) {
  .setup-card {
    display: none;
  }
}

/* Prevent wide filter rows and drawers from forcing horizontal page scroll. */
html,
body {
  overflow-x: hidden;
}

.content-grid > *,
.side-panel,
.feed-panel,
.side-card {
  min-width: 0;
}

@media (max-width: 1020px) {
  .content-grid {
    grid-template-columns: minmax(0, 1fr);
  }

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

@media (max-width: 760px) {
  .side-panel {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* IONOS production additions */
.logout-link {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}
.logout-link:hover { color: white; text-decoration: underline; }
.loading-state {
  min-height: 180px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 750;
}
.loading-state[hidden] { display: none; }
.roadmap-card { border-top: 4px solid var(--green); }
.coming-soon {
  display: inline-flex;
  margin-top: 8px;
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--green-dark);
  background: var(--soft-green);
  font-size: 0.78rem;
  font-weight: 850;
}
.link-button { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }
.notification-card.priority-urgent { box-shadow: inset 4px 0 0 #b42318; }
.notification-card.priority-high { box-shadow: inset 4px 0 0 #f79009; }

.auth-page {
  min-height: 100vh;
  background: linear-gradient(125deg, #032e61 0 42%, #f4f7fa 42% 100%);
}
.auth-shell {
  width: min(1050px, calc(100% - 40px));
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 0.7fr);
  align-items: center;
  gap: clamp(40px, 8vw, 110px);
}
.setup-shell { width: min(1250px, calc(100% - 40px)); grid-template-columns: 0.65fr 1.35fr; }
.auth-brand { color: white; }
.auth-brand .brand-mark { margin-bottom: 28px; }
.auth-brand .eyebrow { color: rgba(255,255,255,.7); }
.auth-brand h1 { margin: 0; font-size: clamp(2.2rem, 5vw, 4.3rem); line-height: .98; letter-spacing: -.055em; }
.auth-brand p:last-child { max-width: 480px; color: rgba(255,255,255,.75); font-size: 1.08rem; line-height: 1.65; }
.auth-card {
  border: 1px solid rgba(3,46,97,.08);
  border-radius: 26px;
  padding: clamp(28px, 5vw, 48px);
  background: white;
  box-shadow: 0 26px 70px rgba(3,46,97,.16);
}
.setup-card-large { margin: 40px 0; }
.auth-card h2 { margin: 0 0 24px; color: var(--blue); font-size: 2rem; }
.login-form, .setup-form { display: grid; gap: 18px; }
.login-form label, .setup-form label { display: grid; gap: 8px; color: var(--ink); font-size: .86rem; font-weight: 850; }
.login-form input, .setup-form input {
  width: 100%;
  min-height: 50px;
  border: 1px solid #cfd8e3;
  border-radius: 12px;
  padding: 11px 13px;
  color: var(--ink);
  background: white;
}
.login-form input:focus, .setup-form input:focus { outline: 3px solid rgba(115,182,41,.2); border-color: var(--green); }
.privacy-note, .form-intro { color: var(--muted); font-size: .88rem; line-height: 1.55; }
.alert { margin-bottom: 20px; border-radius: 14px; padding: 14px 16px; line-height: 1.5; }
.alert.error { color: #7a271a; border: 1px solid #fecdca; background: #fef3f2; }
.alert ul { margin: 8px 0 0; padding-left: 20px; }
.setup-form fieldset { margin: 0; border: 1px solid var(--line); border-radius: 16px; padding: 20px; }
.setup-form legend { padding: 0 8px; color: var(--blue); font-weight: 900; }
.form-grid { display: grid; gap: 16px; }
.form-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid .wide { grid-column: 1 / -1; }
.success-message { border-left: 4px solid var(--green); padding-left: 14px; color: var(--muted); }
.setup-results { display: grid; gap: 0; margin: 24px 0; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.setup-results div { display: grid; grid-template-columns: 150px 1fr; gap: 20px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.setup-results div:last-child { border-bottom: 0; }
.setup-results dt { color: var(--muted); font-weight: 750; }
.setup-results dd { margin: 0; overflow-wrap: anywhere; }
.secret-code { display: block; border-radius: 8px; padding: 10px; background: #f3f5f8; }

@media (max-width: 860px) {
  .auth-page { background: var(--canvas); }
  .auth-shell, .setup-shell { min-height: auto; padding: 28px 0 48px; grid-template-columns: 1fr; gap: 24px; }
  .auth-brand { border-radius: 24px; padding: 28px; background: var(--blue); }
  .auth-brand h1 { font-size: 2.3rem; }
  .auth-card, .setup-card-large { margin: 0; }
  .form-grid.two { grid-template-columns: 1fr; }
  .form-grid .wide { grid-column: auto; }
  .setup-results div { grid-template-columns: 1fr; gap: 5px; }
}

@media (max-width: 760px) {
  .topbar-meta .clock-block { display: none; }
  .topbar-meta { gap: 10px; }
  .logout-link { display: none; }
}

/* Version 2 notification, calendar and action centre */
.notification-card {
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0;
  overflow: hidden;
}

.notification-open {
  min-width: 0;
  border: 0;
  padding: 15px;
  color: inherit;
  background: transparent;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  text-align: left;
}

.notification-open:focus-visible {
  outline: 3px solid rgba(115, 182, 41, 0.35);
  outline-offset: -3px;
}

.notification-meta {
  min-width: 86px;
  border-left: 1px solid #edf0f4;
  padding: 15px 13px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.notification-rex-link {
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--blue);
  background: var(--soft-blue);
  font-size: 0.72rem;
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.notification-rex-link:hover {
  background: #dbe8f6;
}

.calendar-card {
  border-top: 4px solid var(--green);
}

.calendar-heading {
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.calendar-controls {
  display: flex;
  gap: 6px;
}

.calendar-nav {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--blue);
  background: white;
  font-size: 1.35rem;
  font-weight: 900;
  line-height: 1;
}

.calendar-nav:hover {
  border-color: #afbed0;
  background: var(--soft-blue);
}

.calendar-weekdays,
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
}

.calendar-weekdays {
  margin-bottom: 6px;
  color: #98a2b3;
  font-size: 0.66rem;
  font-weight: 900;
  text-align: center;
}

.calendar-day,
.calendar-blank {
  min-height: 35px;
  border-radius: 10px;
}

.calendar-day {
  position: relative;
  border: 1px solid transparent;
  color: #475467;
  background: #f8fafc;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 800;
}

.calendar-day.today {
  border-color: var(--blue);
  color: var(--blue);
  background: var(--soft-blue);
}

.calendar-day.has-events {
  color: var(--blue);
  background: var(--soft-green);
}

.calendar-day i {
  position: absolute;
  right: 3px;
  bottom: 3px;
  min-width: 14px;
  height: 14px;
  border-radius: 999px;
  padding: 0 3px;
  color: white;
  background: var(--green-dark);
  display: grid;
  place-items: center;
  font-size: 0.55rem;
  font-style: normal;
  font-weight: 950;
}

.calendar-note {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.45;
}

.action-card {
  min-height: 220px;
}

.task-count {
  min-width: 30px;
  height: 30px;
  border-radius: 999px;
  color: var(--blue);
  background: var(--soft-blue);
  display: grid;
  place-items: center;
  font-size: 0.76rem;
  font-weight: 950;
}

.task-list {
  display: grid;
  gap: 9px;
}

.task-item {
  position: relative;
  border: 1px solid #e7ecf2;
  border-radius: 14px;
  padding: 12px 34px 12px 12px;
  color: inherit;
  background: #fbfcfd;
  display: grid;
  gap: 4px;
  text-decoration: none;
}

.task-item:hover {
  border-color: #b7c4d3;
  background: white;
}

.task-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.task-topline strong {
  color: var(--blue);
  font-size: 0.82rem;
  line-height: 1.3;
}

.task-priority {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 7px;
  color: var(--blue-2);
  background: var(--soft-blue);
  font-size: 0.56rem;
  font-weight: 950;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.task-priority.priority-high,
.task-priority.priority-urgent {
  color: #9a3412;
  background: #fff3e8;
}

.task-property,
.task-date {
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.35;
}

.task-property {
  font-weight: 750;
}

.task-arrow {
  position: absolute;
  top: 50%;
  right: 13px;
  color: var(--blue);
  font-size: 1.25rem;
  font-weight: 900;
  transform: translateY(-50%);
}

.task-empty,
.sidebar-error {
  margin: 0;
  border-radius: 13px;
  padding: 16px;
  color: var(--muted);
  background: #f8fafc;
  font-size: 0.8rem;
  line-height: 1.5;
}

.task-empty[hidden] {
  display: none;
}

.calendar-grid .sidebar-error {
  grid-column: 1 / -1;
}

@media (max-width: 1020px) {
  .side-panel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .notification-card {
    grid-template-columns: minmax(0, 1fr);
  }

  .notification-meta {
    min-width: 0;
    border-top: 1px solid #edf0f4;
    border-left: 0;
    padding: 9px 14px;
    flex-direction: row;
    align-items: center;
  }

  .side-panel {
    grid-template-columns: minmax(0, 1fr);
  }
}


/* Version 2.1 deletion controls */
.panel-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  flex-wrap: wrap;
}

.danger-text {
  color: var(--danger);
}

.button.danger-button {
  color: var(--danger);
  border-color: #f1b8b4;
  background: #fff7f6;
}

.button.danger-button:hover {
  background: #feeceb;
}

.drawer-actions:has(.danger-button) {
  grid-template-columns: auto 1fr 1fr;
}

@media (max-width: 540px) {
  .drawer-actions:has(.danger-button) {
    grid-template-columns: 1fr;
  }

  .panel-actions {
    width: 100%;
    justify-content: space-between;
    gap: 12px;
  }
}

/* Version 2.2 compact pinned dashboard */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  min-height: 78px;
  padding-top: max(14px, env(safe-area-inset-top));
  padding-bottom: 14px;
}

.dashboard-main {
  padding-top: clamp(20px, 2.5vw, 30px);
}

.content-grid {
  grid-template-columns: minmax(0, 1.8fr) minmax(340px, 0.9fr);
}

.account-menu-wrap {
  position: relative;
}

.account-menu-button {
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  padding: 9px 12px;
  color: white;
  background: rgba(255, 255, 255, 0.09);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 850;
  cursor: pointer;
}

.account-menu-button:hover,
.account-menu-button[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.16);
}

.account-menu-chevron {
  font-size: 1rem;
  line-height: 1;
  transition: transform 150ms ease;
}

.account-menu-button[aria-expanded="true"] .account-menu-chevron {
  transform: rotate(180deg);
}

.account-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 130;
  width: 220px;
  border: 1px solid rgba(3, 46, 97, 0.12);
  border-radius: 15px;
  padding: 7px;
  background: white;
  box-shadow: 0 22px 55px rgba(3, 46, 97, 0.22);
}

.account-menu[hidden] {
  display: none;
}

.account-menu-item {
  width: 100%;
  min-height: 44px;
  border: 0;
  border-radius: 10px;
  padding: 10px 12px;
  color: var(--blue);
  background: transparent;
  display: flex;
  align-items: center;
  text-align: left;
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 850;
  cursor: pointer;
}

.account-menu-item:hover {
  background: var(--soft-blue);
}

.account-menu-item:disabled {
  color: var(--muted);
  cursor: default;
}

.account-menu-signout {
  color: var(--danger);
}

.calendar-day {
  padding: 0;
  font: inherit;
  cursor: pointer;
}

.calendar-day:hover {
  border-color: #aebdce;
  background: white;
  transform: translateY(-1px);
}

.calendar-day.selected {
  border-color: var(--green-dark);
  color: white;
  background: var(--green-dark);
  box-shadow: 0 7px 16px rgba(77, 134, 20, 0.2);
}

.calendar-day.selected i {
  color: var(--green-dark);
  background: white;
}

.live-alert {
  position: fixed;
  top: max(88px, calc(env(safe-area-inset-top) + 76px));
  left: 50%;
  z-index: 120;
  width: min(560px, calc(100% - 32px));
  border: 1px solid rgba(115, 182, 41, 0.65);
  border-left: 6px solid var(--green);
  border-radius: 17px;
  padding: 15px 18px;
  color: var(--ink);
  background: white;
  box-shadow: 0 24px 65px rgba(3, 46, 97, 0.24);
  display: grid;
  gap: 4px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -18px) scale(0.98);
  transition: opacity 180ms ease, transform 180ms ease;
}

.live-alert.show {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0) scale(1);
  cursor: pointer;
}

.live-alert-label {
  color: var(--green-dark);
  font-size: 0.65rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.live-alert strong {
  color: var(--blue);
  font-size: 1rem;
}

.live-alert span:last-child {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 1020px) {
  .content-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .topbar {
    min-height: 72px;
  }

  .topbar-meta {
    margin-left: auto;
  }

  .account-menu-button span:first-child {
    display: none;
  }

  .account-menu-button {
    width: 42px;
    padding: 8px;
    justify-content: center;
  }

  .account-menu-chevron {
    font-size: 1.25rem;
  }

  .dashboard-main {
    padding-top: 18px;
  }

  .live-alert {
    top: max(78px, calc(env(safe-area-inset-top) + 68px));
  }
}

/* Version 2.2.1 reliable fixed top bar */
:root {
  --dd-topbar-height: 92px;
}

body {
  overflow-x: hidden;
}

.topbar {
  position: fixed !important;
  top: 0;
  right: 0;
  left: 0;
  z-index: 1000;
  width: 100%;
}

.app-shell {
  padding-top: var(--dd-topbar-height);
}

@media (max-width: 760px) {
  :root {
    --dd-topbar-height: 82px;
  }
}

/* Version 2.3 Rex property images */
.notification-visual {
  width: 88px;
  min-width: 88px;
  height: 66px;
  border-radius: 13px;
  overflow: hidden;
  background: var(--soft-blue);
  display: grid;
  place-items: center;
}

.notification-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.notification-visual .event-icon {
  width: 46px;
  height: 46px;
}

.detail-property-image {
  width: 100%;
  max-height: 280px;
  margin-bottom: 14px;
  border-radius: 18px;
  display: block;
  object-fit: cover;
  background: var(--soft-blue);
}

.task-item.has-image {
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: center;
  padding-left: 8px;
}

.task-image {
  width: 58px;
  height: 46px;
  border-radius: 10px;
  display: block;
  object-fit: cover;
  background: var(--soft-blue);
}

.task-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.live-alert.has-image {
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
}

.live-alert-image {
  width: 92px;
  height: 68px;
  border-radius: 12px;
  display: block;
  object-fit: cover;
  background: var(--soft-blue);
}

.live-alert-image[hidden] {
  display: none;
}

.live-alert-content {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.live-alert-content > span:last-child {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 560px) {
  .notification-visual {
    width: 72px;
    min-width: 72px;
    height: 58px;
  }

  .notification-open {
    gap: 11px;
  }

  .notification-detail {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .live-alert.has-image {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .live-alert-image {
    width: 72px;
    height: 58px;
  }
}

/* Version 2.4 exchange and completion board */
.exchange-completion-board {
  margin-bottom: 22px;
  border: 1px solid rgba(3, 46, 97, 0.09);
  border-radius: var(--radius);
  padding: 20px;
  background: linear-gradient(120deg, #ffffff, #f7fbff);
  box-shadow: var(--shadow);
}

.exchange-board-heading {
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.exchange-board-heading h2 {
  margin: 0;
  color: var(--blue);
  font-size: 1.15rem;
}

.exchange-board-count {
  min-width: 34px;
  height: 34px;
  border-radius: 999px;
  padding: 0 10px;
  color: white;
  background: var(--blue);
  display: grid;
  place-items: center;
  font-size: 0.82rem;
  font-weight: 900;
}

.exchange-board-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.exchange-board-item {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 10px;
  color: inherit;
  background: white;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  text-decoration: none;
  transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.exchange-board-item:hover {
  border-color: #b9c8d9;
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(3, 46, 97, 0.09);
}

.exchange-property-visual {
  width: 72px;
  height: 58px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--soft-blue);
  display: grid;
  place-items: center;
}

.exchange-property-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.exchange-property-fallback {
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 950;
}

.exchange-property-copy {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.exchange-property-copy > strong {
  overflow: hidden;
  color: var(--blue);
  font-size: 0.88rem;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.exchange-progress-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.progress-pill {
  border-radius: 999px;
  padding: 5px 8px;
  font-size: 0.66rem;
  font-weight: 850;
  line-height: 1;
}

.progress-pill.exchanged {
  color: var(--blue);
  background: var(--soft-blue);
}

.progress-pill.completion-set {
  color: var(--green-dark);
  background: var(--soft-green);
}

.progress-pill.completion-pending {
  color: #8a5a00;
  background: var(--soft-amber);
}

.exchange-open-label {
  grid-column: 2;
  color: var(--green-dark);
  font-size: 0.7rem;
  font-weight: 900;
}

.exchange-board-empty,
.exchange-board-error {
  margin: 0;
  border: 1px dashed #cbd5e1;
  border-radius: 14px;
  padding: 16px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.72);
  text-align: center;
  font-size: 0.84rem;
}

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

@media (max-width: 680px) {
  .exchange-completion-board {
    padding: 16px;
  }

  .exchange-board-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .exchange-board-item {
    grid-template-columns: 64px minmax(0, 1fr);
  }

  .exchange-property-visual {
    width: 64px;
    height: 52px;
  }
}


/* Version 2.4.1: exchange board inline with summary cards */
.exchange-completion-board {
  grid-column: span 2;
  min-width: 0;
  min-height: 110px;
  margin-bottom: 0;
  padding: 15px;
  align-self: stretch;
}

.exchange-board-heading {
  margin-bottom: 9px;
}

.exchange-board-heading .eyebrow {
  margin-bottom: 2px;
}

.exchange-board-heading h2 {
  font-size: 0.98rem;
}

.exchange-board-count {
  min-width: 29px;
  height: 29px;
  padding: 0 8px;
  font-size: 0.74rem;
}

.exchange-board-list {
  grid-template-columns: 1fr;
  gap: 7px;
}

.exchange-board-item {
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 9px;
  border-radius: 12px;
  padding: 7px;
}

.exchange-property-visual {
  width: 48px;
  height: 42px;
  border-radius: 9px;
}

.exchange-property-copy {
  gap: 5px;
}

.exchange-property-copy > strong {
  font-size: 0.76rem;
}

.exchange-progress-row {
  gap: 4px;
}

.progress-pill {
  padding: 4px 6px;
  font-size: 0.58rem;
}

.exchange-open-label {
  display: none;
}

.exchange-board-empty,
.exchange-board-error {
  padding: 11px;
  font-size: 0.76rem;
}

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

  .exchange-completion-board {
    grid-column: span 2;
  }
}

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

  .exchange-completion-board {
    grid-column: 1 / -1;
  }
}

/* Version 2.5 valuation request pipeline */
.workspace-tabs {
  margin: -4px 0 24px;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 8px;
}

.workspace-tab {
  min-height: 44px;
  border: 0;
  border-bottom: 3px solid transparent;
  padding: 8px 13px 11px;
  color: var(--muted);
  background: transparent;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 900;
  cursor: pointer;
}

.workspace-tab:hover {
  color: var(--blue);
}

.workspace-tab.active {
  border-bottom-color: var(--green);
  color: var(--blue);
}

.workspace-tab span {
  min-width: 24px;
  height: 24px;
  border-radius: 999px;
  padding: 0 7px;
  color: var(--blue);
  background: var(--soft-blue);
  display: grid;
  place-items: center;
  font-size: 0.7rem;
}

.workspace-tab.active span {
  color: var(--green-dark);
  background: var(--soft-green);
}

.workspace-view[hidden] {
  display: none;
}

.valuation-summary {
  margin: 20px 0 4px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.valuation-summary > div {
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 13px 15px;
  background: #fbfcfd;
}

.valuation-summary span,
.valuation-summary strong {
  display: block;
}

.valuation-summary span {
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 750;
}

.valuation-summary strong {
  margin-top: 4px;
  color: var(--blue);
  font-size: 1.45rem;
}

.valuation-list {
  display: grid;
  gap: 11px;
}

.valuation-card {
  border: 1px solid var(--line);
  border-left: 5px solid #d89b18;
  border-radius: 17px;
  overflow: hidden;
  background: linear-gradient(90deg, rgba(255, 246, 223, 0.72), white 34%);
  transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.valuation-card:hover {
  border-color: #b7c4d3;
  box-shadow: 0 10px 24px rgba(3, 46, 97, 0.07);
  transform: translateY(-1px);
}

.valuation-card.status-booked,
.valuation-card.status-completed,
.valuation-card.status-instructed {
  border-left-color: var(--green);
  background: linear-gradient(90deg, rgba(239, 248, 231, 0.92), white 38%);
}

.valuation-open {
  width: 100%;
  min-width: 0;
  border: 0;
  padding: 14px;
  color: inherit;
  background: transparent;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  text-align: left;
  cursor: pointer;
}

.valuation-open:focus-visible {
  outline: 3px solid rgba(115, 182, 41, 0.35);
  outline-offset: -3px;
}

.valuation-visual {
  width: 76px;
  height: 60px;
  border-radius: 13px;
  overflow: hidden;
  background: var(--soft-blue);
  display: grid;
  place-items: center;
}

.valuation-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.valuation-source-mark {
  color: var(--blue);
  font-size: 0.9rem;
  font-weight: 950;
  letter-spacing: 0.02em;
}

.valuation-main {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.valuation-topline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.valuation-topline strong {
  min-width: 0;
  overflow: hidden;
  color: var(--blue);
  font-size: 0.95rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.valuation-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 5px 8px;
  color: #8a5a00;
  background: var(--soft-amber);
  font-size: 0.62rem;
  font-weight: 950;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.valuation-status.status-booked,
.valuation-status.status-completed,
.valuation-status.status-instructed {
  color: var(--green-dark);
  background: var(--soft-green);
}

.valuation-contact {
  color: #344054;
  font-size: 0.86rem;
  font-weight: 800;
}

.valuation-detail,
.valuation-appointment {
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.35;
}

.valuation-appointment {
  color: var(--blue-2);
  font-weight: 800;
}

.valuation-card.status-booked .valuation-appointment {
  color: var(--green-dark);
}

.valuation-date {
  min-width: 78px;
  color: #98a2b3;
  display: grid;
  gap: 3px;
  font-size: 0.65rem;
  font-weight: 800;
  text-align: right;
  text-transform: uppercase;
}

.valuation-date strong {
  color: var(--blue);
  font-size: 0.73rem;
  text-transform: none;
}

.notification-card.type-valuation_booked {
  border-left: 5px solid var(--green);
  background: linear-gradient(90deg, rgba(239, 248, 231, 0.9), white 30%);
}

.notification-card.type-valuation_request:not(.unread) {
  border-left: 5px solid #d89b18;
  background: linear-gradient(90deg, rgba(255, 246, 223, 0.58), white 26%);
}

.event-icon.valuation_booked {
  color: var(--green-dark);
  background: var(--soft-green);
}

.event-icon.valuation_request {
  color: #8a5a00;
  background: var(--soft-amber);
}

.valuation-detail-hero {
  border-left-color: var(--green);
}

@media (max-width: 760px) {
  .workspace-tabs {
    margin-bottom: 20px;
  }

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

  .valuation-summary > div {
    padding: 11px;
  }

  .valuation-summary span {
    font-size: 0.66rem;
  }

  .valuation-summary strong {
    font-size: 1.2rem;
  }

  .valuation-open {
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 11px;
  }

  .valuation-visual {
    width: 64px;
    height: 52px;
  }

  .valuation-date {
    grid-column: 2;
    min-width: 0;
    display: flex;
    gap: 7px;
    text-align: left;
  }
}

@media (max-width: 460px) {
  .valuation-summary {
    grid-template-columns: 1fr;
  }

  .valuation-summary > div {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .valuation-summary strong {
    margin-top: 0;
  }

  .valuation-topline strong {
    width: 100%;
    white-space: normal;
  }
}


/* v3.2.7 Valuations search and calendar */
.valuation-panel-heading {
  gap: 16px;
  align-items: center;
}

.valuation-view-switch {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 3px;
  background: #f7f9fb;
}

.valuation-view-button {
  border: 0;
  border-radius: 9px;
  padding: 8px 13px;
  color: var(--muted);
  background: transparent;
  font: inherit;
  font-size: .76rem;
  font-weight: 850;
  cursor: pointer;
}

.valuation-view-button.active {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 2px 8px rgba(3, 46, 97, .16);
}

.valuation-toolbar {
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.valuation-search {
  flex: 1 1 440px;
  max-width: 680px;
}

.valuation-search input {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 13px;
  color: var(--blue);
  background: #fff;
  font: inherit;
  font-size: .85rem;
  outline: none;
}

.valuation-search input:focus {
  border-color: var(--blue-2);
  box-shadow: 0 0 0 3px rgba(3, 46, 97, .08);
}

.valuation-search-clear,
.valuation-calendar-today,
.valuation-calendar-nav {
  border: 1px solid var(--line);
  border-radius: 10px;
  min-height: 40px;
  padding: 8px 12px;
  color: var(--blue);
  background: #fff;
  font: inherit;
  font-size: .76rem;
  font-weight: 850;
  cursor: pointer;
}

.valuation-search-clear:hover,
.valuation-calendar-today:hover,
.valuation-calendar-nav:hover {
  border-color: #b7c4d3;
  background: #f7f9fb;
}

.valuation-calendar-controls {
  margin: 2px 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.valuation-calendar-navigation {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.valuation-calendar-navigation strong {
  min-width: 150px;
  color: var(--blue);
  text-align: center;
}

.valuation-calendar-nav {
  width: 40px;
  padding: 5px;
  font-size: 1.25rem;
  line-height: 1;
}

.valuation-calendar-note {
  flex: 1 1 260px;
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.4;
}

.valuation-calendar {
  overflow-x: auto;
}

.valuation-calendar-grid {
  min-width: 900px;
  display: grid;
  grid-template-columns: repeat(7, minmax(120px, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}

.valuation-calendar-weekday {
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 9px 10px;
  color: #657587;
  background: #f7f9fb;
  font-size: .68rem;
  font-weight: 900;
  letter-spacing: .03em;
  text-align: center;
  text-transform: uppercase;
}

.valuation-calendar-day {
  min-height: 135px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 8px;
  background: #fff;
}

.valuation-calendar-day.is-outside {
  background: #f8fafc;
}

.valuation-calendar-day.is-today {
  background: #f8fbf4;
  box-shadow: inset 0 0 0 2px rgba(115, 182, 41, .45);
}

.valuation-calendar-day-number {
  margin-bottom: 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--blue);
  font-size: .76rem;
  font-weight: 900;
}

.valuation-calendar-day-number small {
  border-radius: 999px;
  min-width: 20px;
  padding: 2px 6px;
  color: var(--green-dark);
  background: var(--soft-green);
  font-size: .62rem;
  text-align: center;
}

.valuation-calendar-appointments {
  display: grid;
  gap: 6px;
}

.valuation-calendar-appointment {
  width: 100%;
  border: 1px solid #dbe6d1;
  border-left: 4px solid var(--green);
  border-radius: 9px;
  padding: 7px 8px;
  color: #344054;
  background: #f7fbf2;
  display: grid;
  gap: 2px;
  text-align: left;
  cursor: pointer;
}

.valuation-calendar-appointment:hover {
  border-color: #bdd4a5;
  background: #f1f8e9;
}

.valuation-calendar-appointment strong {
  overflow: hidden;
  color: var(--blue);
  font-size: .7rem;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.valuation-calendar-appointment span {
  overflow: hidden;
  color: var(--muted);
  font-size: .62rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.valuation-calendar-appointment .valuation-calendar-time {
  color: var(--green-dark);
  font-weight: 900;
}

.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;
}

@media (max-width: 760px) {
  .valuation-panel-heading {
    align-items: flex-start;
  }

  .valuation-toolbar {
    align-items: stretch;
  }

  .valuation-search {
    flex-basis: 100%;
  }

  .valuation-calendar-controls {
    align-items: flex-start;
  }

  .valuation-calendar-note {
    flex-basis: 100%;
  }
}

/* v3.2.8 Valuations side calendar */
.valuation-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.1fr) minmax(280px, .8fr);
  gap: 22px;
  align-items: start;
}

.valuation-content-grid > *,
.valuation-side-panel {
  min-width: 0;
}

.valuation-side-panel {
  display: grid;
  gap: 16px;
}

.valuation-side-calendar .calendar-day {
  cursor: pointer;
}

.valuation-side-calendar .calendar-day[aria-pressed="true"] {
  border-color: var(--blue);
  box-shadow: inset 0 0 0 1px var(--blue);
}

@media (max-width: 1020px) {
  .valuation-content-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* v3.5.13 valuation lifecycle status */
.valuation-card.status-instructed {
  border-left-color: #1f6fb2;
  background: linear-gradient(90deg, rgba(31,111,178,.08), #fff 20%);
}
.valuation-status.status-instructed {
  background: #e7f1fb;
  color: #175a92;
}
.valuation-card.status-instructed .valuation-appointment {
  color: #175a92;
}
.valuation-calendar .calendar-day.has-unbooked:not(.has-booked):not(.has-instructed) { box-shadow: inset 0 -3px 0 #d99a00; }
.valuation-calendar .calendar-day.has-booked:not(.has-instructed) { box-shadow: inset 0 -3px 0 #5db536; }
.valuation-calendar .calendar-day.has-instructed { box-shadow: inset 0 -3px 0 #1f6fb2; }
