:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif;color:#172033;background:#eef2f7;font-synthesis:none}*{box-sizing:border-box}body{margin:0;min-height:100vh}button,input,textarea,select{font:inherit}button{cursor:pointer}.app{display:grid;grid-template-columns:245px minmax(0,1fr);min-height:100vh}.sidebar{position:sticky;top:0;height:100vh;background:#111827;color:#fff;padding:22px 16px;display:flex;flex-direction:column}.brand{display:flex;align-items:center;gap:11px;padding:4px 8px 24px}.brand-mark{width:38px;height:38px;border-radius:12px;background:#fff;color:#111827;display:grid;place-items:center;font-weight:850}.brand strong,.brand small{display:block}.brand small{margin-top:2px;color:#aeb8ca}nav{display:grid;gap:6px}.nav{border:0;background:transparent;color:#c9d1df;text-align:left;padding:12px 13px;border-radius:10px;font-weight:650}.nav:hover,.nav.active{background:#273246;color:#fff}.sidebar-bottom{margin-top:auto;padding:12px 8px}.sidebar-bottom small{color:#96a0b2}.status{font-size:13px;margin-bottom:7px;line-height:1.4}.status.good{color:#8ce6ae}.status.bad{color:#ffb4b4}.main{min-width:0;padding:28px}.page{display:none;max-width:1320px;margin:0 auto}.page.active{display:block}.page-header{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:20px}.page-header h1{margin:0;font-size:30px;letter-spacing:-.025em}.page-header p{margin:6px 0 0;color:#68748a}.header-actions{display:flex;gap:9px;align-items:center}.mode{display:flex;gap:9px;align-items:center;color:#69758a;font-size:14px}select,input,textarea{border:1px solid #cbd3df;border-radius:11px;padding:11px 12px;background:#fff;color:#172033;outline:none}select:focus,input:focus,textarea:focus{border-color:#66758f;box-shadow:0 0 0 3px #66758f18}.primary,.secondary,.danger{border:0;border-radius:11px;padding:11px 16px;font-weight:750}.primary{background:#172033;color:#fff}.primary:hover{background:#26334b}.secondary{background:#e8edf4;color:#172033}.secondary:hover{background:#dce3ec}.danger{background:#fee2e2;color:#a31d1d}.full{width:100%;margin-top:10px}.quick-prompts{display:flex;gap:8px;overflow-x:auto;margin:-5px 0 12px}.quick-prompts button{border:1px solid #d8dee8;background:#fff;border-radius:999px;padding:8px 12px;white-space:nowrap;color:#4f5b70}.chat-shell{height:calc(100vh - 180px);min-height:540px;background:#fff;border-radius:18px;box-shadow:0 14px 38px #17203312;overflow:hidden;display:flex;flex-direction:column}.messages{flex:1;overflow-y:auto;padding:24px}.message{max-width:78%;margin:9px 0;padding:12px 14px;border-radius:15px;white-space:pre-wrap;line-height:1.48}.message.assistant{background:#eef2f7;border-bottom-left-radius:4px}.message.user{margin-left:auto;background:#172033;color:#fff;border-bottom-right-radius:4px}.message.error{color:#a52d2d;background:#fff0f0}.message-meta{font-size:11px;color:#8a94a6;margin:2px 0 12px}.composer{display:flex;gap:10px;padding:15px;border-top:1px solid #e5e9ef}.composer textarea{flex:1;resize:none;min-height:58px}.summary-strip{display:grid;grid-template-columns:2fr 1fr 1fr;gap:12px;margin-bottom:16px}.summary-strip>div{background:#fff;padding:15px;border-radius:14px;box-shadow:0 8px 24px #1720330e}.summary-strip small,.summary-strip strong{display:block}.summary-strip small{color:#748095;margin-bottom:5px}.dashboard-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.dashboard-grid.two{grid-template-columns:repeat(2,minmax(0,1fr))}.card{background:#fff;border-radius:16px;padding:19px;box-shadow:0 10px 30px #17203310}.card.wide{max-width:900px}.card h2{margin:0 0 14px;font-size:18px}.event,.list-row,.memory-card,.proposal{border:1px solid #e2e7ee;border-radius:12px;padding:12px;margin:9px 0;background:#fafbfd}.event{cursor:pointer}.event:hover{border-color:#b9c3d2}.event strong,.event span,.event small{display:block}.event span,.event small{color:#6d788c;margin-top:4px}.empty{color:#7a8497;padding:8px 0}.stack{display:grid;gap:9px}.stack label{display:grid;gap:5px;font-size:13px;color:#657086}.item-list{margin-top:14px}.list-row{display:flex;align-items:flex-start;gap:10px;justify-content:space-between}.list-row .content{min-width:0;flex:1}.list-row strong,.list-row small{display:block}.list-row small{color:#758096;margin-top:4px}.icon-button{border:0;background:transparent;padding:5px 7px;color:#7b8496;border-radius:7px}.icon-button:hover{background:#edf1f6;color:#172033}.large-input{width:100%;resize:vertical;min-height:185px;line-height:1.5}.actions{display:flex;gap:9px;margin-top:12px}.proposal-list{max-width:900px;margin:16px 0}.proposal{display:grid;grid-template-columns:auto 1fr;gap:12px;background:#fff}.proposal input[type=checkbox]{width:18px;height:18px;margin-top:2px}.proposal-title{display:flex;justify-content:space-between;gap:12px}.badge{display:inline-block;padding:3px 7px;border-radius:999px;background:#e8edf4;font-size:12px;font-weight:750;text-transform:capitalize}.proposal p{margin:7px 0 0;color:#536078}.proposal small{display:block;margin-top:6px;color:#818b9e}.hidden{display:none!important}.search{width:min(360px,100%)}.memory-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:13px}.memory-card{background:#fff;margin:0}.memory-card .top{display:flex;justify-content:space-between;gap:10px}.memory-card p{line-height:1.45}.memory-card small{color:#788397}.settings-card{max-width:820px}.settings-card dl{margin:0 0 25px}.settings-card dl div{display:grid;grid-template-columns:170px 1fr;padding:10px 0;border-bottom:1px solid #edf0f4}.settings-card dt{font-weight:750}.settings-card dd{margin:0;color:#5f6c82}pre{white-space:pre-wrap;background:#f3f5f8;padding:12px;border-radius:10px}.calendar-toolbar{display:grid;grid-template-columns:auto auto minmax(180px,1fr);gap:14px;align-items:center;margin-bottom:14px}.calendar-nav,.view-tabs{display:flex;gap:6px;align-items:center}.calendar-nav strong{min-width:190px;margin-left:7px}.view-tabs button{border:1px solid #d7dee8;background:#fff;border-radius:9px;padding:8px 11px;color:#596579}.view-tabs button.active{background:#172033;color:#fff;border-color:#172033}.calendar-layout{display:grid;grid-template-columns:minmax(0,1fr) 310px;gap:16px}.calendar-card{min-height:600px;position:relative}.calendar-side{display:grid;align-content:start;gap:16px}.loading{position:absolute;inset:0;background:#ffffffd9;display:grid;place-items:center;z-index:5;font-weight:700}.week-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:8px}.day-column{min-width:0;border:1px solid #e1e6ed;border-radius:12px;padding:9px;background:#fafbfd}.day-column.today{border-color:#8290a6;background:#f4f7fb}.day-heading{font-weight:800;margin-bottom:8px}.day-heading small{display:block;color:#7a8496;font-weight:500}.calendar-event{border-left:4px solid #7d8ca5;background:#eef2f7;border-radius:8px;padding:8px;margin:7px 0;cursor:pointer;overflow:hidden}.calendar-event:hover{background:#e4eaf2}.calendar-event strong,.calendar-event small{display:block}.calendar-event small{color:#657187;margin-top:3px}.month-grid{display:grid;grid-template-columns:repeat(7,1fr);border-top:1px solid #dfe5ed;border-left:1px solid #dfe5ed}.month-weekday{padding:8px;text-align:center;font-weight:750;color:#667287;border-right:1px solid #dfe5ed;border-bottom:1px solid #dfe5ed;background:#f6f8fb}.month-day{min-height:120px;padding:7px;border-right:1px solid #dfe5ed;border-bottom:1px solid #dfe5ed;background:#fff;overflow:hidden}.month-day.outside{background:#f7f8fa;color:#a1a9b7}.month-day.today{box-shadow:inset 0 0 0 2px #76859e}.month-number{font-weight:750;margin-bottom:5px}.month-event{display:block;width:100%;border:0;text-align:left;background:#e9eef5;color:#27344a;border-radius:5px;padding:4px 5px;margin:3px 0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:12px}.agenda-group{margin-bottom:18px}.agenda-date{font-weight:850;margin-bottom:7px}.two-inputs{display:grid;grid-template-columns:1fr 1fr;gap:9px}.modal{position:fixed;inset:0;z-index:100}.modal-backdrop{position:absolute;inset:0;background:#10182799}.modal-panel{position:relative;width:min(620px,calc(100% - 28px));max-height:calc(100vh - 36px);overflow:auto;margin:18px auto;background:#fff;border-radius:18px;padding:20px;box-shadow:0 25px 80px #0004}.modal-title{display:flex;justify-content:space-between;align-items:flex-start;gap:15px}.modal-title h2{margin:0}.modal-title p{margin:6px 0 0}.modal-actions{display:grid;grid-template-columns:auto 1fr auto auto;gap:9px;align-items:center;margin-top:8px}.check{display:flex!important;align-items:center;gap:8px!important}.check input{width:17px;height:17px}.warning{background:#fff7df;color:#805700;padding:9px;border-radius:9px}.import-ok{background:#e8f7ed;color:#1e6a38;padding:10px 12px;border-radius:10px;margin-bottom:12px}.import-error{background:#fff0f0;color:#9d2929;padding:10px 12px;border-radius:10px;margin-bottom:12px}@media(max-width:1050px){.calendar-layout{grid-template-columns:1fr}.week-grid{grid-template-columns:repeat(2,1fr)}.calendar-toolbar{grid-template-columns:1fr}.memory-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:800px){.app{grid-template-columns:1fr}.sidebar{position:static;height:auto;padding:12px}.brand{padding-bottom:10px}nav{display:flex;overflow-x:auto}.nav{white-space:nowrap}.sidebar-bottom{display:none}.main{padding:16px}.dashboard-grid,.dashboard-grid.two,.memory-grid,.summary-strip{grid-template-columns:1fr}.chat-shell{height:68vh}.page-header{align-items:flex-start;flex-direction:column}.header-actions{width:100%;flex-wrap:wrap}.message{max-width:92%}.week-grid{grid-template-columns:1fr}.month-day{min-height:95px}.calendar-header{flex-direction:column}.modal-actions{grid-template-columns:1fr 1fr}.modal-actions span{display:none}.two-inputs{grid-template-columns:1fr}}


