:root {
  --ink: #11251d;
  --text: #11251d;
  --muted: #66786f;
  --line: #dce6e0;
  --soft-line: #edf3ef;
  --bg: #f3f6f4;
  --panel: #ffffff;
  --panel-soft: #f8fbf9;
  --accent: #0f6b48;
  --accent-strong: #084c35;
  --accent-soft: #e8f5ee;
  --danger: #b91c1c;
  --danger-soft: #fef2f2;
  --danger-bg: #fff5f4;
  --warning: #a15c00;
  --warning-bg: #fff8e6;
  --shadow-sm: 0 8px 22px rgb(17 37 29 / 7%);
  --shadow-md: 0 18px 52px rgb(17 37 29 / 10%);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 78% -10%, rgb(15 107 72 / 16%), transparent 28%),
    linear-gradient(180deg, #fbfdfc 0%, var(--bg) 42%, #eef4f0 100%);
  letter-spacing: 0;
}

body::before {
  content: "";
  position: fixed;
  z-index: -1;
  inset: 0 0 auto;
  height: 220px;
  background:
    linear-gradient(135deg, transparent 54%, rgb(15 107 72 / 10%) 54% 58%, transparent 58%),
    linear-gradient(150deg, transparent 61%, rgb(26 80 118 / 14%) 61% 66%, transparent 66%),
    linear-gradient(180deg, rgb(255 255 255 / 78%), rgb(255 255 255 / 0));
  opacity: 0.9;
  pointer-events: none;
}

body.modal-open {
  overflow: hidden;
}

.page {
  width: min(1220px, calc(100% - 48px));
  margin: 0 auto;
  padding: 28px 0 42px;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 230px;
}

.brand-mark {
  position: relative;
  width: 54px;
  height: 42px;
  flex: 0 0 auto;
}

