:root {
  --paper: #F6F3ED;
  --paper2: #FFFAF2;
  --ink: #111820;
  --muted: #73808D;
  --blue: #2D86F7;
  --blue2: #86C8F8;
  --red: #DC1118;
  --pink: #F5BBC5;
  --card: #CBD5DF;
  --card2: #E3E9EE;
  --line: #D6DCE1;
  --navy: #12314E;
  --shadow: 0 20px 55px rgba(21,35,52,.14);
  --safe-bottom: max(14px,env(safe-area-inset-bottom));
}

* {
  box-sizing: border-box;
}

html,body {
  margin: 0;
  min-height: 100%;
  background: #E9EDF1;
  color: var(--ink);
  font-family: Inter,Arial,Helvetica,sans-serif;
}

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

button {
  cursor: pointer;
}

button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible {
  outline: 3px solid rgba(45,134,247,.25);
  outline-offset: 2px;
}

[hidden] {
  display: none !important;
}

.app {
  width: 100%;
  min-height: 100dvh;
  background: var(--paper);
  margin: auto;
  position: relative;
}

.app-shell {
  min-height: 100dvh;
  padding-bottom: 102px;
}

.desktop-bar {
  display: none;
}

.mobile-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 14px 4px;
  font-size: 12px;
  font-weight: 850;
  color: #52606D;
}

.mobile-top>div {
  display: flex;
  align-items: center;
  gap: 5px;
}

.top-mini {
  border: 0;
  background: transparent;
  color: inherit;
  font-weight: 850;
  padding: 6px;
}

.home-btn {
  border: 0;
  background: var(--paper2);
  border-radius: 999px;
  padding: 7px 10px;
  font-weight: 900;
  color: var(--navy);
  box-shadow: 0 3px 10px rgba(0,0,0,.06);
}

.page {
  display: none;
  padding: 14px 20px 30px;
}

.page.active {
  display: block;
}

.hero-row {
  display: block;
}

.title-pill {
  width: 100%;
  min-height: 58px;
  border-radius: 30px;
  background: var(--blue);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  font-size: 28px;
  font-weight: 650;
}

.subnav {
  display: flex;
  gap: 8px;
  margin: 12px 0 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.subnav::-webkit-scrollbar {
  display: none;
}

.subtab {
  flex: 1 0 88px;
  height: 48px;
  border: 0;
  border-radius: 24px;
  background: var(--pink);
  color: var(--red);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 6px 9px;
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}

.subtab .ico {
  font-size: 17px;
  line-height: 1;
}

.subtab.active {
  background: var(--red);
  color: white;
}

.panel {
  display: none;
}

.panel.active {
  display: block;
}

.frame-offset {
  margin-top: 28px;
}

.card {
  background: var(--card);
  border-radius: 22px;
  padding: 18px;
}

.card h3 {
  margin: 0 0 8px;
}

.card p {
  margin: 0;
  color: #53616D;
  line-height: 1.55;
}

.btn {
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  background: var(--blue);
  color: white;
  font-weight: 850;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn.secondary {
  background: var(--pink);
  color: var(--red);
}

.btn.ghost {
  background: var(--paper2);
  color: var(--ink);
  border: 1px solid var(--line);
}

.grid {
  display: grid;
  gap: 12px;
}

.two,.three {
  grid-template-columns: 1fr;
}

.four {
  grid-template-columns: repeat(2,1fr);
}

.tiny {
  font-size: 11px;
  color: var(--muted);
}

.kicker {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-weight: 900;
  color: #53616D;
}

.action-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.section-custom {
  margin-top: 16px;
  background: var(--card2);
  border-radius: 18px;
  overflow: hidden;
}

.section-custom img {
  width: 100%;
  max-height: 280px;
  object-fit: cover;
  display: block;
}

.section-custom-text {
  padding: 15px;
  color: #53616D;
  line-height: 1.55;
  white-space: pre-wrap;
}

/*Home*/

.home-intro {
  border-radius: 26px;
  background: linear-gradient(145deg,#0D3156,#1A5C98);
  color: white;
  padding: 26px;
  min-height: 205px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  margin-top: 28px;
}

.home-intro h1 {
  font-size: 38px;
  line-height: .98;
  margin: 0 0 10px;
  letter-spacing: -.035em;
}

.home-intro p {
  margin: 0;
  color: rgba(255,255,255,.82);
  line-height: 1.5;
}

.home-grid {
  display: grid;
  grid-template-columns: repeat(2,1fr);
  gap: 12px;
  margin-top: 14px;
}

.home-card {
  min-height: 142px;
  border: 0;
  border-radius: 24px;
  background: var(--card);
  text-align: left;
  padding: 17px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--ink);
  position: relative;
  overflow: hidden;
}

.home-card .home-ico {
  font-size: 27px;
}

.home-card strong {
  font-size: 15px;
}

.home-card small {
  display: block;
  color: #66737F;
  line-height: 1.35;
  margin-top: 4px;
}

.home-card.has-image {
  background-size: cover !important;
  background-position: center !important;
  color: white !important;
}

.home-card.has-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,rgba(0,0,0,.08),rgba(0,0,0,.58));
}