/* Weather */
.weather-current-card { margin-bottom: 16px; }
.weather-current { display:flex; align-items:center; justify-content:space-between; gap:24px; }
.weather-current small, .weather-current strong, .weather-current span { display:block; }
.weather-current strong { font-size:44px; line-height:1; margin:7px 0; letter-spacing:-.04em; }
.weather-current-details { display:grid; gap:6px; color:#657086; text-align:right; }
.weather-grid { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:13px; }
.weather-day { min-width:0; }
.weather-day-title { display:flex; justify-content:space-between; gap:8px; align-items:baseline; }
.weather-day-title small { color:#7a8497; }
.weather-condition { color:#58657b; min-height:42px; margin:14px 0; }
.weather-temps { display:flex; gap:9px; align-items:baseline; }
.weather-temps strong { font-size:30px; }
.weather-temps span { color:#7b8597; font-size:19px; }
.weather-details { display:grid; gap:4px; color:#778296; font-size:13px; margin-top:12px; }
.weather-today strong,.weather-today span,.weather-today small { display:block; }
.weather-today span,.weather-today small { color:#6d788c; margin-top:4px; }
@media(max-width:1100px){.weather-grid{grid-template-columns:repeat(3,minmax(0,1fr));}}
@media(max-width:700px){.weather-grid{grid-template-columns:repeat(2,minmax(0,1fr));}.weather-current{align-items:flex-start;flex-direction:column}.weather-current-details{text-align:left}}


/* V4 schedule-focused layout */
.summary-three { grid-template-columns: repeat(3, minmax(0,1fr)); }
.today-layout { display:grid; grid-template-columns:minmax(0,2fr) minmax(300px,1fr); gap:16px; margin-bottom:16px; }
.today-side { display:grid; gap:16px; align-content:start; }
.today-agenda-card { min-height:480px; }
.card-heading { display:flex; justify-content:space-between; align-items:flex-start; gap:14px; margin-bottom:12px; }
.card-heading h2 { margin:0; }
.card-heading small, .muted { color:#738096; line-height:1.45; }
.small-button { padding:8px 11px; }
.text-button { border:0; background:transparent; color:#30466b; font-weight:750; padding:4px 2px; }
.text-button:hover { text-decoration:underline; }
.compact-form { margin-bottom:14px; padding:12px; background:#f5f7fa; border-radius:12px; }
.insights-card { margin-top:0; }
.insight-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; }
.insight { border-radius:12px; padding:12px; border:1px solid #e1e6ee; display:grid; gap:5px; }
.insight span { color:#5f6c82; line-height:1.4; }
.insight.warning { background:#fff7eb; border-color:#f1d39d; }
.insight.good { background:#effaf3; border-color:#bde0c8; }
.insight.info { background:#f3f6fb; }

.event-large { padding:15px; }
.event-main { min-width:0; }
.event-weather-slot { margin-top:8px; }
.event-weather { background:#eaf2fb; color:#2e4c72; border-radius:9px; padding:7px 9px; font-size:12px; line-height:1.35; }
.event-weather.unavailable { background:#f4f5f7; color:#7d8798; }
.event-weather-days { display:flex; flex-wrap:wrap; gap:6px 12px; margin-top:5px; }
.event-weather-days span { color:#52657e; }
.weather-loading { font-size:12px; color:#8190a4; }
.missing-location { color:#a06d27 !important; }

.weather-header { align-items:flex-start; }
.location-search-form { display:flex; gap:9px; align-items:flex-start; min-width:min(520px,100%); }
.location-search-form .search { flex:1; min-width:260px; }
.autocomplete-wrap { position:relative; }
.autocomplete-results { position:absolute; z-index:50; top:calc(100% + 5px); left:0; right:0; background:white; border:1px solid #d5dce7; border-radius:12px; box-shadow:0 16px 35px #17203328; max-height:320px; overflow:auto; padding:5px; }
.autocomplete-results button { width:100%; text-align:left; border:0; background:transparent; padding:10px 11px; border-radius:8px; display:grid; gap:2px; }
.autocomplete-results button:hover, .autocomplete-results button.active { background:#eef3f9; }
.autocomplete-results button span { color:#728096; font-size:12px; }
.section-heading { display:flex; justify-content:space-between; align-items:flex-end; gap:18px; margin:12px 0; }
.section-heading h2 { margin:0; }
.section-heading p { margin:4px 0 0; color:#738096; }
.place-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin-bottom:18px; }
.place-card { text-align:left; border:1px solid #dce3ec; background:white; border-radius:14px; padding:14px; box-shadow:0 8px 24px #1720330d; display:grid; gap:4px; }
.place-card:hover { border-color:#98a7bd; transform:translateY(-1px); }
.place-card strong { font-size:16px; }
.place-card small { color:#738096; }
.place-card p { margin:5px 0 0; color:#53627a; line-height:1.35; }
.place-source { justify-self:start; font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:.06em; color:#60718a; background:#edf1f6; padding:3px 6px; border-radius:999px; }

.week-grid { display:grid; grid-template-columns:repeat(7,minmax(130px,1fr)); gap:8px; overflow-x:auto; }
.week-day { min-height:390px; background:#f7f9fc; border:1px solid #e1e6ed; border-radius:12px; padding:8px; }
.week-day.today { border-color:#7d91ae; background:#f0f5fb; }
.week-day > header { display:flex; justify-content:space-between; align-items:center; padding:5px 3px 9px; }
.week-day > header span { font-size:20px; font-weight:800; }
.week-day .event { padding:9px; font-size:12px; }
.week-day .event-weather-slot { margin-top:5px; }
.week-day .event-weather { padding:5px 6px; font-size:10px; }
.week-day .event-weather-days { display:none; }
.month-grid { display:grid; grid-template-columns:repeat(7,minmax(100px,1fr)); gap:1px; background:#dfe5ed; border:1px solid #dfe5ed; }
.month-heading { background:#f0f3f7; padding:8px; text-align:center; font-weight:750; }
.month-cell { min-height:125px; background:white; padding:7px; }
.month-cell.outside { background:#f6f7f9; color:#99a2b0; }
.month-cell.today { box-shadow:inset 0 0 0 2px #657b9b; }
.month-cell > header { font-weight:800; margin-bottom:5px; }
.month-event { display:block; width:100%; border:0; background:#eaf0f8; color:#233754; text-align:left; border-radius:6px; padding:4px 6px; margin:3px 0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:11px; }
.agenda-day { margin-bottom:22px; }
.agenda-day h3 { margin:0 0 8px; padding-bottom:7px; border-bottom:1px solid #e4e8ee; }
.calendar-day-view > h2 { margin-top:0; }

.settings-tabs { display:flex; gap:7px; margin-bottom:15px; }
.settings-tabs button { border:0; border-radius:10px; padding:10px 14px; background:#dfe5ed; color:#35435a; font-weight:750; }
.settings-tabs button.active { background:#172033; color:white; }
.settings-panel { display:none; }
.settings-panel.active { display:block; }

@media(max-width:1050px) {
  .today-layout { grid-template-columns:1fr; }
  .today-side { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .place-grid, .insight-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media(max-width:700px) {
  .summary-three, .today-side, .place-grid, .insight-grid { grid-template-columns:1fr; }
  .location-search-form { width:100%; min-width:0; flex-wrap:wrap; }
  .location-search-form .search { min-width:0; width:100%; }
  .week-grid { grid-template-columns:repeat(7,220px); }
}

.event-modal-weather { margin:2px 0 4px; }


/* V4.1 private places and address/store search */
.field-help {
  display:block;
  margin-top:5px;
  color:#758197;
  font-size:12px;
  line-height:1.35;
}
.settings-place-layout {
  display:grid;
  grid-template-columns:minmax(320px, 0.9fr) minmax(360px, 1.1fr);
  gap:16px;
}
.privacy-note {
  margin:14px 0 0;
  padding:10px 12px;
  border-radius:10px;
  background:#f4f6f9;
  color:#657188;
  font-size:12px;
  line-height:1.45;
}
.saved-place-list {
  display:grid;
  gap:10px;
}
.saved-place-card {
  border:1px solid #e0e5ec;
  border-radius:12px;
  padding:13px;
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:14px;
  background:#fafbfd;
}
.saved-place-card strong,
.saved-place-card span,
.saved-place-card small {
  display:block;
}
.saved-place-card span {
  margin-top:4px;
  color:#526078;
}
.saved-place-card small {
  margin-top:4px;
  color:#7a8598;
}
.saved-place-card p {
  margin:7px 0 0;
  color:#606d82;
}
.saved-place-actions {
  display:flex;
  gap:7px;
  flex-shrink:0;
}
.saved-place-actions .danger {
  padding:8px 10px;
}
@media(max-width:900px) {
  .settings-place-layout {
    grid-template-columns:1fr;
  }
  .saved-place-card {
    flex-direction:column;
  }
}


/* V5 merged Home + schedule/travel calendar */
.home-layout {
  display:grid;
  grid-template-columns:minmax(0,1.45fr) minmax(370px,.9fr);
  gap:16px;
  align-items:start;
  margin-bottom:16px;
}
.home-left { display:grid; gap:16px; }
.home-chat { position:sticky; top:20px; }
.chat-card {
  height:calc(100vh - 110px);
  min-height:650px;
  display:flex;
  flex-direction:column;
  padding:0;
  overflow:hidden;
}
.chat-heading {
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:12px;
  padding:18px 18px 10px;
}
.chat-heading h2 { margin:0; }
.chat-heading small { color:#748198; }
.chat-heading select { max-width:185px; padding:8px; }
.chat-card .quick-prompts { padding:0 18px 10px; }
.chat-card .messages { flex:1; padding:16px 18px; min-height:0; }
.chat-card .composer { margin-top:auto; }

.summary-strip {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
  margin-bottom:16px;
}
.summary-strip > div {
  background:white;
  border-radius:14px;
  padding:13px 15px;
  box-shadow:0 8px 26px #1720330d;
  min-width:0;
}
.summary-strip small {
  display:block;
  color:#78849a;
  margin-bottom:4px;
}
.summary-strip strong {
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.home-lower-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:16px;
}
.inline-search {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:9px;
}
.inline-search input { width:100%; }
.compact-forecast { margin-top:12px; }
.compact-current {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  background:#eef3f9;
  border-radius:12px;
  padding:11px 13px;
}
.compact-current strong,
.compact-current span { display:block; }
.compact-days {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
  margin-top:8px;
}
.compact-days > div {
  border:1px solid #e1e6ed;
  border-radius:10px;
  padding:9px;
  font-size:12px;
  line-height:1.4;
}
.data-note {
  margin:12px 0 0;
  color:#78849a;
  font-size:12px;
  line-height:1.4;
}

/* Home chronological schedule */
.home-timeline { display:grid; }
.timeline-row {
  display:grid;
  grid-template-columns:105px 18px minmax(0,1fr);
  gap:8px;
  min-height:58px;
  position:relative;
}
.timeline-time {
  text-align:right;
  padding:9px 4px 0 0;
  color:#6f7b91;
  font-size:12px;
  white-space:nowrap;
}
.timeline-marker {
  position:relative;
  width:14px;
}
.timeline-marker::before {
  content:"";
  position:absolute;
  top:0;
  bottom:0;
  left:6px;
  width:2px;
  background:#dce3ec;
}
.timeline-marker::after {
  content:"";
  position:absolute;
  top:13px;
  left:2px;
  width:10px;
  height:10px;
  border-radius:50%;
  background:#667a99;
  box-shadow:0 0 0 3px white;
}
.timeline-content {
  border:1px solid #e1e6ed;
  border-radius:11px;
  padding:10px 12px;
  margin-bottom:8px;
  min-width:0;
}
.timeline-content strong,
.timeline-content span,
.timeline-content small { display:block; }
.timeline-content span { margin-top:3px; color:#526078; }
.timeline-content small { margin-top:4px; color:#7b879a; }
.event-row .timeline-content { background:#f8fafc; cursor:pointer; }
.event-row .timeline-content:hover { border-color:#97a7bd; }
.travel-row .timeline-content { background:#edf4fb; border-style:dashed; }
.travel-row.conflict .timeline-content { background:#fff0f0; border-color:#e3a3a3; }
.downtime-row .timeline-content { background:#eff9f3; }
.buffer-row .timeline-content { background:#fff8e8; }
.travel-marker::after { background:#4f7fae; }
.downtime-marker::after { background:#4f9a6b; }
.buffer-marker::after { background:#d39832; }
.warning-text { color:#a26821 !important; }
.weather-day-chips { display:flex; flex-wrap:wrap; gap:4px 9px; margin-top:4px; }
.weather-day-chips span { font-size:11px; color:#52657e; }

/* Calendar actual-time visualization */
.time-grid-shell {
  min-width:720px;
  overflow:hidden;
}
.time-grid-header,
.all-day-row {
  display:grid;
  grid-template-columns:62px repeat(var(--day-count,7), minmax(110px,1fr));
}
.time-grid-header { position:sticky; top:0; z-index:8; background:white; }
.axis-header { border-bottom:1px solid #dfe5ed; }
.day-header {
  border:0;
  border-left:1px solid #e1e6ed;
  border-bottom:1px solid #dfe5ed;
  background:#f7f9fc;
  padding:8px;
  display:flex;
  justify-content:center;
  align-items:center;
  gap:8px;
}
.day-header span { font-size:18px; font-weight:800; }
.day-header.today { background:#edf4fb; }
.day-header.selected { box-shadow:inset 0 -3px #506f98; }
.all-day-row {
  border-bottom:1px solid #dfe5ed;
  background:white;
}
.all-day-label {
  padding:8px 5px;
  color:#768399;
  font-size:11px;
  text-align:right;
}
.all-day-cell {
  border-left:1px solid #e1e6ed;
  min-height:38px;
  padding:4px;
}
.all-day-cell button {
  width:100%;
  border:0;
  border-radius:6px;
  padding:4px 6px;
  background:#e9eff7;
  text-align:left;
  font-size:11px;
}
.time-grid-body {
  display:grid;
  grid-template-columns:62px minmax(0,1fr);
  overflow:auto;
  max-height:calc(100vh - 290px);
}
.time-axis {
  position:relative;
  background:white;
  border-right:1px solid #dfe5ed;
}
.time-axis span {
  position:absolute;
  right:7px;
  transform:translateY(-7px);
  color:#778398;
  font-size:11px;
}
.time-day-columns {
  display:grid;
  grid-template-columns:repeat(var(--day-count,7), minmax(110px,1fr));
  position:relative;
}
.time-day-column {
  position:relative;
  border-right:1px solid #e1e6ed;
  background:#fff;
}
.time-day-column.selected { background:#fbfdff; }
.hour-line {
  position:absolute;
  left:0;
  right:0;
  border-top:1px solid #edf0f4;
  pointer-events:none;
}
.grid-block {
  position:absolute;
  left:4px;
  right:4px;
  z-index:3;
  border:0;
  border-radius:7px;
  padding:4px 6px;
  text-align:left;
  overflow:hidden;
  line-height:1.2;
  box-shadow:0 2px 6px #17203318;
}
.grid-block strong,
.grid-block span { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.grid-block strong { font-size:11px; }
.grid-block span { font-size:9px; margin-top:2px; opacity:.85; }
.grid-event { background:#dce8f6; color:#203a5b; }
.grid-travel { background:#edf4fb; color:#315c82; border:1px dashed #73a0c6; }
.grid-downtime { background:#e8f6ed; color:#316a45; }
.grid-buffer { background:#fff4d9; color:#805a14; }
.grid-conflict { background:#ffe1e1; color:#9c2929; border-color:#d97979; }
.calendar-card { overflow:auto; }
.day-itinerary .timeline-row {
  grid-template-columns:72px 14px minmax(0,1fr);
  min-height:52px;
}
.day-itinerary .timeline-content { padding:8px 9px; }
.day-itinerary .timeline-time { font-size:10px; }
.agenda-view .timeline-row { max-width:900px; }
.calendar-layout { grid-template-columns:minmax(0,1fr) 330px; }

/* Settings */
.settings-place-layout {
  display:grid;
  grid-template-columns:minmax(320px,.9fr) minmax(360px,1.1fr);
  gap:16px;
}
.saved-place-list { display:grid; gap:10px; }
.saved-place-card {
  display:flex;
  justify-content:space-between;
  gap:12px;
  border:1px solid #e0e5ec;
  border-radius:12px;
  padding:12px;
  background:#fafbfd;
}
.saved-place-card strong,
.saved-place-card span,
.saved-place-card small { display:block; }
.saved-place-card span { margin-top:3px; color:#59677e; }
.saved-place-card small { margin-top:3px; color:#7a8598; }
.saved-place-actions { display:flex; gap:6px; flex-shrink:0; }
.field-help { display:block; margin-top:5px; color:#79859a; font-size:11px; }

/* JS dynamically sets the number of time columns */
.time-grid-shell:has(.day-header:nth-child(2):last-child),
.time-grid-shell.day-view { --day-count:1; }
.time-grid-shell { --day-count:7; }

@media(max-width:1150px) {
  .home-layout { grid-template-columns:1fr; }
  .home-chat { position:static; }
  .chat-card { height:700px; }
  .calendar-layout { grid-template-columns:1fr; }
  .calendar-side { grid-template-columns:repeat(2,minmax(0,1fr)); display:grid; gap:16px; }
}
@media(max-width:850px) {
  .summary-strip { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .home-lower-grid,
  .compact-days,
  .settings-place-layout { grid-template-columns:1fr; }
  .calendar-side { grid-template-columns:1fr; }
  .timeline-row { grid-template-columns:80px 16px minmax(0,1fr); }
}
@media(max-width:600px) {
  .summary-strip { grid-template-columns:1fr; }
  .home-layout { display:block; }
  .home-chat { margin-top:16px; }
  .chat-card { min-height:600px; height:75vh; }
  .timeline-time { font-size:10px; }
  .inline-search { grid-template-columns:1fr; }
}


/* V5.1 calendar readability and combined arrival-buffer travel */
.time-grid-shell.time-day-grid { min-width: 820px; }
.time-grid-shell.time-week-grid { min-width: 1780px; }
.time-grid-header,
.all-day-row {
  grid-template-columns: 68px repeat(var(--day-count,7), minmax(240px,1fr));
}
.time-grid-body { grid-template-columns: 68px minmax(0,1fr); }
.time-day-columns {
  grid-template-columns: repeat(var(--day-count,7), minmax(240px,1fr));
}
.time-day-column {
  --event-lane-right: 35%;
  --travel-lane-left: 67%;
}
.lane-divider {
  position:absolute;
  top:0;
  bottom:0;
  left:65%;
  border-left:1px dashed #d6dde8;
  pointer-events:none;
  z-index:1;
}
.grid-block {
  padding:5px 7px;
  min-height:0;
  overflow:hidden;
  z-index:3;
}
.grid-event {
  left:5px;
  right:var(--event-lane-right);
  background:#dce8f6;
  color:#203a5b;
}
.grid-travel,
.grid-downtime {
  left:var(--travel-lane-left);
  right:5px;
}
.grid-block strong,
.grid-block span {
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.grid-block strong { font-size:12px; line-height:1.15; }
.grid-time { font-size:10px !important; opacity:.82; margin-top:2px; }
.grid-subtitle { font-size:10px !important; margin-top:2px; }
.grid-detail { font-size:9px !important; margin-top:3px; opacity:.86; }
.grid-weather {
  font-size:9px !important;
  margin-top:4px;
  padding-top:3px;
  border-top:1px solid #ffffff80;
  opacity:.95;
}
.grid-block.compact .grid-detail,
.grid-block.compact .grid-weather { display:none; }
.grid-block.tiny {
  padding:3px 5px;
  border-radius:5px;
}
.grid-block.tiny strong { font-size:10px; }
.grid-block.tiny .grid-time,
.grid-block.tiny .grid-subtitle,
.grid-block.tiny .grid-detail,
.grid-block.tiny .grid-weather { display:none; }
.grid-travel { background:#edf4fb; color:#315c82; border:1px dashed #73a0c6; }
.grid-downtime { background:#e8f6ed; color:#316a45; }
.grid-conflict { background:#ffe1e1; color:#9c2929; border-color:#d97979; }
.all-day-cell button strong,
.all-day-cell button small { display:block; }
.all-day-cell button small { margin-top:3px; font-size:9px; color:#53667e; }
.month-event { white-space:normal; }
.month-event span,
.month-event small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.month-event small { font-size:9px; opacity:.8; margin-top:2px; }
.buffer-row,
.grid-buffer { display:none !important; }
@media(max-width:900px) {
  .time-grid-shell.time-week-grid { min-width:1680px; }
  .time-grid-shell.time-day-grid { min-width:720px; }
}


/* V5.2 aligned calendar columns */
.calendar-card {
  overflow:auto;
  max-height:calc(100vh - 220px);
}
.time-grid-shell {
  overflow:visible !important;
  width:max-content;
  min-width:100%;
}
.time-grid-header,
.all-day-row {
  grid-template-columns:76px repeat(var(--day-count,7), minmax(230px,1fr)) !important;
  width:100%;
}
.time-grid-header {
  position:sticky;
  top:0;
  z-index:12;
}
.all-day-row {
  position:sticky;
  top:47px;
  z-index:11;
  box-shadow:0 2px 5px #1720330c;
}
.time-grid-body {
  grid-template-columns:76px minmax(0,1fr) !important;
  overflow:visible !important;
  max-height:none !important;
  width:100%;
}
.time-axis {
  position:sticky;
  left:0;
  z-index:9;
}
.time-day-columns {
  grid-template-columns:repeat(var(--day-count,7), minmax(230px,1fr)) !important;
}
.time-day-column {
  --event-lane-right:5px !important;
  --travel-lane-left:5px !important;
  min-width:230px;
}
.lane-divider { display:none !important; }
.grid-event,
.grid-travel,
.grid-downtime {
  left:5px !important;
  right:5px !important;
}
.grid-travel { z-index:5; }
.grid-event { z-index:4; }
.grid-downtime { z-index:2; }
.grid-conflict {
  left:42% !important;
  z-index:7;
}
.all-day-cell,
.time-day-column {
  box-sizing:border-box;
}
.time-day-grid .all-day-cell,
.time-day-grid .time-day-column {
  min-width:620px;
}

/* Event editor */
.modal-panel {
  width:min(760px, calc(100vw - 28px));
  max-height:92vh;
  overflow:auto;
}
.event-editor {
  display:grid;
  gap:14px;
}
.event-editor-section {
  border:1px solid #e1e6ed;
  border-radius:14px;
  padding:16px;
  background:#fbfcfe;
}
.event-editor-section label > input,
.event-editor-section label > textarea {
  margin-top:6px;
}
.event-title-field input {
  font-size:18px;
  font-weight:700;
  padding:14px 15px;
}
.event-editor-section-heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:18px;
  margin-bottom:13px;
}
.event-editor-section-heading h3 {
  margin:0;
  font-size:17px;
}
.event-editor-section-heading p {
  margin:4px 0 0;
  color:#738096;
  font-size:12px;
  line-height:1.4;
}
.segmented-control {
  display:inline-grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:4px;
  padding:4px;
  border-radius:12px;
  background:#e8edf4;
  margin-bottom:14px;
}
.segmented-control button {
  border:0;
  background:transparent;
  color:#536078;
  border-radius:9px;
  padding:9px 16px;
  font-weight:750;
}
.segmented-control button.active {
  background:white;
  color:#172033;
  box-shadow:0 2px 8px #17203318;
}
.all-day-toggle {
  display:flex;
  align-items:center;
  gap:8px;
  padding:8px 11px;
  border:1px solid #d6dde7;
  border-radius:10px;
  background:white;
  white-space:nowrap;
}
.all-day-toggle input {
  width:17px;
  height:17px;
}
.event-date-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}
.event-time-grid {
  margin-top:12px;
  display:grid;
  grid-template-columns:minmax(0,1fr) 36px minmax(0,1fr);
  gap:8px;
  align-items:end;
}
.event-date-grid label,
.event-time-grid label {
  font-size:12px;
  font-weight:750;
  color:#536078;
}
.event-date-grid input,
.event-time-grid input {
  width:100%;
  margin-top:6px;
  padding:12px;
  font-size:15px;
  background:white;
}
.time-arrow {
  display:grid;
  place-items:center;
  height:44px;
  color:#79869a;
  font-size:20px;
}
.event-weather-preview {
  min-height:72px;
  border-radius:11px;
  background:#eef4fb;
  padding:12px;
}
.event-preview-empty {
  color:#718096;
  line-height:1.45;
}
.event-preview-summary {
  display:flex;
  justify-content:space-between;
  gap:12px;
  margin-bottom:9px;
}
.event-preview-summary span {
  color:#62728b;
  font-size:12px;
}
.event-preview-days {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(145px,1fr));
  gap:8px;
}
.event-preview-days > div {
  background:white;
  border-radius:9px;
  padding:9px;
  display:grid;
  gap:3px;
}
.event-preview-days span,
.event-preview-days small {
  color:#66748a;
  font-size:11px;
}

/* General settings */
.settings-general-grid {
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(310px,.65fr);
  gap:16px;
}
.settings-form {
  margin-top:6px;
}
.settings-field-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}
.settings-field-grid label {
  font-size:12px;
  font-weight:750;
  color:#536078;
}
.settings-field-grid input,
.settings-field-grid select {
  width:100%;
  margin-top:6px;
}
.number-with-unit {
  position:relative;
}
.number-with-unit input {
  padding-right:78px;
}
.number-with-unit span {
  position:absolute;
  right:12px;
  top:50%;
  transform:translateY(-15%);
  color:#7b8798;
  font-size:11px;
  pointer-events:none;
}
.settings-switches {
  display:grid;
  gap:8px;
  margin-top:4px;
}
.setting-switch {
  display:grid;
  grid-template-columns:22px minmax(0,1fr);
  gap:10px;
  align-items:start;
  border:1px solid #e0e5ed;
  border-radius:11px;
  padding:11px;
  background:#fafbfd;
}
.setting-switch input {
  width:18px;
  height:18px;
  margin-top:2px;
}
.setting-switch strong,
.setting-switch small {
  display:block;
}
.setting-switch small {
  margin-top:3px;
  color:#768297;
  font-weight:400;
  line-height:1.35;
}
.settings-save-status {
  align-self:center;
  color:#6a768a;
  font-size:13px;
}
.settings-save-status.success { color:#287348; }
.settings-save-status.error { color:#a93232; }

@media(max-width:1000px) {
  .settings-general-grid {
    grid-template-columns:1fr;
  }
}
@media(max-width:650px) {
  .event-date-grid,
  .settings-field-grid {
    grid-template-columns:1fr;
  }
  .event-time-grid {
    grid-template-columns:1fr;
  }
  .time-arrow {
    height:auto;
    transform:rotate(90deg);
  }
  .event-editor-section-heading {
    flex-direction:column;
  }
}


/* V6.1 Home reflow and form polish */
.home-layout {
  align-items:stretch;
}
.home-left,
.home-chat {
  min-width:0;
}
.home-left > .card,
.home-chat,
.chat-card {
  height:560px;
  min-height:560px;
}
.home-left > .card {
  display:flex;
  flex-direction:column;
}
.home-left #home-timeline {
  flex:1;
  min-height:0;
  overflow:auto;
}
.home-chat {
  position:static;
}
.chat-card {
  max-height:560px;
}
.home-lower-grid {
  margin-bottom:16px;
}
.v61-home-search-card {
  position:relative;
  padding:10px 13px;
  margin-bottom:15px;
  z-index:30;
}
.v61-home-search-row {
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;
  gap:10px;
  align-items:center;
}
.v61-home-search-row input {
  width:100%;
  border:0;
  box-shadow:none;
  font-size:16px;
  padding:9px 2px;
}
.v61-search-icon {
  width:32px;
  height:32px;
  display:grid;
  place-items:center;
  border-radius:10px;
  background:#edf1f6;
  color:#506078;
  font-size:20px;
}
#v6-home-search-results {
  position:absolute;
  left:0;
  right:0;
  top:calc(100% + 6px);
  max-height:420px;
  overflow:auto;
  padding:8px 13px;
  background:white;
  border-radius:14px;
  box-shadow:0 20px 50px #1720332b;
  border:1px solid #dfe5ed;
}

.event-editor-section label,
.event-editor-section input,
.event-editor-section textarea,
.event-editor-section select,
.event-title-field,
#event-title,
#event-location,
#event-description {
  width:100%;
  min-width:0;
}
.event-editor-section label {
  display:grid;
  gap:6px;
}
.event-editor-section input,
.event-editor-section textarea,
.event-editor-section select {
  display:block;
}
.event-editor-section textarea {
  resize:vertical;
}
.free-slot-button {
  width:100%;
  border:1px solid #dfe5ed;
  background:#fafbfd;
  border-radius:11px;
  padding:11px 12px;
  margin:7px 0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  text-align:left;
}
.free-slot-button:hover {
  background:#eef4fb;
  border-color:#8fa3bd;
}
.free-slot-button strong,
.free-slot-button small {
  display:block;
}
.free-slot-button small {
  margin-top:4px;
  color:#758197;
}
.free-slot-button > span {
  color:#315d94;
  font-weight:750;
  white-space:nowrap;
}

@media(max-width:1100px) {
  .home-left > .card,
  .home-chat,
  .chat-card {
    height:auto;
    min-height:520px;
  }
}


/* V6.2 chat activity feedback */
.message.thinking {
  display:flex;
  align-items:center;
  gap:9px;
  color:#5d6a80;
  min-height:44px;
}
.chat-thinking-spinner {
  width:17px;
  height:17px;
  border:2px solid #c7d0dd;
  border-top-color:#263b5d;
  border-radius:50%;
  flex:0 0 auto;
  animation:chat-thinking-spin .85s linear infinite;
}
.chat-thinking-text {
  animation:chat-thinking-pulse 1.4s ease-in-out infinite;
}
@keyframes chat-thinking-spin {
  to { transform:rotate(360deg); }
}
@keyframes chat-thinking-pulse {
  0%,100% { opacity:.58; }
  50% { opacity:1; }
}


/* V6.3 — general AI chat removed */
.home-layout {
  display:block !important;
  grid-template-columns:1fr !important;
}
.home-left {
  width:100%;
}
.home-left > .card {
  width:100%;
  height:auto !important;
  min-height:560px;
}
.home-left #home-timeline {
  max-height:760px;
}
.home-chat,
.chat-card {
  display:none !important;
}
@media(max-width:1100px) {
  .home-left > .card {
    min-height:500px;
  }
}


/* V7 unified one-page dashboard */
html { scroll-behavior:smooth; }
body { background:#eef2f7; }
.app.v7-unified-app { display:block !important; min-height:100vh; }
.sidebar { display:none !important; }
.v7-unified-main {
  width:min(1540px, calc(100% - 36px));
  margin:0 auto;
  padding:24px 0 54px !important;
}
.v7-topbar {
  position:sticky;
  top:0;
  z-index:70;
  background:rgba(255,255,255,.94);
  backdrop-filter:blur(16px);
  border-bottom:1px solid #dfe5ed;
  box-shadow:0 7px 24px #1720330c;
}
.v7-topbar-inner {
  width:min(1540px, calc(100% - 36px));
  min-height:72px;
  margin:0 auto;
  display:grid;
  grid-template-columns:minmax(230px,1fr) auto auto;
  align-items:center;
  gap:18px;
}
.v7-brand { display:flex; align-items:center; gap:11px; min-width:0; }
.v7-brand strong,.v7-brand small { display:block; }
.v7-brand strong { font-size:17px; }
.v7-brand small { color:#758096; margin-top:2px; }
.v7-service-status {
  display:flex;
  align-items:center;
  gap:8px;
  padding:7px 10px;
  border-radius:999px;
  background:#f3f6fa;
  white-space:nowrap;
}
.v7-service-status .status { margin:0; color:#34425a; }
.v7-service-status .status.good { color:#247046; }
.v7-service-status .status.bad { color:#a52d2d; }
.v7-service-status small { color:#758096; }
.v7-top-actions { display:flex; gap:8px; align-items:center; justify-content:flex-end; }
.v7-icon-button {
  width:42px; height:42px; border:0; border-radius:11px;
  background:#e8edf4; color:#172033; font-size:20px; font-weight:800;
}
.v7-icon-button:hover { background:#dce3ec; }
.v7-dashboard-intro { margin:5px 0 18px; }
.v7-dashboard-intro h1 { margin:0; font-size:32px; letter-spacing:-.03em; }
.v7-dashboard-intro p { margin:6px 0 0; color:#68748a; }
#page-home { display:block !important; max-width:none !important; }
.v7-dashboard-section { display:block; scroll-margin-top:92px; margin:18px 0; }
.v7-calendar-section > .page-header {
  margin:0 0 12px;
  padding:0 2px;
}
.v7-calendar-section .calendar-layout {
  grid-template-columns:minmax(0,1fr) 330px;
}
.v7-calendar-section .calendar-card { min-height:520px; }
.v7-calendar-section .agenda-view { max-width:none; }
.v7-calendar-section .agenda-day {
  background:#fff;
  border:1px solid #e2e7ee;
  border-radius:14px;
  padding:14px;
  margin-bottom:12px;
}
.v7-calendar-section .agenda-day h3 {
  position:sticky;
  top:82px;
  z-index:3;
  margin:-14px -14px 10px;
  padding:12px 14px;
  background:#fff;
  border-bottom:1px solid #e7ebf1;
  border-radius:14px 14px 0 0;
}
.v7-overlay-panel {
  position:fixed;
  inset:0;
  z-index:120;
  overflow:auto;
  padding:24px max(20px, calc((100vw - 1380px)/2));
  background:#eef2f7;
}
.v7-overlay-panel.v7-open { display:block !important; }
.v7-overlay-header { position:sticky; top:0; z-index:5; padding:12px 0; background:#eef2f7f2; backdrop-filter:blur(12px); }
body.v7-overlay-active { overflow:hidden; }
#page-trips,#page-settings { max-width:none !important; }
.home-lower-grid { margin-top:16px; }
@media(max-width:1120px) {
  .v7-topbar-inner { grid-template-columns:1fr auto; padding:9px 0; }
  .v7-service-status { display:none; }
  .v7-calendar-section .calendar-layout { grid-template-columns:1fr; }
}
@media(max-width:760px) {
  .v7-topbar-inner { width:calc(100% - 20px); grid-template-columns:1fr; gap:8px; }
  .v7-brand { padding-top:4px; }
  .v7-top-actions { justify-content:flex-start; overflow-x:auto; padding-bottom:5px; }
  .v7-top-actions button { white-space:nowrap; }
  .v7-unified-main { width:calc(100% - 20px); padding-top:14px !important; }
  .calendar-toolbar { grid-template-columns:1fr; }
  .view-tabs { overflow-x:auto; }
  .v7-overlay-panel { padding:12px; }
}
html[data-theme="dark"] .v7-topbar,
html[data-theme="dark"] .v7-overlay-header {
  background:rgba(17,24,39,.94);
  border-color:#374151;
  color:#e6ebf2;
}
html[data-theme="dark"] .v7-service-status {
  background:#1f2937;
}
html[data-theme="dark"] .v7-brand small,
html[data-theme="dark"] .v7-service-status small,
html[data-theme="dark"] .v7-dashboard-intro p {
  color:#aeb8ca;
}
html[data-theme="dark"] .v7-calendar-section .agenda-day,
html[data-theme="dark"] .v7-calendar-section .agenda-day h3 {
  background:#1f2937;
  border-color:#374151;
}


/* V7.1 remote account */
.v71-account {
  display:flex;
  align-items:center;
  gap:8px;
  border-left:1px solid #dce3ec;
  padding-left:12px;
  margin-left:3px;
}
.v71-account img,
.v71-account-fallback {
  width:34px;
  height:34px;
  border-radius:50%;
  object-fit:cover;
}
.v71-account-fallback {
  display:grid;
  place-items:center;
  background:#172033;
  color:white;
  font-weight:800;
}
.v71-account div {
  max-width:155px;
}
.v71-account strong,
.v71-account small {
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.v71-account strong {
  font-size:12px;
}
.v71-account small {
  color:#738096;
  font-size:10px;
}
.v71-account a,
.v71-sign-in {
  color:#405675;
  font-weight:750;
  font-size:12px;
  text-decoration:none;
}
.v71-account a:hover,
.v71-sign-in:hover {
  text-decoration:underline;
}
@media(max-width:1050px) {
  .v71-account div { display:none; }
}


/* V7.2 agenda layout fix
   Agenda uses normal page scrolling instead of a nested calendar scrollbar.
   This removes the empty block below the clipped agenda and prevents date
   headings from floating over unrelated events while the page scrolls. */
.v7-calendar-section {
  margin-bottom:8px;
}
.v7-calendar-section .calendar-layout {
  align-items:start;
}
.v7-calendar-section .calendar-card.agenda-expanded {
  min-height:0 !important;
  max-height:none !important;
  height:auto !important;
  overflow:visible !important;
}
.v7-calendar-section .calendar-card.agenda-expanded #calendar-view {
  overflow:visible;
}
.v7-calendar-section .calendar-card.agenda-expanded .agenda-day h3 {
  position:static !important;
  top:auto !important;
  z-index:auto !important;
}
.v7-calendar-section .calendar-card.agenda-expanded .agenda-day:last-child {
  margin-bottom:0;
}
.v7-calendar-section + .home-lower-grid,
.home-lower-grid {
  margin-top:8px !important;
}

/* Day and week retain their own scrolling area, but it is a little taller so
   less of the schedule is clipped before the next dashboard section. */
.v7-calendar-section .calendar-card:not(.agenda-expanded) {
  max-height:calc(100vh - 155px);
}


/* V7.3 full-width Agenda
   The former two-column calendar kept reserving 330px for the sidebar after
   those cards ended, leaving a long empty strip beside later agenda dates.
   In Agenda view the utility cards become a compact row above the schedule
   and the agenda receives the full dashboard width. */
.v7-calendar-section .calendar-layout.agenda-layout {
  grid-template-columns:minmax(0,1fr) !important;
  grid-template-areas:
    "tools"
    "agenda";
  gap:12px;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
  grid-area:agenda;
  width:100%;
  min-width:0;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
  grid-area:tools;
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(250px,.85fr) minmax(230px,.75fr);
  gap:12px;
  align-items:start;
  width:100%;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
  min-width:0;
  margin:0;
}
.v7-calendar-section .calendar-layout.agenda-layout .day-itinerary {
  max-height:230px;
  overflow:auto;
  padding-right:3px;
}
.v7-calendar-section .calendar-layout.agenda-layout .agenda-view,
.v7-calendar-section .calendar-layout.agenda-layout .agenda-day {
  width:100%;
  max-width:none;
}
.v7-calendar-section .calendar-layout.agenda-layout .agenda-day {
  margin-left:0;
  margin-right:0;
}

@media(max-width:1050px) {
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card:first-child {
    grid-column:1 / -1;
  }
}
@media(max-width:700px) {
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    grid-template-columns:1fr;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card:first-child {
    grid-column:auto;
  }
}


/* V7.4 compact responsive dashboard
   Agenda is a dedicated scroll window again, but the entire calendar area has
   an intentional height. The utility column is the same height, so nothing
   leaves a long blank strip or pushes the rest of the dashboard far down. */
.v7-calendar-section .calendar-layout.agenda-layout {
  display:grid !important;
  grid-template-columns:minmax(0,1fr) 310px !important;
  grid-template-areas:"agenda tools" !important;
  gap:12px !important;
  align-items:stretch !important;
  height:clamp(560px,68vh,760px);
  height:clamp(560px,68dvh,760px);
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
  grid-area:agenda;
  width:100%;
  min-width:0;
  min-height:0 !important;
  max-height:none !important;
  height:100% !important;
  overflow:hidden !important;
  padding:12px;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-card #calendar-view {
  height:100%;
  min-height:0;
  overflow-y:auto !important;
  overflow-x:hidden;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
  -webkit-overflow-scrolling:touch;
  padding-right:4px;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
  grid-area:tools;
  display:flex !important;
  flex-direction:column;
  gap:10px;
  width:100%;
  height:100%;
  min-height:0;
  overflow-y:auto;
  overflow-x:hidden;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;
  -webkit-overflow-scrolling:touch;
  padding-right:3px;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
  flex:0 0 auto;
  min-width:0;
  margin:0;
  padding:14px;
}
.v7-calendar-section .calendar-layout.agenda-layout .day-itinerary {
  max-height:250px;
  overflow:auto;
  padding-right:2px;
}
.v7-calendar-section .calendar-layout.agenda-layout .agenda-view,
.v7-calendar-section .calendar-layout.agenda-layout .agenda-day {
  width:100%;
  max-width:none;
}
.v7-calendar-section .calendar-layout.agenda-layout .agenda-day {
  padding:10px;
  margin:0 0 9px;
  border-radius:11px;
}
.v7-calendar-section .calendar-layout.agenda-layout .agenda-day h3 {
  position:static !important;
  margin:0 0 7px !important;
  padding:0 2px 8px !important;
  border-radius:0 !important;
  background:transparent !important;
}
.v7-calendar-section .calendar-layout.agenda-layout .agenda-view .timeline-row {
  max-width:none;
}
.v7-calendar-section .calendar-layout.agenda-layout .timeline-content {
  padding:8px 10px;
  margin-bottom:6px;
}
.v7-calendar-section .calendar-layout.agenda-layout .timeline-row {
  min-height:48px;
}
.v7-calendar-section .calendar-layout.agenda-layout .timeline-time {
  padding-top:7px;
}

/* Keep the dashboard to roughly one or two useful screens on desktop. */
.v7-dashboard-intro {
  margin-bottom:12px;
}
.summary-strip {
  margin-bottom:12px;
}
.v7-dashboard-section {
  margin:12px 0;
}
.home-lower-grid {
  gap:10px;
  margin-top:10px !important;
}
.v6-home-intelligence {
  gap:10px !important;
  margin:10px 0 !important;
}
.home-lower-grid > .card,
.v6-home-intelligence > .card {
  padding:14px;
}
.v6-home-intelligence > .card {
  max-height:330px;
  overflow:auto;
}

/* Tablet: calendar window remains bounded; utility cards become a swipeable row. */
@media(max-width:980px) {
  .v7-calendar-section .calendar-layout.agenda-layout {
    grid-template-columns:minmax(0,1fr) !important;
    grid-template-areas:
      "agenda"
      "tools" !important;
    height:auto;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
    height:clamp(500px,64vh,680px) !important;
    height:clamp(500px,64dvh,680px) !important;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    display:flex !important;
    flex-direction:row;
    height:auto;
    max-height:none;
    overflow-x:auto;
    overflow-y:hidden;
    scroll-snap-type:x mandatory;
    scrollbar-width:thin;
    padding:2px 0 6px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
    flex:0 0 min(360px,82vw);
    max-height:300px;
    overflow:auto;
    scroll-snap-align:start;
  }
}

/* Phone layout */
@media(max-width:700px) {
  body {
    overflow-x:hidden;
  }
  .v7-topbar {
    position:sticky;
    top:0;
    z-index:80;
  }
  .v7-topbar-inner {
    width:calc(100% - 12px) !important;
    min-height:auto;
    padding:7px 0 !important;
    gap:6px !important;
  }
  .v7-brand strong {
    font-size:15px;
  }
  .v7-brand small,
  .v71-account div,
  .v7-service-status {
    display:none !important;
  }
  .v7-top-actions {
    width:100%;
    justify-content:flex-start !important;
    gap:6px;
    overflow-x:auto;
    overscroll-behavior-x:contain;
    scrollbar-width:none;
    padding-bottom:2px;
  }
  .v7-top-actions::-webkit-scrollbar {
    display:none;
  }
  .v7-top-actions button,
  .v7-top-actions a {
    flex:0 0 auto;
    min-height:38px;
    padding:8px 11px;
    white-space:nowrap;
  }
  .v7-icon-button {
    width:38px;
    height:38px;
  }
  .v71-account {
    padding-left:7px;
    margin-left:0;
  }
  .v71-account img,
  .v71-account-fallback {
    width:30px;
    height:30px;
  }

  .v7-unified-main {
    width:calc(100% - 12px) !important;
    padding:9px 0 24px !important;
  }
  .v7-dashboard-intro h1 {
    font-size:24px;
  }
  .v7-dashboard-intro p {
    font-size:12px;
  }
  .summary-strip {
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    gap:7px;
  }
  .summary-strip > div {
    padding:10px;
    min-height:68px;
  }
  .summary-strip small {
    font-size:10px;
  }
  .summary-strip strong {
    font-size:13px;
    white-space:normal;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
  }

  .v7-calendar-section > .page-header {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:start;
    gap:8px;
  }
  .v7-calendar-section > .page-header h1 {
    font-size:22px;
  }
  .v7-calendar-section > .page-header p {
    display:none;
  }
  .v7-calendar-section > .page-header .header-actions {
    width:auto;
    flex-wrap:nowrap;
  }
  .v7-calendar-section > .page-header .header-actions button {
    padding:8px 10px;
    font-size:12px;
  }

  .calendar-toolbar {
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:7px !important;
    margin-bottom:8px;
  }
  .calendar-nav {
    display:grid;
    grid-template-columns:auto auto auto minmax(0,1fr);
    gap:5px;
    width:100%;
  }
  .calendar-nav button {
    padding:8px 10px;
  }
  .calendar-nav strong {
    min-width:0 !important;
    margin-left:2px !important;
    align-self:center;
    text-align:right;
    font-size:12px;
    line-height:1.2;
  }
  .view-tabs {
    display:grid !important;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:4px;
    width:100%;
    overflow:visible !important;
  }
  .view-tabs button {
    min-width:0;
    padding:8px 4px;
    font-size:11px;
  }
  #calendar-search {
    width:100%;
    max-width:none;
    padding:9px 10px;
  }

  .v7-calendar-section .calendar-layout.agenda-layout {
    gap:8px !important;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
    height:58vh !important;
    height:58dvh !important;
    min-height:420px !important;
    max-height:610px !important;
    padding:7px;
    border-radius:13px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card #calendar-view {
    padding-right:1px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .agenda-day {
    padding:8px;
    margin-bottom:7px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .agenda-day h3 {
    font-size:13px;
    padding-bottom:6px !important;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-row {
    grid-template-columns:58px 11px minmax(0,1fr);
    gap:4px;
    min-height:44px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-time {
    font-size:9px;
    line-height:1.2;
    white-space:normal;
    padding-right:1px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-marker {
    width:10px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-marker::before {
    left:4px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-marker::after {
    left:0;
    width:9px;
    height:9px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-content {
    padding:7px 8px;
    border-radius:9px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-content strong {
    font-size:12px;
    line-height:1.25;
  }
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-content span,
  .v7-calendar-section .calendar-layout.agenda-layout .timeline-content small {
    font-size:10px;
    line-height:1.3;
    overflow-wrap:anywhere;
  }

  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    gap:8px;
    margin:0;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
    flex-basis:86vw;
    max-height:270px;
    padding:12px;
    border-radius:13px;
  }

  /* Swipeable compact cards prevent the lower dashboard from becoming a very
     long phone page while keeping every feature available. */
  .home-lower-grid,
  .v6-home-intelligence {
    display:flex !important;
    grid-template-columns:none !important;
    gap:8px !important;
    overflow-x:auto;
    overflow-y:hidden;
    scroll-snap-type:x mandatory;
    overscroll-behavior-x:contain;
    scrollbar-width:none;
    padding:1px 0 7px;
  }
  .home-lower-grid::-webkit-scrollbar,
  .v6-home-intelligence::-webkit-scrollbar {
    display:none;
  }
  .home-lower-grid > .card,
  .v6-home-intelligence > .card {
    flex:0 0 88vw;
    min-width:0;
    max-height:310px;
    overflow:auto;
    scroll-snap-align:start;
    padding:12px;
  }
  .v6-week-load {
    height:125px;
  }
  .insight-grid {
    grid-template-columns:1fr !important;
  }

  .card {
    border-radius:13px;
  }
  .modal-panel,
  .v6-trip-modal-panel,
  .v61-trip-assistant-panel {
    width:100vw !important;
    max-width:none !important;
    height:100vh !important;
    height:100dvh !important;
    max-height:none !important;
    margin:0 !important;
    border-radius:0 !important;
    padding:13px !important;
  }
  .v7-overlay-panel {
    padding:8px !important;
  }
  .v6-trip-sidebar {
    position:static !important;
    max-height:none !important;
  }
  #v6-trip-list {
    display:flex;
    gap:7px;
    overflow-x:auto;
    scroll-snap-type:x mandatory;
  }
  .v6-trip-list-item {
    flex:0 0 78vw;
    scroll-snap-align:start;
  }
  .v6-trip-header-card {
    padding:12px;
  }
  .v6-trip-tabs {
    position:sticky;
    top:0;
    z-index:4;
    background:#eef2f7;
    padding:5px 0;
  }
  .v6-itinerary-item {
    grid-template-columns:70px minmax(0,1fr) !important;
    gap:8px;
    padding:9px;
  }
  .v6-itinerary-item > b {
    grid-column:2;
  }
}

/* Very small phones */
@media(max-width:390px) {
  .summary-strip {
    grid-template-columns:1fr 1fr !important;
  }
  .calendar-nav strong {
    font-size:10px;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
    min-height:390px !important;
  }
  .home-lower-grid > .card,
  .v6-home-intelligence > .card {
    flex-basis:91vw;
  }
}


/* V7.5 utility-panel correction
   Only the Agenda itself should have an internal vertical scrollbar.
   The selected-day itinerary, free-time finder, and travel-plan cards now
   participate in normal page layout and never create a second vertical
   scrolling column. */
.v7-calendar-section .calendar-layout.agenda-layout {
  height:auto !important;
  min-height:clamp(560px,68vh,760px);
  min-height:clamp(560px,68dvh,760px);
  align-items:start !important;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
  height:clamp(560px,68vh,760px) !important;
  height:clamp(560px,68dvh,760px) !important;
  align-self:start;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
  height:auto !important;
  min-height:0 !important;
  max-height:none !important;
  overflow:visible !important;
  scrollbar-gutter:auto !important;
  padding-right:0 !important;
  align-self:start;
}
.v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
  max-height:none !important;
  overflow:visible !important;
}
.v7-calendar-section .calendar-layout.agenda-layout .day-itinerary {
  max-height:none !important;
  overflow:visible !important;
  padding-right:0 !important;
}

/* Tablet: utilities form a normal responsive grid rather than a swipe/scroll
   strip. */
@media(max-width:980px) {
  .v7-calendar-section .calendar-layout.agenda-layout {
    min-height:0;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    display:grid !important;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:10px;
    width:100%;
    overflow:visible !important;
    padding:0 !important;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
    width:auto;
    max-height:none !important;
    overflow:visible !important;
    scroll-snap-align:none;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card:first-child {
    grid-column:1 / -1;
  }
}

/* Phone: utility cards stack beneath the Agenda with no nested scrolling. */
@media(max-width:700px) {
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    display:grid !important;
    grid-template-columns:1fr;
    gap:8px;
    overflow:visible !important;
  }
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card,
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card:first-child {
    grid-column:auto;
    width:100%;
    max-height:none !important;
    overflow:visible !important;
  }
}


/* V7.6 Agenda and utility alignment
   The right column now contains only the selected-day summary and Find free
   time. Both columns share the same intentional height, and Find free time is
   given more horizontal space. */
@media(min-width:981px) {
  .v7-calendar-section .calendar-layout.agenda-layout {
    grid-template-columns:minmax(0,1fr) minmax(360px,400px) !important;
    height:clamp(660px,78vh,860px) !important;
    height:clamp(660px,78dvh,860px) !important;
    min-height:660px !important;
    align-items:stretch !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
    height:100% !important;
    min-height:0 !important;
    align-self:stretch !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    display:grid !important;
    grid-template-rows:minmax(190px,.72fr) minmax(350px,1.28fr);
    gap:12px;
    height:100% !important;
    min-height:0 !important;
    align-self:stretch !important;
    overflow:visible !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card {
    width:100%;
    min-width:0;
    height:100%;
    min-height:0;
    margin:0;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .day-itinerary-card {
    display:flex;
    flex-direction:column;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .day-itinerary-card .day-itinerary {
    flex:1;
    min-height:0;
    overflow:hidden !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card {
    padding:18px;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:11px 12px;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form > label:nth-of-type(3),
  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form > .two-inputs,
  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form > button {
    grid-column:1 / -1;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card input,
  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card select,
  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card button {
    width:100%;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card .two-inputs {
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:12px;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card #free-time-results {
    margin-top:12px;
  }
}

/* Tablet keeps the Agenda window long, with the two utility cards beneath it
   in equal-width columns. */
@media(min-width:701px) and (max-width:980px) {
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
    height:clamp(600px,72vh,780px) !important;
    height:clamp(600px,72dvh,780px) !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side {
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-side > .card:first-child {
    grid-column:auto !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:10px;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form > label:nth-of-type(3),
  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form > .two-inputs,
  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card form > button {
    grid-column:1 / -1;
  }
}

/* Phone gets a taller Agenda window while the two utilities remain ordinary,
   non-scrollable cards underneath. */
@media(max-width:700px) {
  .v7-calendar-section .calendar-layout.agenda-layout > .calendar-card {
    height:66vh !important;
    height:66dvh !important;
    min-height:470px !important;
    max-height:680px !important;
  }

  .v7-calendar-section .calendar-layout.agenda-layout .free-time-card {
    padding:14px;
  }
}
