/* Notea 7.8.3.0 — Phone-first layout and responsive rules.
   This file preserves cascade order from the consolidated legacy stylesheet. */
:root{
  --notea-violet:#5b45ef;
  --notea-indigo:#26358f;
  --notea-deep:#17235f;
  --notea-lilac:#a78bfa;
  --notea-blue:#4f8fe8;
  --notea-cream:#ffd88b;
  --notea-glass:rgba(255,255,255,.14);
  --notea-soft-shadow:0 18px 44px rgba(53,48,116,.13);
}

/* Shared premium controls */

.module-head-actions{display:flex;align-items:center;gap:9px;justify-self:end}

.module-settings-button,.settings-page-gear{
  width:46px;height:46px;min-width:46px;border:1px solid var(--line);border-radius:15px;
  display:grid;place-items:center;background:var(--paper);color:var(--text);font-size:18px;
  box-shadow:0 8px 24px rgba(38,42,86,.07)
}

.module-settings-button:hover{background:var(--accent-soft);color:var(--accent)}

.settings-page-gear{cursor:default}

.portal-bottom-nav,.notes-bottom-nav{display:none}

.notes-screen-title{display:none}

.hub-header-create{display:none;width:40px;height:40px;min-width:40px;border:1px solid var(--line);border-radius:13px;background:var(--paper);color:var(--text);place-items:center;font-size:25px;line-height:1;box-shadow:0 8px 24px rgba(38,42,86,.07)}

/* Hub — selected option E */

