@font-face {
  font-family: Manrope;
  src: url('/assets/manrope-latin.woff2') format('woff2');
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

.wamin-app {
  --bg: #FAF9F6;
  --surface: #FFFFFF;
  --ink: #17231F;
  --muted: #52655D;
  --brand: #145C43;
  --soft: #EDF4EE;
  --line: #DFE6DF;
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.7 Manrope, system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: 24px; }
a { color: var(--brand); text-underline-offset: 4px; }
button, input, select, textarea { font: inherit; }
button, summary { cursor: pointer; }
img { display: block; max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; }
h1, h2, h3 { font-weight: 800; line-height: 1.25; letter-spacing: -.04em; }
h1 { font-size: clamp(30px, 3.5vw, 42px); }
h2 { font-size: 23px; }
h3 { font-size: 17px; }
p + p { margin-top: 12px; }
::selection { background: #d5e8db; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 4px; }
.app-container { max-width: 1200px; margin-inline: auto; padding-inline: 32px; }
.app-header { border-bottom: 1px solid var(--line); }
.header-inner { min-height: 86px; display: flex; align-items: center; gap: 32px; }
.brand { display: inline-flex; flex-shrink: 0; }
.brand img { width: 140px; height: 40px; }
.main-nav { display: flex; align-items: center; gap: 24px; }
.main-nav a { min-height: 44px; display: inline-flex; align-items: center; font-size: 13px; font-weight: 700; color: var(--muted); text-decoration: none; }
.main-nav a:hover, .main-nav .nav-current { color: var(--brand); }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.language-switch { display: flex; gap: 2px; }
.language-switch a { display: grid; place-items: center; min-width: 36px; min-height: 44px; border-radius: 8px; font-size: 12px; font-weight: 750; color: var(--muted); text-decoration: none; }
.language-switch [aria-current] { background: var(--soft); color: var(--brand); }
.account-menu { position: relative; }
.account-menu summary { display: flex; align-items: center; gap: 10px; min-height: 44px; font-weight: 700; font-size: 13px; list-style: none; }
.account-menu summary::-webkit-details-marker { display: none; }
.account-name { max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-panel { position: absolute; z-index: 5; top: 54px; right: 0; width: 240px; background: var(--surface); padding: 20px; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 8px 24px #17231f08; overflow-wrap: anywhere; }
.account-panel button { width: 100%; }
.icon { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.svg-definitions { position: absolute; width: 0; height: 0; overflow: hidden; }
.skip-link { position: fixed; top: -100px; left: 20px; z-index: 10; padding: 12px 20px; border-radius: 8px; background: var(--brand); color: white; }
.skip-link:focus { top: 12px; }
.app-main { padding-top: 46px; padding-bottom: 64px; min-height: calc(100vh - 190px); }
.page-intro { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.page-intro h1 { margin-top: 10px; }
.page-intro > div { min-width: 0; overflow-wrap: anywhere; }
.page-intro p:not(.eyebrow) { color: var(--muted); max-width: 680px; margin-top: 14px; }
.eyebrow { color: var(--brand); font-size: 11px; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; }
.page-intro .pill { margin-top: 18px; flex-shrink: 0; }
.card { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 30px; margin-bottom: 24px; overflow-wrap: anywhere; }
.card > h2, .card-heading { margin-bottom: 16px; }
.card > p { margin-bottom: 18px; }
.card > p:last-child { margin-bottom: 0; }
.card-heading { display: flex; align-items: flex-start; gap: 14px; }
.card-heading h2 { margin-top: 3px; }
.card-heading p { margin-top: 6px; }
.step-number, .icon-tile { display: grid; place-items: center; width: 42px; height: 42px; flex-shrink: 0; background: var(--soft); color: var(--brand); border-radius: 12px; font-weight: 800; }
.card-soft { background: var(--soft); }
.muted { color: var(--muted); font-size: 13px; line-height: 1.75; }
label { display: block; color: var(--ink); font-size: 13px; font-weight: 700; margin: 18px 0 7px; }
input, select, textarea { width: 100%; min-width: 0; min-height: 48px; padding: 11px 14px; border: 1px solid #cad6cd; border-radius: 9px; background: white; color: var(--ink); font-size: 16px; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #65786d; opacity: 1; }
textarea { resize: vertical; }
input[type=radio] { width: 18px; min-height: 18px; height: 18px; margin: 4px 0 0; accent-color: var(--brand); flex-shrink: 0; }
input[type=file] { background: var(--bg); padding: 10px; }
input[type=file]::file-selector-button { padding: 8px 12px; margin-right: 12px; border: 0; border-radius: 6px; background: var(--soft); color: var(--brand); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
button, .button { display: inline-flex; justify-content: center; align-items: center; gap: 12px; min-height: 48px; margin-top: 22px; padding: 11px 18px; border: 1px solid var(--brand); border-radius: 9px; background: var(--brand); color: white; font-size: 13px; font-weight: 750; line-height: 1.6; text-decoration: none; }
button:hover, .button:hover { background: #0d4934; }
button.secondary, .button.secondary { background: transparent; color: var(--brand); border-color: #b9cdc0; }
button.secondary:hover, .button.secondary:hover { background: var(--soft); }
button:disabled { opacity: .5; cursor: default; }
.header-actions .button { margin: 0; }
.text-link { display: inline-flex; gap: 10px; align-items: center; min-height: 44px; font-size: 13px; font-weight: 750; }
.text-link .icon { width: 17px; height: 17px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 20px; }
.field { min-width: 0; }
.form-note { margin-top: 12px; }
.form-details { margin-top: 24px; border-top: 1px solid var(--line); padding-top: 14px; }
.form-details > summary { min-height: 44px; font-size: 13px; font-weight: 750; color: var(--brand); padding-block: 10px; }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.workspace-grid > *, .settings-content { min-width: 0; }
.business-list { display: grid; gap: 12px; margin-top: 22px; }
.business-link { display: flex; align-items: center; gap: 14px; padding: 18px; border: 1px solid var(--line); border-radius: 16px; text-decoration: none; transition: border-color .15s, background .15s; }
.business-link:hover { border-color: #a8c4b2; background: #f8fbf8; }
.business-link strong { color: var(--ink); font-size: 16px; }
.business-link small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.business-link > .icon { margin-left: auto; width: 18px; }
.empty-state { background: var(--bg); border: 1px dashed #cbd8ce; border-radius: 16px; padding: 24px; margin-top: 20px; }
.empty-state > .icon { color: var(--brand); margin-bottom: 12px; }
.empty-state p { color: var(--muted); font-size: 14px; }
.price-row { padding-block: 18px; border-bottom: 1px solid #d4e1d5; }
.price-row:last-of-type { border: 0; }
.price-row p { font-weight: 750; }
.settings-layout { display: grid; grid-template-columns: 205px minmax(0, 1fr); gap: 36px; align-items: start; }
.section-nav { position: sticky; top: 24px; }
.section-nav > .eyebrow { padding: 0 12px 12px; }
.section-nav a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 12px; border-radius: 9px; color: var(--muted); font-weight: 650; font-size: 13px; text-decoration: none; }
.section-nav a:hover, .section-nav a:focus-visible { background: var(--soft); color: var(--brand); }
.section-nav span { display: grid; place-items: center; font-size: 11px; width: 24px; height: 24px; border: 1px solid var(--line); border-radius: 7px; }
.section-nav .nav-divider { margin-top: 16px; border-top: 1px solid var(--line); border-radius: 0; padding-top: 18px; }
.operator-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; border: 0; padding: 0; margin: 18px 0; }
.operator-options legend { padding: 0 0 8px; font-size: 13px; font-weight: 700; }
.operator-option { display: flex; align-items: flex-start; gap: 12px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; margin: 0; cursor: pointer; }
.operator-option:has(input:checked) { border-color: var(--brand); background: var(--soft); }
.operator-option small { display: block; margin-top: 6px; color: var(--muted); font-weight: 400; font-size: 12px; line-height: 1.75; }
.persona-library { border: 1px solid #d5e3d7; background: #f4f8f3; border-radius: 16px; padding: 22px; margin: 24px 0; }
.persona-library h3 { margin-bottom: 6px; }
.persona-library summary { min-height: 44px; cursor: pointer; padding-block: 10px; font-size: 13px; font-weight: 700; }
.persona-template { border-top: 1px solid #dce8e0; margin-top: 18px; padding-top: 10px; }
.persona-template > summary { font-size: 15px; }
.persona-template h4 { font-size: 13px; margin-top: 18px; }
.persona-template-label { color: var(--muted); font-size: 12px; font-weight: 700; margin: 18px 0 4px; }
.persona-template-text { white-space: pre-line; font-size: 14px; }
.persona-template-example { background: white; border-left: 3px solid var(--brand); border-radius: 0 8px 8px 0; padding: 14px 16px; font-size: 14px; }
.persona-template-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.persona-template-status { margin-top: 12px; }
.persona-template-status:empty { display: none; }
.binding-card { background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: 18px; margin-block: 18px; }
form.inline { display: inline; }
form.inline button { margin-right: 6px; }
.pill { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 7px; font-size: 11px; font-weight: 750; line-height: 1.6; background: var(--soft); color: var(--brand); }
.pill-confirmed { background: #E5F2E9; color: #145C43; }
.pill-pending { background: #FFF4D6; color: #75520C; }
.error { color: #923522; background: #fff2ea; border-radius: 9px; padding: 12px 16px; font-size: 13px; }
.form-error { margin: 12px 0; }
.form-error strong, .form-error span { display: block; }
.form-error strong { margin-bottom: 4px; }
input[aria-invalid="true"] { border-color: #923522; }
code { background: var(--soft); color: var(--brand); padding: 3px 7px; border-radius: 5px; font-size: 12px; overflow-wrap: anywhere; }
.table-scroll { overflow-x: auto; margin-block: 16px; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 13px 12px; border-bottom: 1px solid var(--line); }
th { background: #f6f8f4; color: var(--muted); font-weight: 650; font-size: 11px; }
td { vertical-align: top; }
.record-row { padding-block: 16px; border-bottom: 1px solid var(--line); }
.record-row:last-child { border: 0; }
.service-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.service-card { display: flex; align-items: center; gap: 16px; padding: 22px 26px; }
.service-card h2 { font-size: 15px; letter-spacing: -.02em; margin-bottom: 4px; }
.pairing-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: 40px; align-items: center; }
.pairing-copy > p { color: var(--muted); margin-top: 16px; }
.pairing-copy .pill { margin-top: 16px; }
.qr-panel { background: var(--bg); border: 1px solid var(--line); border-radius: 20px; padding: 24px; text-align: center; }
.qr-frame { display: grid; place-items: center; min-height: 260px; background: white; border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.qr-frame img { width: 100%; height: auto; }
.qr-placeholder { padding: 28px 12px; color: var(--muted); max-width: 260px; font-size: 13px; }
.qr-placeholder .icon { display: block; width: 44px; height: 44px; margin: 0 auto 16px; color: var(--brand); }
.qr-placeholder strong { display: block; }
.qr-placeholder p { margin-top: 12px; }
.qr-panel > p { margin-top: 14px; }
.connected-card { display: flex; align-items: flex-start; gap: 18px; padding-block: 36px; }
.connected-card h2 { margin-bottom: 10px; }
.activation-card { max-width: 680px; margin-inline: auto; }
.activation-card h1 { font-size: 32px; margin-top: 12px; }
.activation-card > p { margin-top: 20px; }
.activation-code { display: block; background: var(--soft); padding: 22px; text-align: center; font-size: clamp(18px, 3vw, 24px); letter-spacing: .06em; }
.app-footer { display: flex; align-items: center; gap: 16px; border-top: 1px solid var(--line); padding-block: 24px; color: var(--muted); font-size: 11px; }
.app-footer > span { font-weight: 800; color: var(--brand); font-size: 15px; }
.register-card { max-width: 480px; margin-inline: auto; }
@media (max-width: 900px) {
  .settings-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .section-nav { position: static; display: flex; flex-wrap: wrap; gap: 4px; }
  .section-nav > .eyebrow { width: 100%; padding-left: 0; }
  .section-nav a { min-height: 44px; background: var(--soft); }
  .section-nav .nav-divider { border: 0; border-radius: 9px; margin: 0; padding-top: 10px; }
  .workspace-grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); }
  .pairing-layout { gap: 24px; }
}
@media (max-width: 640px) {
  .app-container { padding-inline: 20px; }
  .header-inner { min-height: 76px; gap: 10px; flex-wrap: wrap; padding-block: 12px; }
  .brand img { width: 112px; height: 32px; }
  .header-actions { gap: 10px; }
  .account-name { max-width: 86px; }
  .account-menu summary { gap: 4px; font-size: 12px; }
  .language-switch a { min-width: 30px; }
  .main-nav { order: 3; width: 100%; gap: 20px; border-top: 1px solid var(--line); padding-top: 4px; }
  .main-nav a { min-height: 44px; }
  .app-main { padding-top: 28px; padding-bottom: 36px; }
  .page-intro { gap: 12px; margin-bottom: 24px; flex-wrap: wrap; }
  .page-intro .pill { margin: 0; }
  .page-intro p:not(.eyebrow) { font-size: 14px; }
  .card { padding: 22px; border-radius: 20px; margin-bottom: 18px; }
  h2 { font-size: 21px; }
  .workspace-grid, .form-grid, .operator-options, .service-grid, .pairing-layout { grid-template-columns: minmax(0, 1fr); }
  .workspace-grid, .service-grid { gap: 0; }
  .card-heading { gap: 12px; }
  .step-number { width: 36px; height: 36px; border-radius: 10px; }
  .persona-library { padding: 18px; }
  .persona-template-actions { flex-direction: column; gap: 0; }
  .persona-template-actions button { width: 100%; }
  .section-nav a { font-size: 12px; padding-inline: 10px; gap: 8px; }
  .section-nav span { width: 20px; height: 20px; }
  .qr-panel { padding: 18px; }
  .qr-frame { min-height: 230px; }
  .service-card { padding: 20px 22px; }
  .app-footer { align-items: flex-start; flex-direction: column; gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

.error-page { max-width: 680px; margin: 28px auto; }
.error-page h1 { margin: 16px 0 24px; }
.error-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.app-footer { flex-wrap: wrap; }
.app-legal-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.app-legal-links a { min-height: 44px; display: inline-flex; align-items: center; }