.brand-mark::before,
.brand-mark::after,
.brand-mark span {
  content: "";
  position: absolute;
  bottom: 0;
  display: block;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

.brand-mark::before {
  left: 0;
  width: 42px;
  height: 40px;
  background: linear-gradient(135deg, var(--accent-strong), #149466);
}

.brand-mark::after {
  right: 2px;
  width: 32px;
  height: 30px;
  background: linear-gradient(135deg, #d8efe4, var(--accent));
}

.brand-mark span {
  left: 14px;
  width: 14px;
  height: 16px;
  background: #ffffff;
  opacity: 0.9;
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex: 1;
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.top-nav span {
  border-radius: 999px;
  padding: 8px 14px;
  white-space: nowrap;
}

.top-nav .active {
  color: var(--accent);
  background: var(--accent-soft);
}

.header-actions {
  display: flex;
  justify-content: flex-end;
  min-width: 170px;
}

.language-switch {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.language-switch button {
  width: auto;
  min-width: 72px;
  height: 34px;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: 13px;
}

.language-switch button.active {
  color: white;
  background: var(--accent);
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

h1 {
  margin: 0;
  font-size: 32px;
  line-height: 1.18;
  letter-spacing: 0;
}

.panel,
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.panel {
  padding: 22px;
  margin-bottom: 22px;
  backdrop-filter: blur(10px);
}

.search-panel {
  position: relative;
  z-index: 30;
}

.form {
  display: grid;
  grid-template-columns: 1.4fr 180px 180px 180px 120px;
  gap: 14px;
  align-items: end;
}

.form > label,
.form > button {
  min-width: 0;
}

.mountain-search-field {
  position: relative;
  z-index: 40;
}

.mountain-suggestions {
  position: absolute;
  z-index: 90;
  top: calc(100% + 6px);
  right: 0;
  left: 0;
  max-height: min(320px, 52vh);
  overflow-x: hidden;
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--panel);
  box-shadow: var(--shadow-md);
  -webkit-overflow-scrolling: touch;
}

.mountain-suggestion {
  width: 100%;
  min-height: 52px;
  height: auto;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 9px 12px;
  color: var(--ink);
  background: var(--panel);
  text-align: left;
  cursor: pointer;
}

.mountain-suggestion:hover,
.mountain-suggestion:focus {
  background: #eef8f1;
  outline: none;
}

.mountain-suggestion strong {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
}

.mountain-suggestion span {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.mountain-suggestion-empty {
  padding: 12px;
  color: var(--muted);
  font-size: 13px;
}

.precheck-row {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  margin-top: 4px;
}

.precheck-field {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-width: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 650;
  line-height: 18px;
}

.precheck-field input {
  position: absolute;
  left: 0;
  top: 50%;
  width: 18px;
  height: 18px;
  margin: 0;
  opacity: 0;
  transform: translateY(-50%);
  cursor: pointer;
}

.precheck-field span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  white-space: normal;
}

.precheck-field span::before {
  content: "";
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  border: 1.5px solid #9aaba2;
  border-radius: 4px;
  background-color: #ffffff;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 13px 13px;
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.precheck-field input:checked + span::before {
  border-color: var(--accent);
  background-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg width='14' height='14' viewBox='0 0 14 14' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M3 7.1 5.8 10 11 4' fill='none' stroke='white' stroke-width='2.1' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.precheck-field input:focus-visible + span::before {
  box-shadow: 0 0 0 3px rgb(15 107 72 / 18%);
}

label span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

input,
button {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0 12px;
  font: inherit;
}

input {
  min-width: 0;
  color: var(--ink);
  background: #fbfdfc;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

input[type="date"] {
  -webkit-appearance: none;
  appearance: none;
}

input:focus {
  border-color: rgb(15 107 72 / 55%);
  background: #ffffff;
  outline: none;
  box-shadow: 0 0 0 4px rgb(15 107 72 / 10%);
}

input:disabled {
  color: var(--muted);
  background: #f1f5f2;
}

.coming-soon-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  vertical-align: middle;
}

.field-coming-soon > span {
  display: flex;
  align-items: center;
  gap: 2px;
}

.field-coming-soon input:disabled {
  border-style: dashed;
  color: var(--muted);
  background: #f0f3f1;
  cursor: not-allowed;
}

button {
  border: 0;
  color: white;
  background: linear-gradient(180deg, #12835a 0%, var(--accent) 100%);
  box-shadow: 0 8px 18px rgb(15 107 72 / 20%);
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

button:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgb(15 107 72 / 24%);
}

button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.status {
  min-height: 22px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 14px;
}

.status.error {
  border: 1px solid #fecaca;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  color: var(--danger);
  background: var(--danger-soft);
}

.form-helper {
  grid-column: 1 / -1;
  margin: -1px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.retry-status {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.retry-button {
  width: auto;
  min-width: 88px;
  height: 30px;
  padding: 0 14px;
  font-size: 13px;
}

.hidden {
  display: none;
}

.dashboard {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 18px;
}

.card {
  padding: 20px;
}

.card h2 {
  margin: 0 0 14px;
  font-size: 19px;
  line-height: 1.25;
  letter-spacing: 0;
}

.card-subtitle {
  margin: -4px 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.hero-card,
.wide-card {
  grid-column: 1 / -1;
}

.risk-section {
  display: grid;
  gap: 18px;
}

.card-kicker {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.hero-card {
  position: relative;
  overflow: hidden;
  padding: 26px;
}

.hero-card::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 58%;
  height: 150px;
  background:
    linear-gradient(145deg, transparent 58%, rgb(19 98 69 / 11%) 58% 64%, transparent 64%),
    linear-gradient(155deg, transparent 62%, rgb(26 80 118 / 13%) 62% 70%, transparent 70%),
    linear-gradient(180deg, rgb(230 241 236 / 72%), rgb(255 255 255 / 0));
  opacity: 0.75;
  pointer-events: none;
}

.hero-card > * {
  position: relative;
  z-index: 1;
}

.hero-subtitle {
  margin: -7px 0 22px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.score-row {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr) 260px;
  gap: 24px;
  align-items: stretch;
}

.score-decision {
  position: relative;
  overflow: hidden;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px;
  background: linear-gradient(180deg, #ffffff 0%, var(--panel-soft) 100%);
}

.score-decision::after {
  content: "";
  position: absolute;
  right: -24px;
  bottom: -22px;
  width: 130px;
  height: 80px;
  background:
    linear-gradient(135deg, transparent 44%, rgb(15 107 72 / 13%) 45% 55%, transparent 56%),
    linear-gradient(155deg, transparent 48%, rgb(15 107 72 / 10%) 49% 62%, transparent 63%);
  opacity: 0.8;
  pointer-events: none;
}

.score-decision:has(.final-decision.danger) {
  border-color: #f7b4ad;
  background: linear-gradient(180deg, #fffafa 0%, var(--danger-bg) 100%);
}

.score-decision:has(.final-decision.danger) .score-label {
  color: var(--danger);
}

.score-decision:has(.final-decision.warning) {
  border-color: #f0d98b;
  background: linear-gradient(180deg, #fffefa 0%, var(--warning-bg) 100%);
}

.score-decision:has(.final-decision.warning) .score-label {
  color: var(--warning);
}

.score-visual {
  align-self: stretch;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 24px 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbf9 100%);
  text-align: center;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 80%);
}

.score-visual h3 {
  margin: 0 0 16px;
  color: var(--ink);
  font-size: 18px;
}

.score-visual:has(.score-danger) {
  border-color: #f7b4ad;
  background: linear-gradient(180deg, #fffafa 0%, var(--danger-bg) 100%);
}

.score-visual:has(.score-warning) {
  border-color: #f0d98b;
  background: linear-gradient(180deg, #fffefa 0%, var(--warning-bg) 100%);
}

.score-value {
  color: var(--accent);
  font-size: 96px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0;
}

.score-value.score-danger {
  color: var(--danger);
}

.score-value.score-warning {
  color: var(--warning);
}

.score-value.score-ok {
  color: var(--accent);
}

.score-gauge-wrap {
  width: 100%;
  height: 10px;
  margin: 18px 0 8px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
}

.score-gauge-fill {
  width: 0;
  height: 100%;
  border-radius: 999px;
  transition: width 0.4s ease;
}

.score-gauge-fill.score-danger {
  background: var(--danger);
}

.score-gauge-fill.score-warning {
  background: var(--warning);
}

.score-gauge-fill.score-ok {
  background: var(--accent);
}

.score-gauge-labels {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.3;
}

.score-label {
  margin-bottom: 10px;
  font-size: 34px;
  font-weight: 800;
  line-height: 1.15;
}

.decision-alert {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px;
  background: linear-gradient(180deg, #ffffff 0%, var(--panel-soft) 100%);
}

.score-decision:has(.final-decision.danger) .decision-alert {
  border-color: #f7b4ad;
  background: linear-gradient(180deg, #fffafa 0%, var(--danger-bg) 100%);
}

.score-decision:has(.final-decision.warning) .decision-alert {
  border-color: #f0d98b;
  background: linear-gradient(180deg, #fffefa 0%, var(--warning-bg) 100%);
}

.final-decision {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  margin-bottom: 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 11px;
  color: var(--accent);
  background: #eef8f1;
  font-size: 13px;
  font-weight: 800;
}

.decision-note {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 14px;
  background: #ffffff;
}

.decision-note strong {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 14px;
}

.decision-note-advice {
  background: linear-gradient(180deg, #ffffff 0%, var(--accent-soft) 100%);
}

.decision-note-advice strong {
  color: var(--accent);
}

.final-decision.danger {
  border-color: #f3b1aa;
  color: var(--danger);
  background: var(--danger-bg);
}

.final-decision.warning {
  border-color: #ead58b;
  color: var(--warning);
  background: var(--warning-bg);
}

.summary {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}

.data-hint {
  margin: 10px 0 0;
  color: var(--warning);
  font-size: 13px;
  line-height: 1.5;
}

.score-explanation {
  margin-top: 0;
  border-top: 0;
  padding-top: 0;
  min-width: 0;
}

.score-explanation h3 {
  margin: 0 0 8px;
  font-size: 22px;
  line-height: 1.3;
}

.score-explanation-summary {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.score-plain-takeaway {
  margin: 0 0 12px;
  border: 1px solid var(--soft-line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  background: var(--accent-soft);
  color: var(--text);
  font-size: 13px;
  line-height: 1.6;
}

.score-factor-summary {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  font-size: 13px;
  line-height: 1.4;
}

.score-factor-summary strong {
  color: var(--text);
}

.score-factor-summary span {
  border: 1px solid #cfe6d8;
  border-radius: 999px;
  background: var(--accent-soft);
  padding: 4px 9px;
  color: var(--accent);
  font-weight: 800;
}

.score-factor-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.score-factor {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 16px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgb(17 37 29 / 7%);
}

.score-factor::before {
  content: "!";
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  color: var(--danger);
  background: var(--danger-soft);
  font-weight: 900;
}

.score-factor strong {
  display: block;
  margin-bottom: 3px;
  font-size: 13px;
}

.score-factor p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.score-effect {
  align-self: start;
  white-space: nowrap;
  color: var(--danger);
  font-size: 18px;
  font-weight: 800;
}

.score-risk-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 18px 0 10px;
  border-radius: 999px;
  padding: 7px 13px;
  color: var(--danger);
  background: var(--danger-soft);
  font-size: 14px;
  font-weight: 900;
}

.score-risk-pill--danger {
  color: var(--danger);
  background: var(--danger-soft);
}

.score-risk-pill--warning {
  color: var(--warning);
  background: var(--warning-bg);
}

.score-risk-pill--ok {
  color: var(--accent);
  background: var(--accent-soft);
}

.score-visual-note {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

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

.metric-grid div,
.weather-grid div,
.clothing-list div {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, #ffffff 0%, var(--panel-soft) 100%);
  padding: 13px;
}

.weather-dashboard {
  display: grid;
  gap: 14px;
}

.weather-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.weather-metric {
  position: relative;
  min-height: 76px;
  padding: 13px 50px 13px 14px !important;
}

.weather-icon {
  position: absolute;
  top: 50%;
  right: 13px;
  display: inline-flex;
  width: 27px;
  height: 27px;
  color: var(--accent);
  opacity: 0.7;
  transform: translateY(-50%);
}

.weather-icon svg {
  width: 100%;
  height: 100%;
}

.hourly-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.hourly-summary-grid div {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  min-height: 66px;
  padding: 12px 56px 12px 14px;
  background: linear-gradient(180deg, #ffffff 0%, var(--panel-soft) 100%);
}

.hourly-summary-grid span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.hourly-summary-grid strong {
  font-size: 16px;
}

.weather-actions {
  display: flex;
  justify-content: flex-end;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.secondary-button {
  width: auto;
  min-width: 180px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--accent);
  background: var(--accent-soft);
  box-shadow: none;
}

.secondary-button:disabled {
  color: var(--muted);
  background: #eef2ef;
  cursor: not-allowed;
}

.hourly-detail {
  max-height: min(62vh, 620px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.hourly-detail table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.hourly-detail th,
.hourly-detail td {
  border-bottom: 1px solid var(--line);
  padding: 13px 14px;
  text-align: left;
  white-space: nowrap;
}

.hourly-detail th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: var(--muted);
  background: #f8faf8;
  font-weight: 800;
}

.hourly-detail td:last-child {
  white-space: normal;
  min-width: 180px;
}

.hourly-risk-row {
  background: #fff8db;
}

.hourly-risk-row td:first-child {
  border-left: 4px solid var(--warning);
  font-weight: 800;
}

.modal-overlay {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgb(24 35 31 / 52%);
}

.modal-overlay.hidden {
  display: none;
}

.modal-panel {
  width: min(1180px, calc(100vw - 56px));
  max-height: calc(100vh - 56px);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--panel);
  box-shadow: 0 24px 80px rgb(24 35 31 / 24%);
  padding: 22px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.modal-header h2 {
  margin: 0;
  font-size: 24px;
}

.icon-button {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0;
  color: var(--ink);
  background: #f8faf8;
  font-size: 24px;
  line-height: 1;
}

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

.modal-summary div {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  background: #f8faf8;
}

.modal-summary span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.modal-summary strong {
  font-size: 18px;
}

.modal-help {
  margin: 0 0 12px;
  color: var(--warning);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
}

dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

dd {
  margin: 6px 0 0;
  font-size: 17px;
  font-weight: 800;
}

.risk-list {
  display: grid;
  gap: 11px;
}

.risk-list--flow {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.risk-item {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #ffffff;
  padding: 12px 13px;
}

.risk-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.risk-severity-dot {
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  margin-top: 5px;
  border-radius: 50%;
  background: #a0b5aa;
}

.risk-item--high {
  border-color: #f7b4ad;
  background: var(--danger-bg);
}

.risk-item--high .risk-severity-dot {
  background: var(--danger);
}

.risk-item--caution {
  border-color: #f0d98b;
  background: var(--warning-bg);
}

.risk-item--caution .risk-severity-dot {
  background: var(--warning);
}

.risk-item--info .risk-severity-dot {
  background: #a0b5aa;
}

.risk-item.red-flag {
  border-color: #f7b4ad;
  background: var(--danger-bg);
}

.high-risk-card {
  border-color: #f7b4ad;
  background: linear-gradient(180deg, #fff9f8 0%, #fff4f3 100%);
  box-shadow: 0 14px 40px rgb(185 28 28 / 8%);
}

.high-risk-card h2 {
  color: var(--danger);
}

.risk-notices-card {
  min-height: 0;
}

.warning-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  margin-right: 6px;
  border-radius: 50%;
  color: white;
  background: var(--danger);
  font-size: 12px;
  line-height: 1;
}

.risk-item.attention,
.attention-card {
  border-color: #f0d98b;
  background: var(--warning-bg);
}

.risk-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}

.risk-head span {
  color: var(--accent);
  font-weight: 800;
}

.risk-item.red-flag .risk-head span {
  color: var(--danger);
}

.risk-item.attention .risk-head span {
  color: var(--warning);
}

.risk-item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.risk-item p:first-child {
  margin-top: 0;
}

.blocking-reason-item {
  border-color: #f7b4ad;
  background: var(--danger-bg);
}

.blocking-reason-item .risk-severity-dot {
  background: var(--danger);
}

.risk-item.compact {
  padding: 10px 12px;
}

.rule-meta {
  display: grid;
  gap: 6px;
  margin: 10px 0 0;
}

.rule-meta div {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 8px;
  align-items: baseline;
}

.rule-meta dt,
.rule-meta dd {
  margin: 0;
  font-size: 12px;
}

.rule-meta dd {
  color: var(--ink);
  font-weight: 700;
  overflow-wrap: anywhere;
}

.missing-fields {
  overflow-wrap: anywhere;
  font-size: 12px;
}

.field-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.field-tags span {
  border: 1px solid #f0d98b;
  border-radius: 999px;
  padding: 4px 7px;
  color: var(--warning);
  background: #fffdf0;
  font-size: 12px;
  font-weight: 700;
}

.card-note {
  margin: -4px 0 12px;
  color: var(--warning);
  font-size: 13px;
  font-weight: 700;
}

.equipment-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.equipment-grid > div {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, #ffffff 0%, var(--panel-soft) 100%);
  padding: 16px;
}

.equipment-grid h3 {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 15px;
}

ul {
  margin: 0;
  padding-left: 18px;
  color: var(--ink);
  line-height: 1.9;
}

.clothing-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.empty {
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #f8faf8;
  padding: 12px;
}

.debug-card {
  background: #f8faf8;
}

.debug-card summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.debug-card pre {
  max-height: 360px;
  overflow: auto;
  margin: 12px 0 0;
  border: 1px solid var(--line);
  padding: 12px;
  background: #ffffff;
  color: #2d3330;
  font-size: 12px;
  line-height: 1.5;
}

.weather-unavailable-hidden {
  display: none;
}

.weather-unavailable-card {
  border-color: #f0d98b;
  background: var(--warning-bg);
}

.weather-unavailable-card h2 {
  margin-bottom: 10px;
}

.weather-unavailable-lead,
.weather-unavailable-message {
  margin: 0 0 10px;
  color: #5f4b00;
  line-height: 1.7;
}

.weather-retry-button {
  margin-top: 4px;
  margin-bottom: 12px;
}

.weather-source-errors {
  margin-top: 12px;
  border-top: 1px solid #f0d98b;
  padding-top: 12px;
}

.weather-source-errors summary {
  cursor: pointer;
  color: var(--warning);
  font-size: 13px;
  font-weight: 800;
}

.weather-source-errors ul {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding-left: 0;
  list-style: none;
}

.weather-source-errors li {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 10px;
  border: 1px solid #f0d98b;
  border-radius: var(--radius-sm);
  padding: 9px 10px;
  background: #fffdf0;
  color: #5f4b00;
  font-size: 12px;
}

.weather-source-errors span {
  overflow-wrap: anywhere;
}

.disclaimer {
  margin-top: 24px;
  border: 1px solid #f0d98b;
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  color: #5f4b00;
  background: linear-gradient(180deg, #fffdf2 0%, #fff9df 100%);
  box-shadow: var(--shadow-sm);
}

.disclaimer h2 {
  margin: 0 0 8px;
  font-size: 16px;
}

.disclaimer p {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
}

.trust-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) 1.15fr;
  gap: 16px;
  align-items: center;
  margin-top: 18px;
  padding: 6px 4px 0;
}

.trust-strip > div {
  display: grid;
  grid-template-columns: 42px 1fr;
  column-gap: 10px;
  align-items: center;
}

.trust-icon {
  display: grid;
  grid-row: span 2;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 900;
}

.trust-strip strong {
  font-size: 13px;
}

.trust-strip p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.trust-slogan {
  display: block !important;
  color: var(--muted);
  font-size: 15px;
  font-weight: 800;
  text-align: right;
}

@media (max-width: 980px) {
  .page {
    width: min(100% - 28px, 760px);
    padding-top: 18px;
  }

  .header {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
  }

  .top-nav {
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .header-actions {
    min-width: 0;
  }

  .form,
  .dashboard,
  .equipment-grid,
  .clothing-list,
  .score-row,
  .modal-summary,
  .weather-grid,
  .risk-list--flow,
  .hourly-summary-grid,
  .trust-strip {
    grid-template-columns: 1fr;
  }

  .panel {
    padding: 18px;
  }

  .form > label,
  .form > button,
  .form input {
    width: 100%;
    max-width: 100%;
  }

  .score-factor {
    grid-template-columns: 38px 1fr;
  }

  .score-effect {
    grid-column: 2;
  }

  .trust-strip > div {
    grid-template-columns: 38px 1fr;
  }

  .trust-slogan {
    text-align: left;
  }

  .weather-actions {
    justify-content: stretch;
  }

  .secondary-button {
    width: 100%;
  }

  .modal-overlay {
    align-items: stretch;
    justify-content: stretch;
    overflow-y: auto;
    padding: max(10px, env(safe-area-inset-top)) 10px max(10px, env(safe-area-inset-bottom));
    -webkit-overflow-scrolling: touch;
  }

  .modal-panel {
    width: 100%;
    height: calc(100dvh - 20px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    max-height: none;
    overflow-y: auto;
    padding: 16px;
    -webkit-overflow-scrolling: touch;
  }

  @supports not (height: 100dvh) {
    .modal-panel {
      height: calc(100vh - 24px);
    }
  }

  .hourly-detail {
    width: 100%;
    max-width: 100%;
    max-height: none;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
  }

  .hourly-detail table {
    min-width: 680px;
  }

  .hourly-detail th,
  .hourly-detail td {
    padding: 12px 10px;
    font-size: 13px;
  }

  .hourly-detail td:last-child {
    min-width: 150px;
  }
}
