:root {
  --bone: #dfded5;
  --ink: #202024;
  --obsidian: #2d2638;
  --union: #e04360;
  --union-deep: #a53146;
  --virtue-deep: #114746;
  --border: #6a6864;
  --muted: #423f3c;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bone);
  font-synthesis: none;
  line-height: 1.6;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100svh; display: flex; flex-direction: column; }
a { color: var(--virtue-deep); text-underline-offset: .23em; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--union-deep); outline-offset: 5px; }
h1:focus, main:focus { outline: none; }
.skip-link { position: absolute; top: .75rem; left: .75rem; transform: translateY(-200%); z-index: 5; padding: .65rem 1rem; background: var(--bone); }
.skip-link:focus { transform: translateY(0); }
.site-header, .site-footer { display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 1.5rem clamp(1.25rem, 5vw, 4rem); }
.site-header { border-bottom: 1px solid var(--border); }
.wordmark { font-size: 1.5rem; font-weight: 750; text-decoration: none; color: var(--obsidian); letter-spacing: -.05em; }
.wordmark span { font-size: .88rem; display: block; letter-spacing: .05em; font-weight: 500; line-height: 1.1; }
.portal-label { font-size: .8rem; color: var(--muted); }
main { flex: 1; width: 100%; display: grid; align-items: center; padding: clamp(2rem, 6vw, 5rem) 1.25rem; }
.portal-shell { width: 100%; max-width: 44rem; margin: 0 auto; }
.section-label { display: flex; align-items: center; gap: .65rem; font-size: .78rem; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); font-weight: 650; }
.marker { width: .55rem; height: .55rem; background: var(--union); }
.status { margin: 1rem 0 1.5rem; font-size: .9rem; color: var(--virtue-deep); }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); line-height: 1.15; letter-spacing: -.035em; color: var(--union-deep); margin: 0 0 1.25rem; font-weight: 720; overflow-wrap: anywhere; }
h2 { font-size: 1.1rem; color: var(--obsidian); margin: 0 0 .5rem; }
p { margin-top: 0; }
.intro { max-width: 36rem; font-size: 1.08rem; margin-bottom: 2rem; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 1.5rem; min-height: 3rem; padding: .7rem 1.35rem; text-decoration: none; border: 2px solid transparent; font-weight: 650; cursor: pointer; border-radius: .3rem; }
.primary { color: var(--bone); background: var(--union-deep); }
.primary:hover { background: #531823; }
.secondary { color: var(--obsidian); background: transparent; border-color: var(--obsidian); }
.secondary:hover { background: #bbb9b2; }
.button:disabled { cursor: wait; opacity: .75; }
.support-copy { color: var(--muted); font-size: .85rem; margin: 1.5rem 0 0; max-width: 36rem; }
.profile { margin: 0 0 2.25rem; border-top: 1px solid var(--border); }
.profile div { padding: .9rem 0; border-bottom: 1px solid var(--border); display: grid; grid-template-columns: minmax(8rem, 1fr) 2fr; gap: 1rem; }
dt { font-size: .84rem; color: var(--muted); }
dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.account-tools { border-left: .25rem solid var(--virtue-deep); padding-left: 1.25rem; margin-bottom: 2rem; }
.account-tools > p { font-size: .95rem; }
.account-links { display: flex; flex-wrap: wrap; gap: .4rem 1.5rem; }
.account-links a { padding: .55rem 0; font-size: .9rem; font-weight: 650; min-height: 2.75rem; }
.notice { color: #531823; padding: .9rem 1rem; border: 1px solid var(--union-deep); border-left-width: .25rem; margin-bottom: 1.5rem; }
.loading-line { display: block; height: .2rem; width: 7rem; background: var(--virtue-deep); animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .4; } }
.site-footer { border-top: 1px solid var(--border); font-size: .75rem; color: var(--muted); padding-block: 1rem; }
@media (max-width: 480px) {
  .site-header { align-items: flex-start; }
  .portal-label { max-width: 7rem; text-align: right; }
  .profile div { grid-template-columns: 1fr; gap: .2rem; }
  .account-links { flex-direction: column; align-items: flex-start; }
  .site-footer { align-items: flex-start; flex-direction: column; gap: .2rem; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; scroll-behavior: auto !important; } }

.technical-access { margin-top: 2.25rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.technical-access > p { color: var(--muted); font-size: .9rem; margin-bottom: 1rem; }
.technical-access form { display: grid; gap: .75rem; max-width: 28rem; }
.technical-access label { font-size: .9rem; font-weight: 650; }
.technical-access input { font: inherit; font-size: 1rem; color: var(--ink); background: var(--bone); border: 1px solid var(--border); border-radius: .3rem; min-height: 3rem; padding: .7rem .8rem; min-width: 0; width: 100%; }
.technical-access .button { justify-self: start; }
.technical-access input:disabled { opacity: .75; }

main:has(.dashboard:not([hidden])) {
  align-items: start;
  padding: clamp(1.25rem, 3vw, 3rem) clamp(1rem, 5vw, 4rem);
  background: #f3f1eb;
}
.portal-shell:has(.dashboard:not([hidden])) { max-width: 88rem; }
.portal-shell:has(.dashboard:not([hidden])) > .section-label { display: none; }
.portal-shell:has(.dashboard:not([hidden])) > .status { margin: 0 0 1rem; }
.dashboard {
  --surface: #faf9f6;
  --divider: #d4d0c9;
  display: grid;
  grid-template-columns: minmax(10rem, 12rem) minmax(0, 1fr);
  gap: clamp(1rem, 3vw, 2.75rem);
}
.dashboard-nav { display: flex; flex-direction: column; gap: .2rem; align-self: start; }
.dashboard-nav a {
  display: flex;
  align-items: center;
  min-height: 2.75rem;
  padding: .45rem .85rem;
  border-radius: .45rem;
  font-size: .92rem;
  font-weight: 650;
  text-decoration: none;
}
.dashboard-nav a:hover { background: var(--bone); text-decoration: underline; }
.dashboard-content { min-width: 0; display: grid; gap: clamp(1.2rem, 3vw, 2.25rem); }
.dashboard-content > * { scroll-margin-top: 1.25rem; }
.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(7rem, 34%);
  align-items: center;
  gap: 1.5rem;
  min-height: 13rem;
  background: var(--obsidian);
  color: #faf9f6;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-radius: .85rem;
}
.dashboard-eyebrow { color: #d7d3e0; margin: 0 0 .4rem; font-size: .88rem; }
.dashboard-hero h1 {
  color: inherit;
  font-size: clamp(2.8rem, 6.5vw, 5rem);
  line-height: 1;
  margin-bottom: .8rem;
  letter-spacing: -.065em;
}
.dashboard-greeting { margin: 0; overflow-wrap: anywhere; }
.dashboard-art { position: relative; height: 8.5rem; min-width: 0; }
.dashboard-orbit {
  position: absolute;
  inset: 16% 7%;
  border: 1px solid #9c94ac;
  border-radius: 50%;
}
.orbit-wide { transform: rotate(-24deg); }
.orbit-narrow { transform: rotate(28deg); }
.dashboard-node {
  position: absolute;
  width: .75rem;
  aspect-ratio: 1;
  border-radius: 50%;
}
.node-coral { background: var(--union); top: 19%; right: 19%; }
.node-cyan { background: #10bac9; bottom: 17%; left: 19%; }
.node-gold { background: #f19520; top: 46%; left: 46%; width: .55rem; }
.dashboard-content h2 { margin: 0 0 .8rem; font-size: 1.25rem; }
.dashboard-modules {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .85rem;
}
.dashboard-modules li, .dashboard-account {
  border: 1px solid var(--divider);
  border-radius: .7rem;
  background: var(--surface);
  padding: clamp(1rem, 2.2vw, 1.5rem);
}
.dashboard-modules h3 { margin: .65rem 0 .25rem; font-size: 1.08rem; }
.dashboard-modules p { color: var(--muted); font-size: .9rem; margin: 0 0 .75rem; }
.dashboard-modules small { color: var(--virtue-deep); font-size: .8rem; font-weight: 650; }
.module-icon {
  display: block;
  position: relative;
  height: 1.35rem;
  width: 1.35rem;
  border: 2px solid var(--virtue-deep);
}
.module-clients { border-radius: 50%; }
.module-sites { border-top-width: 5px; border-radius: .2rem; }
.module-payments { width: 1.05rem; border-radius: .15rem; }
.module-payments::after {
  content: '';
  position: absolute;
  inset: .22rem .14rem auto;
  border-top: 2px solid var(--virtue-deep);
  height: .25rem;
  border-bottom: 2px solid var(--virtue-deep);
}
.dashboard-account .profile { margin: 0 0 1.5rem; }
.dashboard-account .profile div { border-color: var(--divider); }
.dashboard-account .account-tools { margin: .85rem 0 1.5rem; }
.dashboard-account .account-tools h3 { margin: 0 0 .5rem; color: var(--obsidian); }
@media (max-width: 850px) {
  .dashboard { grid-template-columns: minmax(0, 1fr); }
  .dashboard-nav { flex-direction: row; flex-wrap: wrap; }
}
@media (max-width: 620px) {
  .dashboard-modules { grid-template-columns: minmax(0, 1fr); }
  .dashboard-hero { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .dashboard-art { display: none; }
}