.home-card.has-image>* {
  position: relative;
  z-index: 1;
}

.home-card.has-image small {
  color: rgba(255,255,255,.86);
}

/*Cover*/

.cover-frame {
  border-radius: 25px;
  overflow: hidden;
  background: radial-gradient(circle at 68% 22%,rgba(255,255,255,.2),transparent 24%),linear-gradient(145deg,#0C2E51,#155185 55%,#0B2A49);
  background-size: cover;
  background-position: center;
  min-height: 560px;
  display: flex;
  align-items: flex-end;
  padding: 20px;
}

.cover-card {
  width: 100%;
  background: var(--paper2);
  border-radius: 26px;
  padding: 28px 22px;
  text-align: center;
  box-shadow: 0 12px 30px rgba(0,0,0,.12);
}

.cover-card h1 {
  font-size: 40px;
  line-height: .98;
  margin: 0 0 15px;
  letter-spacing: -.04em;
}

.cover-card .eyebrow {
  font-size: 9px;
  letter-spacing: .24em;
  font-weight: 900;
  margin-bottom: 18px;
}

.cover-card h2 {
  font-size: 22px;
  line-height: 1.1;
  margin: 0;
}

.rule {
  height: 1px;
  background: #C7CDD2;
  margin: 18px 0;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  gap: 4px;
  margin-top: 8px;
}

.count-unit strong {
  display: block;
  font-size: 25px;
}

.count-unit span {
  font-size: 9px;
  color: #63717E;
}

.cover-time {
  font-size: 11px;
  font-weight: 800;
  color: #23496A;
  margin-top: 12px;
}

.cover-tag {
  font-size: 20px;
  font-style: italic;
  color: #21415F;
  margin-top: 14px;
}

.simple-list {
  display: grid;
  gap: 10px;
}

.simple-row {
  background: var(--card);
  border-radius: 18px;
  padding: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

/*Agenda*/

.event-preview {
  background: var(--card);
  border-radius: 24px;
  min-height: 245px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.event-preview-photo {
  width: 100%;
  min-height: 150px;
  border-radius: 18px;
  background-size: cover;
  background-position: center;
  margin-bottom: 16px;
}

.preview-date {
  font-size: 26px;
  font-weight: 900;
  color: var(--red);
  line-height: 1;
}

.preview-month {
  font-size: 38px;
  font-weight: 950;
  color: var(--red);
  line-height: 1;
  margin-top: 4px;
}

.preview-title {
  font-size: 28px;
  font-weight: 950;
  color: var(--red);
  line-height: 1.08;
  margin-top: 8px;
}

.preview-meta {
  font-size: 12px;
  color: #697581;
  margin-top: 12px;
  line-height: 1.5;
}

.calendar-card {
  background: var(--paper2);
  border-radius: 24px;
  padding: 18px;
  margin-top: 16px;
}

.week,.dates {
  display: grid;
  grid-template-columns: repeat(7,1fr);
  gap: 7px;
  text-align: center;
}

.week {
  margin-bottom: 9px;
  font-size: 16px;
}

.week span {
  color: #4A8FD1;
}

.week span:first-child {
  color: #D53B36;
}

.day-cell {
  min-height: 46px;
  border: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: #659FD4;
  font-size: 16px;
  border-radius: 14px;
  padding: 4px;
}

.day-cell.sun {
  color: #D53B36;
}

.day-cell.today {
  background: #E4F1FF;
  font-weight: 950;
}

.day-cell.selected {
  background: #D7EAFF;
  font-weight: 950;
}

.event-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
}

.agenda-events {
  display: grid;
  gap: 10px;
}

.event-card {
  background: var(--card);
  border-radius: 20px;
  padding: 15px;
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 13px;
  align-items: start;
}

.event-card.has-image {
  grid-template-columns: 58px 64px 1fr;
}

.event-thumb {
  width: 58px;
  height: 58px;
  border-radius: 13px;
  object-fit: cover;
}

.event-date {
  background: var(--paper2);
  border-radius: 14px;
  padding: 9px;
  text-align: center;
  color: var(--red);
  font-weight: 900;
}

.event-meta {
  font-size: 11px;
  color: #6B7782;
  margin-top: 5px;
  line-height: 1.45;
}

.todo {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.todo-dot {
  width: 24px;
  height: 24px;
  border: 3px solid var(--red);
  background: var(--pink);
  border-radius: 50%;
  flex: 0 0 auto;
}

/*News*/

.news-card {
  background: var(--card);
  border-radius: 22px;
  padding: 16px;
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 13px;
}

.thumb {
  width: 70px;
  aspect-ratio: 1;
  border-radius: 17px;
  background: linear-gradient(145deg,var(--blue2),#E3EEF7);
  object-fit: cover;
}

.news-card h3 {
  font-size: 16px;
  margin: 2px 0 5px;
}

.news-card p {
  font-size: 13px;
  margin: 0;
  color: #586571;
  line-height: 1.45;
}

.badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 9px;
}

.badge {
  font-size: 10px;
  font-weight: 900;
  background: var(--paper2);
  padding: 5px 8px;
  border-radius: 999px;
}

.news-actions {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 11px;
}

.source-link {
  font-size: 11px;
  color: #245D91;
  text-decoration: underline;
  margin-top: 8px;
  display: inline-block;
}

.post-goal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: .12em;
  color: #5C6C7A;
  font-weight: 800;
}

.post-goal-title {
  font-size: 29px;
  line-height: 1.05;
  margin: 10px 0 16px;
  letter-spacing: -.025em;
}

.goal-panel {
  background: #E5EBEF;
  border-radius: 20px;
  padding: 17px;
}

.goal-progress-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-weight: 900;
}

.goal-bar {
  height: 12px;
  background: #B8C8CF;
  border-radius: 999px;
  overflow: hidden;
  margin: 16px 0;
}

.goal-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg,#A9C0C8,#12334E);
  border-radius: inherit;
}

