* {
  box-sizing: border-box;
}

:root {
  --bg: #f6f1eb;
  --panel: rgba(255, 252, 248, 0.92);
  --panel-strong: #fffaf5;
  --line: rgba(75, 48, 29, 0.12);
  --text: #24160f;
  --muted: #756458;
  --accent: #8f5f47;
  --accent-soft: rgba(143, 95, 71, 0.1);
  --shadow: 0 20px 50px rgba(61, 36, 20, 0.08);
}

body {
  margin: 0;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top, rgba(255, 244, 232, 0.95), rgba(246, 241, 235, 0.92) 32%),
    linear-gradient(180deg, #f7f0e8 0%, #f3ede6 100%);
  color: var(--text);
}

img {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
p {
  margin: 0;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.app-shell {
  width: min(100%, 430px);
  margin: 0 auto;
  padding: 18px 14px 36px;
  display: grid;
  gap: 14px;
}

.hero-card,
.viewer-card,
.section-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-card {
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 248, 241, 0.92)),
    var(--panel);
}

.hero-card__top,
.section-head,
.item-card__top,
.spec-row,
.source-card {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.eyebrow,
.section-kicker,
.item-card__eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent);
  font-weight: 800;
}

.hero-card__status,
.signal-row span,
.confidence,
.section-hint,
.hero-card__meta span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.hero-card__status {
  padding: 8px 10px;
  color: var(--accent);
  background: var(--accent-soft);
}

.hero-card h1 {
  margin-top: 14px;
  font-size: 31px;
  line-height: 1.04;
  font-family: "Times New Roman", Georgia, serif;
}

.hero-card__desc {
  margin-top: 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.hero-card__meta,
.signal-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-card__meta {
  margin-top: 16px;
}

.hero-card__meta span,
.signal-row span {
  padding: 8px 11px;
  background: rgba(36, 22, 15, 0.05);
  color: #5b483d;
}

.viewer-card {
  padding: 10px;
}

.viewer-stage {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  aspect-ratio: 4 / 5.25;
  background: #eadfd4;
}

.viewer-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 34% center;
}

.hotspots {
  position: absolute;
  inset: 0;
}

.hotspot {
  position: absolute;
  transform: translate(-50%, -50%);
  border: 0;
  border-radius: 999px;
  padding: 9px 12px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(36, 22, 15, 0.15);
  cursor: pointer;
}

.hotspot.is-active {
  background: var(--accent);
  color: #fff;
}

.thumb-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.thumb {
  border: 0;
  padding: 0;
  background: transparent;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 1;
  cursor: pointer;
  opacity: 0.68;
}

.thumb.is-active {
  opacity: 1;
  outline: 2px solid rgba(143, 95, 71, 0.85);
  outline-offset: 1px;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.section-card {
  padding: 18px;
}

.summary-card {
  display: grid;
  gap: 12px;
}

.summary-card__text {
  color: var(--muted);
  line-height: 1.65;
  font-size: 15px;
}

.section-head {
  margin-bottom: 14px;
}

.section-head h2,
.summary-card h2 {
  margin-top: 4px;
  font-size: 26px;
  line-height: 1.08;
  font-family: "Times New Roman", Georgia, serif;
}

.section-hint {
  padding: 8px 10px;
  color: var(--muted);
  background: rgba(36, 22, 15, 0.05);
}

.item-list,
.analysis-list,
.source-list {
  display: grid;
  gap: 12px;
}

.item-card,
.analysis-point,
.source-card {
  border-radius: 22px;
  border: 1px solid var(--line);
  background: var(--panel-strong);
  padding: 16px;
}

.item-card {
  cursor: pointer;
}

.item-card.is-active {
  border-color: rgba(143, 95, 71, 0.45);
  box-shadow: 0 14px 34px rgba(143, 95, 71, 0.1);
}

.item-card h3,
.source-card h3 {
  margin-top: 6px;
  font-size: 20px;
  line-height: 1.2;
  font-family: "Times New Roman", Georgia, serif;
}

.confidence {
  padding: 7px 10px;
  white-space: nowrap;
}

.confidence--high {
  background: rgba(33, 126, 79, 0.12);
  color: #1d724b;
}

.confidence--mid {
  background: rgba(185, 114, 15, 0.14);
  color: #9a5e0b;
}

.confidence--low {
  background: rgba(120, 89, 65, 0.12);
  color: #785941;
}

.spec-row {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(75, 48, 29, 0.08);
  font-size: 14px;
}

.spec-row span {
  color: var(--muted);
}

.spec-row strong {
  font-weight: 700;
  color: var(--text);
}

.item-card__note,
.analysis-point p,
.source-card p {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}

.item-card__link,
.source-card a {
  display: inline-flex;
  margin-top: 14px;
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

.item-card__link:hover,
.source-card a:hover {
  text-decoration: underline;
}

@media (max-width: 380px) {
  .app-shell {
    padding-inline: 10px;
  }

  .hero-card h1 {
    font-size: 28px;
  }

  .section-head h2,
  .summary-card h2 {
    font-size: 24px;
  }

  .hotspot {
    padding: 8px 10px;
    font-size: 11px;
  }
}