.portal[data-active-module="hub"]{
  background:
    radial-gradient(circle at 86% 12%,rgba(157,126,255,.35),transparent 30%),
    radial-gradient(circle at 10% 78%,rgba(73,126,245,.23),transparent 32%),
    linear-gradient(165deg,#3444bb 0%,#25358f 40%,#17235f 100%);
}

.portal[data-active-module="hub"] .portal-header{
  border-bottom-color:rgba(255,255,255,.1);background:rgba(30,43,126,.58);color:#fff
}

.portal[data-active-module="hub"] .portal-brand strong{color:#fff}

.portal[data-active-module="hub"] .portal-brand small{color:rgba(255,255,255,.7)}

.portal[data-active-module="hub"] .local-pill,
.portal[data-active-module="hub"] .portal-icon-button{
  border-color:rgba(255,255,255,.22);background:rgba(255,255,255,.11);color:#fff;backdrop-filter:blur(18px)
}

.portal[data-active-module="hub"] .portal-main{width:min(760px,calc(100% - 30px));padding-top:26px}

.hub-screen{
  min-height:calc(100dvh - 160px);border:0!important;border-radius:0!important;padding:0!important;
  background:transparent!important;box-shadow:none!important;color:#fff
}

.hub-screen::after{display:none!important}

.hub-hero{position:relative;margin-bottom:18px}

.hub-greeting{padding:2px 2px 14px}

.hub-kicker{margin:0;color:#fff;font-size:clamp(28px,4vw,42px);font-weight:850;letter-spacing:-.045em}

.hub-greeting h1{margin:5px 0 0;color:rgba(255,255,255,.78);font-size:clamp(14px,2vw,18px);font-weight:500;letter-spacing:0}

.hub-search{height:54px;border:1px solid rgba(255,255,255,.27);border-radius:17px;background:rgba(255,255,255,.13);display:flex;align-items:center;gap:12px;padding:0 9px 0 16px;box-shadow:inset 0 1px rgba(255,255,255,.18);backdrop-filter:blur(18px)}

.hub-search>span{font-size:26px;color:rgba(255,255,255,.8)}

.hub-search input{min-width:0;flex:1;border:0;outline:0;background:transparent;color:#fff;font-size:14px}

.hub-search input::placeholder{color:rgba(255,255,255,.7)}

.hub-search button{width:38px;height:38px;border:0;border-radius:12px;background:rgba(255,255,255,.12);color:#fff;font-size:19px}

.premium-hub-grid{grid-template-columns:1fr!important;gap:12px!important}

.premium-hub-grid .hub-card{
  min-height:126px!important;border:1px solid rgba(255,255,255,.45)!important;border-radius:24px!important;padding:19px!important;
  grid-template-columns:64px minmax(0,1fr) 96px 38px!important;gap:15px!important;color:#172047;box-shadow:0 18px 38px rgba(6,13,58,.2),inset 0 1px rgba(255,255,255,.65)!important;
  backdrop-filter:blur(18px);overflow:hidden
}

.premium-hub-grid .hub-card:hover{transform:translateY(-2px) scale(1.005)}

.premium-hub-grid .notes-card{background:linear-gradient(135deg,#fff5dc 0%,#ffd68d 50%,#f1bd63 100%)!important}

.premium-hub-grid .revisits-card{background:linear-gradient(135deg,#f3eaff 0%,#c5a7ff 52%,#9c7ce7 100%)!important}

.premium-hub-grid .ministry-card{background:linear-gradient(135deg,#e6f4ff 0%,#92c5fa 54%,#5c92e5 100%)!important}

.premium-hub-grid .hub-card-icon{
  width:64px;height:64px;border-radius:19px!important;background:rgba(255,255,255,.68)!important;color:inherit!important;
  font-size:29px;box-shadow:0 10px 24px rgba(34,36,86,.11)
}

.premium-hub-grid .hub-card-copy{position:relative;z-index:2}

.premium-hub-grid .hub-card-copy strong{font-size:22px!important;color:#172047;letter-spacing:-.035em}

.premium-hub-grid .hub-card-copy small{max-width:310px;font-size:12px!important;line-height:1.45!important;color:rgba(23,32,71,.72)!important}

.hub-card-art{width:96px;height:72px;opacity:.24;align-self:end;position:relative}

.note-art::before{content:"";position:absolute;inset:8px 18px 0 2px;border:3px solid currentColor;border-radius:8px;transform:rotate(-8deg)}

.note-art::after{content:"≡";position:absolute;right:5px;top:16px;font-size:60px;line-height:1;transform:rotate(22deg)}

.study-art::before{content:"⌁";position:absolute;font-size:82px;line-height:1;right:4px;top:-4px;transform:rotate(-12deg)}

.ministry-art::before{content:"▂▅▇";position:absolute;font-size:58px;letter-spacing:-10px;right:5px;bottom:2px}

.premium-hub-grid .hub-card-arrow{width:36px;height:36px;border:1px solid rgba(255,255,255,.65);border-radius:50%;display:grid;place-items:center;color:#24356d;font-size:26px;background:rgba(255,255,255,.22)}

.premium-summary{margin-top:18px!important;border:0!important;border-radius:22px!important;background:rgba(255,255,255,.09)!important;padding:15px!important;backdrop-filter:blur(18px)}

.premium-summary>header{border:0!important;padding:0 2px 11px!important;align-items:center!important}

.premium-summary h2{color:#fff;font-size:16px!important}

.premium-summary>header button{border:0;background:transparent;color:rgba(255,255,255,.8);font-size:11px}

.premium-summary .summary-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:8px!important;padding:0!important}

.premium-summary .summary-grid>div{display:flex!important;flex-direction:column;align-items:center;text-align:center;gap:5px;padding:12px 6px!important;border:1px solid rgba(255,255,255,.13);border-radius:16px;background:rgba(255,255,255,.08)}

.premium-summary .summary-icon{width:35px;height:35px;border-radius:11px;grid-row:auto;background:rgba(255,255,255,.14)!important;color:#fff!important}

.premium-summary strong{color:#fff;font-size:18px!important}

.premium-summary small{color:rgba(255,255,255,.72)!important;font-size:8px!important;line-height:1.2;white-space:normal!important}

.streak-soft{background:rgba(62,205,184,.22)!important;color:#9affeb!important}

.hub-fab{display:none;width:58px;height:58px;border:0;border-radius:50%;background:linear-gradient(135deg,#7c5cff,#5140d7);color:#fff;font-size:35px;box-shadow:0 13px 28px rgba(45,33,147,.38),inset 0 1px rgba(255,255,255,.4)}

/* Revisits — selected option C */

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

.revisits-metrics article{display:grid;grid-template-columns:34px 1fr;grid-template-rows:auto auto;column-gap:9px;align-items:center;padding:13px 12px;background:var(--paper)}

.revisits-metrics article:nth-child(1){background:color-mix(in srgb,#eee7ff 74%,var(--paper));border-color:#d9ccfb}

.revisits-metrics article:nth-child(2){background:color-mix(in srgb,#e5f2ff 74%,var(--paper));border-color:#cee4f7}

.revisits-metrics article:nth-child(3){background:color-mix(in srgb,#fff0c9 64%,var(--paper));border-color:#f0dcaa}

.revisits-metrics article:nth-child(4){background:var(--panel);border-color:var(--line)}

.revisits-metrics .metric-icon{grid-row:1/3;width:34px;height:34px;border-radius:11px;display:grid;place-items:center;font-size:15px;color:var(--accent);background:rgba(255,255,255,.7)}

.revisits-metrics strong{font-size:25px!important;margin:0!important;line-height:1;color:var(--text)!important}

.revisits-metrics small{font-size:8px!important;text-transform:none!important;letter-spacing:0!important;margin-top:3px;color:var(--muted)}

.people-records-panel .record-group{margin:10px;border:1px solid var(--line);border-radius:17px;background:var(--paper);overflow:hidden}

.people-records-panel .record-group>summary{padding-inline:13px;background:color-mix(in srgb,var(--panel) 70%,transparent)}

.people-records-panel .record-group-items{border-left:0;margin:0;padding:0 10px 8px}

.people-records-panel .record-item{min-height:66px}

.people-records-panel .people-avatar{border-radius:50%;background:linear-gradient(135deg,#eee7ff,#e4f1ff);color:#5742c4}

/* Ministry — selected option D */

.ministry-top-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-bottom:12px}

.ministry-top-metrics article{border:1px solid var(--line);border-radius:17px;background:var(--paper);padding:13px 8px;text-align:center;display:grid;gap:4px;box-shadow:0 7px 20px rgba(42,49,94,.035)}

.ministry-top-metrics article:nth-child(1){background:color-mix(in srgb,#e5f2ff 65%,var(--paper))}

.ministry-top-metrics article:nth-child(2){background:color-mix(in srgb,#eee7ff 65%,var(--paper))}

.ministry-top-metrics article:nth-child(3){background:color-mix(in srgb,#fff0c9 55%,var(--paper))}

.ministry-top-metrics article:nth-child(4){background:color-mix(in srgb,#f0eaff 55%,var(--paper))}

.ministry-top-metrics span{font-size:18px;color:#5b45ef}

.ministry-top-metrics strong{font-size:18px;letter-spacing:-.035em}

.ministry-top-metrics small{font-size:8px;color:var(--muted)}

.ministry-timer-hero{min-height:auto!important;padding:20px!important;background:linear-gradient(135deg,color-mix(in srgb,#f1eeff 85%,var(--paper)),var(--paper))!important;box-shadow:var(--notea-soft-shadow)}

.ministry-timer-hero .timer-display{font-size:52px;padding:22px 0;color:#22328c}

.ministry-timer-hero .timer-actions{grid-template-columns:1fr auto}

.ministry-timer-hero .timer-start{grid-column:auto!important;min-height:50px!important;border:0!important;background:linear-gradient(90deg,#566af5,#5942e8)!important;color:#fff!important;font-size:13px!important;box-shadow:0 12px 28px rgba(72,68,215,.24)}

.ministry-timer-hero [data-ministry-timer-pause]{min-width:110px}

.ministry-timer-hero [data-ministry-timer-save]{grid-column:1/-1}

.ministry-profile-card{margin:12px 0;border:1px solid var(--line);border-radius:17px;background:var(--paper);padding:13px 16px;display:grid;grid-template-columns:48px minmax(0,1fr);align-items:center;gap:12px}

.profile-orb{width:48px;height:48px;border-radius:16px;display:grid;place-items:center;background:#eee7ff;color:#5b45ef;font-size:23px}

.ministry-profile-card>div{display:grid}

.ministry-profile-card strong{font-size:14px}

.ministry-profile-card small{font-size:9px;color:var(--muted);margin-top:4px;line-height:1.35}

.ministry-profile-card>span:last-child{font-size:24px;color:var(--muted)}

.ministry-goal-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:12px}

.goal-card{border:1px solid var(--line);border-radius:18px;background:var(--paper);padding:16px}

.goal-card header{display:flex;justify-content:space-between;align-items:center}

.goal-card header strong{font-size:11px}

.goal-card header span{padding:4px 8px;border-radius:999px;background:var(--accent-soft);color:var(--accent);font-size:9px;font-weight:800}

.goal-card>b{display:block;font-size:25px;margin:14px 0 8px;letter-spacing:-.04em;color:#26358f}

.goal-track{height:7px;border-radius:99px;background:var(--panel-2);overflow:hidden}

.goal-track i{display:block;height:100%;width:0;border-radius:inherit;background:linear-gradient(90deg,#604af0,#8a73ff);transition:width .35s ease}

.goal-card>small{display:block;color:var(--muted);font-size:8px;margin-top:8px}

.goal-card>p{margin:10px 0 0;padding:9px;border-radius:11px;background:var(--accent-soft);color:var(--accent);font-size:9px;line-height:1.35;font-weight:700}

.ministry-bottom-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(260px,.8fr);gap:12px}

.ministry-year-mini{padding:15px!important}

.ministry-year-mini .year-bars{height:160px;margin-top:10px;gap:4px}

.ministry-year-mini .year-bar b{display:none}

.ministry-year-mini>header>strong{font-size:17px!important}

.ministry-recent-panel .record-group>summary{min-height:44px}

.ministry-recent-panel .record-item{min-height:61px}

/* Settings — selected option D */

.settings-screen{max-width:800px}

.settings-layout{display:grid;grid-template-columns:1fr;gap:14px}

.settings-welcome{border:1px solid color-mix(in srgb,var(--accent) 22%,var(--line));border-radius:22px;padding:24px;display:flex;align-items:center;justify-content:space-between;gap:18px;background:linear-gradient(135deg,#f3efff,#e8efff);box-shadow:var(--notea-soft-shadow)}

.settings-welcome strong{font-size:19px;color:#3b31a0}

.settings-welcome p{max-width:470px;color:#626882;font-size:12px;line-height:1.55;margin:7px 0 0}

.settings-welcome>span{width:74px;height:74px;border-radius:23px;display:grid;place-items:center;background:rgba(255,255,255,.55);font-size:36px;color:#7058ef}

.settings-group{border-radius:20px!important;box-shadow:0 9px 28px rgba(35,42,88,.045)}

.settings-group>header{padding-bottom:15px!important;margin-bottom:5px!important}

.settings-control{min-height:62px!important;border-top:1px solid var(--line);padding:9px 2px!important}

.settings-action{min-height:62px!important}

.ministry-facts{margin-top:12px;border-radius:15px;padding:14px;display:grid;grid-template-columns:36px 1fr;gap:10px;background:linear-gradient(135deg,#f5f1ff,#eef3ff);color:#4d4e74}

.ministry-facts>span{width:36px;height:36px;border:1px solid #cfc3fb;border-radius:50%;display:grid;place-items:center;color:#604af0;font-size:19px}

.ministry-facts ul{margin:0;padding-left:18px}

.ministry-facts li{font-size:9px;line-height:1.55;margin:2px 0}

/* Notes — selected option C, editorial and serene */

.workspace{position:relative;background:
  radial-gradient(circle at 86% 8%,rgba(150,132,245,.13),transparent 32%),
  linear-gradient(135deg,#fbfbff,#f7f6fc)}

.paper{max-width:900px!important;padding:58px 68px 48px!important;border-radius:28px!important;border:1px solid rgba(113,98,199,.14)!important;box-shadow:0 24px 70px rgba(49,45,99,.09)!important;background:
  radial-gradient(circle at 92% 3%,rgba(135,111,235,.10),transparent 24%),
  linear-gradient(180deg,rgba(255,255,255,.98),rgba(253,252,255,.98))!important}

.page-heading{position:relative;padding-bottom:28px!important;overflow:hidden}

.page-heading::after{content:"";position:absolute;width:260px;height:150px;right:-30px;top:-30px;background:radial-gradient(ellipse at center,rgba(134,114,232,.09),transparent 67%);border-radius:50%;pointer-events:none}

.page-title{font-family:var(--serif)!important;font-size:clamp(45px,5vw,68px)!important;font-weight:500!important;letter-spacing:-.04em!important;color:#131a3a!important}

.page-meta{margin-top:12px!important}

.page-meta>span{font-size:11px!important;color:#707896!important}

.page-meta button{border-radius:999px!important;background:#eeeaff!important;color:#5c45d9!important;border-color:#dcd2ff!important}

.toolbar{border-radius:16px!important;background:rgba(247,246,252,.9)!important;border:1px solid #e8e4f3!important;box-shadow:none!important;margin-bottom:28px!important}

.free-editor{font-family:var(--serif)!important;font-size:20px!important;line-height:1.8!important;color:#2f385c!important;max-width:720px;margin:auto}

.free-editor h2,.free-editor h3{font-family:var(--ui)!important;color:#1c2345}

.free-editor blockquote{margin:26px 0;padding:8px 0 8px 30px;border-left:3px solid #7862e8;color:#2c3459;font-size:1.15em;font-style:italic;background:transparent}

.free-editor ul,.free-editor ol{padding-left:28px}

.free-editor li{margin:8px 0}

.paper-footer{margin-top:42px!important;color:#8a8fa5!important}

.empty-workspace{border-radius:28px;background:rgba(255,255,255,.72);box-shadow:var(--notea-soft-shadow)}

/* Corrección de contraste: en móvil (<761px) la hoja "editorial" antes se
   quedaba siempre clara y no seguía el tema oscuro. La hacemos consciente
   del tema para que combine con el resto de la app en cualquier tamaño. */

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .workspace{background:
  radial-gradient(circle at 86% 8%,color-mix(in srgb,var(--accent) 10%,transparent),transparent 32%),
  linear-gradient(135deg,var(--bg),var(--panel))!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .paper{background:var(--paper)!important;border-color:var(--line)!important;color:var(--text)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .page-title{color:var(--text)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .page-meta>span{color:var(--muted)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .page-meta button{background:var(--accent-soft)!important;color:var(--accent)!important;border-color:color-mix(in srgb,var(--accent) 35%,var(--line))!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .toolbar{background:var(--paper)!important;border-color:var(--line)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .free-editor{color:var(--text)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .free-editor h2,:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .free-editor h3{color:var(--text)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .free-editor blockquote{border-left-color:var(--accent)!important;color:var(--muted)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .paper-footer{color:var(--muted)!important}

:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .empty-workspace{background:color-mix(in srgb,var(--paper) 85%,transparent)!important}

/* Desktop refinements */

@media(min-width:761px){
  .portal[data-active-module="hub"] .portal-main{padding-bottom:70px}
  .premium-hub-grid .hub-card{min-height:120px!important}
  .module-screen{padding-bottom:60px}
}

/* Mobile-first final layouts */

@media(max-width:760px){
  body{overflow:hidden}
  .portal{padding-bottom:calc(76px + env(safe-area-inset-bottom))}
  .portal-main{width:100%!important;margin:0!important;padding:12px 12px 18px!important}
  .portal[data-active-module="hub"] .portal-header{height:70px;padding:env(safe-area-inset-top) 16px 0;position:sticky}
  .portal[data-active-module="hub"] .portal-main{padding:8px 14px 14px!important}
  .portal:not([data-active-module="hub"]) .portal-header{display:none}
  .portal:not([data-active-module="hub"]) .portal-main{padding-top:max(14px,env(safe-area-inset-top))!important}
  .portal-brand small,.local-pill{display:none!important}.portal-logo{width:36px!important;height:40px!important}.portal-brand strong{font-size:21px!important}.portal-icon-button{width:45px!important;height:45px!important;border-radius:15px!important}
  .hub-screen{min-height:auto!important;padding-bottom:10px!important}
  .hub-kicker{font-size:28px}.hub-greeting h1{font-size:13px;line-height:1.4}
  .hub-search{height:49px;border-radius:15px}.hub-search input{font-size:12px}
  .premium-hub-grid{gap:10px!important}
  .premium-hub-grid .hub-card{min-height:101px!important;padding:13px!important;border-radius:20px!important;grid-template-columns:50px minmax(0,1fr) 43px!important;gap:11px!important}
  .premium-hub-grid .hub-card-icon{width:50px;height:50px;border-radius:16px!important;font-size:22px}
  .premium-hub-grid .hub-card-copy strong{font-size:17px!important}.premium-hub-grid .hub-card-copy small{font-size:9.5px!important;margin-top:4px!important}
  .hub-card-art{display:none}.premium-hub-grid .hub-card-arrow{width:34px;height:34px;font-size:22px}
  .premium-summary{margin-top:11px!important;padding:11px!important}.premium-summary>header{padding-bottom:8px!important}.premium-summary h2{font-size:14px!important}.premium-summary .summary-grid{gap:5px!important}.premium-summary .summary-grid>div{padding:8px 3px!important;border-radius:13px}.premium-summary .summary-icon{width:28px;height:28px;font-size:12px}.premium-summary strong{font-size:15px!important}.premium-summary small{font-size:6.8px!important}
  .hub-fab{display:grid;place-items:center;position:fixed;z-index:62;left:50%;bottom:calc(55px + env(safe-area-inset-bottom));transform:translateX(-50%)}
  .portal-bottom-nav,.notes-bottom-nav{
    position:fixed;left:8px;right:8px;bottom:max(8px,env(safe-area-inset-bottom));z-index:60;height:68px;
    display:grid;grid-template-columns:repeat(5,1fr);align-items:end;padding:7px 7px 8px;border:1px solid rgba(93,92,145,.16);border-radius:22px;
    background:rgba(255,255,255,.94);box-shadow:0 14px 40px rgba(28,28,68,.18);backdrop-filter:blur(24px)
  }
  .portal-bottom-nav button,.notes-bottom-nav button{height:52px;border:0;background:transparent;color:#737994;border-radius:14px;display:grid;place-content:center;justify-items:center;gap:2px;padding:0}
  .portal-bottom-nav button span,.notes-bottom-nav button span{font-size:18px;line-height:1}.portal-bottom-nav button small,.notes-bottom-nav button small{font-size:7.5px;font-weight:700}
  .portal-bottom-nav button.is-active,.notes-bottom-nav button.is-active{color:#4e42df;background:#f0edff}
  .portal[data-active-module="hub"] .portal-bottom-nav{background:rgba(255,255,255,.96)}
  .portal[data-active-module="hub"] .portal-bottom-nav button:nth-child(3){padding-top:10px}

  .module-screen{max-width:none;width:100%;padding-bottom:84px}
  .module-header{grid-template-columns:44px minmax(0,1fr) auto!important;gap:10px!important;margin:0 0 13px!important;align-items:center!important}
  .module-header h1{font-size:27px!important;line-height:1!important;letter-spacing:-.045em}.module-header .eyebrow{font-size:7px!important;margin-bottom:4px!important}.module-header>div>p:last-child{display:none!important}
  .back-button,.module-settings-button{width:44px!important;height:44px!important;min-width:44px!important;border-radius:14px!important}.module-head-actions{gap:7px}.module-primary{width:44px!important;min-width:44px!important;height:44px!important;min-height:44px!important;border-radius:14px!important;padding:0!important}.module-primary span{display:none!important}
  .module-toolbar{grid-template-columns:1fr!important;gap:8px!important;margin-bottom:10px!important}.module-search{height:45px!important;border-radius:14px!important;padding:0 13px!important}.module-search input{font-size:11px!important}.segmented{padding:4px!important;border-radius:14px!important;justify-content:space-between!important}.segmented button{flex:1;height:35px!important;padding:0 7px!important;font-size:8.5px!important}

  .revisits-metrics{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:6px!important;margin-bottom:10px!important}.revisits-metrics article{display:flex!important;flex-direction:column!important;gap:3px!important;padding:8px 3px!important;border-radius:13px!important}.revisits-metrics .metric-icon{width:26px;height:26px;border-radius:9px;font-size:12px}.revisits-metrics strong{font-size:18px!important}.revisits-metrics small{font-size:6.5px!important}
  .people-records-panel{border:0!important;background:transparent!important}.people-records-panel>header{display:none}.people-records-panel .record-list{padding:0!important}.people-records-panel .record-group{margin:0 0 8px!important;border-radius:15px!important}.people-records-panel .record-group>summary{min-height:45px!important}.people-records-panel .record-group-items{padding:0 8px 5px!important}.people-records-panel .record-item{min-height:55px!important;grid-template-columns:34px minmax(0,1fr) auto 12px!important}.people-records-panel .record-main strong{font-size:10.5px!important}.people-records-panel .record-main small,.people-records-panel .record-main em{font-size:7.5px!important}.people-records-panel .status-chip{display:block!important;font-size:6.5px!important;padding:4px 6px!important}
  .revisits-primary{position:fixed;z-index:63;right:18px;bottom:calc(83px + env(safe-area-inset-bottom));border-radius:50%!important;box-shadow:0 13px 27px rgba(91,69,239,.32)!important}

  .ministry-screen .module-toolbar{grid-template-columns:1fr auto!important}.ministry-screen .segmented{min-width:0}.service-year-pill{width:auto!important;white-space:nowrap;font-size:7px!important;padding:8px 9px!important}
  .ministry-top-metrics{gap:5px;margin-bottom:8px}.ministry-top-metrics article{padding:8px 3px;border-radius:13px}.ministry-top-metrics span{font-size:14px}.ministry-top-metrics strong{font-size:13px}.ministry-top-metrics small{font-size:6px}
  .ministry-timer-hero{padding:12px!important;border-radius:17px!important}.ministry-timer-hero .timer-display{font-size:38px;padding:15px 0}.ministry-timer-hero .timer-start{min-height:42px!important;font-size:10px!important}.ministry-timer-hero [data-ministry-timer-pause]{min-width:74px}.ministry-timer-hero [data-ministry-timer-save]{min-height:34px!important}
  .ministry-profile-card{margin:8px 0;padding:9px 11px;border-radius:14px;grid-template-columns:38px minmax(0,1fr)}.profile-orb{width:38px;height:38px;border-radius:12px;font-size:18px}.ministry-profile-card strong{font-size:11px}.ministry-profile-card small{font-size:7px}
  .ministry-goal-grid{gap:7px;margin-bottom:8px}.goal-card{padding:10px;border-radius:14px}.goal-card header strong{font-size:8px}.goal-card header span{font-size:7px;padding:3px 5px}.goal-card>b{font-size:19px;margin:9px 0 6px}.goal-card>small{font-size:6.5px}.goal-card>p{font-size:7px;padding:7px;margin-top:7px}.goal-track{height:5px}
  .ministry-bottom-grid{grid-template-columns:1fr;gap:8px}.ministry-year-mini{padding:10px!important}.ministry-year-mini .year-bars{height:100px}.ministry-recent-panel .record-item{min-height:53px!important}
  .ministry-primary{position:fixed;z-index:63;right:18px;bottom:calc(83px + env(safe-area-inset-bottom));border-radius:50%!important;box-shadow:0 13px 27px rgba(59,117,166,.3)!important}

  .settings-header{grid-template-columns:44px minmax(0,1fr) 44px!important}.settings-page-gear{width:44px;height:44px;min-width:44px;border-radius:14px}
  .settings-layout{gap:9px}.settings-welcome{padding:15px;border-radius:17px}.settings-welcome strong{font-size:15px}.settings-welcome p{font-size:9px;margin-top:5px}.settings-welcome>span{width:48px;height:48px;border-radius:15px;font-size:25px}
  .settings-group{padding:13px!important;border-radius:16px!important}.settings-group>header{padding-bottom:10px!important}.settings-group>header>span{width:39px!important;height:39px!important}.settings-group h2{font-size:15px!important}.settings-group header p{font-size:8px!important}.settings-control,.settings-action{min-height:52px!important}.settings-control>span,.settings-action b{font-size:10px!important}.settings-control select{min-width:112px!important;font-size:9px!important;padding:9px 25px 9px 9px!important}.settings-action small{font-size:7.5px!important}.ministry-rule-note{padding:9px!important}.ministry-facts{padding:10px;grid-template-columns:30px 1fr}.ministry-facts>span{width:30px;height:30px;font-size:15px}.ministry-facts li{font-size:7.2px}

  /* Notes/editor mobile */
  .app{padding-bottom:76px}.workspace{height:calc(100dvh - 76px)}
  .topbar{height:62px!important;min-height:62px!important;display:grid!important;grid-template-columns:1fr auto 1fr!important;padding:env(safe-area-inset-top) 8px 0!important;background:rgba(250,249,255,.9)!important;backdrop-filter:blur(18px)}
  .notes-screen-title{display:block;grid-column:2;grid-row:1;align-self:center;font-size:18px;letter-spacing:-.02em}.topbar-left{grid-column:1;grid-row:1;min-width:0}.topbar-actions{grid-column:3;grid-row:1;justify-self:end}
  .hub-return-button{width:42px!important;height:42px!important;border-radius:14px!important}.hub-return-button b{display:none}.save-state{max-width:52px;padding:0!important;border:0!important;background:transparent!important}.save-state span{display:none}
  .topbar-actions .wol-book-button,.topbar-actions [data-favorite],.topbar-actions [data-focus]{display:none!important}.topbar-actions .icon-button{width:42px!important;height:42px!important;border-radius:14px!important}.settings-everywhere{display:grid!important}
  .workspace-scroll{padding:9px 8px 20px!important}.paper{min-height:calc(100dvh - 154px)!important;padding:27px 22px 30px!important;border-radius:21px!important}.page-heading{padding-bottom:18px!important}.page-title{font-size:42px!important;line-height:1.03!important}.page-meta{margin-top:9px!important}.toolbar{position:sticky;top:0;z-index:5;margin:0 -8px 20px!important;padding:5px!important;border-radius:14px!important;overflow-x:auto!important;flex-wrap:nowrap!important}.free-editor{font-size:18px!important;line-height:1.75!important}.paper-footer{margin-top:30px!important}.empty-workspace{min-height:calc(100dvh - 160px)!important;border-radius:21px!important}
  .notes-bottom-nav{z-index:90}.sidebar{z-index:110}
}

@media(max-width:390px){
  .premium-hub-grid .hub-card{min-height:94px!important}.hub-kicker{font-size:25px}.premium-summary .summary-grid>div{padding-inline:2px!important}.premium-summary small{font-size:6px!important}
  .ministry-goal-grid{grid-template-columns:1fr}.ministry-bottom-grid{grid-template-columns:1fr}.ministry-timer-hero .timer-display{font-size:34px}
  .page-title{font-size:37px!important}.paper{padding-inline:17px!important}
}

/* =========================================================
   COMPACT MOBILE DOCK + CLEAN EDITOR HEADER
   Tablet and desktop remain unchanged.
   ========================================================= */

@media(max-width:760px){
  /* New-page action belongs in the Hub header beside Settings. */
  .portal[data-active-module="hub"] .hub-header-create{
    display:grid!important;
    width:45px!important;
    height:45px!important;
    min-width:45px!important;
    border-radius:15px!important;
    border-color:rgba(255,255,255,.22)!important;
    background:rgba(255,255,255,.11)!important;
    color:#fff!important;
    font-size:28px!important;
    box-shadow:inset 0 1px rgba(255,255,255,.25),0 8px 22px rgba(12,20,83,.18)!important;
    backdrop-filter:blur(18px)!important;
  }
  .portal:not([data-active-module="hub"]) .hub-header-create{display:none!important}
  .hub-fab{display:none!important}

  /* The editor already has Inicio in the bottom dock. */
  .hub-return-button{display:none!important}

  /* Inicio in the dock replaces the redundant back buttons on mobile. */
  [data-module-screen="revisits"] .back-button,
  [data-module-screen="ministry"] .back-button{display:none!important}
  [data-module-screen="revisits"] .module-header,
  [data-module-screen="ministry"] .module-header{grid-template-columns:minmax(0,1fr) auto!important}

  /* The mobile dock and Más replace these sidebar footer actions. */
  .sidebar-footer{display:none!important}

  /* Compact browser dock: no large unused block beneath the icons. */
  .portal-bottom-nav,
  .notes-bottom-nav{
    left:0!important;
    right:0!important;
    bottom:0!important;
    width:100%!important;
    height:60px!important;
    min-height:60px!important;
    padding:4px 8px 3px!important;
    border-left:0!important;
    border-right:0!important;
    border-bottom:0!important;
    border-radius:18px 18px 0 0!important;
    align-items:center!important;
    box-shadow:0 -7px 24px rgba(28,28,68,.13)!important;
  }
  .portal-bottom-nav button,
  .notes-bottom-nav button{
    height:48px!important;
    min-height:48px!important;
    border-radius:12px!important;
    gap:1px!important;
  }
  .portal-bottom-nav button span,
  .notes-bottom-nav button span{font-size:17px!important}
  .portal-bottom-nav button small,
  .notes-bottom-nav button small{font-size:7px!important;line-height:1!important}
  .portal[data-active-module="hub"] .portal-bottom-nav button:nth-child(3){padding-top:0!important}

  /* Reserve only the real dock height. */
  .portal{padding-bottom:60px!important}
  .portal-main,
  .portal[data-active-module="hub"] .portal-main{padding-bottom:70px!important}
  .module-screen{padding-bottom:72px!important}
  .app{padding-bottom:60px!important}
  .workspace{height:calc(100dvh - 60px)!important}
}

/* Installed PWAs need only the actual device safe-area, not extra browser space. */

@media(max-width:760px) and (display-mode:standalone){
  .portal-bottom-nav,
  .notes-bottom-nav{
    height:calc(60px + env(safe-area-inset-bottom))!important;
    padding-bottom:calc(3px + env(safe-area-inset-bottom))!important;
  }
  .portal{padding-bottom:calc(60px + env(safe-area-inset-bottom))!important}
  .portal-main,
  .portal[data-active-module="hub"] .portal-main{padding-bottom:calc(70px + env(safe-area-inset-bottom))!important}
  .module-screen{padding-bottom:calc(72px + env(safe-area-inset-bottom))!important}
  .app{padding-bottom:calc(60px + env(safe-area-inset-bottom))!important}
  .workspace{height:calc(100dvh - 60px - env(safe-area-inset-bottom))!important}
}

/* =========================================================
   ONE CREATE ACTION + COMPACT MINISTRY OVERVIEW
   Mobile only. Tablet and desktop remain unchanged.
   ========================================================= */

@media(max-width:760px){
  /* One creation action per module, always in the header. */
  .revisits-primary,
  .ministry-primary{
    position:static!important;
    inset:auto!important;
    transform:none!important;
    width:44px!important;
    min-width:44px!important;
    height:44px!important;
    min-height:44px!important;
    border-radius:14px!important;
    box-shadow:0 8px 20px rgba(55,49,145,.13)!important;
  }
  .module-head-actions{display:flex!important;align-items:center!important;gap:7px!important}
  .module-head-actions .module-primary span{display:none!important}

  /* The empty states explain the top action instead of repeating it. */
  .people-empty{min-height:210px!important;padding:22px 16px!important}
  .people-empty p{max-width:240px!important;margin-bottom:0!important}
  .ministry-empty{min-height:112px!important;padding:12px 10px!important}
  .ministry-empty>span{width:38px!important;height:38px!important;border-radius:12px!important;font-size:17px!important}
  .ministry-empty strong{font-size:12px!important;margin-top:7px!important}
  .ministry-empty p{max-width:290px!important;font-size:8px!important;margin:3px 0 0!important}

  /* Tabs and service-year selector are visually equal-height cards. */
  .ministry-screen .module-toolbar{
    grid-template-columns:minmax(0,1.55fr) minmax(118px,.75fr)!important;
    align-items:stretch!important;
    gap:8px!important;
  }
  .ministry-screen .module-toolbar .segmented,
  .ministry-screen .service-year-pill{
    min-height:48px!important;
    height:48px!important;
    border-radius:15px!important;
    box-sizing:border-box!important;
  }
  .ministry-screen .module-toolbar .segmented{align-items:center!important;padding:4px!important}
  .ministry-screen .module-toolbar .segmented button{height:38px!important}
  .ministry-screen .service-year-pill{
    width:100%!important;
    justify-self:stretch!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:5px 8px!important;
    white-space:normal!important;
    text-align:center!important;
    line-height:1.15!important;
  }
  .ministry-screen .service-year-pill strong{display:block!important;margin-left:4px!important}

  /* Monthly and annual progress stay side by side, including small phones. */
  .ministry-goal-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:7px!important;
    margin-bottom:8px!important;
  }
  .ministry-goal-grid .goal-card{min-width:0!important;padding:9px 8px!important;border-radius:14px!important}
  .ministry-goal-grid .goal-card header{gap:4px!important}
  .ministry-goal-grid .goal-card header strong{font-size:7.7px!important;line-height:1.15!important}
  .ministry-goal-grid .goal-card header span{font-size:6.5px!important;padding:3px 5px!important;flex:0 0 auto!important}
  .ministry-goal-grid .goal-card>b{font-size:17px!important;margin:8px 0 6px!important;white-space:nowrap!important}
  .ministry-goal-grid .goal-card>small{font-size:6.2px!important;line-height:1.25!important;min-height:16px!important}
  .ministry-goal-grid .goal-card>p{font-size:6.6px!important;line-height:1.25!important;padding:6px!important;margin-top:6px!important;min-height:34px!important}

  /* Recent activity is compact and no longer dominates the screen. */
  .ministry-recent-panel{min-height:0!important;border-radius:15px!important}
  .ministry-recent-panel>header{height:40px!important;padding:0 11px!important}
  .ministry-recent-panel h2{font-size:13px!important}
  .ministry-recent-panel .record-list{padding:0 6px!important}
  .ministry-recent-panel .record-group>summary{min-height:39px!important}
  .ministry-recent-panel .record-item{min-height:48px!important;padding-block:5px!important}

  /* No floating creation controls may overlap lists, charts or reports. */
  [data-module-screen="revisits"] .module-primary,
  [data-module-screen="ministry"] .module-primary{z-index:auto!important}
}

@media(max-width:370px){
  .ministry-screen .module-toolbar{grid-template-columns:minmax(0,1.35fr) minmax(108px,.85fr)!important}
  .ministry-screen .service-year-pill{font-size:6.5px!important;padding-inline:5px!important}
  .ministry-goal-grid{gap:5px!important}
  .ministry-goal-grid .goal-card{padding-inline:7px!important}
  .ministry-goal-grid .goal-card>b{font-size:15px!important}
}

/* =========================================================
   COMPACT MOBILE FORMS
   Keep dialogs fully contained, compact and easy to close.
   ========================================================= */

@media(max-width:760px){
  .module-dialog{
    width:calc(100% - 22px)!important;
    max-width:560px!important;
    max-height:min(88dvh,690px)!important;
    overflow:hidden!important;
    border-radius:22px!important;
    margin:auto!important;
    box-shadow:0 24px 70px rgba(18,20,45,.28)!important;
  }
  .module-dialog::backdrop{
    background:rgba(20,22,32,.48)!important;
    backdrop-filter:blur(8px)!important;
  }
  .module-form{
    display:grid!important;
    grid-template-rows:auto minmax(0,1fr) auto!important;
    width:100%!important;
    max-height:min(88dvh,690px)!important;
    padding:0!important;
    overflow:hidden!important;
    background:var(--paper)!important;
  }
  .module-form>header{
    position:relative!important;
    z-index:2!important;
    margin:0!important;
    padding:14px 15px 11px!important;
    border-bottom:1px solid var(--line)!important;
    background:color-mix(in srgb,var(--paper) 94%,transparent)!important;
    backdrop-filter:blur(14px)!important;
  }
  .module-form header small{
    font-size:7.5px!important;
    letter-spacing:.15em!important;
  }
  .module-form h2{
    margin-top:3px!important;
    font-size:21px!important;
    line-height:1.05!important;
  }
  .dialog-x{
    width:36px!important;
    height:36px!important;
    min-width:36px!important;
    border-radius:12px!important;
    font-size:22px!important;
  }
  .form-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:8px 9px!important;
    min-height:0!important;
    overflow-y:auto!important;
    overscroll-behavior:contain!important;
    scrollbar-gutter:stable!important;
    padding:11px 15px 12px!important;
    align-content:start!important;
  }
  .form-grid .span-2{grid-column:1/-1!important}
  .form-grid label{gap:4px!important;min-width:0!important}
  .form-grid label>span{
    font-size:8px!important;
    line-height:1.15!important;
  }
  .form-grid input,
  .form-grid select,
  .form-grid textarea{
    min-width:0!important;
    min-height:42px!important;
    padding:9px 10px!important;
    border-radius:11px!important;
    font-size:10.5px!important;
    line-height:1.2!important;
  }
  .form-grid textarea{
    min-height:66px!important;
    max-height:88px!important;
    resize:none!important;
  }
  .module-form>footer{
    position:relative!important;
    z-index:3!important;
    display:flex!important;
    align-items:center!important;
    gap:8px!important;
    margin:0!important;
    padding:10px 15px calc(10px + env(safe-area-inset-bottom))!important;
    border-top:1px solid var(--line)!important;
    background:color-mix(in srgb,var(--paper) 96%,transparent)!important;
    backdrop-filter:blur(14px)!important;
  }
  .module-form>footer>span{display:none!important}
  .module-form>footer button{
    min-height:40px!important;
    padding:0 12px!important;
    border-radius:11px!important;
    font-size:9.5px!important;
    white-space:nowrap!important;
  }
  .module-form>footer button:not(.danger-outline){flex:1 1 0!important}
  .module-form>footer .primary{flex:1.45 1 0!important}
  .module-form>footer .danger-outline{
    flex:0 0 auto!important;
    grid-column:auto!important;
    justify-self:auto!important;
  }
}

@media(max-width:370px){
  .module-dialog{
    width:calc(100% - 14px)!important;
    max-height:90dvh!important;
    border-radius:19px!important;
  }
  .module-form{max-height:90dvh!important}
  .module-form>header{padding-inline:12px!important}
  .form-grid{padding-inline:12px!important;gap:7px!important}
  .module-form>footer{padding-inline:12px!important}
  .form-grid input,.form-grid select,.form-grid textarea{font-size:10px!important}
}

/* =========================================================
   RESTORE BIBLE WOL ON MOBILE
   Keeps the editor companion visible without crowding the header.
   ========================================================= */

@media(max-width:760px){
  .topbar-actions .wol-book-button{
    display:grid!important;
    place-items:center;
    color:#5144d8;
    background:#f0edff;
    border-color:rgba(91,69,239,.18);
  }
  .topbar-actions{gap:3px!important}
  .topbar-actions .icon-button{
    width:39px!important;
    height:39px!important;
    min-width:39px!important;
    border-radius:13px!important;
  }
  .topbar-actions .wol-book-button svg{width:20px;height:20px}
}

@media(max-width:390px){
  .topbar-actions{gap:1px!important}
  .topbar-actions .icon-button{
    width:37px!important;
    height:37px!important;
    min-width:37px!important;
    border-radius:12px!important;
  }
  .notes-screen-title{font-size:17px!important}
}

/* =========================================================
   CLEAN MODULE HEADERS
   Settings stays in the Hub; mobile module headers use icons.
   ========================================================= */

.module-mobile-section-icon{display:none}

.compact-module-header{grid-template-columns:minmax(0,1fr) auto}

@media(max-width:760px){
  /* Revisitas and Ministerio are already named in the bottom dock. */
  .compact-module-header{
    position:relative!important;
    grid-template-columns:44px auto!important;
    align-items:center!important;
    justify-content:space-between!important;
    min-height:44px!important;
    margin-bottom:12px!important;
  }
  .module-mobile-section-icon{
    display:grid!important;
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    place-items:center!important;
    border:1px solid var(--line)!important;
    border-radius:14px!important;
    background:var(--paper)!important;
    box-shadow:0 8px 22px rgba(38,42,86,.07)!important;
    font-size:20px!important;
    line-height:1!important;
  }
  .revisits-section-icon{color:#7655bd!important;background:#f3edff!important;border-color:rgba(118,85,189,.16)!important}
  .ministry-section-icon{color:#3b75a6!important;background:#e8f4ff!important;border-color:rgba(59,117,166,.16)!important}

  /* Keep the true page heading available to assistive technology. */
  .compact-module-header .module-title-copy{
    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;
  }
  .compact-module-header .module-head-actions{
    grid-column:2!important;
    justify-self:end!important;
  }
}

/* =========================================================
   SETTINGS ICON HEADER
   On mobile, Settings uses the same compact icon language as
   Revisitas and Ministerio while preserving the back action.
   ========================================================= */

.settings-section-icon{color:#5b45ef;background:#f0edff;border-color:rgba(91,69,239,.16)}

@media(max-width:760px){
  .compact-settings-header{
    grid-template-columns:44px 44px minmax(0,1fr)!important;
    justify-content:start!important;
    gap:8px!important;
    min-height:44px!important;
    margin-bottom:12px!important;
  }
  .compact-settings-header .settings-section-icon{
    display:grid!important;
    grid-column:2!important;
  }
  .compact-settings-header .settings-title-copy{
    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;
  }
}

/* =========================================================
   DESKTOP / TABLET LANDSCAPE REDESIGN
   Selected directions:
   Hub B · Notes B · Revisitas B (content) · Ministerio C
   Mobile rules remain untouched at 760px and below.
   ========================================================= */

.desktop-global-nav,.notes-library-heading{display:none}

@media (min-width:761px){
  :root{--desktop-nav-w:224px;--desktop-library-w:300px;--desktop-radius:24px;--desktop-soft-shadow:0 18px 55px rgba(31,39,87,.09)}
  body{overflow:hidden}

  /* Unified navigation — same destinations as mobile, adapted to landscape. */
  .desktop-global-nav{
    display:flex;flex-direction:column;min-width:0;padding:20px 14px 16px;color:#fff;
    background:
      radial-gradient(circle at 18% 8%,rgba(255,255,255,.18),transparent 23%),
      linear-gradient(165deg,#4f42d9 0%,#302f91 48%,#172457 100%);
    box-shadow:16px 0 45px rgba(24,29,79,.13);overflow:hidden;position:relative;z-index:45
  }
  .desktop-global-nav::after{content:"";position:absolute;inset:auto -90px -100px auto;width:250px;height:250px;border-radius:50%;background:rgba(126,151,255,.16);filter:blur(2px);pointer-events:none}
  .desktop-nav-brand{display:flex;align-items:center;gap:11px;border:0;background:transparent;color:#fff;text-align:left;padding:4px 7px 22px;position:relative;z-index:1}
  .desktop-nav-brand>span:first-child{width:42px;height:42px;display:grid;place-items:center;filter:drop-shadow(0 10px 18px rgba(10,18,67,.2))}
  .desktop-nav-brand img{width:100%;height:100%;object-fit:contain}.desktop-nav-brand>span:last-child{display:grid}.desktop-nav-brand strong{font-size:18px;letter-spacing:-.03em}.desktop-nav-brand small{font-size:9px;color:rgba(255,255,255,.66);margin-top:2px}
  .desktop-nav-menu{display:grid;gap:6px;position:relative;z-index:1}.desktop-nav-menu button,.desktop-nav-links button{width:100%;min-height:46px;border:1px solid transparent;border-radius:14px;background:transparent;color:rgba(255,255,255,.72);display:grid;grid-template-columns:34px 1fr;align-items:center;gap:7px;padding:0 11px;text-align:left;transition:.18s ease}
  .desktop-nav-menu button>span,.desktop-nav-links button>span{width:30px;height:30px;border-radius:10px;display:grid;place-items:center;font-size:17px}.desktop-nav-menu button b,.desktop-nav-links button b{font-size:11px;font-weight:730}
  .desktop-nav-menu button:hover,.desktop-nav-links button:hover{background:rgba(255,255,255,.09);color:#fff;transform:translateX(2px)}
  .desktop-nav-menu button.is-active{color:#fff;border-color:rgba(255,255,255,.15);background:linear-gradient(135deg,rgba(255,255,255,.22),rgba(255,255,255,.10));box-shadow:inset 0 1px rgba(255,255,255,.15),0 12px 28px rgba(14,18,70,.15)}
  .desktop-nav-menu button.is-active>span{background:rgba(255,255,255,.16)}
  .desktop-new-note{position:relative;z-index:1;min-height:44px;margin:0 5px 14px;border:1px solid rgba(255,255,255,.18);border-radius:14px;background:linear-gradient(135deg,#9c6cff,#684df2);color:#fff;display:flex;align-items:center;justify-content:center;gap:7px;box-shadow:0 12px 28px rgba(30,20,111,.25)}
  .desktop-new-note span{font-size:20px}.desktop-new-note b{font-size:10px}
  .desktop-nav-spacer{flex:1}
  .desktop-nav-focus-card{position:relative;z-index:1;margin:12px 4px;padding:14px;border:1px solid rgba(255,255,255,.12);border-radius:16px;background:rgba(255,255,255,.08);display:grid;grid-template-columns:28px 1fr;gap:9px;align-items:start;backdrop-filter:blur(14px)}
  .desktop-nav-focus-card span{width:28px;height:28px;border-radius:9px;background:rgba(255,255,255,.12);display:grid;place-items:center}.desktop-nav-focus-card strong{font-size:9px;line-height:1.45;color:rgba(255,255,255,.78)}
  .desktop-nav-links{display:grid;gap:5px;margin:0 0 7px;position:relative;z-index:1}
  .desktop-local-status{position:relative;z-index:1;margin:0 5px;border:1px solid rgba(255,255,255,.12);border-radius:13px;padding:10px 11px;display:flex;align-items:center;gap:8px;color:rgba(255,255,255,.72);font-size:9px;background:rgba(255,255,255,.055)}
  .desktop-local-status i{width:8px;height:8px;border-radius:50%;background:#68d6a0;box-shadow:0 0 0 5px rgba(104,214,160,.14)}

  /* PORTAL SHELL */
  .portal{height:100dvh;display:grid;grid-template-columns:var(--desktop-nav-w) minmax(0,1fr);grid-template-rows:68px minmax(0,1fr);overflow:hidden;background:
    radial-gradient(circle at 82% 2%,rgba(129,104,242,.10),transparent 29%),
    linear-gradient(135deg,#f8f8fd,#f3f5fb)}
  .portal-global-nav{grid-column:1;grid-row:1/3}
  .portal-header{grid-column:2;grid-row:1;position:relative!important;top:auto!important;height:68px;padding:0 28px;border-bottom:1px solid rgba(92,91,139,.11);background:rgba(250,250,255,.84);backdrop-filter:blur(20px);justify-content:flex-end}
  .portal-header .portal-brand{display:none}.portal-header-actions{gap:9px}.portal-header .local-pill{display:flex!important;height:36px;background:rgba(255,255,255,.82)}
  .portal-header .hub-header-create{display:grid!important;width:auto!important;min-width:42px!important;padding:0 13px!important;font-size:20px!important;border-radius:13px!important;color:#fff!important;border:0!important;background:linear-gradient(135deg,#8061f5,#5d48de)!important;box-shadow:0 10px 24px rgba(82,63,201,.20)!important}
  .portal-header .portal-icon-button{width:42px;height:42px;border-radius:13px;background:rgba(255,255,255,.88)}
  .portal-main{grid-column:2;grid-row:2;width:100%!important;max-width:none!important;margin:0!important;padding:28px 34px 44px!important;overflow:auto;min-height:0}
  .portal-screen{width:min(1280px,100%);margin-inline:auto}
  .portal-bottom-nav{display:none!important}

  /* HUB — selected B: modern gradient sidebar + airy editorial dashboard. */
  .portal[data-active-module="hub"]{background:linear-gradient(135deg,#f8f8fd,#f2f4fb)!important}
  .portal[data-active-module="hub"] .portal-header{background:rgba(250,250,255,.84)!important;border-bottom-color:rgba(92,91,139,.11)!important}
  .portal[data-active-module="hub"] .portal-main{width:100%!important;padding:28px 34px 44px!important}
  .hub-screen{min-height:0!important;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important}
  .hub-screen::after{display:none!important}
  .hub-hero{display:grid;grid-template-columns:minmax(0,1fr) minmax(350px,.72fr);align-items:center;gap:26px;margin:0 0 20px!important;padding:28px 30px;border:1px solid rgba(99,91,176,.13);border-radius:28px;background:
    radial-gradient(circle at 80% 18%,rgba(128,98,245,.22),transparent 26%),
    linear-gradient(135deg,rgba(255,255,255,.96),rgba(242,239,255,.94));box-shadow:var(--desktop-soft-shadow);overflow:hidden}
  .hub-greeting{padding:0!important}.hub-kicker{color:#1e2340!important;font-size:clamp(34px,3vw,48px)!important;line-height:1!important;letter-spacing:-.055em!important}.hub-greeting h1{color:#777d98!important;font-size:15px!important;line-height:1.5!important;margin-top:10px!important}
  .hub-search{height:54px!important;border:1px solid rgba(93,82,192,.16)!important;border-radius:17px!important;background:rgba(255,255,255,.78)!important;box-shadow:0 12px 30px rgba(47,43,98,.07)!important}.hub-search>span{color:#6554d9!important}.hub-search input{color:#282e4d!important;font-size:13px!important}.hub-search input::placeholder{color:#8c91a8!important}.hub-search button{background:#eeebff!important;color:#5544d8!important}
  .premium-hub-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:16px!important}
  .premium-hub-grid .hub-card{min-height:188px!important;padding:22px!important;border-radius:24px!important;grid-template-columns:52px minmax(0,1fr) 42px!important;grid-template-rows:auto 1fr!important;align-items:start!important;gap:14px!important;box-shadow:var(--desktop-soft-shadow)!important}
  .premium-hub-grid .notes-card{background:linear-gradient(145deg,#fff8e8,#ffe6a9)!important;border-color:#efd79d!important}.premium-hub-grid .revisits-card{background:linear-gradient(145deg,#f6f1ff,#d8c0ff)!important;border-color:#d4c1f8!important}.premium-hub-grid .ministry-card{background:linear-gradient(145deg,#eff8ff,#b9ddff)!important;border-color:#bfdcf1!important}
  .premium-hub-grid .hub-card-icon{width:52px!important;height:52px!important;border-radius:17px!important;background:rgba(255,255,255,.70)!important;box-shadow:inset 0 1px rgba(255,255,255,.65)}
  .premium-hub-grid .hub-card-copy{grid-column:1/4;align-self:end}.premium-hub-grid .hub-card-copy strong{font-size:22px!important;color:#202541!important}.premium-hub-grid .hub-card-copy small{font-size:11px!important;color:#646a83!important;max-width:230px!important}
  .premium-hub-grid .hub-card-arrow{grid-column:3!important;grid-row:1!important;width:38px!important;height:38px!important;border:1px solid rgba(47,48,86,.16)!important;border-radius:50%!important;display:grid!important;place-items:center!important;font-size:22px!important;color:#313653!important;background:rgba(255,255,255,.35)!important}
  .premium-summary{margin-top:17px!important;padding:18px!important;border-radius:22px!important;background:rgba(255,255,255,.80)!important;box-shadow:var(--desktop-soft-shadow)!important}.premium-summary>header{padding-bottom:12px!important}.premium-summary h2{font-size:18px!important}.premium-summary .summary-grid{grid-template-columns:repeat(4,1fr)!important;gap:10px!important;padding-top:13px!important}.premium-summary .summary-grid>div{border:1px solid rgba(91,91,132,.10);border-radius:15px;background:rgba(248,248,253,.78);padding:12px!important}.premium-summary .summary-icon{width:36px;height:36px;border-radius:12px}.premium-summary strong{font-size:20px!important}

  /* MODULES WITH SHARED SIDEBAR */
  .module-screen{max-width:1280px!important;padding:4px 0 58px!important}
  .module-header{margin-bottom:18px!important}.module-title-copy h1{font-size:40px!important;line-height:1!important}.module-title-copy p{display:block!important;color:#7c8299!important;font-size:12px!important;margin-top:7px!important}.module-primary{min-height:44px!important;border-radius:14px!important;padding-inline:17px!important}

  /* REVISITAS — selected B interior. */
  [data-module-screen="revisits"]{display:grid;grid-template-columns:1fr;gap:13px}
  [data-module-screen="revisits"] .module-header{display:grid;grid-template-columns:minmax(0,1fr) auto!important;align-items:end;margin:0!important}
  [data-module-screen="revisits"] .module-toolbar{display:grid;grid-template-columns:minmax(360px,1fr) auto!important;gap:14px;margin:0!important;align-items:center}
  [data-module-screen="revisits"] .module-search{height:48px;border-radius:15px;background:rgba(255,255,255,.86);box-shadow:0 10px 28px rgba(42,45,91,.045)}
  [data-module-screen="revisits"] .segmented{min-width:430px;height:48px;padding:5px;border-radius:15px;background:rgba(255,255,255,.86);box-shadow:0 10px 28px rgba(42,45,91,.045)}
  [data-module-screen="revisits"] .segmented button{height:38px;font-size:9px;padding:0 18px}
  .revisits-metrics{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:12px!important;margin:0!important}.revisits-metrics article{min-height:88px!important;border-radius:18px!important;padding:15px 16px!important;grid-template-columns:38px 1fr!important;box-shadow:0 10px 28px rgba(42,45,91,.04)}.revisits-metrics .metric-icon{width:36px;height:36px;border-radius:12px}.revisits-metrics strong{font-size:24px!important}.revisits-metrics small{font-size:9px!important}
  .people-records-panel{min-height:430px!important;border-radius:24px!important;background:rgba(255,255,255,.88)!important;box-shadow:var(--desktop-soft-shadow)!important;overflow:hidden}.people-records-panel>header{height:58px;padding:0 20px!important}.people-records-panel .record-list{padding:10px 12px 18px!important}.people-records-panel .module-empty{min-height:315px!important;background:transparent!important}.people-records-panel .module-empty>span{width:72px!important;height:72px!important;border-radius:22px!important;background:linear-gradient(135deg,#f0eaff,#e7e3ff)!important;color:#6d54dc!important;font-size:30px!important}.people-records-panel .module-empty strong{font-size:22px!important}.people-records-panel .module-empty p{font-size:11px!important}

  /* MINISTERIO — selected C: balanced command center with circular timer. */
  [data-module-screen="ministry"] .module-header{margin-bottom:16px!important}
  .ministry-toolbar{grid-template-columns:auto minmax(240px,1fr)!important;align-items:center!important;margin-bottom:14px!important}.ministry-toolbar .segmented{height:46px;padding:5px;border-radius:15px;background:rgba(255,255,255,.86);box-shadow:0 10px 28px rgba(42,45,91,.045)}.ministry-toolbar .segmented button{height:36px;padding-inline:20px}.service-year-pill{height:46px;min-width:245px;border-radius:15px!important;display:flex;align-items:center;justify-content:center!important;background:rgba(255,255,255,.86)!important;box-shadow:0 10px 28px rgba(42,45,91,.045);font-size:9px!important}
  .ministry-panel[data-ministry-panel="overview"]{display:grid!important;grid-template-columns:minmax(300px,.75fr) minmax(560px,1.7fr);grid-template-areas:"timer metrics" "timer goals" "profile profile" "bottom bottom";gap:13px;align-items:stretch}
  .ministry-top-metrics{grid-area:metrics;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:10px!important;margin:0!important}.ministry-top-metrics article{min-height:95px;padding:14px 8px!important;border-radius:18px!important;box-shadow:0 10px 28px rgba(42,45,91,.04)!important}.ministry-top-metrics span{font-size:20px!important}.ministry-top-metrics strong{font-size:21px!important}.ministry-top-metrics small{font-size:8px!important}
  .ministry-timer-hero{--timer-progress:0deg;grid-area:timer;min-height:272px!important;border-radius:24px!important;padding:20px!important;display:grid!important;grid-template-rows:auto 1fr auto!important;align-items:center!important;justify-items:center!important;background:linear-gradient(145deg,#ffffff,#f5f3ff)!important;box-shadow:var(--desktop-soft-shadow)!important;position:relative!important;overflow:hidden!important}.ministry-timer-hero::before{content:"";position:absolute;width:184px;height:184px;border-radius:50%;background:conic-gradient(from -90deg,#7594ee 0deg,#8a6ce8 var(--timer-progress),#e7e9f7 var(--timer-progress) 360deg);-webkit-mask:radial-gradient(farthest-side,transparent calc(100% - 16px),#000 calc(100% - 15px));mask:radial-gradient(farthest-side,transparent calc(100% - 16px),#000 calc(100% - 15px));top:45px;left:50%;transform:translateX(-50%);filter:drop-shadow(0 8px 15px rgba(91,74,213,.10));transition:background .25s linear}.ministry-timer-hero>header{width:100%;z-index:1}.ministry-timer-hero .timer-display{z-index:1;font-size:30px!important;letter-spacing:-.04em!important;padding:0!important;align-self:center!important}.ministry-timer-hero .timer-actions{z-index:1;width:100%;grid-template-columns:1fr!important;gap:8px!important}.ministry-timer-hero .timer-start{min-height:45px!important;border-radius:14px!important}.ministry-timer-hero [data-ministry-timer-pause]{width:100%!important}.ministry-timer-hero [data-ministry-timer-save]{grid-column:auto!important;min-height:36px!important}
  .ministry-goal-grid{grid-area:goals;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important;margin:0!important}.ministry-goal-grid .goal-card{min-height:164px;padding:17px!important;border-radius:20px!important;box-shadow:0 10px 28px rgba(42,45,91,.04)}.ministry-goal-grid .goal-card>b{font-size:25px!important}.ministry-goal-grid .goal-card>p{min-height:42px}
  .ministry-profile-card{grid-area:profile;margin:0!important;border-radius:18px!important;padding:12px 16px!important;box-shadow:0 10px 28px rgba(42,45,91,.04)}
  .ministry-bottom-grid{grid-area:bottom;grid-template-columns:minmax(0,1.35fr) minmax(340px,.75fr)!important;gap:13px!important}.ministry-recent-panel{min-height:230px!important;border-radius:22px!important;box-shadow:var(--desktop-soft-shadow)!important}.ministry-recent-panel .module-empty{min-height:160px!important}.ministry-year-mini{border-radius:22px!important;box-shadow:var(--desktop-soft-shadow)!important}.ministry-year-mini .year-bars{height:150px!important}
  .ministry-calendar-card,.report-card,.service-year-card{box-shadow:var(--desktop-soft-shadow)}

  /* NOTES — selected B: dark unified sidebar + notes library + editor. */
  .app{height:100dvh;display:grid!important;grid-template-columns:var(--desktop-nav-w) var(--desktop-library-w) minmax(0,1fr)!important;background:linear-gradient(135deg,#f7f8fc,#f3f4fa)!important;transition:grid-template-columns .24s ease!important}
  .notes-global-nav{grid-column:1;grid-row:1}
  .app>.sidebar{grid-column:2;grid-row:1;position:relative!important;inset:auto!important;width:100%!important;transform:none!important;opacity:1!important;pointer-events:auto!important;border-right:1px solid rgba(91,91,132,.12)!important;background:rgba(250,250,254,.92)!important;box-shadow:10px 0 30px rgba(32,37,77,.035)!important;z-index:22!important}
  .app>.workspace{grid-column:3;grid-row:1;height:100dvh!important;background:linear-gradient(135deg,#fbfbfe,#f5f5fb)!important}
  .app.sidebar-collapsed{grid-template-columns:var(--desktop-nav-w) 0 minmax(0,1fr)!important}.app.sidebar-collapsed>.sidebar{transform:translateX(-100%)!important;opacity:0!important;pointer-events:none!important}
  .app.focus-mode{grid-template-columns:1fr!important}.app.focus-mode .desktop-global-nav{display:none!important}.app.focus-mode>.workspace{grid-column:1!important}
  .sidebar-header{height:68px!important;padding:0 13px 0 17px!important;background:rgba(255,255,255,.70)!important}.sidebar-header .brand{display:none!important}.notes-library-heading{display:block!important;font-size:18px;letter-spacing:-.03em}.sidebar-collapse-button{display:grid!important}
  .pages-tools{padding:14px 14px 10px!important}.compact-actions{grid-template-columns:1.35fr .9fr .9fr!important;gap:7px!important;margin:0 0 10px!important}.compact-actions button{height:48px!important;border-radius:13px!important}.compact-actions .action-page{background:linear-gradient(135deg,#8a68f5,#644be6)!important;color:#fff!important;border:0!important;box-shadow:0 10px 24px rgba(84,63,200,.18)!important}.compact-actions .action-page .action-icon,.compact-actions .action-page small{color:#fff!important}.compact-actions small{font-size:9px!important}.search-box{height:42px!important;border-radius:13px!important;background:#fff!important}.page-list{padding:0 10px 14px!important}.folder-block{border-radius:14px!important;background:#fff!important}.page-open{border-radius:12px!important;margin-bottom:4px!important}.sidebar-footer{display:none!important}
  .workspace{grid-template-rows:68px minmax(0,1fr)!important}.topbar{height:68px!important;padding:0 18px!important;background:rgba(250,250,254,.86)!important}.notes-screen-title{display:none!important}.topbar-left{order:0}.topbar-actions{gap:5px!important}.topbar-actions .wol-book-button{width:auto!important;min-width:112px!important;padding:0 12px!important;display:flex!important;gap:7px!important;border-radius:13px!important;color:#4d43d7!important;background:#f0edff!important}.wol-button-label{display:inline!important;font-size:9px;font-weight:750}.topbar-actions .icon-button{border:1px solid rgba(91,91,132,.12);background:#fff}
  .workspace-scroll{padding:20px!important;background:transparent!important}.empty-workspace{min-height:calc(100dvh - 108px)!important;border:1px solid rgba(96,91,164,.12)!important;border-radius:24px!important;background:rgba(255,255,255,.88)!important;box-shadow:var(--desktop-soft-shadow)!important}.empty-workspace h2{font-size:28px!important}.empty-workspace button{border:0!important;background:linear-gradient(135deg,#8061f5,#5d48de)!important;color:#fff!important;box-shadow:0 12px 28px rgba(82,63,201,.18)!important}
  .paper{max-width:none!important;min-height:calc(100dvh - 108px)!important;border-radius:24px!important;padding:46px 58px 42px!important}.page-heading,.template-heading,.toolbar,.free-editor,.template-program,.paper-footer{max-width:980px!important}.page-title{font-size:52px!important}.free-editor{max-width:820px!important;font-size:19px!important}
  .notes-bottom-nav{display:none!important}

  /* SETTINGS uses the same shell and remains comfortably wide. */
  .settings-screen{max-width:1180px!important}.settings-layout{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:16px!important}.settings-group,.settings-welcome,.privacy-note{box-shadow:0 12px 34px rgba(42,45,91,.05)}
}

@media (min-width:761px){
  .portal[data-active-module="hub"] .local-pill,
  .portal[data-active-module="hub"] .portal-icon-button{
    border-color:rgba(91,91,132,.13)!important;background:rgba(255,255,255,.88)!important;color:#343a58!important
  }
  .portal[data-active-module="hub"] .hub-header-create{color:#fff!important}
  .portal[data-active-module="hub"] .hub-screen{color:var(--text)!important}
  .portal[data-active-module="hub"] .premium-summary{background:rgba(255,255,255,.82)!important;border:1px solid rgba(91,91,132,.10)!important}
  .portal[data-active-module="hub"] .premium-summary h2{color:#232844!important}
  .portal[data-active-module="hub"] .premium-summary>header button{color:#6255d6!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div{background:rgba(248,248,253,.86)!important;border-color:rgba(91,91,132,.10)!important}
  .portal[data-active-module="hub"] .premium-summary .summary-icon{color:#5c4cdd!important;background:#eeebff!important}
  .portal[data-active-module="hub"] .premium-summary strong{color:#222742!important}
  .portal[data-active-module="hub"] .premium-summary small{color:#7a8096!important}
}

/* Tablet landscape tuning: preserve the horizontal experience without overflow. */

@media (min-width:761px) and (max-width:1180px){
  :root{--desktop-nav-w:200px;--desktop-library-w:270px}
  .portal-main{padding:24px 24px 36px!important}
  .desktop-global-nav{padding-inline:12px}.desktop-nav-brand{padding-inline:5px}.desktop-nav-focus-card{padding:12px}.desktop-nav-menu button b{font-size:10px}
  .hub-hero{grid-template-columns:minmax(280px,1fr) minmax(280px,.78fr);gap:18px;padding:25px 28px}.hub-kicker{font-size:36px!important}.hub-greeting h1{font-size:13px!important}
  .premium-hub-grid{gap:12px!important}.premium-hub-grid .hub-card{min-height:184px!important;padding:18px!important}.premium-hub-grid .hub-card-copy strong{font-size:19px!important}
  .module-title-copy h1{font-size:34px!important}.module-primary{min-width:100px!important;padding-inline:13px!important;font-size:11px!important}

  [data-module-screen="revisits"] .module-toolbar{grid-template-columns:1fr!important;gap:9px!important}
  [data-module-screen="revisits"] .segmented{min-width:0!important;width:100%!important}
  .revisits-metrics{gap:8px!important}.revisits-metrics article{min-width:0!important;min-height:80px!important;padding:11px 9px!important}.revisits-metrics .metric-icon{width:31px;height:31px}.revisits-metrics strong{font-size:21px!important}
  .people-records-panel{min-width:0!important}

  .ministry-panel[data-ministry-panel="overview"]{grid-template-columns:minmax(280px,.82fr) minmax(0,1.45fr)!important;gap:10px!important}
  .ministry-top-metrics{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}.ministry-top-metrics article{min-width:0!important;min-height:76px!important;padding:9px 6px!important}.ministry-top-metrics span{font-size:16px!important}.ministry-top-metrics strong{font-size:18px!important}
  .ministry-timer-hero{min-width:0!important;min-height:266px!important;padding:16px!important}.ministry-timer-hero::before{width:168px;height:168px;top:48px}.ministry-timer-hero .timer-display{font-size:27px!important}
  .ministry-goal-grid{min-width:0!important;gap:8px!important}.ministry-goal-grid .goal-card{min-width:0!important;min-height:145px!important;padding:14px!important}.ministry-goal-grid .goal-card>b{font-size:21px!important}
  .ministry-profile-card,.ministry-bottom-grid,.ministry-bottom-grid>*{min-width:0!important}.ministry-bottom-grid{grid-template-columns:minmax(0,1.35fr) minmax(260px,.65fr)!important;gap:10px!important}
  .ministry-year-mini .year-bars{height:130px!important}
  .service-year-pill{min-width:210px!important}

  .app{grid-template-columns:var(--desktop-nav-w) var(--desktop-library-w) minmax(0,1fr)!important}.workspace-scroll{padding:18px!important}.empty-workspace{min-width:0!important}.topbar-actions .wol-book-button{min-width:104px!important}
}

/* =========================================================
   DESKTOP/TABLET POLISH
   Requested cleanup: compact Settings, simplified actions,
   Settings navigation label, and a live Ministry timer ring.
   ========================================================= */

/* The local lock/status is not needed inside Revisitas y Estudios. */

.portal[data-active-module="revisits"] .local-pill{display:none!important}

@media (min-width:761px){
  /* Hub: no global plus button. */
  .portal[data-active-module="hub"] .hub-header-create{display:none!important}

  /* Revisitas: remove both desktop local-status indicators from this module. */
  .portal[data-active-module="revisits"] .portal-global-nav .desktop-local-status{display:none!important}

  /* Notes: the library already contains Página, Carpeta and Seleccionar. */
  .notes-global-nav .desktop-new-note{display:none!important}
  .notes-global-nav .desktop-nav-menu{margin-top:4px}
  .desktop-nav-links button b{letter-spacing:.01em}

  /* Short, clear WOL label. */
  .topbar-actions .wol-book-button{min-width:82px!important}

  /* Settings: compact two-column dashboard that fits a standard landscape screen. */
  .settings-screen{max-width:1120px!important}
  .settings-screen .module-header{margin-bottom:12px!important}
  .settings-screen .module-title-copy h1,.settings-screen .settings-title-copy h1{font-size:34px!important}
  .settings-screen .settings-title-copy>p:last-child{font-size:10px!important;margin-top:3px!important}
  .settings-layout{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;
    grid-template-areas:
      "appearance data"
      "ministry app"
      "privacy privacy";
    gap:12px!important;
    align-items:start;
  }
  .appearance-settings-group{grid-area:appearance}
  .ministry-settings-group{grid-area:ministry}
  .data-settings-group{grid-area:data}
  .app-settings-group{grid-area:app}
  .settings-layout>.privacy-note{grid-area:privacy;margin:0!important}
  .settings-welcome{display:none!important}
  .settings-group{padding:14px 16px!important;border-radius:18px!important}
  .settings-group>header{padding-bottom:9px!important;margin-bottom:0!important}
  .settings-group>header>span{width:36px!important;height:36px!important;border-radius:11px!important;font-size:16px!important}
  .settings-group h2{font-size:16px!important}
  .settings-group header p{font-size:8px!important;margin-top:2px!important}
  .settings-control,.settings-action{min-height:49px!important;padding-block:6px!important}
  .settings-control>span,.settings-action b{font-size:10px!important}
  .settings-action small{font-size:7.5px!important;margin-top:2px!important}
  .settings-control select{min-width:130px!important;padding:8px 28px 8px 10px!important;font-size:9px!important}
  .ministry-rule-note{padding:8px 10px!important;font-size:8px!important}
  .ministry-facts{padding:9px 10px!important;grid-template-columns:28px 1fr!important;gap:8px!important}
  .ministry-facts>span{width:28px!important;height:28px!important;font-size:14px!important}
  .ministry-facts ul{gap:2px!important}.ministry-facts li{font-size:7px!important;line-height:1.35!important}
  .privacy-note{min-height:auto!important;padding:10px 14px!important;border-radius:15px!important;display:grid!important;grid-template-columns:28px 1fr!important;gap:9px!important}
  .privacy-note>span{width:28px!important;height:28px!important;font-size:14px!important}.privacy-note strong{font-size:10px!important}.privacy-note p{font-size:7.5px!important;line-height:1.4!important;margin-top:2px!important}
}

/* =========================================================
   DESKTOP/TABLET CLEANUP
   These rules apply to desktop and tablet layouts. Mobile is unchanged.
   ========================================================= */

@media (min-width:761px){
  /* Keep one clear local-status indicator in the unified sidebar. */
  .portal-header{display:none!important}
  .portal{grid-template-rows:minmax(0,1fr)!important}
  .portal-global-nav{grid-row:1!important}
  .portal-main{grid-row:1!important;padding-top:24px!important}
  .desktop-local-status{display:flex!important}
  .portal[data-active-module="revisits"] .portal-global-nav .desktop-local-status{display:flex!important}

  /* Remove duplicated inspirational widgets; retain only the current sync status at the bottom. */

  /* A white Notea symbol has proper contrast on the gradient sidebar. */
  .desktop-nav-brand img{content:url("/assets/notea-symbol-white.png");filter:none!important;opacity:.98}
  .desktop-nav-brand>span:first-child{filter:drop-shadow(0 8px 16px rgba(7,12,55,.22))}

  /* Notes: WOL remains in the editor toolbar, not repeated at the bottom of navigation. */
  .notes-global-nav .desktop-nav-links{display:none!important}
  .notes-global-nav .desktop-local-status{margin-top:auto}

  /* Softer Página action so the document glyph remains crisp and visible. */
  .compact-actions .action-page{
    color:#5d50cf!important;
    background:linear-gradient(145deg,#f3f0ff,#e7e2ff)!important;
    border:1px solid rgba(102,83,214,.18)!important;
    box-shadow:0 8px 20px rgba(75,61,170,.08)!important
  }
  .compact-actions .action-page .action-icon{
    color:#5d50cf!important;
    background:rgba(255,255,255,.72)!important;
    box-shadow:inset 0 0 0 1px rgba(102,83,214,.08)
  }
  .compact-actions .action-page small{color:#5146bf!important}
  .compact-actions .action-page:hover{background:linear-gradient(145deg,#ece7ff,#ded7ff)!important;transform:translateY(-1px)}

  /* Focus mode is a centered writing canvas instead of an oversized blank sheet. */
  .app.focus-mode{background:linear-gradient(135deg,#f3f4fa,#eceef8)!important}
  .app.focus-mode .workspace-scroll{padding:24px!important;display:block!important}
  .app.focus-mode .paper,
  .app.focus-mode .empty-workspace{
    width:min(1040px,calc(100vw - 72px))!important;
    min-height:calc(100dvh - 48px)!important;
    margin:0 auto!important;
    border:1px solid rgba(96,91,164,.12)!important;
    border-radius:26px!important;
    background:rgba(255,255,255,.94)!important;
    box-shadow:0 26px 70px rgba(35,40,89,.10)!important
  }
  .app.focus-mode .paper{padding:52px 64px 44px!important}
  .app.focus-mode .focus-exit{top:18px;right:24px;border-color:rgba(96,91,164,.16);background:rgba(255,255,255,.92);box-shadow:0 10px 28px rgba(35,40,89,.10)}

  /* Settings: no redundant back button, eyebrow, description, gear or privacy block. */
  .settings-screen .back-button,
  .settings-screen .settings-section-icon,
  .settings-screen .settings-title-copy .eyebrow,
  .settings-screen .settings-title-copy>p:last-child{display:none!important}
  .settings-screen .settings-title-copy h1{font-size:34px!important;line-height:1!important;margin:0!important}
  .settings-screen .settings-layout{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    grid-template-areas:"appearance ministry" "data app"!important;
    gap:12px!important
  }
  .settings-screen .settings-group{padding:13px 15px!important;border-radius:18px!important}
  .settings-screen .settings-group>header{padding-bottom:8px!important}
  .settings-screen .settings-group>header>span{width:34px!important;height:34px!important;border-radius:11px!important}
  .settings-screen .settings-group h2{font-size:15px!important}
  .settings-screen .settings-control,.settings-screen .settings-action{min-height:46px!important}
  .settings-screen .settings-action small{font-size:7.5px!important}
  .settings-screen .ministry-facts{margin-top:8px!important;padding:8px 10px!important}

  /* Every Ministry tab replaces the current content area and starts at the same viewport position. */
  [data-module-screen="ministry"] [data-ministry-panel="calendar"] .ministry-calendar-card,
  [data-module-screen="ministry"] [data-ministry-panel="report"] .report-grid{
    min-height:calc(100dvh - 220px)!important;
    align-content:start
  }
}

/* =========================================================
   DESKTOP/TABLET TYPOGRAPHY CLARITY
   Slightly larger, crisper interface text for Revisitas,
   Ministerio and Ajustes. Mobile remains unchanged.
   ========================================================= */

@media (min-width:761px){
  [data-module-screen="revisits"],
  [data-module-screen="ministry"],
  .settings-screen{
    -webkit-font-smoothing:antialiased;
    -moz-osx-font-smoothing:grayscale;
    text-rendering:optimizeLegibility;
  }

  /* Revisitas y Estudios */
  [data-module-screen="revisits"] .module-title-copy p{font-size:13px!important;line-height:1.5!important}
  [data-module-screen="revisits"] .module-search input{font-size:14px!important;font-weight:500!important}
  [data-module-screen="revisits"] .segmented button{font-size:11px!important;font-weight:780!important}
  [data-module-screen="revisits"] .revisits-metrics small{font-size:10px!important;font-weight:700!important}
  [data-module-screen="revisits"] .revisits-metrics span{font-size:10px!important}
  [data-module-screen="revisits"] .people-records-panel h2{font-size:18px!important}
  [data-module-screen="revisits"] .people-records-panel>header span{font-size:11px!important}
  [data-module-screen="revisits"] .record-main strong{font-size:14px!important;font-weight:800!important}
  [data-module-screen="revisits"] .record-main small{font-size:11px!important;line-height:1.4!important}
  [data-module-screen="revisits"] .record-main em{font-size:10px!important}
  [data-module-screen="revisits"] .status-chip{font-size:9px!important}
  [data-module-screen="revisits"] .module-empty p{font-size:12px!important;line-height:1.5!important}

  /* Ministerio */
  [data-module-screen="ministry"] .module-title-copy p{font-size:13px!important;line-height:1.5!important}
  [data-module-screen="ministry"] .ministry-toolbar .segmented button{font-size:11px!important;font-weight:780!important}
  [data-module-screen="ministry"] .service-year-pill{font-size:11px!important;font-weight:650!important}
  [data-module-screen="ministry"] .ministry-top-metrics small{font-size:10px!important;font-weight:650!important}
  [data-module-screen="ministry"] .ministry-timer-hero>header small,
  [data-module-screen="ministry"] .timer-card small{font-size:10px!important}
  [data-module-screen="ministry"] .timer-actions button{font-size:11px!important}
  [data-module-screen="ministry"] .goal-card header strong{font-size:12px!important}
  [data-module-screen="ministry"] .goal-card header span{font-size:10px!important}
  [data-module-screen="ministry"] .goal-card>small{font-size:9.5px!important;line-height:1.4!important}
  [data-module-screen="ministry"] .goal-card>p{font-size:10px!important;line-height:1.45!important}
  [data-module-screen="ministry"] .ministry-profile-card strong{font-size:15px!important}
  [data-module-screen="ministry"] .ministry-profile-card small{font-size:10.5px!important;line-height:1.45!important}
  [data-module-screen="ministry"] .ministry-recent-panel h2{font-size:18px!important}
  [data-module-screen="ministry"] .ministry-recent-panel>header span{font-size:10px!important}
  [data-module-screen="ministry"] .module-empty p{font-size:11.5px!important;line-height:1.5!important}
  [data-module-screen="ministry"] .calendar-weekday{font-size:10px!important}
  [data-module-screen="ministry"] .calendar-day b{font-size:14px!important}
  [data-module-screen="ministry"] .calendar-day small{font-size:9.5px!important}
  [data-module-screen="ministry"] .calendar-hint{font-size:11px!important}
  [data-module-screen="ministry"] .report-card small,
  [data-module-screen="ministry"] .service-year-card small{font-size:10px!important}
  [data-module-screen="ministry"] .report-card dt{font-size:12px!important}
  [data-module-screen="ministry"] .report-actions button{font-size:11px!important}
  [data-module-screen="ministry"] .year-bar small,
  [data-module-screen="ministry"] .year-bar b{font-size:8px!important}

  /* Ajustes */
  .settings-screen .settings-group h2{font-size:17px!important;font-weight:800!important}
  .settings-screen .settings-control>span,
  .settings-screen .settings-action b{font-size:12px!important;font-weight:750!important}
  .settings-screen .settings-action small{font-size:9px!important;line-height:1.4!important}
  .settings-screen .settings-control select{font-size:11px!important;font-weight:650!important}
  .settings-screen .ministry-facts li{font-size:9px!important;line-height:1.45!important}
}

/* =========================================================
   DESKTOP/TABLET MINISTRY TABS + THEMED NAV
   - Ministry tabs replace the active panel in the same area.
   - The unified left navigation follows the selected theme.
   Mobile remains unchanged.
   ========================================================= */

@media (min-width:761px){
  /* The overview has an explicit display:grid rule. This stronger hidden
     rule ensures Calendar and Report replace it instead of appearing below. */
  [data-module-screen="ministry"] .ministry-panel:not([hidden]){width:100%;margin-top:0!important}
  [data-module-screen="ministry"] .ministry-panel[data-ministry-panel="overview"]:not([hidden]){display:grid!important}
  [data-module-screen="ministry"] .ministry-panel[data-ministry-panel="calendar"]:not([hidden]),
  [data-module-screen="ministry"] .ministry-panel[data-ministry-panel="report"]:not([hidden]){display:block!important}

  /* Theme-aware gradient palette for the unified desktop/tablet sidebar. */
  html[data-theme="light"]{
    --desktop-nav-start:#6856ec;--desktop-nav-mid:#4238b4;--desktop-nav-end:#202b70;
    --desktop-nav-glow:rgba(158,178,255,.24);--desktop-nav-shadow:rgba(40,35,125,.20)
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]){
    --desktop-nav-start:#3b4267;--desktop-nav-mid:#292e49;--desktop-nav-end:#151824;
    --desktop-nav-glow:rgba(139,145,255,.20);--desktop-nav-shadow:rgba(0,0,0,.34)
  }
  html[data-theme="pink"]{
    --desktop-nav-start:#ef7fb6;--desktop-nav-mid:#c94f91;--desktop-nav-end:#702b60;
    --desktop-nav-glow:rgba(255,196,224,.26);--desktop-nav-shadow:rgba(125,43,88,.22)
  }
  html[data-theme="green"]{
    --desktop-nav-start:#59c488;--desktop-nav-mid:#318d64;--desktop-nav-end:#1e5747;
    --desktop-nav-glow:rgba(169,241,196,.24);--desktop-nav-shadow:rgba(27,91,60,.22)
  }
  html[data-theme="purple"]{
    --desktop-nav-start:#9b76ef;--desktop-nav-mid:#704fc8;--desktop-nav-end:#392a78;
    --desktop-nav-glow:rgba(207,182,255,.25);--desktop-nav-shadow:rgba(71,44,133,.23)
  }
  html[data-theme="yellow"]{
    --desktop-nav-start:#dda943;--desktop-nav-mid:#aa7923;--desktop-nav-end:#62471d;
    --desktop-nav-glow:rgba(255,224,147,.25);--desktop-nav-shadow:rgba(105,72,18,.22)
  }
  .desktop-global-nav{
    background:
      radial-gradient(circle at 18% 8%,rgba(255,255,255,.20),transparent 24%),
      linear-gradient(165deg,var(--desktop-nav-start) 0%,var(--desktop-nav-mid) 49%,var(--desktop-nav-end) 100%)!important;
    box-shadow:16px 0 45px var(--desktop-nav-shadow)!important;
    transition:background .28s ease,box-shadow .28s ease
  }
  .desktop-global-nav::after{background:var(--desktop-nav-glow)!important;transition:background .28s ease}
}

/* =========================================================
   JAPANDI PRODUCTIVITY DESKTOP / TABLET
   Concept C selected by the user. Visual-only redesign for
   landscape desktop/tablet. Mobile styles remain unchanged.
   ========================================================= */

@media (min-width:761px){
  :root{
    --c-bg:#f4f0e9;--c-bg-2:#ebe5dc;--c-paper:#fffdf8;--c-paper-2:#f8f4ec;
    --c-ink:#283028;--c-muted:#737b70;--c-line:#d8d0c4;
    --c-accent:#788c72;--c-accent-deep:#5e745a;--c-accent-soft:#e5ece1;
    --c-lav:#aaa1c8;--c-lav-soft:#eeeaf6;--c-gold:#c9a66a;--c-gold-soft:#f5ead4;
    --c-blue:#8da9b6;--c-blue-soft:#e6eef1;--c-stone:#b8afa3;--c-shadow:0 18px 52px rgba(75,69,57,.10);
    --c-shadow-soft:0 10px 28px rgba(75,69,57,.07);
    --c-display:"Inter","Aptos","Segoe UI",system-ui,-apple-system,sans-serif;
    --c-ui:"Inter","Aptos","Segoe UI",system-ui,-apple-system,sans-serif;
    --desktop-nav-w:214px;--desktop-library-w:304px;
    --c-nav-start:#f8f4eb;--c-nav-end:#ece5d9;--c-nav-active:#7f9378;--c-nav-ink:#30372f;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]){
    --c-bg:#1f2420;--c-bg-2:#171b18;--c-paper:#292f2a;--c-paper-2:#242a25;
    --c-ink:#f1efe7;--c-muted:#adb5aa;--c-line:#455047;
    --c-accent:#91a88a;--c-accent-deep:#748d70;--c-accent-soft:#344138;
    --c-lav:#aaa0c6;--c-lav-soft:#3a3545;--c-gold:#d0ad72;--c-gold-soft:#433a2d;
    --c-blue:#93aeb7;--c-blue-soft:#344247;--c-stone:#857e74;--c-shadow:0 20px 56px rgba(0,0,0,.30);
    --c-shadow-soft:0 12px 30px rgba(0,0,0,.20);
    --c-nav-start:#263028;--c-nav-end:#1c231d;--c-nav-active:#81977c;--c-nav-ink:#f3efe5;
  }
  html[data-theme="pink"]{
    --c-bg:#f5ecec;--c-bg-2:#eadcdc;--c-paper:#fffafa;--c-paper-2:#f8eeee;
    --c-ink:#3b2e32;--c-muted:#856e76;--c-line:#dec9ce;
    --c-accent:#b87d8e;--c-accent-deep:#975f72;--c-accent-soft:#f2dfe5;
    --c-lav:#aa95c4;--c-lav-soft:#eee5f5;--c-gold:#c8a36b;--c-gold-soft:#f5ead8;
    --c-blue:#8da7b0;--c-blue-soft:#e6eff1;--c-nav-start:#f5e9ed;--c-nav-end:#ead7df;--c-nav-active:#b5768b;--c-nav-ink:#4a3039;
  }
  html[data-theme="green"]{
    --c-bg:#edf2ea;--c-bg-2:#dfe8dc;--c-paper:#fbfdf7;--c-paper-2:#f1f6ee;
    --c-ink:#27352b;--c-muted:#6c7c70;--c-line:#cbd9ca;
    --c-accent:#69906f;--c-accent-deep:#4f7258;--c-accent-soft:#deebdf;
    --c-lav:#9f99bd;--c-lav-soft:#ebe9f3;--c-gold:#c3a160;--c-gold-soft:#f3ead4;
    --c-blue:#84a6ae;--c-blue-soft:#dfedef;--c-nav-start:#edf4e9;--c-nav-end:#dce8d9;--c-nav-active:#658b6c;--c-nav-ink:#29402f;
  }
  html[data-theme="purple"]{
    --c-bg:#f0ebf4;--c-bg-2:#e3dce9;--c-paper:#fdfafd;--c-paper-2:#f5eff7;
    --c-ink:#342f3a;--c-muted:#7c7183;--c-line:#d5c9dc;
    --c-accent:#9381a9;--c-accent-deep:#745f8d;--c-accent-soft:#e8dff0;
    --c-lav:#9c8dbd;--c-lav-soft:#e9e2f1;--c-gold:#c5a16c;--c-gold-soft:#f4e9d6;
    --c-blue:#8fa5b4;--c-blue-soft:#e4ecf1;--c-nav-start:#f1ebf5;--c-nav-end:#e2d9ea;--c-nav-active:#8d79a5;--c-nav-ink:#42364b;
  }
  html[data-theme="yellow"]{
    --c-bg:#f5f0df;--c-bg-2:#eae1c8;--c-paper:#fffdf4;--c-paper-2:#f9f3df;
    --c-ink:#3a3427;--c-muted:#81765f;--c-line:#ded2b4;
    --c-accent:#aa925c;--c-accent-deep:#8d7444;--c-accent-soft:#f0e8cc;
    --c-lav:#9e97b7;--c-lav-soft:#ebe8f0;--c-gold:#c39545;--c-gold-soft:#f4e4bd;
    --c-blue:#8da3aa;--c-blue-soft:#e5eceb;--c-nav-start:#f5efdc;--c-nav-end:#e8dfc4;--c-nav-active:#a38b55;--c-nav-ink:#493f2b;
  }

  body{font-family:var(--c-ui);background:var(--c-bg);color:var(--c-ink);-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}

  /* Unified Japandi navigation — calm, light and theme-aware. */
  .desktop-global-nav{
    color:var(--c-nav-ink)!important;padding:20px 14px 14px!important;
    background:
      radial-gradient(circle at 20% 88%,color-mix(in srgb,var(--c-nav-active) 13%,transparent),transparent 30%),
      linear-gradient(170deg,var(--c-nav-start),var(--c-nav-end))!important;
    border-right:1px solid color-mix(in srgb,var(--c-line) 86%,transparent)!important;
    box-shadow:12px 0 40px rgba(76,70,59,.08)!important;overflow:hidden!important
  }
  .desktop-global-nav::before{
    content:"";position:absolute;left:22px;right:22px;bottom:102px;height:94px;opacity:.48;pointer-events:none;
    background:
      radial-gradient(ellipse at 24% 74%,transparent 0 27%,color-mix(in srgb,var(--c-nav-active) 34%,transparent) 28% 29%,transparent 30%),
      radial-gradient(ellipse at 58% 52%,transparent 0 25%,color-mix(in srgb,var(--c-nav-active) 30%,transparent) 26% 27%,transparent 28%),
      linear-gradient(115deg,transparent 48%,color-mix(in srgb,var(--c-nav-active) 34%,transparent) 49% 50%,transparent 51%);
    transform:rotate(-7deg)
  }
  .desktop-global-nav::after{width:210px!important;height:210px!important;right:-108px!important;bottom:-112px!important;background:color-mix(in srgb,var(--c-nav-active) 10%,transparent)!important}
  .desktop-nav-brand{gap:11px!important;padding:0 6px 22px!important;color:var(--c-nav-ink)!important}
  .desktop-nav-brand>span:first-child{width:42px!important;height:42px!important;border-radius:13px!important;background:var(--c-nav-active)!important;padding:7px!important;box-shadow:0 10px 20px color-mix(in srgb,var(--c-nav-active) 20%,transparent)!important}
  .desktop-nav-brand>span:first-child img{filter:brightness(0) invert(1)!important}
  .desktop-nav-brand strong{font-family:var(--c-display);font-size:21px!important;letter-spacing:-.01em!important;color:var(--c-nav-ink)!important}
  .desktop-nav-brand small{color:color-mix(in srgb,var(--c-nav-ink) 57%,transparent)!important;font-size:8.5px!important}
  .desktop-nav-menu{gap:5px!important}
  .desktop-nav-menu button,.desktop-nav-links button{min-height:43px!important;border:1px solid transparent!important;border-radius:12px!important;color:color-mix(in srgb,var(--c-nav-ink) 72%,transparent)!important;grid-template-columns:32px 1fr!important;padding:0 9px!important}
  .desktop-nav-menu button>span,.desktop-nav-links button>span{width:29px!important;height:29px!important;border-radius:9px!important;font-size:15px!important;background:transparent!important}
  .desktop-nav-menu button b,.desktop-nav-links button b{font-size:10.5px!important;font-weight:700!important}
  .desktop-nav-menu button:hover,.desktop-nav-links button:hover{background:color-mix(in srgb,var(--c-nav-active) 8%,transparent)!important;color:var(--c-nav-ink)!important}
  .desktop-nav-menu button.is-active{background:var(--c-nav-active)!important;color:#fffdf7!important;border-color:color-mix(in srgb,var(--c-nav-active) 80%,#fff)!important;box-shadow:0 10px 23px color-mix(in srgb,var(--c-nav-active) 24%,transparent)!important}
  .desktop-nav-menu button.is-active>span{background:rgba(255,255,255,.16)!important}
  .desktop-nav-focus-card{display:none!important}
  .desktop-nav-spacer{min-height:110px!important}
  .desktop-local-status{margin:0 4px!important;border:1px solid color-mix(in srgb,var(--c-nav-active) 20%,var(--c-line))!important;background:color-mix(in srgb,var(--c-paper) 52%,transparent)!important;color:color-mix(in srgb,var(--c-nav-ink) 73%,transparent)!important;border-radius:12px!important;padding:9px 10px!important}
  .desktop-local-status i{background:#5bbb7c!important;box-shadow:0 0 0 4px rgba(91,187,124,.13)!important}

  /* Shared canvas and typography. */
  .portal,.app{
    background:
      radial-gradient(circle at 93% 6%,color-mix(in srgb,var(--c-lav) 14%,transparent),transparent 28%),
      radial-gradient(circle at 10% 92%,color-mix(in srgb,var(--c-gold) 10%,transparent),transparent 27%),
      linear-gradient(135deg,var(--c-bg),var(--c-bg-2))!important
  }
  .portal-main{position:relative;padding:25px 32px 40px!important}
  .portal-main::after{content:"";position:fixed;right:20px;bottom:18px;width:210px;height:160px;pointer-events:none;opacity:.20;background:radial-gradient(ellipse at 30% 72%,transparent 0 29%,var(--c-accent) 30% 31%,transparent 32%),radial-gradient(ellipse at 66% 47%,transparent 0 26%,var(--c-accent) 27% 28%,transparent 29%),linear-gradient(122deg,transparent 49%,var(--c-accent) 50% 50.7%,transparent 51%);transform:rotate(-10deg)}
  .portal-screen{width:min(1290px,100%)!important}
  .portal-screen[hidden]{display:none!important}
  .module-screen{padding-top:0!important}
  .module-title-copy h1,.settings-title-copy h1,.hub-kicker,.notes-screen-title{font-family:var(--c-display)!important;color:var(--c-ink)!important}
  .module-title-copy h1{font-size:43px!important;letter-spacing:-.045em!important}
  .module-title-copy p{color:var(--c-muted)!important;line-height:1.5!important}
  .module-primary,.primary,.timer-start,.report-actions .primary{background:linear-gradient(135deg,var(--c-accent),var(--c-accent-deep))!important;border-color:var(--c-accent-deep)!important;color:#fff!important;box-shadow:0 10px 22px color-mix(in srgb,var(--c-accent-deep) 23%,transparent)!important}
  .module-primary:hover,.primary:hover,.timer-start:hover{filter:brightness(1.03);transform:translateY(-1px)}

  /* Hub / Inicio */
  .hub-screen{display:grid!important;grid-template-columns:1fr!important;gap:15px!important}
  .hub-hero{position:relative!important;margin:0!important;padding:27px 30px!important;min-height:145px!important;grid-template-columns:minmax(0,1fr) minmax(360px,.72fr)!important;border:1px solid var(--c-line)!important;border-radius:24px!important;background:
      repeating-radial-gradient(ellipse at 88% 110%,transparent 0 27px,color-mix(in srgb,var(--c-line) 31%,transparent) 28px 29px,transparent 30px 51px),
      var(--c-paper)!important;box-shadow:var(--c-shadow)!important;overflow:hidden!important}
  .hub-hero::before{content:"";position:absolute;left:28px;bottom:-24px;width:150px;height:80px;border:1px solid color-mix(in srgb,var(--c-accent) 25%,transparent);border-radius:50%;transform:rotate(-7deg);opacity:.55}
  .hub-kicker{font-size:43px!important;font-weight:700!important;letter-spacing:-.045em!important}
  .hub-greeting h1{font-size:14px!important;color:var(--c-muted)!important;margin-top:7px!important}
  .hub-search{height:49px!important;border:1px solid var(--c-line)!important;border-radius:14px!important;background:color-mix(in srgb,var(--c-paper) 88%,transparent)!important;box-shadow:0 8px 20px rgba(75,69,57,.05)!important;padding-left:16px!important}
  .hub-search>span{color:var(--c-accent)!important}.hub-search input{color:var(--c-ink)!important}.hub-search input::placeholder{color:var(--c-muted)!important}.hub-search button{width:38px!important;height:38px!important;border-radius:11px!important;background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important;margin-right:5px!important}
  .premium-hub-grid{gap:14px!important}
  .premium-hub-grid .hub-card{min-height:195px!important;padding:20px!important;border:1px solid var(--c-line)!important;border-radius:22px!important;grid-template-columns:52px minmax(0,1fr) 38px!important;grid-template-rows:auto 1fr!important;box-shadow:var(--c-shadow-soft)!important;overflow:hidden!important}
  .premium-hub-grid .notes-card{background:linear-gradient(145deg,color-mix(in srgb,var(--c-accent-soft) 90%,var(--c-paper)),color-mix(in srgb,var(--c-accent) 17%,var(--c-paper)))!important}
  .premium-hub-grid .revisits-card{background:linear-gradient(145deg,var(--c-lav-soft),color-mix(in srgb,var(--c-lav) 23%,var(--c-paper)))!important}
  .premium-hub-grid .ministry-card{background:linear-gradient(145deg,var(--c-gold-soft),color-mix(in srgb,var(--c-gold) 22%,var(--c-paper)))!important}
  .premium-hub-grid .hub-card-icon{width:52px!important;height:52px!important;border-radius:15px!important;background:rgba(255,255,255,.65)!important;color:var(--c-ink)!important;border:1px solid rgba(255,255,255,.72)!important;box-shadow:0 8px 18px rgba(75,69,57,.06)!important}
  .premium-hub-grid .hub-card-copy{grid-column:1/4!important;align-self:end!important}.premium-hub-grid .hub-card-copy strong{font-family:var(--c-display)!important;font-size:24px!important;color:var(--c-ink)!important}.premium-hub-grid .hub-card-copy small{font-size:10.5px!important;color:var(--c-muted)!important;max-width:260px!important}
  .premium-hub-grid .hub-card-arrow{grid-column:3!important;grid-row:1!important;width:37px!important;height:37px!important;border:1px solid color-mix(in srgb,var(--c-line) 80%,transparent)!important;border-radius:50%!important;background:rgba(255,255,255,.34)!important;color:var(--c-ink)!important;font-size:22px!important}
  .premium-hub-grid .hub-card-art{display:none!important}
  .premium-summary{border:1px solid var(--c-line)!important;border-radius:22px!important;background:var(--c-paper)!important;box-shadow:var(--c-shadow-soft)!important;padding:17px 18px!important}
  .premium-summary header{border:0!important}.premium-summary h2{font-family:var(--c-display)!important;font-size:18px!important;color:var(--c-ink)!important}.premium-summary header button{color:var(--c-accent-deep)!important}
  .premium-summary .summary-grid{gap:10px!important}.premium-summary .summary-grid>div{border:1px solid var(--c-line)!important;border-radius:15px!important;background:var(--c-paper-2)!important;padding:13px!important}.premium-summary .summary-icon{background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important}.premium-summary .summary-grid>div:nth-child(2) .summary-icon{background:var(--c-lav-soft)!important;color:#756c9a!important}.premium-summary .summary-grid>div:nth-child(3) .summary-icon{background:var(--c-blue-soft)!important;color:#66858d!important}.premium-summary .summary-grid>div:nth-child(4) .summary-icon{background:var(--c-gold-soft)!important;color:#967640!important}.premium-summary strong{color:var(--c-ink)!important}.premium-summary small{color:var(--c-muted)!important}

  /* Shared modules */
  .module-header{margin-bottom:17px!important}.compact-module-header{grid-template-columns:minmax(0,1fr) auto!important}.module-mobile-section-icon{display:none!important}.module-toolbar{gap:12px!important;margin-bottom:13px!important}.module-search,.segmented{border:1px solid var(--c-line)!important;background:var(--c-paper)!important;box-shadow:0 8px 20px rgba(75,69,57,.045)!important}.module-search{border-radius:14px!important}.module-search span{color:var(--c-accent)!important}.module-search input{color:var(--c-ink)!important}.module-search input::placeholder{color:var(--c-muted)!important}.segmented{border-radius:13px!important;padding:4px!important}.segmented button{border-radius:9px!important;color:var(--c-muted)!important}.segmented button.is-active{background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important;box-shadow:none!important}

  /* Revisitas y Estudios */
  [data-module-screen="revisits"] .module-header{align-items:end!important}.revisits-primary{background:linear-gradient(135deg,var(--c-lav),#877da9)!important;border-color:#8176a5!important}
  .revisits-metrics{gap:10px!important;margin-bottom:13px!important}.revisits-metrics article{min-height:88px!important;border:1px solid var(--c-line)!important;border-radius:17px!important;padding:14px!important;grid-template-columns:37px 1fr!important;background:var(--c-paper)!important;box-shadow:var(--c-shadow-soft)!important}.revisits-metrics article:nth-child(1){background:color-mix(in srgb,var(--c-lav-soft) 75%,var(--c-paper))!important}.revisits-metrics article:nth-child(2){background:color-mix(in srgb,var(--c-blue-soft) 78%,var(--c-paper))!important}.revisits-metrics article:nth-child(3){background:color-mix(in srgb,var(--c-gold-soft) 78%,var(--c-paper))!important}.revisits-metrics article:nth-child(4){background:color-mix(in srgb,var(--c-accent-soft) 75%,var(--c-paper))!important}.revisits-metrics .metric-icon{width:35px!important;height:35px!important;border-radius:11px!important;background:rgba(255,255,255,.70)!important;color:var(--c-accent-deep)!important}.revisits-metrics strong{font-family:var(--c-display)!important;color:var(--c-ink)!important;font-size:25px!important}.revisits-metrics small{color:var(--c-muted)!important;font-size:9px!important}
  .people-records-panel{border:1px solid var(--c-line)!important;border-radius:20px!important;background:var(--c-paper)!important;box-shadow:var(--c-shadow)!important;overflow:hidden!important}.people-records-panel>header{border-color:var(--c-line)!important;background:linear-gradient(90deg,var(--c-paper),var(--c-paper-2))!important}.people-records-panel h2{font-family:var(--c-display)!important;color:var(--c-ink)!important}.person-group{border:1px solid var(--c-line)!important;border-radius:15px!important;background:var(--c-paper-2)!important}.person-group>header{border-color:var(--c-line)!important}.record-item{border-color:var(--c-line)!important}.record-avatar{background:var(--c-lav-soft)!important;color:#74699a!important}.record-main strong{color:var(--c-ink)!important}.record-main small{color:var(--c-muted)!important}.record-main em{color:var(--c-accent-deep)!important}.status-chip{background:var(--c-lav-soft)!important;color:#74699a!important}
  .module-empty>span{background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important}.module-empty h3{font-family:var(--c-display)!important;color:var(--c-ink)!important}.module-empty p{color:var(--c-muted)!important}

  /* Ministerio */
  [data-module-screen="ministry"] .module-header{margin-bottom:14px!important}.ministry-primary{background:linear-gradient(135deg,var(--c-accent),var(--c-accent-deep))!important}
  .ministry-toolbar{margin-bottom:13px!important}.service-year-pill{border:1px solid var(--c-line)!important;border-radius:13px!important;background:var(--c-paper)!important;color:var(--c-muted)!important;box-shadow:var(--c-shadow-soft)!important}
  [data-module-screen="ministry"] .ministry-panel[hidden]{display:none!important}
  [data-module-screen="ministry"] .ministry-panel:not([hidden]){width:100%!important;margin-top:0!important}
  [data-module-screen="ministry"] .ministry-panel[data-ministry-panel="overview"]:not([hidden]){display:grid!important;grid-template-columns:minmax(290px,.75fr) minmax(550px,1.65fr)!important;grid-template-areas:"timer metrics" "timer goals" "profile profile" "bottom bottom"!important;gap:12px!important}
  [data-module-screen="ministry"] .ministry-panel[data-ministry-panel="calendar"]:not([hidden]),[data-module-screen="ministry"] .ministry-panel[data-ministry-panel="report"]:not([hidden]){display:block!important}
  .ministry-timer-hero,.ministry-top-metrics article,.goal-card,.ministry-profile-card,.ministry-recent-panel,.service-year-card,.ministry-calendar-card,.report-card{border:1px solid var(--c-line)!important;background:var(--c-paper)!important;box-shadow:var(--c-shadow-soft)!important;color:var(--c-ink)!important}
  .ministry-timer-hero{border-radius:21px!important;background:linear-gradient(160deg,var(--c-paper),color-mix(in srgb,var(--c-accent-soft) 52%,var(--c-paper)))!important}.ministry-timer-hero>header small{color:var(--c-muted)!important}.timer-ring{border-color:color-mix(in srgb,var(--c-accent) 25%,var(--c-line))!important;background:radial-gradient(circle,var(--c-paper) 61%,transparent 62%),conic-gradient(var(--c-accent) var(--timer-progress,0%),color-mix(in srgb,var(--c-line) 42%,transparent) 0)!important}.timer-ring strong{font-family:var(--c-display)!important;color:var(--c-ink)!important}.timer-actions button:last-child{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-muted)!important}
  .ministry-top-metrics{gap:10px!important}.ministry-top-metrics article{border-radius:16px!important}.ministry-top-metrics article:nth-child(1){background:var(--c-blue-soft)!important}.ministry-top-metrics article:nth-child(2){background:var(--c-lav-soft)!important}.ministry-top-metrics article:nth-child(3){background:var(--c-gold-soft)!important}.ministry-top-metrics article:nth-child(4){background:var(--c-accent-soft)!important}.ministry-top-metrics strong{font-family:var(--c-display)!important;color:var(--c-ink)!important}.ministry-top-metrics small{color:var(--c-muted)!important}
  .ministry-goal-grid{gap:10px!important}.goal-card{border-radius:17px!important}.goal-card header strong{font-family:var(--c-display)!important;color:var(--c-ink)!important}.goal-card header span,.goal-card>small,.goal-card>p{color:var(--c-muted)!important}.goal-track{background:color-mix(in srgb,var(--c-line) 45%,var(--c-paper))!important}.goal-track i{background:linear-gradient(90deg,var(--c-accent),var(--c-gold))!important}.ministry-profile-card{border-radius:17px!important}.ministry-profile-card>span{background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important}.ministry-profile-card strong{font-family:var(--c-display)!important;color:var(--c-ink)!important}.ministry-profile-card small{color:var(--c-muted)!important}
  .ministry-bottom-grid{gap:11px!important}.ministry-recent-panel,.service-year-card{border-radius:20px!important}.ministry-recent-panel>header{border-color:var(--c-line)!important}.ministry-recent-panel h2,.service-year-card h3{font-family:var(--c-display)!important;color:var(--c-ink)!important}.service-year-card{background:linear-gradient(155deg,var(--c-paper),var(--c-paper-2))!important}.year-bar i{background:color-mix(in srgb,var(--c-line) 42%,var(--c-paper))!important}.year-bar i::after{background:linear-gradient(var(--c-accent),var(--c-gold))!important}
  .ministry-calendar-card{border-radius:21px!important;min-height:calc(100dvh - 225px)!important}.calendar-head{border-color:var(--c-line)!important}.calendar-head h2{font-family:var(--c-display)!important;color:var(--c-ink)!important}.calendar-head small,.calendar-weekday,.calendar-hint{color:var(--c-muted)!important}.calendar-head button{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-accent-deep)!important}.calendar-day{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-ink)!important}.calendar-day:hover{border-color:var(--c-accent)!important;background:var(--c-accent-soft)!important}.calendar-day.is-today{border-color:var(--c-accent)!important;box-shadow:inset 0 0 0 1px var(--c-accent)!important}.calendar-day.has-time{background:var(--c-gold-soft)!important}.calendar-day small{color:var(--c-accent-deep)!important}
  .report-grid{min-height:calc(100dvh - 225px)!important;gap:13px!important}.report-card{border-radius:21px!important}.report-card dl>div{border-color:var(--c-line)!important}.report-card h2,.report-card dd{font-family:var(--c-display)!important;color:var(--c-ink)!important}.report-card dt,.report-card small{color:var(--c-muted)!important}.report-actions button:first-child{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-ink)!important}

  /* Settings */
  .settings-screen{max-width:1120px!important;padding-top:0!important}.settings-screen .compact-settings-header{display:block!important;margin:0 0 12px!important;min-height:auto!important}.settings-screen .back-button,.settings-screen .settings-section-icon,.settings-screen .settings-title-copy .eyebrow,.settings-screen .settings-title-copy>p:last-child{display:none!important}.settings-screen .settings-title-copy h1{font-size:39px!important;line-height:1!important;margin:0!important}
  .settings-screen .settings-layout{grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-areas:"appearance ministry" "data app"!important;gap:13px!important}.settings-screen .settings-layout>.privacy-note{display:none!important}
  .settings-screen .settings-group{border:1px solid var(--c-line)!important;border-radius:18px!important;background:var(--c-paper)!important;padding:14px 16px!important;box-shadow:var(--c-shadow-soft)!important}.settings-screen .settings-group>header{border-color:var(--c-line)!important;padding-bottom:9px!important}.settings-screen .settings-group>header p{display:none!important}.settings-screen .settings-group>header>span{width:35px!important;height:35px!important;border-radius:11px!important;background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important}.settings-screen .settings-group h2{font-family:var(--c-display)!important;font-size:18px!important;color:var(--c-ink)!important}.settings-screen .settings-control,.settings-screen .settings-action{min-height:48px!important;border-color:var(--c-line)!important;color:var(--c-ink)!important}.settings-screen .settings-control select{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-ink)!important;border-radius:10px!important}.settings-screen .settings-action:hover{background:var(--c-accent-soft)!important}.settings-screen .settings-action small{color:var(--c-muted)!important}.ministry-rule-note{background:var(--c-blue-soft)!important;color:var(--c-ink)!important}.ministry-facts{background:var(--c-lav-soft)!important;border-color:color-mix(in srgb,var(--c-lav) 28%,var(--c-line))!important}.ministry-facts>span{color:var(--c-accent-deep)!important;background:var(--c-paper)!important}.ministry-facts li{color:var(--c-muted)!important}

  /* Notes editor */
  .app{height:100dvh;display:grid!important;grid-template-columns:var(--desktop-nav-w) var(--desktop-library-w) minmax(0,1fr)!important;background:linear-gradient(135deg,var(--c-bg),var(--c-bg-2))!important}.notes-global-nav{grid-column:1;grid-row:1/2}.sidebar{grid-column:2;background:color-mix(in srgb,var(--c-paper) 94%,transparent)!important;border-right:1px solid var(--c-line)!important;color:var(--c-ink)!important}.workspace{grid-column:3;background:transparent!important}.sidebar-header{border-color:var(--c-line)!important;background:linear-gradient(90deg,var(--c-paper),var(--c-paper-2))!important}.notes-library-heading{font-family:var(--c-display)!important;font-size:22px!important;color:var(--c-ink)!important}.sidebar-collapse-button{color:var(--c-accent-deep)!important}
  .pages-tools{padding-top:13px!important}.compact-actions button{border:1px solid var(--c-line)!important;background:var(--c-paper)!important;border-radius:12px!important;box-shadow:0 7px 15px rgba(75,69,57,.045)!important}.compact-actions button:hover{background:var(--c-accent-soft)!important;border-color:var(--c-accent)!important}.compact-actions .action-page{background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important;border-color:color-mix(in srgb,var(--c-accent) 42%,var(--c-line))!important}.compact-actions .action-page .action-icon{background:var(--c-paper)!important;color:var(--c-accent-deep)!important}.compact-actions .action-page small{color:var(--c-accent-deep)!important}.compact-actions .action-folder .action-icon{background:var(--c-gold-soft)!important;color:#927343!important}.compact-actions .action-select .action-icon{background:var(--c-blue-soft)!important;color:#66858d!important}
  .search-box{border-color:var(--c-line)!important;background:var(--c-paper)!important;border-radius:12px!important}.search-box input{color:var(--c-ink)!important}.search-box span{color:var(--c-accent-deep)!important}.page-list{background:transparent!important}.folder-block{border-color:var(--c-line)!important;background:var(--c-paper)!important}.page-row.is-active{background:var(--c-accent-soft)!important}
  .topbar{height:64px!important;border-bottom:1px solid var(--c-line)!important;background:color-mix(in srgb,var(--c-paper) 88%,transparent)!important;backdrop-filter:blur(18px)!important}.notes-screen-title{font-size:24px!important}.save-state{border-color:var(--c-line)!important;background:var(--c-paper)!important;color:var(--c-muted)!important}.wol-book-button{border:1px solid var(--c-line)!important;background:var(--c-paper)!important;color:var(--c-accent-deep)!important}.topbar-actions>.icon-button{border:1px solid var(--c-line)!important;background:var(--c-paper)!important;color:var(--c-ink)!important}.topbar-actions>.icon-button:hover{background:var(--c-accent-soft)!important}
  .workspace-scroll{padding:18px!important;background:transparent!important}.empty-workspace,.paper{border:1px solid var(--c-line)!important;border-radius:22px!important;background:
      radial-gradient(ellipse at 9% 91%,transparent 0 28px,color-mix(in srgb,var(--c-accent) 15%,transparent) 29px 30px,transparent 31px),
      repeating-linear-gradient(0deg,transparent 0 31px,rgba(90,100,84,.025) 32px),var(--c-paper)!important;box-shadow:var(--c-shadow)!important}
  .empty-workspace{min-height:calc(100dvh - 100px)!important;position:relative!important;overflow:hidden!important}.empty-workspace::after{content:"";position:absolute;left:35px;bottom:34px;width:125px;height:105px;opacity:.34;background:radial-gradient(ellipse at 30% 70%,transparent 0 25%,var(--c-accent) 26% 27%,transparent 28%),radial-gradient(ellipse at 65% 42%,transparent 0 23%,var(--c-accent) 24% 25%,transparent 26%),linear-gradient(122deg,transparent 49%,var(--c-accent) 50% 50.8%,transparent 51%)}.empty-icon{width:72px!important;height:72px!important;border-radius:20px!important;background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important;border:1px solid color-mix(in srgb,var(--c-accent) 23%,var(--c-line))!important}.empty-workspace h2{font-family:var(--c-display)!important;color:var(--c-ink)!important;font-size:31px!important}.empty-workspace p{color:var(--c-muted)!important}.paper{padding:44px 54px 70px!important}.page-title,.template-title-edit{font-family:var(--c-display)!important;color:var(--c-ink)!important}.toolbar{border-color:var(--c-line)!important;background:color-mix(in srgb,var(--c-paper) 91%,transparent)!important;box-shadow:0 10px 24px rgba(75,69,57,.06)!important}.toolbar button,.toolbar select,.color-tool{border-color:var(--c-line)!important;background:var(--c-paper)!important}.free-editor{color:var(--c-ink)!important}.paper-footer{color:var(--c-muted)!important;border-color:var(--c-line)!important}.more-menu{border-color:var(--c-line)!important;background:var(--c-paper)!important;box-shadow:var(--c-shadow)!important}.more-menu button:hover{background:var(--c-accent-soft)!important}
  .app.focus-mode{background:linear-gradient(135deg,var(--c-bg),var(--c-bg-2))!important}.app.focus-mode .paper,.app.focus-mode .empty-workspace{border-color:var(--c-line)!important;background:var(--c-paper)!important;box-shadow:var(--c-shadow)!important}.app.focus-mode .focus-exit{border-color:var(--c-line)!important;background:var(--c-paper)!important;color:var(--c-ink)!important}

  /* Dialogs */
  .module-dialog::backdrop,.template-dialog::backdrop,.folder-dialog::backdrop,.move-dialog::backdrop,.about-dialog::backdrop{background:rgba(47,52,45,.44)!important;backdrop-filter:blur(7px)}
  .module-form,.dialog-shell,.folder-dialog form,.move-dialog form,.about-dialog form{border:1px solid var(--c-line)!important;background:var(--c-paper)!important;color:var(--c-ink)!important;box-shadow:0 30px 90px rgba(47,52,45,.25)!important}.module-form input,.module-form select,.module-form textarea,.folder-dialog input{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-ink)!important}.module-form header,.module-form footer{border-color:var(--c-line)!important}.dialog-x,.dialog-close{border-color:var(--c-line)!important;background:var(--c-paper-2)!important;color:var(--c-accent-deep)!important}
}

@media (min-width:761px) and (max-width:1180px){
  :root{--desktop-nav-w:196px;--desktop-library-w:286px}
  .portal-main{padding-inline:27px!important}.module-title-copy h1{font-size:38px!important}.hub-kicker{font-size:38px!important}.premium-hub-grid .hub-card{min-height:180px!important}.premium-hub-grid .hub-card-copy strong{font-size:21px!important}
  [data-module-screen="ministry"] .ministry-panel[data-ministry-panel="overview"]:not([hidden]){grid-template-columns:270px minmax(0,1fr)!important;gap:10px!important}.ministry-top-metrics,.ministry-goal-grid,.ministry-bottom-grid{min-width:0!important;width:100%!important}.ministry-bottom-grid{grid-template-columns:minmax(0,1fr) minmax(230px,.58fr)!important}.settings-screen .settings-title-copy h1{font-size:36px!important}
}

@media (min-width:761px){
  .empty-workspace button.primary,
  .ministry-timer-hero .timer-start,
  .report-actions button.primary{
    background:linear-gradient(135deg,var(--c-accent),var(--c-accent-deep))!important;
    border-color:var(--c-accent-deep)!important;color:#fff!important;
    box-shadow:0 10px 22px color-mix(in srgb,var(--c-accent-deep) 23%,transparent)!important
  }
  .ministry-timer-hero::before{
    background:conic-gradient(from -90deg,var(--c-accent) 0deg,var(--c-gold) var(--timer-progress),color-mix(in srgb,var(--c-line) 48%,transparent) var(--timer-progress) 360deg)!important;
    filter:drop-shadow(0 8px 15px color-mix(in srgb,var(--c-accent) 14%,transparent))!important
  }
  .ministry-top-metrics article:nth-child(1)>span{color:#66858d!important}
  .ministry-top-metrics article:nth-child(2)>span{color:#756c9a!important}
  .ministry-top-metrics article:nth-child(3)>span{color:#967640!important}
  .ministry-top-metrics article:nth-child(4)>span{color:var(--c-accent-deep)!important}
}

/* =========================================================
   JAPANDI REFINADO
   Home temático, selector de nueve paletas, Ajustes ordenados
   y acciones de Notas visualmente consistentes.
   ========================================================= */

/* Three additional themes also receive safe base colors outside desktop. */

html[data-theme="clay"]{--bg:#fbf3ed;--paper:#fffaf5;--panel:#fdf6f0;--panel-2:#f2dfd1;--text:#3f3029;--muted:#806d63;--line:#e7d3c5;--accent:#b66f52;--accent-soft:#f6e1d5;--danger:#b95353;--ok:#638a70;--shadow:0 24px 72px rgba(115,70,48,.12);--accent-2:#cf8b6d;--accent-3:#d7a777}

html[data-theme="mist"]{--bg:#f1f5f5;--paper:#fbfdfc;--panel:#f7faf9;--panel-2:#dde8e8;--text:#293536;--muted:#687a7b;--line:#d0dddd;--accent:#68878a;--accent-soft:#dfebeb;--danger:#b95862;--ok:#5b8a70;--shadow:0 24px 72px rgba(64,86,87,.12);--accent-2:#829fa3;--accent-3:#9b93ad}

html[data-theme="cedar"]{--bg:#f3efe7;--paper:#fcfaf5;--panel:#f7f3eb;--panel-2:#e7dfd2;--text:#342f29;--muted:#756c61;--line:#dcd2c3;--accent:#7d6b52;--accent-soft:#ebe3d7;--danger:#b65a54;--ok:#657e64;--shadow:0 24px 72px rgba(76,65,48,.12);--accent-2:#9b8261;--accent-3:#879276}

@media (min-width:761px){
  :root{
    --c-hero-glow:rgba(120,140,114,.10);
    --c-card-notes-1:#edf1e9;--c-card-notes-2:#dfe7da;--c-card-notes-border:#cbd7c6;
    --c-card-revisits-1:#f1eef4;--c-card-revisits-2:#e6e0ea;--c-card-revisits-border:#d5ccd9;
    --c-card-ministry-1:#f7ecd9;--c-card-ministry-2:#eee0c6;--c-card-ministry-border:#ddcaa7;
    --c-card-icon-bg:rgba(255,253,248,.78);--c-card-arrow-bg:rgba(255,253,248,.48)
  }

  html[data-theme="light"]{
    --c-bg:#f6f2e9;--c-bg-2:#eee8dd;--c-paper:#fffdf8;--c-paper-2:#f8f4ec;
    --c-ink:#293129;--c-muted:#737b70;--c-line:#d8d0c4;
    --c-accent:#788c72;--c-accent-deep:#5d7359;--c-accent-soft:#e5ece1;
    --c-lav:#aaa1c8;--c-lav-soft:#eeeaf6;--c-gold:#c9a66a;--c-gold-soft:#f5ead4;
    --c-blue:#8da9b6;--c-blue-soft:#e6eef1;--c-nav-start:#f8f4eb;--c-nav-end:#ece5d9;--c-nav-active:#7f9378;--c-nav-ink:#30372f;
    --c-hero-glow:rgba(120,140,114,.11);
    --c-shadow:0 20px 54px rgba(120,140,114,.16);--c-shadow-soft:0 11px 28px rgba(120,140,114,.10);
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]){
    color-scheme:dark;
    --c-bg:#191a19;--c-bg-2:#23221f;--c-paper:#2b2925;--c-paper-2:#34312c;
    --c-ink:#f4f0e7;--c-muted:#b9b0a3;--c-line:#4b463f;
    --c-accent:#bba78b;--c-accent-deep:#d9c3a3;--c-accent-soft:#3c352d;
    --c-lav:#a99eb7;--c-lav-soft:#3b3640;--c-gold:#c5a16c;--c-gold-soft:#40372a;
    --c-blue:#8fa5aa;--c-blue-soft:#303b3e;--c-nav-start:#292721;--c-nav-end:#171715;--c-nav-active:#8e795f;--c-nav-ink:#f5f0e6;
    --c-hero-glow:rgba(199,177,145,.10);--c-shadow:0 20px 54px rgba(199,177,145,.16);--c-shadow-soft:0 11px 28px rgba(199,177,145,.10);
    --c-card-notes-1:#30362f;--c-card-notes-2:#3b4238;--c-card-notes-border:#4c5749;
    --c-card-revisits-1:#34313a;--c-card-revisits-2:#413b48;--c-card-revisits-border:#554d5d;
    --c-card-ministry-1:#383128;--c-card-ministry-2:#463b2e;--c-card-ministry-border:#5a4c3a;
    --c-card-icon-bg:rgba(255,248,235,.10);--c-card-arrow-bg:rgba(255,248,235,.08)
  }
  html[data-theme="pink"]{
    --c-bg:#f7efef;--c-bg-2:#ecdfdf;--c-paper:#fffafa;--c-paper-2:#f8eeee;
    --c-ink:#3e3034;--c-muted:#856f76;--c-line:#dec9ce;
    --c-accent:#b67b8b;--c-accent-deep:#965e70;--c-accent-soft:#f2dfe4;
    --c-lav:#aa95c4;--c-lav-soft:#eee5f5;--c-gold:#c5a26d;--c-gold-soft:#f5ead8;
    --c-blue:#8fa5ad;--c-blue-soft:#e6eef0;--c-nav-start:#f5e9ed;--c-nav-end:#ead7df;--c-nav-active:#b5768b;--c-nav-ink:#4a3039;
    --c-hero-glow:rgba(182,123,139,.12);--c-shadow:0 20px 54px rgba(182,123,139,.16);--c-shadow-soft:0 11px 28px rgba(182,123,139,.10);
    --c-card-notes-1:#f1e6e1;--c-card-notes-2:#ead8d1;--c-card-notes-border:#d9bfb6;
    --c-card-revisits-1:#f1e7ef;--c-card-revisits-2:#e8d6e4;--c-card-revisits-border:#d7bfd1;
    --c-card-ministry-1:#f6eadc;--c-card-ministry-2:#efdcc8;--c-card-ministry-border:#dfc7a9
  }
  html[data-theme="green"]{
    --c-bg:#eef3eb;--c-bg-2:#e1e8dd;--c-paper:#fbfdf8;--c-paper-2:#f1f6ee;
    --c-ink:#28352b;--c-muted:#6c7c70;--c-line:#cbd9ca;
    --c-accent:#6d8e70;--c-accent-deep:#527157;--c-accent-soft:#deebdf;
    --c-lav:#a09abd;--c-lav-soft:#ebe9f3;--c-gold:#c0a064;--c-gold-soft:#f3ead4;
    --c-blue:#86a4aa;--c-blue-soft:#dfedef;--c-nav-start:#edf4e9;--c-nav-end:#dce8d9;--c-nav-active:#668a6b;--c-nav-ink:#29402f;
    --c-hero-glow:rgba(109,142,112,.12);--c-shadow:0 20px 54px rgba(109,142,112,.16);--c-shadow-soft:0 11px 28px rgba(109,142,112,.10);
    --c-card-notes-1:#e3ebe0;--c-card-notes-2:#d5e1d2;--c-card-notes-border:#bfd0bd;
    --c-card-revisits-1:#e8ede5;--c-card-revisits-2:#dce5d8;--c-card-revisits-border:#c7d3c3;
    --c-card-ministry-1:#f1ead8;--c-card-ministry-2:#e8ddc3;--c-card-ministry-border:#d6c59d
  }
  html[data-theme="purple"]{
    --c-bg:#f2edf5;--c-bg-2:#e6dfea;--c-paper:#fdfafd;--c-paper-2:#f5eff7;
    --c-ink:#362f3a;--c-muted:#7c7183;--c-line:#d5c9dc;
    --c-accent:#927fa6;--c-accent-deep:#735e89;--c-accent-soft:#e8dff0;
    --c-lav:#9c8dbd;--c-lav-soft:#e9e2f1;--c-gold:#c4a16e;--c-gold-soft:#f4e9d6;
    --c-blue:#8fa4b2;--c-blue-soft:#e4ecf1;--c-nav-start:#f1ebf5;--c-nav-end:#e2d9ea;--c-nav-active:#8d79a5;--c-nav-ink:#42364b;
    --c-hero-glow:rgba(146,127,166,.12);--c-shadow:0 20px 54px rgba(146,127,166,.16);--c-shadow-soft:0 11px 28px rgba(146,127,166,.10);
    --c-card-notes-1:#eae6ec;--c-card-notes-2:#ddd6e1;--c-card-notes-border:#ccc1d1;
    --c-card-revisits-1:#ece3f1;--c-card-revisits-2:#dccde6;--c-card-revisits-border:#c9b6d5;
    --c-card-ministry-1:#f2eadc;--c-card-ministry-2:#e9ddc8;--c-card-ministry-border:#d8c5a7
  }
  html[data-theme="yellow"]{
    --c-bg:#f6f0df;--c-bg-2:#ebe2ca;--c-paper:#fffdf4;--c-paper-2:#f9f3df;
    --c-ink:#3b3427;--c-muted:#81765f;--c-line:#ded2b4;
    --c-accent:#a9905c;--c-accent-deep:#8b7244;--c-accent-soft:#f0e8cc;
    --c-lav:#9f97b7;--c-lav-soft:#ebe8f0;--c-gold:#c39545;--c-gold-soft:#f4e4bd;
    --c-blue:#8da3aa;--c-blue-soft:#e5eceb;--c-nav-start:#f5efdc;--c-nav-end:#e8dfc4;--c-nav-active:#a38b55;--c-nav-ink:#493f2b;
    --c-hero-glow:rgba(169,144,92,.12);--c-shadow:0 20px 54px rgba(169,144,92,.16);--c-shadow-soft:0 11px 28px rgba(169,144,92,.10);
    --c-card-notes-1:#f1ead7;--c-card-notes-2:#e7ddc3;--c-card-notes-border:#d5c49d;
    --c-card-revisits-1:#ece7df;--c-card-revisits-2:#ded6cb;--c-card-revisits-border:#ccc0b0;
    --c-card-ministry-1:#f5e6bd;--c-card-ministry-2:#ebd495;--c-card-ministry-border:#d8b96d
  }
  html[data-theme="clay"]{
    --c-bg:#f8efe9;--c-bg-2:#ebddd4;--c-paper:#fffaf5;--c-paper-2:#f8eee8;
    --c-ink:#402f28;--c-muted:#806d63;--c-line:#e3cec0;
    --c-accent:#b06e52;--c-accent-deep:#8e543d;--c-accent-soft:#f3ddd1;
    --c-lav:#aa96a2;--c-lav-soft:#eee4e8;--c-gold:#c39662;--c-gold-soft:#f2e5d2;
    --c-blue:#879fa0;--c-blue-soft:#e2ebea;--c-nav-start:#f4e9e0;--c-nav-end:#e7d5c9;--c-nav-active:#a7644b;--c-nav-ink:#493229;
    --c-hero-glow:rgba(176,110,82,.12);--c-shadow:0 20px 54px rgba(176,110,82,.16);--c-shadow-soft:0 11px 28px rgba(176,110,82,.10);
    --c-card-notes-1:#efdfd3;--c-card-notes-2:#e4cdbf;--c-card-notes-border:#d1b5a4;
    --c-card-revisits-1:#eee0df;--c-card-revisits-2:#e4d0d0;--c-card-revisits-border:#d1b8b8;
    --c-card-ministry-1:#f2e3cf;--c-card-ministry-2:#e7d1b4;--c-card-ministry-border:#d3b58e
  }
  html[data-theme="mist"]{
    --c-bg:#eef3f2;--c-bg-2:#dfe7e6;--c-paper:#fbfdfc;--c-paper-2:#f1f6f5;
    --c-ink:#2b3738;--c-muted:#6b7b7c;--c-line:#ccd9d8;
    --c-accent:#6b8789;--c-accent-deep:#526f72;--c-accent-soft:#dfeaea;
    --c-lav:#9d9aaf;--c-lav-soft:#e8e7ed;--c-gold:#b59c76;--c-gold-soft:#efe6d8;
    --c-blue:#79979d;--c-blue-soft:#dce9eb;--c-nav-start:#ecf2f0;--c-nav-end:#dce6e4;--c-nav-active:#698486;--c-nav-ink:#2d4041;
    --c-hero-glow:rgba(107,135,137,.12);--c-shadow:0 20px 54px rgba(107,135,137,.16);--c-shadow-soft:0 11px 28px rgba(107,135,137,.10);
    --c-card-notes-1:#e2ebe9;--c-card-notes-2:#d5e1df;--c-card-notes-border:#bfd0cd;
    --c-card-revisits-1:#e7e8ec;--c-card-revisits-2:#d9dce2;--c-card-revisits-border:#c5c9d1;
    --c-card-ministry-1:#eee8df;--c-card-ministry-2:#e3dacd;--c-card-ministry-border:#d0c2ad
  }
  html[data-theme="cedar"]{
    --c-bg:#f3efe7;--c-bg-2:#e5ded2;--c-paper:#fcfaf5;--c-paper-2:#f5f1e9;
    --c-ink:#352f29;--c-muted:#766c61;--c-line:#d9cfbf;
    --c-accent:#7c6b53;--c-accent-deep:#63543f;--c-accent-soft:#e9e1d5;
    --c-lav:#9d968f;--c-lav-soft:#e9e5e1;--c-gold:#ad8d5f;--c-gold-soft:#eee2d0;
    --c-blue:#839392;--c-blue-soft:#e1e8e6;--c-nav-start:#eee9df;--c-nav-end:#ded5c7;--c-nav-active:#76654d;--c-nav-ink:#3d352b;
    --c-hero-glow:rgba(124,107,83,.12);--c-shadow:0 20px 54px rgba(124,107,83,.16);--c-shadow-soft:0 11px 28px rgba(124,107,83,.10);
    --c-card-notes-1:#e8e2d7;--c-card-notes-2:#dcd3c5;--c-card-notes-border:#c8bba9;
    --c-card-revisits-1:#e7e3dc;--c-card-revisits-2:#d9d3c9;--c-card-revisits-border:#c6bdae;
    --c-card-ministry-1:#ede1cf;--c-card-ministry-2:#dfcfb7;--c-card-ministry-border:#cbb693
  }

  html[data-theme]{--bg:var(--c-bg);--paper:var(--c-paper);--panel:var(--c-paper-2);--panel-2:var(--c-accent-soft);--text:var(--c-ink);--muted:var(--c-muted);--line:var(--c-line);--accent:var(--c-accent-deep);--accent-soft:var(--c-accent-soft)}

  /* Remove the old band behind the Home cards and keep the canvas Japandi. */
  .portal[data-active-module="hub"],
  .portal[data-active-module="hub"] .portal-main{
    background:
      radial-gradient(circle at 91% 6%,var(--c-hero-glow),transparent 27%),
      linear-gradient(135deg,var(--c-bg),var(--c-bg-2))!important
  }
  .hub-screen,.premium-hub-grid{background:transparent!important;box-shadow:none!important}
  .hub-screen::before,.hub-screen::after,.hub-hero::before{display:none!important}
  .premium-hub-grid{padding:0!important;border:0!important}
  .hub-hero{background:linear-gradient(135deg,var(--c-paper),color-mix(in srgb,var(--c-accent-soft) 28%,var(--c-paper)))!important}

  /* Home search: one clear search icon, placed on the action button. */
  .hub-search{padding:0 5px 0 16px!important;gap:8px!important}
  .hub-search>span{display:none!important}
  .hub-search button{display:grid!important;place-items:center!important}
  .hub-search button svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}

  /* Cards now follow every selected theme while retaining Japandi balance. */
  .premium-hub-grid .notes-card{background:linear-gradient(145deg,var(--c-card-notes-1),var(--c-card-notes-2))!important;border-color:var(--c-card-notes-border)!important}
  .premium-hub-grid .revisits-card{background:linear-gradient(145deg,var(--c-card-revisits-1),var(--c-card-revisits-2))!important;border-color:var(--c-card-revisits-border)!important}
  .premium-hub-grid .ministry-card{background:linear-gradient(145deg,var(--c-card-ministry-1),var(--c-card-ministry-2))!important;border-color:var(--c-card-ministry-border)!important}
  .premium-hub-grid .hub-card-icon{background:var(--c-card-icon-bg)!important;color:var(--c-ink)!important;border-color:color-mix(in srgb,var(--c-line) 72%,transparent)!important}
  .premium-hub-grid .hub-card-arrow{background:var(--c-card-arrow-bg)!important;color:var(--c-ink)!important;border-color:color-mix(in srgb,var(--c-line) 84%,transparent)!important}

  /* Página, Carpeta and Seleccionar share one visual treatment. */
  .compact-actions{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .compact-actions .action-page,
  .compact-actions .action-folder,
  .compact-actions .action-select{
    background:var(--c-paper)!important;color:var(--c-ink)!important;
    border:1px solid var(--c-line)!important;box-shadow:0 7px 15px rgba(75,69,57,.045)!important
  }
  .compact-actions .action-page small,
  .compact-actions .action-folder small,
  .compact-actions .action-select small{color:var(--c-ink)!important}
  .compact-actions .action-page:hover,
  .compact-actions .action-folder:hover,
  .compact-actions .action-select:hover{background:var(--c-accent-soft)!important;border-color:var(--c-accent)!important}
  .compact-actions .action-page .action-icon{background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important}

  /* Settings: a deliberate, balanced layout rather than four loose cards. */
  .settings-screen .settings-layout{
    display:grid!important;grid-template-columns:minmax(0,1.02fr) minmax(0,.98fr)!important;
    grid-template-areas:"appearance appearance" "ministry data" "app app"!important;
    gap:14px!important;align-items:start!important
  }
  .appearance-settings-group{grid-area:appearance!important;display:grid!important;grid-template-columns:minmax(0,1fr) minmax(260px,.42fr)!important;column-gap:18px!important;row-gap:10px!important}
  .appearance-settings-group>header{grid-column:1/-1!important}
  .appearance-settings-group .theme-select-control{display:none!important}
  .appearance-settings-group .theme-palette{grid-column:1!important;display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:8px!important}
  .appearance-settings-group .settings-control:last-child{grid-column:2!important;align-self:stretch!important;margin:0!important;border:1px solid var(--c-line)!important;border-radius:14px!important;padding:12px 14px!important;background:var(--c-paper-2)!important}
  .ministry-settings-group{grid-area:ministry!important}.data-settings-group{grid-area:data!important}.app-settings-group{grid-area:app!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:0 12px!important}.app-settings-group>header{grid-column:1/-1!important}.app-settings-group .install-app-button{grid-column:1/-1!important}
  .settings-screen .settings-group{overflow:hidden!important}
  .settings-screen .settings-group>header{background:linear-gradient(90deg,var(--c-paper),var(--c-paper-2))!important;margin:-14px -16px 10px!important;padding:13px 16px!important;border-bottom:1px solid var(--c-line)!important}
  .settings-screen .settings-action{border-radius:10px!important;padding-inline:10px!important}

  .theme-palette button{min-height:48px;border:1px solid var(--c-line);border-radius:13px;background:var(--c-paper-2);color:var(--c-ink);display:grid;grid-template-columns:26px 1fr;align-items:center;gap:9px;padding:7px 10px;text-align:left;font:700 10px/1 var(--c-ui);transition:transform .16s ease,border-color .16s ease,background .16s ease,box-shadow .16s ease}
  .theme-palette button:hover{transform:translateY(-1px);border-color:var(--c-accent);background:var(--c-accent-soft)}
  .theme-palette button.is-active{border-color:var(--c-accent-deep);box-shadow:0 0 0 2px color-mix(in srgb,var(--c-accent) 22%,transparent),0 8px 18px rgba(75,69,57,.08);background:var(--c-paper)}
  .theme-palette button i{width:26px;height:26px;border-radius:9px;border:1px solid rgba(35,35,35,.10);box-shadow:inset 0 1px rgba(255,255,255,.35)}
  .theme-palette button[data-theme-choice="light"] i{background:linear-gradient(135deg,#f7f1e6 50%,#83957d 50%)}
  .theme-palette button[data-theme-choice="dark"] i{background:linear-gradient(135deg,#24231f 50%,#c3ad8f 50%)}
  .theme-palette button[data-theme-choice="pink"] i{background:linear-gradient(135deg,#f1dfdf 50%,#b67b8b 50%)}
  .theme-palette button[data-theme-choice="green"] i{background:linear-gradient(135deg,#dce7d8 50%,#6d8e70 50%)}
  .theme-palette button[data-theme-choice="purple"] i{background:linear-gradient(135deg,#e8dff0 50%,#927fa6 50%)}
  .theme-palette button[data-theme-choice="yellow"] i{background:linear-gradient(135deg,#efe3c6 50%,#a9905c 50%)}
  .theme-palette button[data-theme-choice="clay"] i{background:linear-gradient(135deg,#eed8cc 50%,#b06e52 50%)}
  .theme-palette button[data-theme-choice="mist"] i{background:linear-gradient(135deg,#dce8e7 50%,#6b8789 50%)}
  .theme-palette button[data-theme-choice="cedar"] i{background:linear-gradient(135deg,#e5ddd0 50%,#7c6b53 50%)}

  /* Dark mode keeps text, surfaces and controls clearly separated. */
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-screen .settings-group,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .people-records-panel,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-timer-hero,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics article,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .goal-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-profile-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-recent-panel,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .service-year-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-calendar-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .report-card{color:var(--c-ink)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) input::placeholder,:is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) textarea::placeholder{color:#918a80!important}
}

@media (min-width:761px) and (max-width:1180px){
  .appearance-settings-group{grid-template-columns:1fr!important}
  .appearance-settings-group .theme-palette,.appearance-settings-group .settings-control:last-child{grid-column:1!important}
  .appearance-settings-group .theme-palette{grid-template-columns:repeat(3,minmax(0,1fr))!important}
}

/* =========================================================
   JAPANDI POLISH
   Full-canvas Notes empty state, aligned Notes header,
   cleaner Home cards and a coherent Night palette.
   Desktop and tablet only.
   ========================================================= */

@media (min-width:761px){
  /* Remove decorative loop/circle drawings throughout the desktop UI. */
  .desktop-global-nav::before,
  .desktop-global-nav::after,
  .portal-main::after,
  .hub-screen::before,
  .hub-screen::after,
  .hub-hero::before,
  .hub-hero::after,
  .premium-hub-grid::before,
  .premium-hub-grid::after,
  .empty-workspace::after,
  .page-heading::after,
  .login-screen::before,
  .login-screen::after{
    content:none!important;
    display:none!important;
    background:none!important;
  }

  /* Home: no band or broad shadow behind the three main cards. */
  .portal[data-active-module="hub"] .hub-screen,
  .portal[data-active-module="hub"] .premium-hub-grid{
    background:none!important;
    box-shadow:none!important;
    filter:none!important;
  }
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card{
    box-shadow:none!important;
  }

  /* Notes: align the lower rule beneath “Notas” and “Guardado local”. */
  .sidebar-header,
  .topbar{
    height:64px!important;
    min-height:64px!important;
    box-sizing:border-box!important;
    border-bottom:1px solid var(--c-line)!important;
  }
  .workspace{grid-template-rows:64px minmax(0,1fr)!important}

  /* Notes: the empty state is now the full editor canvas, not a sheet. */
  .workspace-scroll{
    padding:0!important;
    background:linear-gradient(135deg,var(--c-bg),var(--c-bg-2))!important;
  }
  .empty-workspace{
    width:100%!important;
    min-height:calc(100dvh - 64px)!important;
    margin:0!important;
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  .paper{
    width:min(980px,calc(100% - 36px))!important;
    margin:18px auto 42px!important;
  }
  .app.focus-mode .empty-workspace{
    border:0!important;
    border-radius:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }

  /* Notes tools sit naturally on the same library background. */
  .pages-tools,
  .compact-actions{
    background:transparent!important;
    box-shadow:none!important;
  }
  .pages-tools{border:0!important}
  .compact-actions .action-page,
  .compact-actions .action-folder,
  .compact-actions .action-select{
    background:var(--c-paper-2)!important;
    border-color:var(--c-line)!important;
    box-shadow:none!important;
  }
  .compact-actions .action-page:hover,
  .compact-actions .action-folder:hover,
  .compact-actions .action-select:hover{
    background:var(--c-accent-soft)!important;
  }

  /* Night theme: neutral charcoal, warm wood and clear hierarchy. */
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]){
    --c-bg:#171716;--c-bg-2:#211f1c;--c-paper:#2a2824;--c-paper-2:#34312c;
    --c-ink:#f5f0e7;--c-muted:#b9afa1;--c-line:#4c463e;
    --c-accent:#b89a73;--c-accent-deep:#dbc29f;--c-accent-soft:#44392e;
    --c-lav:#b2a5c0;--c-lav-soft:#3d3743;--c-gold:#d0aa70;--c-gold-soft:#44382a;
    --c-blue:#9bb2b6;--c-blue-soft:#314044;--c-stone:#94897b;
    --c-nav-start:#25221e;--c-nav-end:#151412;--c-nav-active:#967657;--c-nav-ink:#f6f0e6;
    --c-hero-glow:rgba(204,171,126,.08);
    --c-card-notes-1:#302e2a;--c-card-notes-2:#3a3630;--c-card-notes-border:#50493f;
    --c-card-revisits-1:#312e35;--c-card-revisits-2:#3c3741;--c-card-revisits-border:#514a57;
    --c-card-ministry-1:#352f27;--c-card-ministry-2:#41372c;--c-card-ministry-border:#584a3a;
    --c-card-icon-bg:rgba(255,244,226,.10);--c-card-arrow-bg:rgba(255,244,226,.07)
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .portal,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .app,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .workspace-scroll{
    background:
      radial-gradient(circle at 90% 4%,rgba(188,157,113,.07),transparent 27%),
      linear-gradient(135deg,var(--c-bg),var(--c-bg-2))!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .hub-hero,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-screen .settings-group,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .people-records-panel,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-timer-hero,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .goal-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-profile-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-recent-panel,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .service-year-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-calendar-card,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .report-card{
    background:var(--c-paper)!important;
    border-color:var(--c-line)!important;
    color:var(--c-ink)!important;
    box-shadow:0 14px 34px rgba(0,0,0,.18)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div{
    background:var(--c-paper-2)!important;
    border-color:var(--c-line)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(1) .summary-icon{
    background:#493f32!important;color:#f0d2a5!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(2) .summary-icon{
    background:#403a49!important;color:#d8caef!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(3) .summary-icon{
    background:#334246!important;color:#c7e0e3!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(4) .summary-icon{
    background:#493c2d!important;color:#edcd92!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary h2,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .hub-card-copy strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .empty-workspace h2,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .notes-library-heading{
    color:var(--c-ink)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .hub-card-copy small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .empty-workspace p{
    color:var(--c-muted)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .hub-search,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .search-box,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .save-state,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .wol-book-button,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .topbar-actions>.icon-button,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .folder-block,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .more-menu,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .toolbar,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .toolbar button,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .toolbar select,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .color-tool{
    background:var(--c-paper)!important;
    border-color:var(--c-line)!important;
    color:var(--c-ink)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .sidebar,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .sidebar-header,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .topbar{
    background:var(--c-paper)!important;
    border-color:var(--c-line)!important;
    color:var(--c-ink)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions .action-page,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions .action-folder,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions .action-select{
    background:var(--c-paper-2)!important;
    border-color:var(--c-line)!important;
    color:var(--c-ink)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions .action-page .action-icon{
    background:#493f32!important;color:#f0d2a5!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions .action-folder .action-icon{
    background:#473a2c!important;color:#edc98d!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions .action-select .action-icon{
    background:#334246!important;color:#c7e0e3!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .compact-actions small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .page-open,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .folder-toggle strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .search-box input,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .toolbar select,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .free-editor,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .page-title{
    color:var(--c-ink)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .search-box input::placeholder,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .hub-search input::placeholder,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) input::placeholder,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) textarea::placeholder{
    color:#9f9588!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .page-row.is-active{
    background:var(--c-accent-soft)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .empty-icon{
    background:var(--c-accent-soft)!important;
    color:var(--c-accent-deep)!important;
    border-color:var(--c-line)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .paper{
    background:var(--c-paper)!important;
    border-color:var(--c-line)!important;
    color:var(--c-ink)!important;
    box-shadow:0 18px 48px rgba(0,0,0,.22)!important;
  }
}

/* =========================================================
   HUB MÓVIL JAPANDI + TIPOGRAFÍA LEGIBLE
   Solo teléfonos (<=760px). Escritorio y tablet no cambian.
   ========================================================= */

@media (max-width:760px){
  /* Paleta móvil Japandi vinculada a cada tema. */
  html{
    --m-bg:#f4efe6;--m-surface:#fffdf8;--m-surface-2:#f8f4ec;--m-text:#2d332d;--m-muted:#777469;--m-line:#d9d1c5;
    --m-accent:#65785f;--m-accent-soft:#e5ece1;--m-shadow:0 10px 28px rgba(72,65,53,.09);
    --m-card-notes:#fbfaf5;--m-band-notes:#dfe6da;--m-notes-accent:#52664f;
    --m-card-revisits:#fcf9fc;--m-band-revisits:#e8deeb;--m-revisits-accent:#765f7d;
    --m-card-ministry:#fcf8f2;--m-band-ministry:#ead8cb;--m-ministry-accent:#8d5f48;
    --m-nav-bg:#fffdf9;--m-nav-active-bg:#e8eee4;--m-nav-active:#556b50;--m-nav-ink:#716e66;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]){
    --m-bg:#1a1917;--m-surface:#292621;--m-surface-2:#332f29;--m-text:#f5efe5;--m-muted:#b7aea1;--m-line:#49433b;
    --m-accent:#d7c3a4;--m-accent-soft:#44392f;--m-shadow:0 12px 30px rgba(0,0,0,.28);
    --m-card-notes:#302d28;--m-band-notes:#40463d;--m-notes-accent:#d3e1cb;
    --m-card-revisits:#312e34;--m-band-revisits:#443b48;--m-revisits-accent:#e2d3e7;
    --m-card-ministry:#342e27;--m-band-ministry:#493a30;--m-ministry-accent:#efd0b6;
    --m-nav-bg:#25221e;--m-nav-active-bg:#463b31;--m-nav-active:#f0d9b7;--m-nav-ink:#bdb4a7;
  }
  html[data-theme="pink"]{
    --m-bg:#f7efef;--m-surface:#fffafa;--m-surface-2:#f8eeee;--m-text:#403237;--m-muted:#826e75;--m-line:#decace;
    --m-accent:#a86f80;--m-accent-soft:#f1dfe4;
    --m-card-notes:#fff9f5;--m-band-notes:#eadfd7;--m-notes-accent:#765d52;
    --m-card-revisits:#fff8fb;--m-band-revisits:#ead9e3;--m-revisits-accent:#945f76;
    --m-card-ministry:#fff9f3;--m-band-ministry:#edd9ca;--m-ministry-accent:#9a6548;
    --m-nav-bg:#fff9fa;--m-nav-active-bg:#f2dfe5;--m-nav-active:#986174;--m-nav-ink:#826f76;
  }
  html[data-theme="green"]{
    --m-bg:#eef3eb;--m-surface:#fbfdf8;--m-surface-2:#f1f6ee;--m-text:#29352b;--m-muted:#6d7b70;--m-line:#cbd9ca;
    --m-accent:#5f8063;--m-accent-soft:#deebdf;
    --m-card-notes:#fafcf7;--m-band-notes:#dce8d8;--m-notes-accent:#4f7053;
    --m-card-revisits:#fafcf8;--m-band-revisits:#e3e8dc;--m-revisits-accent:#667660;
    --m-card-ministry:#fcfaf4;--m-band-ministry:#e9dfc8;--m-ministry-accent:#806b43;
    --m-nav-bg:#fbfdf8;--m-nav-active-bg:#dfeadb;--m-nav-active:#55765a;--m-nav-ink:#6a786d;
  }
  html[data-theme="purple"]{
    --m-bg:#f2edf5;--m-surface:#fdfafd;--m-surface-2:#f5eff7;--m-text:#372f3b;--m-muted:#7b7182;--m-line:#d5c9dc;
    --m-accent:#826f96;--m-accent-soft:#e8dff0;
    --m-card-notes:#fbfaf7;--m-band-notes:#e3e2da;--m-notes-accent:#626454;
    --m-card-revisits:#fcf8fd;--m-band-revisits:#dfd2e7;--m-revisits-accent:#745b83;
    --m-card-ministry:#fbf8f2;--m-band-ministry:#e8dac8;--m-ministry-accent:#85654b;
    --m-nav-bg:#fcf9fd;--m-nav-active-bg:#e8dff0;--m-nav-active:#745f88;--m-nav-ink:#79707f;
  }
  html[data-theme="yellow"]{
    --m-bg:#f6f0df;--m-surface:#fffdf4;--m-surface-2:#f9f3df;--m-text:#3c3528;--m-muted:#80755f;--m-line:#ded2b4;
    --m-accent:#967d4e;--m-accent-soft:#f0e8cc;
    --m-card-notes:#fffdf6;--m-band-notes:#e8e5d5;--m-notes-accent:#68705e;
    --m-card-revisits:#fffdf7;--m-band-revisits:#e8e1d8;--m-revisits-accent:#77695f;
    --m-card-ministry:#fff9e9;--m-band-ministry:#ead8ad;--m-ministry-accent:#8f6e2f;
    --m-nav-bg:#fffdf4;--m-nav-active-bg:#f0e6c8;--m-nav-active:#8d743f;--m-nav-ink:#7d735e;
  }
  html[data-theme="clay"]{
    --m-bg:#f8efe9;--m-surface:#fffaf5;--m-surface-2:#f8eee8;--m-text:#402f28;--m-muted:#806d63;--m-line:#e3cec0;
    --m-accent:#a5634b;--m-accent-soft:#f3ddd1;
    --m-card-notes:#fff9f4;--m-band-notes:#eadbd0;--m-notes-accent:#795b4c;
    --m-card-revisits:#fff8f7;--m-band-revisits:#e9d7d8;--m-revisits-accent:#8d6266;
    --m-card-ministry:#fff8ef;--m-band-ministry:#e8d2bc;--m-ministry-accent:#905b3e;
    --m-nav-bg:#fffaf6;--m-nav-active-bg:#f1ddd2;--m-nav-active:#965a44;--m-nav-ink:#806e65;
  }
  html[data-theme="mist"]{
    --m-bg:#eef3f2;--m-surface:#fbfdfc;--m-surface-2:#f1f6f5;--m-text:#2c3839;--m-muted:#6a7a7b;--m-line:#ccd9d8;
    --m-accent:#5e7c7f;--m-accent-soft:#dfeaea;
    --m-card-notes:#fafcfb;--m-band-notes:#dce7e3;--m-notes-accent:#526d67;
    --m-card-revisits:#fafbfc;--m-band-revisits:#dfe1e7;--m-revisits-accent:#656a78;
    --m-card-ministry:#fbfaf7;--m-band-ministry:#e5ddd2;--m-ministry-accent:#746657;
    --m-nav-bg:#fbfdfc;--m-nav-active-bg:#dde9e8;--m-nav-active:#577578;--m-nav-ink:#6a7879;
  }
  html[data-theme="cedar"]{
    --m-bg:#f3efe7;--m-surface:#fcfaf5;--m-surface-2:#f5f1e9;--m-text:#352f29;--m-muted:#766c61;--m-line:#d9cfbf;
    --m-accent:#6d5d48;--m-accent-soft:#e9e1d5;
    --m-card-notes:#fbfaf6;--m-band-notes:#e5dfd4;--m-notes-accent:#665c4d;
    --m-card-revisits:#faf9f6;--m-band-revisits:#e3dfd8;--m-revisits-accent:#6c665f;
    --m-card-ministry:#fbf8f1;--m-band-ministry:#e8d8c1;--m-ministry-accent:#806544;
    --m-nav-bg:#fcfaf5;--m-nav-active-bg:#e9e1d5;--m-nav-active:#665640;--m-nav-ink:#736a60;
  }

  /* Hub móvil: cabecera limpia, sin Settings ni saludo redundante. */
  .portal[data-active-module="hub"]{
    background:var(--m-bg)!important;color:var(--m-text)!important;
  }
  .portal[data-active-module="hub"] .portal-header{
    height:74px!important;padding:env(safe-area-inset-top) 17px 0!important;
    border-bottom:0!important;background:var(--m-bg)!important;color:var(--m-text)!important;
    backdrop-filter:none!important;box-shadow:none!important;
  }
  .portal[data-active-module="hub"] .portal-header-actions{display:none!important}
  .portal[data-active-module="hub"] .portal-brand{gap:10px!important}
  .portal[data-active-module="hub"] .portal-logo{
    width:42px!important;height:44px!important;border-radius:13px!important;padding:4px!important;
    background:var(--m-accent-soft)!important;
  }
  .portal[data-active-module="hub"] .portal-logo img{
    filter:grayscale(.72) sepia(.22) saturate(.7) contrast(.96)!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .portal[data-active-module="hub"] .portal-logo img{filter:grayscale(1) brightness(1.65) sepia(.15)!important}
  .portal[data-active-module="hub"] .portal-brand strong{
    color:var(--m-text)!important;font-family:var(--serif)!important;font-size:27px!important;font-weight:600!important;letter-spacing:-.035em!important;
  }
  .portal[data-active-module="hub"] .portal-main{
    width:100%!important;padding:5px 12px 16px!important;background:var(--m-bg)!important;
    overflow-y:auto!important;overscroll-behavior-y:contain!important;
  }
  .portal[data-active-module="hub"] .hub-screen{color:var(--m-text)!important;padding:0 0 10px!important}
  .portal[data-active-module="hub"] .hub-greeting{display:none!important}
  .portal[data-active-module="hub"] .hub-hero{margin:0 0 14px!important;padding:0!important;background:transparent!important;border:0!important;box-shadow:none!important}
  .portal[data-active-module="hub"] .hub-search{
    height:54px!important;padding:0 6px 0 17px!important;border:1px solid var(--m-line)!important;border-radius:19px!important;
    background:var(--m-surface)!important;box-shadow:var(--m-shadow)!important;backdrop-filter:none!important;
  }
  .portal[data-active-module="hub"] .hub-search input{
    color:var(--m-text)!important;font-size:14px!important;font-weight:500!important;
  }
  .portal[data-active-module="hub"] .hub-search input::placeholder{color:var(--m-muted)!important;opacity:.82!important}
  .portal[data-active-module="hub"] .hub-search button{
    width:42px!important;height:42px!important;border-radius:14px!important;background:var(--m-accent-soft)!important;color:var(--m-accent)!important;
  }
  .portal[data-active-module="hub"] .hub-search button svg{width:21px!important;height:21px!important;stroke-width:2!important}

  /* Tarjetas inspiradas en papel, textiles y tonos naturales Japandi. */
  .portal[data-active-module="hub"] .premium-hub-grid{gap:11px!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card{
    position:relative!important;isolation:isolate!important;min-height:clamp(108px,29vw,126px)!important;
    padding:13px 13px 13px 0!important;border:1px solid var(--m-line)!important;border-radius:22px!important;
    grid-template-columns:78px minmax(0,1fr) 38px!important;grid-template-rows:1fr!important;gap:15px!important;
    color:var(--m-text)!important;background:var(--m-surface)!important;box-shadow:var(--m-shadow)!important;
    backdrop-filter:none!important;overflow:hidden!important;transform:none!important;
  }
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card::before{
    content:""!important;position:absolute!important;z-index:-1!important;inset:0 auto 0 0!important;width:78px!important;border-radius:21px 0 0 21px!important;
  }
  .portal[data-active-module="hub"] .premium-hub-grid .notes-card{background:var(--m-card-notes)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .notes-card::before{background:var(--m-band-notes)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .revisits-card{background:var(--m-card-revisits)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .revisits-card::before{background:var(--m-band-revisits)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .ministry-card{background:var(--m-card-ministry)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .ministry-card::before{background:var(--m-band-ministry)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-icon{
    z-index:2!important;width:54px!important;height:54px!important;justify-self:center!important;border-radius:50%!important;
    background:color-mix(in srgb,var(--m-surface) 90%,transparent)!important;border:1px solid color-mix(in srgb,var(--m-line) 68%,transparent)!important;
    box-shadow:0 7px 18px rgba(69,62,50,.07)!important;font-size:24px!important;
  }
  .portal[data-active-module="hub"] .notes-card .hub-card-icon{color:var(--m-notes-accent)!important}
  .portal[data-active-module="hub"] .revisits-card .hub-card-icon{color:var(--m-revisits-accent)!important}
  .portal[data-active-module="hub"] .ministry-card .hub-card-icon{color:var(--m-ministry-accent)!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-copy{z-index:2!important;align-self:center!important;min-width:0!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-copy strong{
    color:var(--m-text)!important;font-family:var(--serif)!important;font-size:clamp(20px,5.4vw,23px)!important;font-weight:600!important;letter-spacing:-.035em!important;line-height:1.05!important;
  }
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-copy small{
    display:block!important;margin-top:5px!important;color:var(--m-muted)!important;font-size:clamp(10.5px,2.9vw,12px)!important;line-height:1.3!important;max-width:240px!important;
  }
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-arrow{
    z-index:3!important;width:36px!important;height:36px!important;border:1px solid var(--m-line)!important;border-radius:50%!important;
    background:color-mix(in srgb,var(--m-surface) 80%,transparent)!important;color:var(--m-text)!important;font-size:22px!important;
  }
  .portal[data-active-module="hub"] .hub-card-art{
    display:block!important;position:absolute!important;z-index:1!important;right:42px!important;bottom:0!important;width:128px!important;height:82px!important;
    opacity:.42!important;background-repeat:no-repeat!important;background-position:right bottom!important;background-size:contain!important;pointer-events:none!important;
  }
  .portal[data-active-module="hub"] .note-art,
  .portal[data-active-module="hub"] .study-art{
    background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 150 90'%3E%3Cg fill='none' stroke='%238a9a83' stroke-width='1.5' stroke-linecap='round'%3E%3Cpath d='M118 88C112 62 100 39 74 14'/%3E%3Cpath d='M103 62c-11 1-19-2-26-10 12-2 21 1 26 10Z'/%3E%3Cpath d='M91 43c-10-1-17-6-22-14 11 0 19 5 22 14Z'/%3E%3Cpath d='M112 74c8-5 16-6 25-2-7 7-15 8-25 2Z'/%3E%3Cpath d='M81 27c6-6 13-9 21-8-4 8-11 11-21 8Z'/%3E%3C/g%3E%3C/svg%3E")!important;
  }
  .portal[data-active-module="hub"] .study-art{filter:hue-rotate(56deg) saturate(.55)!important;opacity:.34!important}
  .portal[data-active-module="hub"] .ministry-art{
    opacity:.32!important;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 170 90'%3E%3Cg fill='none' stroke='%23a89478' stroke-width='1.4'%3E%3Cpath d='M2 87 44 55l17 16 31-39 28 32 19-14 29 37'/%3E%3Cpath d='M18 87 61 66l24 10 33-22 48 33' opacity='.65'/%3E%3C/g%3E%3C/svg%3E")!important;
  }
  .portal[data-active-module="hub"] .note-art::before,
  .portal[data-active-module="hub"] .note-art::after,
  .portal[data-active-module="hub"] .study-art::before,
  .portal[data-active-module="hub"] .study-art::after,
  .portal[data-active-module="hub"] .ministry-art::before,
  .portal[data-active-module="hub"] .ministry-art::after{content:none!important;display:none!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .portal[data-active-module="hub"] .hub-card-art{opacity:.18!important;filter:grayscale(1) brightness(1.35)!important}

  /* Actividad: limpia, compacta y legible. */
  .portal[data-active-module="hub"] .premium-summary{
    margin-top:12px!important;padding:13px 11px 12px!important;border:1px solid var(--m-line)!important;border-radius:22px!important;
    background:var(--m-surface)!important;box-shadow:var(--m-shadow)!important;backdrop-filter:none!important;
  }
  .portal[data-active-module="hub"] .premium-summary>header{padding:0 3px 10px!important}
  .portal[data-active-module="hub"] .premium-summary h2{
    color:var(--m-text)!important;font-family:var(--serif)!important;font-size:19px!important;font-weight:600!important;
  }
  .portal[data-active-module="hub"] .premium-summary>header button{color:var(--m-accent)!important;font-size:11px!important;font-weight:700!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid{gap:6px!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div{
    min-width:0!important;padding:10px 3px 9px!important;gap:4px!important;border:1px solid color-mix(in srgb,var(--m-line) 80%,transparent)!important;border-radius:15px!important;
    background:var(--m-surface-2)!important;
  }
  .portal[data-active-module="hub"] .premium-summary .summary-icon{width:31px!important;height:31px!important;border-radius:50%!important;font-size:13px!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div:nth-child(1) .summary-icon{background:var(--m-band-notes)!important;color:var(--m-notes-accent)!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div:nth-child(2) .summary-icon{background:var(--m-band-revisits)!important;color:var(--m-revisits-accent)!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div:nth-child(3) .summary-icon{background:color-mix(in srgb,var(--m-band-ministry) 72%,var(--m-surface))!important;color:var(--m-ministry-accent)!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div:nth-child(4) .summary-icon{background:var(--m-band-ministry)!important;color:var(--m-ministry-accent)!important}
  .portal[data-active-module="hub"] .premium-summary strong{color:var(--m-text)!important;font-size:19px!important;line-height:1!important}
  .portal[data-active-module="hub"] .premium-summary small{color:var(--m-muted)!important;font-size:clamp(8px,2.25vw,9.5px)!important;line-height:1.15!important}

  /* Menú inferior temático en todas las pantallas móviles. */
  .portal-bottom-nav,.notes-bottom-nav{
    height:66px!important;min-height:66px!important;padding:5px 8px calc(4px + env(safe-area-inset-bottom))!important;
    border:1px solid color-mix(in srgb,var(--m-line) 85%,transparent)!important;border-radius:22px 22px 0 0!important;
    background:color-mix(in srgb,var(--m-nav-bg) 95%,transparent)!important;box-shadow:0 -8px 24px rgba(58,52,44,.10)!important;
    backdrop-filter:blur(18px)!important;
  }
  .portal-bottom-nav button,.notes-bottom-nav button{
    height:53px!important;min-height:53px!important;color:var(--m-nav-ink)!important;border-radius:14px!important;gap:3px!important;
  }
  .portal-bottom-nav button span,.notes-bottom-nav button span{font-size:20px!important}
  .portal-bottom-nav button small,.notes-bottom-nav button small{font-size:9px!important;line-height:1!important;font-weight:750!important}
  .portal-bottom-nav button.is-active,.notes-bottom-nav button.is-active{
    color:var(--m-nav-active)!important;background:var(--m-nav-active-bg)!important;
  }
  .portal[data-active-module="hub"] .portal-bottom-nav{background:color-mix(in srgb,var(--m-nav-bg) 95%,transparent)!important}
  .portal,.app{padding-bottom:66px!important}
  .portal-main,.portal[data-active-module="hub"] .portal-main{padding-bottom:76px!important}
  .module-screen{padding-bottom:78px!important}
  .workspace{height:calc(100dvh - 66px)!important}

  /* Más legibilidad en Revisitas, Ministerio, Ajustes y formularios móviles. */
  .module-header h1{font-size:clamp(27px,7vw,32px)!important}
  .module-search{height:46px!important;padding-inline:13px!important}
  .module-search input{font-size:14px!important}
  .segmented button{height:36px!important;padding-inline:12px!important;font-size:11.5px!important}
  .metric-grid small,.revisits-metrics small{font-size:clamp(8.5px,2.4vw,10px)!important;line-height:1.2!important}
  .metric-grid strong,.revisits-metrics strong{font-size:clamp(20px,5.6vw,25px)!important}
  .metric-grid span{font-size:9.5px!important}
  .records-panel>header{height:50px!important;padding-inline:14px!important}
  .records-panel h2{font-size:17px!important}
  .records-panel>header span{font-size:10px!important}
  .record-group>summary{min-height:52px!important;padding:9px 6px!important}
  .record-group>summary strong{font-size:13px!important}
  .record-group>summary small{font-size:10px!important;line-height:1.25!important}
  .record-main strong{font-size:13.5px!important}
  .record-main small,.record-main em{font-size:10px!important;line-height:1.3!important}
  .status-chip{font-size:8px!important}
  .module-empty strong{font-size:18px!important}
  .module-empty p{font-size:12px!important;line-height:1.45!important}
  .service-year-pill{font-size:9px!important}
  .ministry-top-metrics span{font-size:17px!important}
  .ministry-top-metrics strong{font-size:17px!important}
  .ministry-top-metrics small{font-size:8.5px!important;line-height:1.2!important}
  .ministry-timer-hero .timer-display{font-size:clamp(38px,11vw,48px)!important}
  .ministry-timer-hero .timer-start{font-size:12px!important}
  .ministry-timer-hero [data-ministry-timer-save],.ministry-timer-hero [data-ministry-timer-pause]{font-size:10.5px!important}
  .ministry-profile-card strong{font-size:13.5px!important}
  .ministry-profile-card small{font-size:10px!important;line-height:1.35!important}
  .goal-card header strong{font-size:10.5px!important}
  .goal-card header span{font-size:9px!important}
  .goal-card>small{font-size:9px!important}
  .goal-card>p{font-size:9.5px!important;line-height:1.4!important}
  .calendar-header h2{font-size:19px!important}
  .calendar-day b{font-size:12px!important}
  .calendar-day small{font-size:8px!important}
  .calendar-hint{font-size:9.5px!important}
  .settings-group h2{font-size:18px!important}
  .settings-group header p{font-size:10.5px!important;line-height:1.35!important}
  .settings-control>span,.settings-action b{font-size:13px!important}
  .settings-control select{font-size:12px!important}
  .settings-action small{font-size:10px!important;line-height:1.3!important}
  .ministry-facts li{font-size:9.5px!important;line-height:1.45!important}
  .module-form h2{font-size:26px!important}
  .form-grid label>span{font-size:12px!important}
  .form-grid input,.form-grid select,.form-grid textarea{font-size:15px!important;padding:12px 13px!important}
  .module-form>footer button{font-size:13px!important}

  /* Editor y biblioteca móvil: títulos y controles fáciles de leer. */
  .notes-screen-title{font-size:20px!important}
  .compact-actions small{font-size:10px!important}
  .search-box input{font-size:14px!important}
  .page-open strong,.folder-toggle strong{font-size:12.5px!important}
  .page-open small,.folder-toggle small{font-size:10px!important}
  .empty-workspace h2{font-size:27px!important}
  .empty-workspace p{font-size:13px!important;line-height:1.45!important}
}

@media (max-width:380px){
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card{
    grid-template-columns:70px minmax(0,1fr) 34px!important;gap:10px!important;min-height:104px!important;
  }
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card::before{width:70px!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-icon{width:49px!important;height:49px!important;font-size:22px!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-copy strong{font-size:19px!important}
  .portal[data-active-module="hub"] .premium-hub-grid .hub-card-copy small{font-size:10px!important}
  .portal[data-active-module="hub"] .hub-card-art{right:34px!important;width:104px!important;opacity:.28!important}
  .portal[data-active-module="hub"] .premium-summary{padding-inline:8px!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid{gap:4px!important}
  .portal[data-active-module="hub"] .premium-summary .summary-grid>div{padding-inline:1px!important}
  .portal-bottom-nav button small,.notes-bottom-nav button small{font-size:8.3px!important}
}

@media (max-width:760px){
  .portal[data-active-module="hub"] .hub-search button svg{
    fill:none!important;stroke:currentColor!important;stroke-width:2!important;stroke-linecap:round!important;stroke-linejoin:round!important;
  }
}

/* =========================================================
   AJUSTES MÓVILES FINALES
   Solo teléfonos (<=760px). Desktop y tablet permanecen intactos.
   ========================================================= */

@media (max-width:760px){
  /* Logo móvil del Hub igual al lenguaje visual del logo desktop:
     símbolo blanco sobre el color temático y nombre limpio. */
  .portal[data-active-module="hub"] .portal-logo{
    width:44px!important;
    height:44px!important;
    padding:7px!important;
    border-radius:13px!important;
    background:var(--m-accent)!important;
    box-shadow:0 8px 18px color-mix(in srgb,var(--m-accent) 24%,transparent)!important;
  }
  .portal[data-active-module="hub"] .portal-logo img{
    content:url("/assets/notea-symbol-white.png")!important;
    width:100%!important;
    height:100%!important;
    object-fit:contain!important;
    filter:none!important;
    opacity:1!important;
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .portal[data-active-module="hub"] .portal-logo img{
    filter:none!important;
  }
  .portal[data-active-module="hub"] .portal-brand strong{
    font-family:var(--c-display,system-ui,sans-serif)!important;
    font-size:25px!important;
    font-weight:800!important;
    letter-spacing:-.035em!important;
  }
  .portal[data-active-module="hub"] .portal-brand small{display:none!important}

  /* El logo de la biblioteca móvil no se duplica junto al botón Editor. */
  .sidebar-header .brand{display:none!important}
  .sidebar-header{justify-content:flex-end!important}
  .sidebar-header-actions{margin-left:auto!important}

  /* Ajustes: sin los dos controles superiores redundantes. */
  .settings-screen .compact-settings-header{
    display:none!important;
  }
  .settings-screen{
    padding-top:10px!important;
  }

  /* El lienzo vacío de Notas ocupa todo el espacio disponible,
     sin verse como una hoja flotante dentro de otra superficie. */
  .workspace-scroll:has(> .empty-workspace:not([hidden])){
    padding:0!important;
    background:var(--paper)!important;
  }
  .workspace-scroll> .empty-workspace:not([hidden]){
    width:100%!important;
    min-height:100%!important;
    height:100%!important;
    margin:0!important;
    padding:28px 22px calc(90px + env(safe-area-inset-bottom))!important;
    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    background:var(--paper)!important;
  }
  .workspace-scroll> .empty-workspace:not([hidden])::before,
  .workspace-scroll> .empty-workspace:not([hidden])::after{
    display:none!important;
    content:none!important;
  }

  /* El panel Tu actividad puede desplazarse completamente por encima
     de la barra inferior y nunca queda tapado. */
  .portal[data-active-module="hub"] .portal-main{
    padding-bottom:calc(104px + env(safe-area-inset-bottom))!important;
    scroll-padding-bottom:calc(104px + env(safe-area-inset-bottom))!important;
  }
  .portal[data-active-module="hub"] .hub-screen{
    padding-bottom:calc(88px + env(safe-area-inset-bottom))!important;
  }
  .portal[data-active-module="hub"] .premium-summary{
    margin-bottom:18px!important;
  }

  /* El glifo del reloj tiene menos masa visual; se compensa para que
     Ministerio se perciba del mismo tamaño que los otros iconos. */
  .portal-bottom-nav button:nth-child(4)>span,
  .notes-bottom-nav button:nth-child(4)>span{
    font-size:24px!important;
    line-height:1!important;
    transform:scale(1.06)!important;
    transform-origin:center!important;
  }
}

/* =========================================================
   AJUSTES MÓVILES DE MINISTERIO Y REVISITAS
   Exclusivo para teléfonos. Desktop y tablet permanecen intactos.
   ========================================================= */

@media (max-width:760px){
  /* Ministerio: icono inferior con el mismo peso y tamaño visual
     que los demás iconos, además de quedar perfectamente centrado. */
  .portal-bottom-nav button:nth-child(4),
  .notes-bottom-nav button:nth-child(4){
    align-content:center!important;
    justify-content:center!important;
    justify-items:center!important;
    padding-top:0!important;
    transform:none!important;
  }
  .portal-bottom-nav button:nth-child(4)>span,
  .notes-bottom-nav button:nth-child(4)>span{
    position:relative!important;
    display:block!important;
    width:23px!important;
    height:23px!important;
    min-width:23px!important;
    min-height:23px!important;
    margin:0 auto!important;
    font-size:0!important;
    line-height:1!important;
    transform:none!important;
    color:currentColor!important;
  }
  .portal-bottom-nav button:nth-child(4)>span::before,
  .notes-bottom-nav button:nth-child(4)>span::before{
    content:""!important;
    position:absolute!important;
    inset:1px!important;
    border:2px solid currentColor!important;
    border-radius:50%!important;
    box-sizing:border-box!important;
  }
  .portal-bottom-nav button:nth-child(4)>span::after,
  .notes-bottom-nav button:nth-child(4)>span::after{
    content:""!important;
    position:absolute!important;
    left:10px!important;
    top:5px!important;
    width:6px!important;
    height:7px!important;
    border-left:2px solid currentColor!important;
    border-bottom:2px solid currentColor!important;
    border-radius:0 0 0 1px!important;
    transform-origin:left bottom!important;
    box-sizing:border-box!important;
  }
  .portal-bottom-nav button:nth-child(4)>small,
  .notes-bottom-nav button:nth-child(4)>small{
    display:block!important;
    width:100%!important;
    text-align:center!important;
    margin:0!important;
    transform:none!important;
  }

  /* Se elimina únicamente la píldora superior redundante del año de servicio. */
  .ministry-screen .service-year-pill{display:none!important}
  .ministry-screen .ministry-toolbar{
    grid-template-columns:1fr!important;
    width:100%!important;
  }
  .ministry-screen .ministry-toolbar .segmented{
    width:100%!important;
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
  }

  /* Revisitas y Estudios: textos secundarios más nítidos y legibles. */
  .revisits-screen .module-title-copy p{
    font-size:13px!important;
    line-height:1.45!important;
  }
  .revisits-screen .segmented button{
    font-size:12px!important;
    font-weight:780!important;
  }
  .revisits-screen .revisits-metrics small{
    font-size:10.5px!important;
    line-height:1.25!important;
    font-weight:720!important;
  }
  .revisits-screen .revisits-metrics span{
    font-size:10px!important;
    line-height:1.2!important;
  }
  .revisits-screen .records-panel>header span{
    font-size:11px!important;
  }
  .revisits-screen .record-group>summary small,
  .revisits-screen .record-main small,
  .revisits-screen .record-main em{
    font-size:11px!important;
    line-height:1.38!important;
  }
  .revisits-screen .status-chip{
    font-size:9px!important;
  }

  /* Ministerio: información pequeña un poco mayor sin romper el layout. */
  .ministry-screen .module-title-copy p{
    font-size:13px!important;
    line-height:1.45!important;
  }
  .ministry-screen .segmented button{
    font-size:12px!important;
    font-weight:780!important;
  }
  .ministry-screen .ministry-top-metrics small{
    font-size:10px!important;
    line-height:1.25!important;
    font-weight:700!important;
  }
  .ministry-screen .ministry-timer-hero>header small,
  .ministry-screen .ministry-timer-hero>header span{
    font-size:10.5px!important;
    line-height:1.3!important;
  }
  .ministry-screen .goal-card header strong{
    font-size:11.5px!important;
  }
  .ministry-screen .goal-card header span,
  .ministry-screen .goal-card>small{
    font-size:10px!important;
    line-height:1.3!important;
  }
  .ministry-screen .goal-card>p{
    font-size:10.5px!important;
    line-height:1.45!important;
  }
  .ministry-screen .ministry-profile-card small{
    font-size:11px!important;
    line-height:1.42!important;
  }
  .ministry-screen .ministry-recent-panel>header span,
  .ministry-screen .report-card small,
  .ministry-screen .service-year-card small{
    font-size:10.5px!important;
    line-height:1.3!important;
  }
  .ministry-screen .calendar-weekday{
    font-size:9px!important;
  }
  .ministry-screen .calendar-day small{
    font-size:9px!important;
  }
  .ministry-screen .calendar-hint{
    font-size:10.5px!important;
    line-height:1.4!important;
  }
  .ministry-screen .report-card dt{
    font-size:11.5px!important;
  }
}

/* =========================================================
   PROGRAMACIÓN, CALENDARIO Y FIREFOX MÓVIL
   ========================================================= */

.person-schedule{grid-column:1/-1;border:1px solid color-mix(in srgb,var(--accent) 18%,var(--line));border-radius:17px;background:color-mix(in srgb,var(--accent-soft) 34%,var(--paper));padding:14px;display:grid;gap:12px}

.person-schedule>header{display:flex;align-items:center;justify-content:space-between;gap:12px;border:0!important;padding:0!important}

.person-schedule>header>div{display:grid;gap:3px}

.person-schedule>header strong{font-size:13px}

.person-schedule>header small{font-size:10px;color:var(--muted);line-height:1.4}

.person-schedule>header>span{width:34px;height:34px;border-radius:11px;background:var(--paper);border:1px solid var(--line);display:grid;place-items:center;color:var(--accent);font-size:18px}

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

.person-schedule-grid label{display:grid;gap:6px}

.person-schedule-grid label>span{font-size:10px;font-weight:750;color:var(--muted)}

.person-calendar-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}

.person-calendar-actions button{min-height:43px;border:1px solid var(--line);border-radius:12px;background:var(--paper);display:flex;align-items:center;justify-content:center;gap:8px;padding:8px 10px;color:var(--text);font-size:10px;font-weight:780}

.person-calendar-actions button:hover:not(:disabled){border-color:color-mix(in srgb,var(--accent) 48%,var(--line));background:var(--accent-soft)}

.person-calendar-actions button:disabled{opacity:.45;cursor:not-allowed}

.person-calendar-actions button>span{width:23px;height:23px;border-radius:8px;background:var(--accent-soft);display:grid;place-items:center;color:var(--accent);font-weight:850}

.person-calendar-actions .calendar-google>span{background:#fff;color:#4285f4;border:1px solid #e2e6ef}

.person-calendar-note{color:var(--muted);font-size:9.5px;line-height:1.4}

.nav-ministry-icon-wrap{display:grid!important;place-items:center!important}

.nav-ministry-icon{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}

@media(max-width:760px){
  html,body{height:100%!important;min-height:100%!important;overflow:hidden!important}
  .portal{height:var(--notea-app-height,100dvh)!important;min-height:0!important;overflow-y:auto!important;overflow-x:hidden!important;overscroll-behavior-y:auto!important;touch-action:pan-y!important;-webkit-overflow-scrolling:touch!important}
  .portal-main,.portal[data-active-module="hub"] .portal-main{overflow:visible!important;min-height:0!important}
  .portal[data-active-module="hub"] .portal-main{padding-bottom:calc(142px + env(safe-area-inset-bottom))!important;scroll-padding-bottom:calc(142px + env(safe-area-inset-bottom))!important}
  .portal[data-active-module="hub"] .hub-screen{padding-bottom:18px!important}.portal[data-active-module="hub"] .premium-summary{margin-bottom:0!important}
  .portal-bottom-nav button:nth-child(4),.notes-bottom-nav button:nth-child(4){align-content:center!important;justify-content:center!important;justify-items:center!important;padding-top:0!important}
  .portal-bottom-nav button:nth-child(4)>span,.notes-bottom-nav button:nth-child(4)>span{width:20px!important;height:20px!important;min-width:20px!important;min-height:20px!important;margin:0 auto!important;display:grid!important;place-items:center!important;font-size:0!important;line-height:1!important;transform:none!important}
  .portal-bottom-nav button:nth-child(4)>span::before,.portal-bottom-nav button:nth-child(4)>span::after,.notes-bottom-nav button:nth-child(4)>span::before,.notes-bottom-nav button:nth-child(4)>span::after{display:none!important;content:none!important}
  .portal-bottom-nav .nav-ministry-icon,.notes-bottom-nav .nav-ministry-icon{width:20px!important;height:20px!important}.portal-bottom-nav button:nth-child(4)>small,.notes-bottom-nav button:nth-child(4)>small{margin:0!important;text-align:center!important;transform:none!important}
  .person-schedule{padding:13px;border-radius:16px;gap:11px}.person-schedule>header strong{font-size:14px}.person-schedule>header small{font-size:11px}.person-schedule-grid{grid-template-columns:1fr;gap:9px}.person-schedule-grid label>span{font-size:12px!important}.person-calendar-actions{grid-template-columns:1fr}.person-calendar-actions button{min-height:48px;font-size:12px;justify-content:flex-start;padding-inline:13px}.person-calendar-note{font-size:10.5px}
}

/* =========================================================
   TEMAS COHERENTES + NOCHE LEGIBLE
   - Móvil: +, cronómetro y contador siguen el tema elegido.
   - Noche: contraste equilibrado en móvil, tablet y escritorio.
   - Acerca de Notea: usa el símbolo nuevo dentro de una placa temática.
   ========================================================= */

/* El diálogo Acerca de Notea usa el símbolo nuevo y no el icono azul antiguo. */

.about-brand .brand-mark{
  width:52px!important;height:52px!important;min-width:52px!important;
  padding:9px!important;border-radius:16px!important;
  background:var(--accent)!important;
  box-shadow:0 10px 24px color-mix(in srgb,var(--accent) 25%,transparent)!important;
  overflow:hidden!important
}

.about-brand .brand-mark img{width:100%!important;height:100%!important;object-fit:contain!important;filter:none!important;opacity:1!important}

@media (min-width:761px){
  .about-brand .brand-mark{background:var(--c-nav-active,var(--c-accent-deep))!important}

  /* Noche de escritorio/tablet: carbón verdoso, superficies separadas y texto claro. */
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]){
    --c-bg:#111513;--c-bg-2:#1a201c;--c-paper:#232a25;--c-paper-2:#2d352f;
    --c-ink:#f5f4ed;--c-muted:#c0c8bd;--c-line:#465249;
    --c-accent:#91a88a;--c-accent-deep:#b9cfb2;--c-accent-soft:#344239;
    --c-lav:#b5a9ca;--c-lav-soft:#3b3644;--c-gold:#d0ad72;--c-gold-soft:#433a2d;
    --c-blue:#9cb8c0;--c-blue-soft:#304248;--c-stone:#9b9388;
    --c-nav-start:#202720;--c-nav-end:#101411;--c-nav-active:#71846d;--c-nav-ink:#f5f4ed;
    --c-hero-glow:rgba(145,168,138,.11);
    --c-card-notes-1:#273029;--c-card-notes-2:#313c34;--c-card-notes-border:#46554a;
    --c-card-revisits-1:#2c2931;--c-card-revisits-2:#37323e;--c-card-revisits-border:#51495a;
    --c-card-ministry-1:#302b24;--c-card-ministry-2:#3b3329;--c-card-ministry-border:#584a39;
    --c-card-icon-bg:rgba(245,244,237,.09);--c-card-arrow-bg:rgba(245,244,237,.07)
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) body,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .portal,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .app{color:var(--c-ink)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .portal-main::after{opacity:.09!important}

  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .module-title-copy h1,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .module-title-copy p,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-title-copy h1,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-group h2,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-control,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-action,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .record-main strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .people-records-panel h2,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-recent-panel h2,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .goal-card header strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-profile-card strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .report-card h2,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .report-card dd,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .calendar-head h2{color:var(--c-ink)!important}

  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .module-title-copy p,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .record-main small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .people-records-panel>header span,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-recent-panel>header span,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .goal-card header span,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .goal-card>small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .goal-card>p,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-profile-card small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .report-card dt,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .report-card small,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .calendar-weekday,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .calendar-hint{color:var(--c-muted)!important}

  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .hub-search,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .module-search,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .segmented,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .service-year-pill,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .people-records-panel,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-screen .settings-group,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .about-dialog form{
    background:var(--c-paper)!important;border-color:var(--c-line)!important;color:var(--c-ink)!important
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .module-search input,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .settings-control select{color:var(--c-ink)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .segmented button{color:var(--c-muted)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .segmented button.is-active{
    background:var(--c-accent-soft)!important;color:var(--c-accent-deep)!important
  }

  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-hub-grid .hub-card-icon,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-hub-grid .hub-card-arrow,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .revisits-metrics .metric-icon{
    background:rgba(245,244,237,.09)!important;
    border-color:rgba(245,244,237,.12)!important;
    color:var(--c-ink)!important
  }
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(1) .summary-icon{background:#354239!important;color:#cce0c7!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(2) .summary-icon{background:#403a49!important;color:#e1d6ee!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(3) .summary-icon{background:#304248!important;color:#d1e6ea!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .premium-summary .summary-grid>div:nth-child(4) .summary-icon{background:#433a2d!important;color:#f0d39b!important}

  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .record-avatar,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .status-chip{background:var(--c-lav-soft)!important;color:#ded3eb!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .record-main em{color:var(--c-accent-deep)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-timer-hero .timer-display{color:var(--c-accent-deep)!important;text-shadow:0 1px 16px rgba(185,207,178,.08)}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-timer-hero>header span{color:var(--c-muted)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-timer-hero [data-ministry-timer-pause],
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-timer-hero [data-ministry-timer-save]{background:var(--c-paper-2)!important;border-color:var(--c-line)!important;color:var(--c-ink)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics article:nth-child(1){background:var(--c-blue-soft)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics article:nth-child(2){background:var(--c-lav-soft)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics article:nth-child(3){background:var(--c-gold-soft)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics article:nth-child(4){background:var(--c-accent-soft)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics strong,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics small{color:var(--c-ink)!important}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) .ministry-top-metrics small{opacity:.76}
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) input::placeholder,
  :is(html[data-theme="dark"],html[data-theme="eclipse"],html[data-theme="peachcoal"],html[data-theme="aurora"]) textarea::placeholder{color:#aab3a8!important;opacity:1!important}
}