.goal-metrics {
  display: grid;
  grid-template-columns: repeat(2,1fr);
  gap: 14px;
}

.goal-metric strong {
  display: block;
  font-size: 17px;
}

.goal-metric span {
  font-size: 13px;
}

.goal-updated {
  margin-top: 9px;
  color: #62717F;
  font-size: 12px;
}

.analytics-overview {
  background: linear-gradient(145deg,#DBEEFF,#F6D9DF);
  border-radius: 24px;
  padding: 20px;
}

.analytics-overview strong {
  display: block;
  font-size: 34px;
  margin-top: 5px;
}

.metric strong {
  display: block;
  font-size: 25px;
  margin-top: 5px;
}

/*Forms / Writing / Help*/

.form-grid {
  display: grid;
  gap: 10px;
}

.field label {
  display: block;
  font-size: 11px;
  font-weight: 900;
  margin: 0 0 5px;
  color: #53616D;
}

.field input,.field select,.field textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--paper2);
  border-radius: 14px;
  padding: 11px 12px;
  color: var(--ink);
}

.editor textarea {
  min-height: 210px;
  resize: vertical;
}

.platform-card {
  text-align: center;
  padding: 20px;
  font-weight: 900;
}

.help-form input,.help-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--paper2);
  border-radius: 14px;
  padding: 11px 12px;
  margin-top: 8px;
}

