:root {
  color-scheme: light;
  --ink: #16333c;
  --ink-soft: #4d6470;
  --teal: #0b666e;
  --teal-deep: #0b555d;
  --teal-pale: #e5f3f2;
  --bg: #f5f8f8;
  --paper: #ffffff;
  --border: #dce6e8;
  --shadow: 0 8px 26px rgb(13 62 67 / 5%);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; line-height: 1.48; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 3px solid #1d9399; outline-offset: 3px; }
[hidden] { display: none !important; }
.app-shell { max-width: 860px; min-height: 100dvh; margin: auto; background: var(--bg); }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 87px; padding: 15px 22px; background: var(--paper); border-bottom: 1px solid var(--border); }
.brand { display: flex; align-items: center; min-width: 0; gap: 10px; }
.brand-mark { display: block; width: 47px; height: 47px; border-radius: 13px; box-shadow: 0 2px 7px #17494f18; }
.brand-title { display: grid; min-width: 0; line-height: 1.2; gap: 3px; }
.brand-title strong { color: #16474d; font-size: 21px; letter-spacing: -.4px; }
.brand-title small { color: var(--ink-soft); font-size: 11px; }
.storage-status { display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0; color: var(--ink-soft); font-size: 11px; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #d5a54b; }
.storage-status.is-ready .status-dot { background: #168761; }
.storage-status.is-error .status-dot { background: #b63745; }
main { padding: 30px 23px 110px; }
.view { animation: fade-in .18s ease-in; }
@keyframes fade-in { from { opacity: .65; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.eyebrow { color: var(--teal); text-transform: uppercase; letter-spacing: .13em; font-size: 11px; font-weight: 800; margin: 0 0 4px; }
h1 { margin: 0; font-size: clamp(26px, 5vw, 32px); letter-spacing: -.85px; line-height: 1.22; }
.intro { margin: 9px 0 24px; color: var(--ink-soft); max-width: 650px; font-size: 15px; }
h2 { font-size: 18px; line-height: 1.35; }
.context-card, .settings-card, .information-card, .feature-tile, .empty-state { background: var(--paper); border: 1px solid var(--border); border-radius: 17px; box-shadow: var(--shadow); }
.context-card { padding: 21px; border-left: 4px solid var(--teal); }
.context-heading { display: flex; align-items: center; gap: 9px; }
.context-heading h2 { font-size: 16px; margin: 0; }
.context-symbol { display: flex; align-items: center; justify-content: center; width: 29px; height: 29px; background: var(--teal-pale); border-radius: 9px; color: var(--teal); font-size: 21px; }
.context-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin: 19px 0 15px; }
.context-grid dt { font-size: 12px; color: var(--ink-soft); margin-bottom: 4px; }
.context-grid dd { font-weight: 650; margin: 0; overflow-wrap: anywhere; font-size: 14px; }
.text-link { color: var(--teal); font-weight: 700; font-size: 13px; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.section-heading { margin: 29px 0 13px; font-size: 18px; }
.tile-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.feature-tile { padding: 18px; display: flex; flex-direction: column; align-items: flex-start; min-height: 206px; }
.tile-top { display: flex; justify-content: space-between; align-items: flex-start; width: 100%; }
.feature-icon { display: flex; justify-content: center; align-items: center; width: 43px; height: 43px; border-radius: 12px; background: var(--teal-pale); color: var(--teal); font-size: 25px; font-weight: 700; }
.phase-chip { font-size: 11px; padding: 5px 9px; color: var(--ink-soft); background: #f2f6f7; border: 1px solid var(--border); border-radius: 100px; }
.feature-tile h3 { margin: 13px 0 3px; font-size: 17px; }
.feature-tile p { margin: 0 0 14px; font-size: 13px; color: var(--ink-soft); }
.planned-button { margin-top: auto; border: 1px solid var(--border); background: #f3f6f6; border-radius: 10px; padding: 9px 12px; font-size: 12px; color: #687b83; width: 100%; cursor: not-allowed; }
.phase-notice, .info-note { margin: 22px 0 0; padding: 13px 15px; border-radius: 12px; background: #edf4f5; color: #37545f; font-size: 13px; }
.bottom-nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: min(100%, 860px); background: #fff; border-top: 1px solid var(--border); display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); z-index: 20; padding: 7px 10px calc(7px + env(safe-area-inset-bottom)); box-shadow: 0 -4px 20px #17394008; }
.nav-link { color: #617882; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 2px; border-radius: 11px; min-height: 52px; text-decoration: none; font-weight: 600; font-size: 11px; }
.nav-link svg { width: 21px; height: 21px; }
.nav-link[aria-current="page"] { color: var(--teal-deep); background: var(--teal-pale); }
.settings-card { padding: 22px; }
.settings-card h2 { margin: 0 0 18px; }
.form-field { display: grid; gap: 7px; margin: 0 0 17px; }
.form-field label, .logo-field > label { font-size: 13px; font-weight: 700; }
input[type="text"] { width: 100%; border-radius: 10px; min-height: 49px; padding: 12px 13px; border: 1px solid #c8d8dc; background: white; color: var(--ink); font-size: 16px; }
input::placeholder { color: #87999f; }
.logo-field { border-top: 1px solid var(--border); padding-top: 18px; margin-top: 8px; }
.field-hint { font-size: 12px; margin: 3px 0 12px; color: var(--ink-soft); }
.logo-preview { display: flex; justify-content: center; align-items: center; min-height: 114px; border: 1px dashed #bfd2d4; border-radius: 12px; background: #f8fbfb; color: var(--ink-soft); font-size: 13px; padding: 12px; }
.logo-preview img { display: block; max-width: 100%; max-height: 100px; object-fit: contain; }
.logo-actions { display: flex; flex-wrap: wrap; gap: 9px; margin: 13px 0 21px; }
.logo-actions input { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; }
.file-label, .secondary-button { display: inline-flex; justify-content: center; align-items: center; padding: 11px 14px; border: 1px solid #bacfd1; color: var(--teal-deep); background: white; border-radius: 10px; font-weight: 700; font-size: 13px; cursor: pointer; }
.secondary-button:disabled { color: #8b9ca2; cursor: not-allowed; background: #f7f9f9; }
.file-label:focus-within { outline: 3px solid #1d9399; outline-offset: 3px; }
.primary-button { display: block; width: 100%; min-height: 49px; border: 0; border-radius: 11px; background: var(--teal-deep); color: white; padding: 12px 15px; font-weight: 750; cursor: pointer; }
.primary-button:hover:not(:disabled) { background: #073e45; }
.primary-button:disabled { opacity: .6; cursor: not-allowed; }
.form-message { margin: 10px 0 0; font-size: 13px; min-height: 1em; color: var(--teal); }
.form-message.is-error { color: #a42535; }
.information-card { margin-top: 16px; padding: 20px 22px; }
.information-card h2 { font-size: 17px; margin: 0 0 8px; }
.information-card p { color: var(--ink-soft); font-size: 13px; margin: 0 0 10px; }
.information-card p:last-child { margin-bottom: 0; }
.empty-state { padding: 43px 24px; text-align: center; }
.empty-state h2 { margin: 12px 0 6px; }
.empty-state p { max-width: 390px; margin: 0 auto; color: var(--ink-soft); font-size: 14px; }
.empty-symbol { display: flex; justify-content: center; align-items: center; margin: auto; width: 64px; height: 64px; border-radius: 16px; background: var(--teal-pale); color: var(--teal); font-size: 33px; }
.reports-list { display: grid; gap: 10px; }
.report-item { padding: 16px; background: white; border: 1px solid var(--border); border-radius: 12px; }
.report-item h2 { font-size: 15px; margin: 0 0 4px; }
.report-item p { margin: 0; color: var(--ink-soft); font-size: 12px; }
.alert { padding: 14px; border-radius: 10px; margin: 0 0 16px; font-size: 13px; }
.alert-error { border: 1px solid #e9b4b6; color: #86272b; background: #fff1f1; }
@media (max-width: 500px) {
  .topbar { padding: 12px 15px; min-height: 75px; }
  .brand-mark { width: 40px; height: 40px; }
  .brand-title strong { font-size: 19px; }
  .brand-title small { max-width: 160px; font-size: 10px; }
  .storage-status { max-width: 93px; font-size: 10px; line-height: 1.2; }
  main { padding: 23px 15px 109px; }
  .context-card, .settings-card, .information-card { padding: 17px; }
  .context-grid { grid-template-columns: 1fr; gap: 11px; }
  .context-grid div { display: grid; grid-template-columns: 90px 1fr; gap: 6px; }
  .context-grid dt { margin: 0; }
  .feature-tile { min-height: 213px; padding: 13px; }
  .feature-tile h3 { font-size: 16px; }
  .feature-tile p { font-size: 12px; }
  .phase-chip { font-size: 10px; padding: 4px 6px; }
  .feature-icon { width: 38px; height: 38px; }
  .planned-button { font-size: 11px; padding: 8px; }
}
@media (max-width: 350px) { .tile-grid { grid-template-columns: 1fr; } .feature-tile { min-height: 180px; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .view { animation: none; } }
