/**
 * Tank SOS — mobile-first calm diagnostic UI
 */

.tank-sos-page {
  --sos-bg: linear-gradient(165deg, #f0f7ff 0%, #f6f8fb 45%, #ffffff 100%);
  --sos-card: #ffffff;
  --sos-border: #dbe4f0;
  --sos-muted: #64748b;
  --sos-accent: #2563eb;
  --sos-accent-soft: rgba(37, 99, 235, 0.08);
  --sos-radius: 16px;
  min-height: 60vh;
}

.tank-sos-main {
  padding-bottom: 3rem;
}

.tank-sos-hero {
  text-align: center;
  padding: 1.25rem 0 1.5rem;
  max-width: 32rem;
  margin: 0 auto;
}

.tank-sos-hero h1 {
  font-size: clamp(1.45rem, 4.5vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 0.5rem;
  color: var(--ht-text, #0f172a);
  line-height: 1.2;
}

.tank-sos-hero-lead {
  margin: 0;
  font-size: 1rem;
  line-height: 1.55;
  color: var(--sos-muted);
  font-weight: 500;
}

.tank-sos-tool-wrap {
  max-width: 28rem;
  margin: 0 auto;
  padding: 0 4px;
}

.tank-sos-card {
  background: var(--sos-card);
  border: 1px solid var(--sos-border);
  border-radius: var(--sos-radius);
  box-shadow: 0 10px 34px rgba(15, 23, 42, 0.06);
  padding: 1.1rem 1rem 1.25rem;
}

.tank-sos-progress-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.tank-sos-step-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--sos-muted);
  letter-spacing: 0.02em;
}

.tank-sos-progress-track {
  flex: 1;
  min-width: 100px;
  height: 6px;
  background: #e8eef6;
  border-radius: 99px;
  overflow: hidden;
}

.tank-sos-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #2563eb);
  border-radius: 99px;
  transition: width 0.35s ease;
  width: 0%;
}

.tank-sos-q-title {
  font-size: 1.08rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: var(--ht-text, #0f172a);
  line-height: 1.35;
}

.tank-sos-options {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.tank-sos-opt {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.95rem 1rem;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  color: #0f172a;
  background: #f8fafc;
  border: 1px solid var(--sos-border);
  border-radius: 12px;
  cursor: pointer;
  line-height: 1.35;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.1s ease;
  -webkit-tap-highlight-color: transparent;
}

.tank-sos-opt:hover,
.tank-sos-opt:focus-visible {
  background: var(--sos-accent-soft);
  border-color: rgba(37, 99, 235, 0.35);
  outline: none;
}

.tank-sos-opt:active {
  transform: scale(0.99);
}

.tank-sos-toolbar {
  margin-top: 1rem;
  display: flex;
  justify-content: flex-end;
}

.tank-sos-reset {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--sos-muted);
  background: none;
  border: none;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  font-family: inherit;
  padding: 0.35rem 0.25rem;
}

.tank-sos-reset:focus-visible {
  outline: 2px solid var(--sos-accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.tank-sos-first-urgent {
  font-size: 0.95rem;
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e3a5f;
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.tank-sos-verdict {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 0.65rem;
  color: #0f172a;
  line-height: 1.3;
}

.tank-sos-subhead {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #475569;
  margin: 0.9rem 0 0.35rem;
}

.tank-sos-p {
  margin: 0 0 0.65rem;
  font-size: 0.95rem;
  line-height: 1.58;
  color: #334155;
}

.tank-sos-steps {
  margin: 0;
  padding-left: 1.2rem;
  font-size: 0.95rem;
  line-height: 1.52;
  color: #1e293b;
}

.tank-sos-steps li + li {
  margin-top: 0.35rem;
}

.tank-sos-result-actions {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.tank-sos-btn-primary {
  display: inline-block;
  text-align: center;
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
  background: #2563eb;
  border-radius: 12px;
  border: none;
  text-decoration: none;
  font-family: inherit;
  cursor: pointer;
}

.tank-sos-btn-primary:hover {
  background: #1d4ed8;
  color: #ffffff;
}

.tank-sos-btn-ghost {
  text-align: center;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--sos-accent);
  text-decoration: none;
  padding: 0.5rem;
}

.tank-sos-index-link-section {
  margin-top: 2.75rem;
  padding-top: 2rem;
  border-top: 1px solid var(--sos-border);
  max-width: 40rem;
  margin-left: auto;
  margin-right: auto;
}

.tank-sos-index-link-section h2 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 0.75rem;
  color: #0f172a;
}

.tank-sos-symptom-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.65rem;
  font-size: 0.9rem;
  line-height: 1.45;
}

.tank-sos-symptom-grid a {
  color: #2563eb;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.tank-sos-symptom-grid a:hover {
  color: #1d4ed8;
}

/* Standalone diagnosis pages */
.tank-sos-article {
  max-width: 40rem;
  margin: 0 auto;
}

.tank-sos-article h1.digest-hub-title {
  font-size: clamp(1.35rem, 4vw, 1.65rem);
}

.tank-sos-confidence {
  font-size: 0.92rem;
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  margin: 1rem 0;
  color: #475569;
}

.tank-sos-warn-box {
  font-size: 0.92rem;
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  background: #fefce8;
  border: 1px solid #fde047;
  margin: 1rem 0;
  color: #713f12;
}

.tank-sos-related-inline {
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: #475569;
}

.tank-sos-related-inline a {
  color: #2563eb;
  font-weight: 600;
}

@media (min-width: 640px) {
  .tank-sos-card {
    padding: 1.35rem 1.35rem 1.5rem;
  }
}