.help-form textarea {
  min-height: 110px;
}

/*Profile*/

.profile-subnav {
  width: 100%;
}

.profile-subnav .subtab {
  flex: 0 0 112px;
}

.profile-content {
  margin-top: 28px;
}

.profile-chip {
  display: inline-flex;
  align-items: center;
  background: var(--red);
  color: white;
  border-radius: 999px;
  padding: 6px 13px;
  margin: 3px 0 0 7px;
  position: relative;
  z-index: 2;
  font-weight: 800;
}

.profile-main-card {
  min-height: 455px;
  background: var(--card);
  border-radius: 24px;
  margin-top: -18px;
  padding: 52px 22px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #75828E;
  font-weight: 850;
}

.profile-lines {
  padding-top: 14px;
}

.profile-line {
  height: 23px;
  border-radius: 999px;
  background: var(--card);
  margin-bottom: 12px;
}

.profile-line.w100 {
  width: 100%;
}

.profile-line.w88 {
  width: 88%;
}

.profile-line.w72 {
  width: 72%;
}

/*Navigation*/

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 80;
  display: grid;
  gap: 4px;
  padding: 9px 8px var(--safe-bottom);
  background: linear-gradient(to top,var(--paper) 80%,rgba(246,243,237,.84));
}

.bottom-btn {
  min-width: 0;
  border: 0;
  background: transparent;
  color: #55718F;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 0;
}

.nav-visual {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--blue2);
  color: white;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 18px;
  box-shadow: 0 7px 15px rgba(53,111,166,.13);
  overflow: hidden;
}

.nav-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.bottom-btn.active .nav-visual {
  background: var(--blue);
  transform: translateY(-1px);
}

.bottom-label {
  font-size: 8px;
  font-weight: 850;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 66px;
}

.bottom-btn.active .bottom-label {
  color: var(--blue);
}

.sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(6,15,24,.34);
  z-index: 110;
}

.more-sheet {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: calc(82px + var(--safe-bottom));
  z-index: 120;
  background: var(--paper2);
  border-radius: 28px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.sheet-grid {
  display: grid;
  grid-template-columns: repeat(2,1fr);
  gap: 10px;
}

.sheet-item {
  border: 0;
  background: var(--card);
  border-radius: 18px;
  padding: 18px 12px;
  text-align: left;
  font-weight: 900;
}

.sheet-item small {
  display: block;
  color: #64717C;
  font-weight: 600;
  margin-top: 5px;
}

.doc-corner {
  position: fixed;
  left: 14px;
  bottom: calc(87px + var(--safe-bottom));
  z-index: 70;
  border: 1px solid #D5CBBB;
  background: var(--paper2);
  border-radius: 18px;
  padding: 9px 12px;
  box-shadow: 0 8px 22px rgba(0,0,0,.10);
  font-weight: 800;
  font-size: 11px;
}

/*Modal / preview*/

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(6,15,24,.48);
  z-index: 600;
  display: grid;
  place-items: center;
  padding: 18px;
}

.dialog {
  width: min(620px,100%);
  max-height: min(90dvh,860px);
  overflow: auto;
  background: var(--paper2);
  border-radius: 28px;
  padding: 22px;
  box-shadow: var(--shadow);
}

