:root {
  color-scheme: dark;
  --bg: #10131a;
  --panel: #171b24;
  --panel-soft: #202634;
  --line: #343b4d;
  --text: #f5f7fb;
  --muted: #aab3c2;
  --accent: #8ee6c8;
  --warning: #ffd166;
  --danger: #ff6b6b;
  --blue: #8fb8ff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter,
    "Pretendard",
    "Noto Sans KR",
    system-ui,
    sans-serif;
}

button,
textarea,
input {
  font: inherit;
}

button {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--text);
  min-height: 44px;
  padding: 0 16px;
  cursor: pointer;
}

button:hover {
  border-color: var(--accent);
}

[hidden] {
  display: none !important;
}

.app-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0;
}

.hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.eyebrow,
.result-kicker {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 10px;
  font-size: clamp(2rem, 5vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: 0;
}

.lead {
  max-width: 680px;
  color: var(--muted);
  line-height: 1.7;
}

.privacy-pill {
  border: 1px solid rgba(142, 230, 200, 0.4);
  border-radius: 999px;
  padding: 10px 14px;
  color: var(--accent);
  white-space: nowrap;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 18px;
}

.input-panel,
.result-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 18px;
}

.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 18px;
}

.tabs button.active {
  background: var(--accent);
  color: #07100d;
  border-color: var(--accent);
  font-weight: 900;
}

label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-weight: 800;
}

textarea,
input[type="file"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0d1016;
  color: var(--text);
  padding: 14px;
}

textarea {
  min-height: 280px;
  resize: vertical;
  line-height: 1.65;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.primary-button {
  background: var(--accent);
  color: #07100d;
  border-color: var(--accent);
  font-weight: 900;
}

.notice,
.disclaimer {
  margin-top: 14px;
  color: var(--muted);
  line-height: 1.55;
}

.image-preview {
  display: grid;
  place-items: center;
  min-height: 260px;
  margin-top: 12px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  overflow: hidden;
  background: #0d1016;
}

.image-preview img {
  max-width: 100%;
  max-height: 340px;
  display: block;
}

.score-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 16px;
  align-items: center;
}

.score-ring {
  display: grid;
  place-items: center;
  width: 106px;
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, var(--panel) 58%, transparent 59%),
    conic-gradient(var(--warning) calc(var(--score-value, 0) * 1%), #303747 0);
  font-size: 1.8rem;
  font-weight: 900;
}

.result-card h2 {
  margin-bottom: 8px;
}

.result-card p,
.result-card li {
  color: var(--muted);
  line-height: 1.6;
}

.result-section {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.result-section h3 {
  margin-bottom: 10px;
  font-size: 1rem;
}

ul {
  padding-left: 20px;
}

@media (max-width: 860px) {
  .app-shell {
    width: min(100% - 20px, 680px);
    padding: 20px 0;
  }

  .hero,
  .workspace {
    display: block;
  }

  .privacy-pill {
    display: inline-block;
    margin-top: 12px;
  }

  .result-card {
    margin-top: 14px;
  }

  .score-row {
    grid-template-columns: 86px 1fr;
  }

  .score-ring {
    width: 84px;
    font-size: 1.4rem;
  }
}
