/* Peony: Brand and Design Guide v1.0 and key screens v0.3. Fonts are served from Peony's
   own server (WEB-02). Aubergine and Plum palette only. */
@font-face{font-family:"TeX Gyre Pagella";src:url("fonts/texgyrepagella-regular.otf") format("opentype");font-weight:400;font-display:swap}
@font-face{font-family:"Inter";src:url("fonts/Inter-Regular.otf") format("opentype");font-weight:400;font-display:swap}
@font-face{font-family:"Inter";src:url("fonts/Inter-Medium.otf") format("opentype");font-weight:500;font-display:swap}
@font-face{font-family:"Inter";src:url("fonts/Inter-SemiBold.otf") format("opentype");font-weight:600;font-display:swap}

:root{
  --aubergine:#2A1B2D; --plum:#5B3160; --champagne:#B08D57; --lilac:#EFE9EE; --porcelain:#FAF8F5;
  --white:#FFFFFF; --stone:#6B6470; --hairline:#E6E1E8; --leaf:#2E6A4F; --garnet:#9E2236; --mist:#F1EEF2;
  --display:"TeX Gyre Pagella","Palatino Linotype",Palatino,serif; --ui:"Inter",system-ui,sans-serif;
}
*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%}
body{background:var(--porcelain);color:var(--aubergine);font-family:var(--ui);font-size:14.5px;line-height:1.5}
a{color:var(--plum)}
:focus-visible{outline:3px solid var(--plum);outline-offset:2px}
.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* app layout: Aubergine side navigation, content on Porcelain */
.app{min-height:100vh;display:grid;grid-template-columns:232px 1fr}
.side{background:var(--aubergine);color:#EDE6EF;padding:28px 20px;display:flex;flex-direction:column;gap:4px}
.brand{display:flex;align-items:center;gap:10px;margin:0 8px 30px;color:#fff;text-decoration:none}
.brand img{width:36px;height:36px}
.brand .word{font-family:var(--display);font-size:27px;letter-spacing:.02em}
.side nav a{display:flex;justify-content:space-between;align-items:center;color:#D8CFDA;text-decoration:none;padding:10px 12px;border-radius:8px;min-height:44px}
.side nav a.on{background:rgba(239,233,238,.12);color:#fff;box-shadow:inset 3px 0 0 var(--plum)}
.side nav a:hover{color:#fff}
.side .foot{margin-top:auto;font-size:12px;color:#B9AEBC;padding:0 12px;line-height:1.5}
.side .foot form{margin-top:8px}
.side nav .sub{display:flex;flex-direction:column;margin:2px 0 6px 12px;border-left:1px solid #4a3a4e}
.side nav .sub a{font-size:13px;min-height:36px;padding:7px 12px;color:#C9BECC}
.side nav .sub a.on{background:none;box-shadow:inset 3px 0 0 var(--champagne);color:#fff}
/* business: the name in full (never cut off), its fiscal year beneath, then change or add */
.biz{border:1px solid #4a3a4e;border-radius:12px;background:#35243A;margin-bottom:12px}
.biz summary{list-style:none;cursor:pointer;display:flex;flex-direction:column;gap:2px;padding:12px 14px;min-height:44px}
.biz summary::-webkit-details-marker{display:none}
.biz-kicker{font-size:11px;letter-spacing:.06em;text-transform:uppercase;color:#B9AEBC}
.biz-name{font-family:var(--display);font-size:17px;line-height:1.25;color:#fff;overflow-wrap:anywhere}
.biz-year{font-size:12px;color:#D8CFDA}
.biz-more{margin-top:6px;font-size:12px;color:#E9DCC4;text-decoration:underline}
.biz[open] .biz-more{display:none}
.biz-menu{border-top:1px solid #4a3a4e;padding:6px}
.biz-menu form{margin:0}
.biz-menu button,.biz-add{display:flex;flex-direction:column;gap:2px;width:100%;text-align:left;background:none;border:0;border-radius:8px;padding:9px 10px;font:inherit;color:#fff;cursor:pointer;text-decoration:none;min-height:44px;justify-content:center}
.biz-menu button:hover,.biz-add:hover{background:rgba(239,233,238,.08)}
.biz-menu button .biz-name{font-size:15px}
.biz-add{font-size:13px;color:#E9DCC4}
.residency{font-size:12px;color:#B9AEBC;line-height:1.45}
.residency strong{display:block;color:#EDE6EF;font-weight:600}
.side .link{background:none;border:0;color:#D8CFDA;font:inherit;font-size:12px;text-decoration:underline;cursor:pointer;padding:0;min-height:24px}
.main{padding:34px 44px;max-width:1180px}
.top{display:flex;justify-content:space-between;align-items:flex-end;gap:16px;margin-bottom:26px;flex-wrap:wrap}
h1{font-family:var(--display);font-weight:400;font-size:34px;line-height:1.15}
.meta{color:var(--stone);font-size:14px}
.where{display:flex;flex-direction:column;align-items:flex-end;text-align:right;max-width:46%}
.where-name{font-family:var(--display);font-size:19px;color:var(--plum);overflow-wrap:anywhere}
.step-no{font-size:13px;color:var(--stone);margin-bottom:4px}
.flow{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-top:28px}
.explain{margin-top:24px;background:var(--mist);border-radius:12px;padding:16px 18px}
.explain ul{margin:8px 0 10px 18px}
.explain li{margin-bottom:6px;font-size:13.5px}
.field .opt{color:var(--stone);font-size:12.5px}
.field .help{font-size:12.5px;color:var(--stone);margin-top:6px;line-height:1.45}
.count{color:var(--stone)}
.grid2{display:grid;grid-template-columns:1.35fr 1fr;gap:28px}
.panel{background:var(--white);border:1px solid var(--hairline);border-radius:14px;padding:26px 28px}
.label{font-size:14px;color:var(--stone)}
.note{font-size:12.5px;color:var(--stone);line-height:1.5}
.rows{margin-top:16px;border-top:1px solid var(--hairline)}
.row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:11px 0;border-bottom:1px solid var(--hairline)}
.row:last-child{border-bottom:0}
.row form{display:inline}
.row .end{display:flex;align-items:center;gap:12px;white-space:nowrap;flex-shrink:0}
.more{margin-top:16px}
.more summary{cursor:pointer;display:inline-block;border:1px solid var(--hairline);border-radius:10px;padding:9px 16px;font-weight:600;min-height:44px;list-style:none}
.more summary::-webkit-details-marker{display:none}
.more[open] summary{margin-bottom:16px}
.ok{color:var(--leaf);font-weight:600}.short{color:var(--garnet);font-weight:600}.wait{color:var(--stone);font-weight:500}
.progress{height:8px;background:var(--mist);border-radius:4px;overflow:hidden;margin:14px 0 6px}
.progress i{display:block;height:100%;background:var(--leaf)}
.messages{list-style:none;margin-bottom:20px}
.messages li{background:var(--lilac);border-radius:10px;padding:10px 14px;margin-bottom:8px}
.messages li.error{border-left:4px solid var(--garnet)}

/* statements and review */
.preview{margin-top:12px;background:var(--mist);border-radius:10px;padding:10px 12px;font-size:12.5px;overflow-x:auto;white-space:pre}
.row.total{font-weight:600}
.row.stack{flex-direction:column;align-items:flex-start;gap:8px}
.row.stack > span{overflow-wrap:anywhere}
.num{font-variant-numeric:tabular-nums;white-space:nowrap}

/* buttons: one main action per screen in Plum; others outlined */
.btn{display:inline-block;background:var(--plum);color:#fff;border-radius:10px;padding:12px 20px;font:inherit;font-weight:600;border:0;cursor:pointer;text-decoration:none;min-height:44px}
.btn.ghost{background:transparent;color:var(--aubergine);border:1px solid var(--hairline)}
.btn.small{padding:7px 14px;font-size:13.5px;min-height:36px}
.btn.wide{width:100%}

/* forms */
.field{margin-bottom:16px}
.field label,.field legend{display:block;font-size:14px;color:var(--stone);margin-bottom:6px}
.field input[type=text],.field input[type=email],.field input[type=password],.field input[type=number],
.field input[type=date],.field select,.field textarea{width:100%;font:inherit;color:var(--aubergine);background:#fff;border:1px solid var(--hairline);border-radius:12px;padding:12px 14px;min-height:44px}
.field input[type=checkbox]{width:20px;height:20px;accent-color:var(--plum);vertical-align:middle;margin-right:8px}
.field.check label{display:flex;align-items:center;color:var(--aubergine)}
.field fieldset{border:0}
.field .choices{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.field .choices label{display:flex;align-items:center;gap:10px;border:1px solid var(--hairline);border-radius:12px;padding:12px 14px;background:#fff;color:var(--aubergine);cursor:pointer;min-height:44px}
.field .choices input{accent-color:var(--plum)}
.field .errors{list-style:none;color:var(--garnet);font-size:13px;margin-top:6px}
.form-errors{list-style:none;color:var(--garnet);margin-bottom:14px}
.section{font-family:var(--display);font-weight:400;font-size:22px;margin:22px 0 12px}
.cols{display:grid;grid-template-columns:1fr 1fr;gap:0 20px}
.key{font-family:var(--ui);font-size:18px;letter-spacing:.08em;background:var(--mist);border-radius:10px;padding:12px 14px;font-variant-numeric:tabular-nums}
.codes{list-style:none;display:grid;grid-template-columns:1fr 1fr;gap:8px;font-size:17px;letter-spacing:.06em;font-variant-numeric:tabular-nums}
.codes li{background:var(--mist);border-radius:8px;padding:8px 12px;text-align:center}

/* sign-in and sign-up: one narrow column, as in the sign-up key screen */
.single{max-width:440px;margin:0 auto;padding:36px 22px 28px;min-height:100vh;display:flex;flex-direction:column}
.single .brand{color:var(--aubergine);margin:0 0 26px}
.single h1{font-size:34px;margin-bottom:10px}
.single .lede{color:var(--stone);font-size:15.5px;margin-bottom:24px}
.single .after{margin-top:16px;text-align:center}
.single footer{margin-top:auto;padding-top:40px;text-align:center;color:var(--stone);font-size:13px}

/* phone: the side navigation becomes a top bar; panels stack */
@media (max-width:820px){
  .app{grid-template-columns:1fr}
  .side{padding:16px 18px;gap:8px}
  .brand{margin:0 0 6px}
  .side nav{display:flex;gap:4px;overflow-x:auto}
  .side .foot{margin-top:6px;padding:0;display:flex;flex-wrap:wrap;gap:4px 14px;align-items:center}
  .side .foot form:first-child{flex-basis:100%}
  .side nav .sub{display:none}
  .biz{flex-basis:100%;margin-bottom:4px}
  .residency{flex-basis:100%}
  .where{align-items:flex-start;text-align:left;max-width:100%}
  .flow .btn{flex:1 1 100%;text-align:center}
  .row{flex-wrap:wrap}
  .main{padding:22px 18px}
  .grid2,.cols{grid-template-columns:1fr}
  .panel{padding:20px}
  h1{font-size:30px}
}