.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.dialog-head h2 {
  margin: 0;
}

.close {
  border: 0;
  background: var(--card2);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 22px;
}

.intro-backdrop {
  position: fixed;
  inset: 0;
  z-index: 700;
  background: rgba(6,18,31,.88);
  display: grid;
  place-items: center;
  padding: 18px;
}

.intro {
  width: min(1020px,100%);
  min-height: min(760px,92dvh);
  border-radius: 32px;
  overflow: hidden;
  position: relative;
  background: radial-gradient(circle at 25% 20%,rgba(132,198,246,.27),transparent 30%),linear-gradient(145deg,#0B2B4D,#174F83 52%,#0A2745);
  background-size: cover;
  background-position: center;
  padding: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.intro-card {
  width: min(720px,94%);
  background: var(--paper2);
  padding: 34px 24px;
  border-radius: 28px;
  text-align: center;
  box-shadow: 0 20px 55px rgba(0,0,0,.28);
}

.intro-card h1 {
  font-size: 46px;
  line-height: .96;
  letter-spacing: -.04em;
  margin: 0 0 18px;
}

.intro-card .mini {
  letter-spacing: .24em;
  font-size: 10px;
  font-weight: 900;
  margin-bottom: 22px;
}

.intro-card h2 {
  font-size: 24px;
  line-height: 1.15;
  margin: 0;
}

.intro-enter {
  margin-top: 24px;
}

.intro-options {
  margin-top: 14px;
  font-size: 11px;
  color: #67727C;
}

.intro-close {
  position: absolute;
  top: 14px;
  right: 14px;
  border: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,.9);
  font-size: 22px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 124px;
  transform: translateX(-50%);
  z-index: 900;
  background: #142535;
  color: white;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  box-shadow: var(--shadow);
}

/*Admin*/

.admin-workspace {
  position: fixed;
  z-index: 500;
  left: 10px;
  right: 10px;
  bottom: 88px;
  max-height: 65dvh;
  overflow: auto;
  background: rgba(255,250,242,.99);
  border: 1px solid #D8CFDF;
  border-radius: 24px;
  box-shadow: 0 22px 60px rgba(20,18,30,.24);
  padding: 14px;
  backdrop-filter: blur(16px);
}

.admin-workspace[hidden] {
  display: none !important;
}

.aw-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.aw-title {
  font-weight: 950;
}

.aw-head-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

.aw-head-btn {
  border: 0;
  border-radius: 999px;
  padding: 7px 9px;
  background: var(--card2);
  font-size: 10px;
  font-weight: 900;
  color: var(--ink);
}

.aw-head-btn:disabled {
  opacity: .4;
  cursor: default;
}

.aw-tabs {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  gap: 6px;
  margin: 12px 0;
}

.aw-tab {
  border: 0;
  border-radius: 14px;
  padding: 9px 6px;
  background: var(--card2);
  color: var(--ink);
  font-size: 11px;
  font-weight: 900;
}

.aw-tab.active {
  background: #7D52B8;
  color: white;
}

.aw-pane {
  display: none;
}

.aw-pane.active {
  display: block;
}

.aw-section {
  border-top: 1px solid var(--line);
  margin-top: 14px;
  padding-top: 14px;
}

.aw-section:first-child {
  border-top: 0;
  margin-top: 0;
  padding-top: 0;
}

.aw-section h3 {
  margin: 0 0 9px;
  font-size: 14px;
}

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

.aw-field label {
  display: block;
  font-size: 10px;
  font-weight: 900;
  color: #65727D;
  margin: 0 0 4px;
}

.aw-field input,.aw-field select,.aw-field textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: white;
  border-radius: 11px;
  padding: 8px 9px;
  color: var(--ink);
}

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

.aw-wide {
  grid-column: 1/-1;
}

.aw-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 11px;
}

.aw-btn {
  border: 0;
  border-radius: 999px;
  padding: 9px 12px;
  font-weight: 900;
  background: var(--navy);
  color: white;
}

.aw-btn.light {
  background: var(--card2);
  color: var(--ink);
}

.aw-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
}

.aw-switch span {
  font-size: 12px;
  font-weight: 750;
}

.aw-card {
  background: var(--card2);
  border-radius: 14px;
  padding: 10px;
  margin-top: 8px;
}

.aw-card strong {
  font-size: 12px;
}

.aw-hex {
  font-family: "Courier New",monospace;
  text-transform: uppercase;
}

.aw-subhead-row {
  display: grid;
  grid-template-columns: auto 68px 1fr;
  gap: 7px;
  align-items: center;
  margin-top: 7px;
}

.aw-nav-row {
  background: var(--card2);
  border-radius: 14px;
  padding: 10px;
  margin-top: 8px;
}

.aw-nav-grid {
  display: grid;
  grid-template-columns: 52px 1fr 72px;
  gap: 7px;
  align-items: center;
}

.aw-nav-img {
  grid-column: 1/-1;
}

body.admin-mode .adminBtn {
  background: #7D52B8 !important;
  color: white !important;
  border-radius: 999px;
}

@media (min-width:700px) {
  body {
    padding: 22px;
  }

  .app {
    max-width: 1120px;
    min-height: calc(100dvh - 44px);
    border-radius: 30px;
    overflow: hidden;
    box-shadow: var(--shadow);
  }

  .app-shell {
    min-height: calc(100dvh - 44px);
    padding-bottom: 108px;
  }

  .page {
    padding: 24px 34px 32px;
  }

  .title-pill {
    max-width: 430px;
    justify-content: flex-start;
    padding-left: 28px;
    font-size: 30px;
  }

  .hero-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
  }

  .subnav {
    width: min(610px,65%);
    margin: 0;
  }

  .subtab {
    height: 54px;
    flex: 1 1 0;
  }

  .two {
    grid-template-columns: repeat(2,1fr);
  }

  .three {
    grid-template-columns: repeat(2,1fr);
  }

  .four {
    grid-template-columns: repeat(4,1fr);
  }

  .home-intro {
    min-height: 255px;
    padding: 32px;
  }

  .home-intro h1 {
    font-size: 50px;
  }

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

  .cover-frame {
    min-height: 650px;
    padding: 34px;
    align-items: center;
    justify-content: flex-end;
  }

  .cover-card {
    width: min(520px,58%);
    padding: 36px 30px;
  }

  .cover-card h1 {
    font-size: 54px;
  }

  .agenda-layout {
    display: grid;
    grid-template-columns: minmax(300px,.82fr) minmax(420px,1.18fr);
    gap: 28px;
    margin-top: 28px;
    align-items: stretch;
  }

  .event-preview {
    min-height: 430px;
  }

  .calendar-card {
    margin-top: 0;
    min-height: 430px;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .day-cell {
    min-height: 52px;
  }

  .goal-metrics {
    grid-template-columns: repeat(4,1fr);
  }

  .form-grid {
    grid-template-columns: repeat(2,1fr);
  }

  .field.wide {
    grid-column: 1/-1;
  }

  .profile-subnav {
    width: min(760px,70%);
  }

  .profile-main-card {
    min-height: 500px;
  }

  .bottom-nav {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: min(760px,calc(100% - 56px));
    bottom: 18px;
    border-radius: 40px;
    padding: 8px 18px;
    background: rgba(246,243,237,.95);
    box-shadow: 0 12px 34px rgba(24,35,55,.14);
    backdrop-filter: blur(12px);
  }

  .bottom-btn {
    flex-direction: row;
    justify-content: center;
    gap: 5px;
  }

  .bottom-label {
    max-width: 86px;
    font-size: 10px;
  }

  .nav-visual {
    width: 44px;
    height: 44px;
  }

  .more-sheet {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: min(680px,calc(100% - 56px));
    bottom: 102px;
  }

  .doc-corner {
    bottom: 22px;
    left: 28px;
  }

  body.admin-mode .bottom-nav {
    left: 22px;
    right: 22px;
    width: auto;
    transform: none;
  }
}

@media (min-width:900px) {
  body.admin-mode .app {
    margin-right: 370px;
    width: calc(100% - 370px);
  }

  body.admin-mode .bottom-nav {
    left: 22px;
    right: 392px;
    width: auto;
    transform: none;
  }

  .admin-workspace {
    left: auto;
    right: 12px;
    top: 12px;
    bottom: 12px;
    width: 346px;
    max-height: none;
    border-radius: 26px;
  }

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

  .aw-wide {
    grid-column: auto;
  }
}

@media (min-width:1100px) {
  body {
    padding: 28px;
  }

  .app {
    max-width: 1440px;
    min-height: calc(100dvh - 56px);
  }

  .app-shell {
    min-height: calc(100dvh - 56px);
    padding-bottom: 34px;
  }

  .mobile-top {
    display: none;
  }

  .desktop-bar {
    display: flex;
    align-items: center;
    gap: 18px;
    height: 82px;
    padding: 0 32px;
    border-bottom: 1px solid var(--line);
    background: rgba(255,255,255,.38);
  }

  .brand {
    font-weight: 950;
    white-space: nowrap;
  }

  .desktop-home {
    border: 0;
    background: var(--paper2);
    border-radius: 999px;
    padding: 8px 12px;
    font-weight: 900;
  }

  .desktop-main-nav {
    display: flex;
    align-items: center;
    gap: 3px;
    flex: 1;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .desk-nav {
    border: 0;
    background: transparent;
    border-bottom: 2px solid transparent;
    padding: 13px 8px;
    font-size: 11px;
    white-space: nowrap;
    color: #35424E;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 5px;
  }

  .desk-nav img {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    object-fit: cover;
  }

  .desk-nav.active {
    border-bottom-color: var(--blue);
    color: var(--blue);
  }

  .desktop-tools {
    display: flex;
    align-items: center;
    gap: 5px;
  }

  .tool {
    border: 0;
    background: transparent;
    padding: 9px 6px;
    font-size: 11px;
    font-weight: 850;
    color: #33414D;
  }

  .page {
    max-width: 1260px;
    margin: auto;
    padding: 36px 44px;
  }

  .title-pill {
    width: 330px;
    flex: 0 0 330px;
  }

  .subnav {
    width: 650px;
    max-width: none;
  }

  .subtab {
    height: 56px;
  }

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

  .home-grid {
    grid-template-columns: repeat(4,1fr);
  }

  .cover-frame {
    min-height: 680px;
  }

  .cover-card {
    width: 56%;
    max-width: 650px;
  }

  .cover-card h1 {
    font-size: 64px;
  }

  .agenda-layout {
    grid-template-columns: minmax(0,42%) minmax(0,58%);
    gap: 42px;
  }

  .event-preview,.calendar-card {
    min-height: 570px;
    border-radius: 34px;
  }

  .preview-date {
    font-size: 36px;
  }

  .preview-month {
    font-size: 58px;
  }

  .preview-title {
    font-size: 40px;
  }

  .week {
    font-size: 24px;
  }

  .day-cell {
    min-height: 68px;
    font-size: 24px;
  }

  .profile-subnav {
    width: 780px;
  }

  .profile-main-card {
    min-height: 560px;
    border-radius: 34px;
  }

  .bottom-nav {
    display: none;
  }

  .doc-corner {
    bottom: 26px;
    left: max(28px,calc((100vw - 1440px)/2 + 28px));
  }

  .more-sheet,.sheet-backdrop {
    display: none !important;
  }

  body.admin-mode .bottom-nav {
    display: none;
  }
}
