:root {
  color-scheme: light;
  --ink: #15201d;
  --muted: #66736f;
  --line: #dce4df;
  --panel: #ffffff;
  --soft: #f4f7f1;
  --mint: #4b8f78;
  --teal: #176b72;
  --rose: #c96567;
  --gold: #b98727;
  --blue: #4b6f9e;
  --shadow: 0 18px 48px rgba(25, 43, 38, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #eef3ee;
  color: var(--ink);
  font-family: "Microsoft JhengHei", "Noto Sans TC", Arial, sans-serif;
}

.home-shell {
  width: min(1120px, calc(100% - 36px));
  margin: 0 auto;
  min-height: 100vh;
  padding: 42px 0;
  display: grid;
  align-content: center;
  gap: 26px;
}

.home-hero {
  display: grid;
  gap: 32px;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.home-hero h1 {
  font-size: 36px;
}

.home-hero p {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.7;
}

.home-services .service-card {
  min-height: 280px;
}

button,
input,
select {
  font: inherit;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 24px 18px;
  background: #f9fbf8;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  color: #fff;
  background: var(--teal);
  font-weight: 800;
}

.face-mark {
  background: var(--rose);
}

.beauty-mark {
  background: var(--gold);
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  margin-top: 3px;
  color: var(--muted);
}

.nav-list {
  display: grid;
  gap: 6px;
}

.nav-list a {
  padding: 11px 12px;
  border-radius: 8px;
  color: var(--muted);
  text-decoration: none;
}

.nav-list a:hover,
.nav-list a.active {
  color: var(--teal);
  background: #e7f0ec;
}

.client-panel {
  display: grid;
  gap: 14px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.client-panel label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
}

.client-panel input,
.client-panel select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fff;
  color: var(--ink);
}

.local-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.local-actions button {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fff;
  color: var(--teal);
  cursor: pointer;
  font-weight: 700;
}

.local-actions button:first-child {
  border-color: var(--teal);
  color: #fff;
  background: var(--teal);
}

.save-status {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.workspace {
  min-width: 0;
  padding: 28px;
  display: grid;
  gap: 24px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

h1 {
  font-size: 30px;
  line-height: 1.25;
}

.topbar p,
.section-heading p,
.upload-panel p {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.primary-button {
  border: 0;
  border-radius: 8px;
  padding: 12px 18px;
  color: #fff;
  background: var(--teal);
  cursor: pointer;
  white-space: nowrap;
}

.face-button {
  background: var(--rose);
}

.beauty-button {
  background: var(--gold);
}

.service-grid,
.section-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.service-card {
  min-height: 210px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  display: grid;
  align-content: space-between;
  gap: 16px;
}

.service-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.service-card h2 {
  font-size: 26px;
}

.service-card p {
  color: var(--muted);
  line-height: 1.65;
}

.service-card a {
  color: var(--teal);
  font-weight: 800;
  text-decoration: none;
}

.scalp-service {
  border-top: 5px solid var(--teal);
}

.face-service {
  border-top: 5px solid var(--rose);
}

.beauty-service {
  border-top: 5px solid var(--gold);
}

.home-services {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.single-report {
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
}

.upload-panel,
.chart-panel,
.recommend-grid article,
.notice {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.upload-panel {
  padding: 18px;
  display: grid;
  gap: 16px;
  align-content: start;
}

.report-profile {
  padding: 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.summary-list {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px 18px;
  margin-top: 18px;
  align-items: center;
}

.summary-list span {
  color: var(--muted);
}

.summary-list strong {
  font-size: 24px;
}

.analysis-status {
  margin: 18px 0 0;
  padding: 12px;
  border-radius: 8px;
  color: var(--muted);
  background: var(--soft);
  line-height: 1.5;
}

.upload-box {
  position: relative;
  display: grid;
  place-items: center;
  width: min(100%, 280px);
  min-height: 0;
  aspect-ratio: 9 / 16;
  justify-self: center;
  border: 1px dashed #aab8b3;
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(75, 143, 120, 0.08), rgba(201, 101, 103, 0.08)),
    #fbfcfb;
  overflow: hidden;
  cursor: pointer;
}

.beauty-upload {
  background:
    linear-gradient(135deg, rgba(185, 135, 39, 0.10), rgba(75, 111, 158, 0.08)),
    #fbfcfb;
}

.upload-box input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.upload-box span {
  position: relative;
  z-index: 1;
  color: var(--teal);
  font-weight: 700;
}

.upload-box img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #0f1512;
  display: none;
}

.upload-box.has-image span {
  align-self: end;
  margin-bottom: 14px;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
}

.scalp-zone-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 12px;
  align-items: start;
}

.zone-upload {
  width: 100%;
  max-width: 180px;
}

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

.summary-strip article,
.metric-card,
.timeline article {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

.summary-strip span,
.summary-strip small {
  color: var(--muted);
}

.summary-strip strong {
  display: block;
  margin: 8px 0 4px;
  font-size: 24px;
  line-height: 1.25;
}

.analysis-layout,
.trend-section,
.recommend-section,
.care-section {
  display: grid;
  gap: 16px;
}

.care-result {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.care-result span {
  color: var(--muted);
  font-size: 13px;
}

.care-result strong {
  display: block;
  margin-top: 6px;
  font-size: 26px;
}

.care-result p {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.care-result button {
  border: 0;
  border-radius: 8px;
  padding: 11px 14px;
  color: #fff;
  background: var(--teal);
  cursor: pointer;
  white-space: nowrap;
}

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

.care-card {
  position: relative;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.care-card.recommended {
  border-color: var(--gold);
  outline: 3px solid rgba(185, 135, 39, 0.22);
}

.care-card.recommended::after {
  content: "建議";
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #fff;
  background: var(--gold);
  font-size: 12px;
  font-weight: 800;
}

.care-card span,
.care-card small {
  color: var(--muted);
}

.care-card h3 {
  margin-top: 10px;
  font-size: 34px;
}

.care-card p {
  margin-top: 10px;
  color: var(--ink);
  line-height: 1.55;
}

.care-card small {
  display: block;
  margin-top: 12px;
  line-height: 1.45;
}

.care-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  padding: 14px;
  border-radius: 8px;
  background: #111714;
  color: #fff;
}

.care-steps article {
  padding: 12px;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
}

.care-steps article:first-child {
  border-left: 0;
}

.care-steps strong {
  display: block;
  color: #f1bd66;
}

.care-steps span {
  display: block;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.5;
  font-size: 13px;
}

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

.metric-grid.compact {
  grid-template-columns: 1fr;
}

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

.mini-summary article {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.mini-summary span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.mini-summary strong {
  display: block;
  margin-top: 6px;
  color: var(--teal);
  font-size: 30px;
}

.metric-card {
  display: grid;
  gap: 12px;
  min-height: 152px;
}

.metric-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.metric-top strong {
  font-size: 16px;
}

.metric-value {
  color: var(--teal);
  font-size: 24px;
  font-weight: 800;
}

.bar {
  height: 8px;
  border-radius: 999px;
  background: #e6ece8;
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--mint);
}

.metric-note {
  color: var(--muted);
  line-height: 1.45;
  font-size: 14px;
}

.metric-detail {
  display: grid;
  gap: 7px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  line-height: 1.5;
  font-size: 13px;
}

.metric-detail strong {
  color: var(--ink);
}

.color-analysis {
  margin-top: 0;
}

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

.color-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.color-card div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.color-card strong {
  color: var(--ink);
}

.color-card span {
  font-size: 24px;
  font-weight: 900;
}

.color-bar {
  height: 8px;
  margin-top: 12px;
  border-radius: 999px;
  background: #e6ece8;
  overflow: hidden;
}

.color-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
}

.color-card p {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.55;
  font-size: 14px;
}

.chart-panel {
  padding: 16px;
}

canvas {
  display: block;
  width: 100%;
  height: auto;
}

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

.timeline span {
  color: var(--muted);
  font-size: 13px;
}

.timeline strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
}

.timeline p {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.5;
}

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

.recommend-grid article {
  padding: 18px;
}

.recommend-grid ul {
  margin: 12px 0 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.7;
}

.notice {
  padding: 16px;
  color: #705015;
  background: #fff8e8;
  border-color: #ead59f;
  box-shadow: none;
}

@media (max-width: 980px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .nav-list {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .nav-list a {
    text-align: center;
  }

  .summary-strip,
  .service-grid,
  .home-services,
  .metric-grid,
  .color-grid,
  .recommend-grid,
  .care-grid,
  .care-steps,
  .timeline {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .care-result {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 680px) {
  .workspace {
    padding: 18px;
  }

  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  h1 {
    font-size: 24px;
  }

  .section-grid,
  .service-grid,
  .home-services,
  .single-report,
  .summary-strip,
  .metric-grid,
  .color-grid,
  .recommend-grid,
  .care-grid,
  .care-steps,
  .timeline,
  .nav-list {
    grid-template-columns: 1fr;
  }

  .upload-box {
    width: min(100%, 260px);
  }

  .scalp-zone-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media print {
  body {
    background: #fff;
  }

  .sidebar,
  .primary-button {
    display: none;
  }

  .app-shell {
    display: block;
  }

  .workspace {
    padding: 0;
  }

  .upload-panel,
  .chart-panel,
  .recommend-grid article,
  .summary-strip article,
  .metric-card,
  .timeline article,
  .notice {
    box-shadow: none;
    break-inside: avoid;
  }
}

body.ai-face-page {
  background: #080d16;
  color: #e9f7ff;
}

.ai-dashboard {
  min-height: 100vh;
  background:
    radial-gradient(circle at 18% 0%, rgba(0, 219, 255, 0.16), transparent 34%),
    linear-gradient(135deg, #080d16 0%, #101522 46%, #090b12 100%);
  padding: 24px;
  display: grid;
  gap: 18px;
}

.ai-hero,
.ai-client-bar,
.ai-panel,
.ai-services article,
.ai-notice {
  border: 1px solid rgba(112, 151, 183, 0.26);
  background: rgba(13, 19, 32, 0.88);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.34);
}

.ai-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 20px 24px;
}

.ai-title {
  display: flex;
  align-items: center;
  gap: 18px;
}

.ai-title p {
  color: #31d7ff;
  font-weight: 800;
}

.ai-title h1 {
  color: #36f3ff;
  font-size: 34px;
}

.ai-title small {
  display: block;
  margin-top: 8px;
  color: rgba(233, 247, 255, 0.68);
  font-size: 18px;
}

.ai-lightbar {
  width: 30px;
  height: 72px;
  border-radius: 999px;
  background: linear-gradient(180deg, #3a7dff, #21f3d0);
  box-shadow: 0 0 24px rgba(33, 243, 208, 0.55);
}

.ai-target {
  min-width: 360px;
  padding: 14px 20px;
  border: 1px solid rgba(127, 162, 201, 0.24);
  border-radius: 999px;
  background: rgba(21, 29, 46, 0.92);
  color: rgba(233, 247, 255, 0.86);
}

.ai-target span {
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-right: 10px;
  border-radius: 999px;
  background: #18b985;
}

.ai-target em {
  font-style: normal;
  color: #d7e7ff;
}

.ai-client-bar {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr)) auto auto minmax(180px, 1fr) auto;
  gap: 10px;
  padding: 14px;
}

.ai-client-bar label {
  display: grid;
  gap: 5px;
  color: rgba(233, 247, 255, 0.64);
  font-size: 12px;
}

.ai-client-bar input,
.ai-client-bar select,
.ai-client-bar button {
  min-height: 38px;
  border: 1px solid rgba(112, 151, 183, 0.24);
  border-radius: 8px;
  padding: 8px 10px;
  background: rgba(8, 13, 22, 0.92);
  color: #e9f7ff;
}

.ai-client-bar button {
  align-self: end;
  color: #061018;
  background: #36f3ff;
  cursor: pointer;
  font-weight: 800;
}

.ai-client-bar p {
  grid-column: 1 / -1;
  color: rgba(233, 247, 255, 0.54);
  font-size: 12px;
}

.ai-board {
  display: grid;
  grid-template-columns: minmax(360px, 0.86fr) minmax(420px, 1.14fr);
  gap: 28px;
}

.ai-panel {
  padding: 18px 24px;
}

.ai-panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(112, 151, 183, 0.2);
}

.ai-panel-title h2 {
  color: #e9f7ff;
  font-size: 20px;
}

.ai-panel-title div {
  display: flex;
  gap: 8px;
}

.ai-panel-title span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
}

.ai-panel-title span:nth-child(1) { background: #18c9ff; }
.ai-panel-title span:nth-child(2) { background: #8f5bff; }
.ai-panel-title span:nth-child(3) { background: #19c88d; }

.vision-frame {
  position: relative;
  display: block;
  width: min(100%, 520px);
  aspect-ratio: 3 / 4;
  margin: 26px auto 0;
  border: 1px solid rgba(54, 243, 255, 0.28);
  border-radius: 12px;
  overflow: hidden;
  background:
    linear-gradient(rgba(54, 243, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(54, 243, 255, 0.08) 1px, transparent 1px),
    #0d1320;
  background-size: 34px 34px;
  cursor: pointer;
}

.vision-frame input {
  position: absolute;
  inset: 0;
  opacity: 0;
  z-index: 5;
  cursor: pointer;
}

.vision-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: none;
}

.vision-frame canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.vision-frame::before,
.vision-frame::after {
  content: "";
  position: absolute;
  inset: 10% 18%;
  border: 1px dashed rgba(54, 243, 255, 0.58);
  border-radius: 50% 50% 46% 46%;
  pointer-events: none;
}

.vision-frame::after {
  inset: 8% 50% 6%;
  border-width: 0 1px 0 0;
  border-radius: 0;
}

.upload-call {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 4;
  padding: 10px 14px;
  border-radius: 8px;
  color: #061018;
  background: rgba(54, 243, 255, 0.9);
  font-weight: 900;
}

.scan-line {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent, rgba(54, 243, 255, 0.28), transparent);
  height: 30%;
  animation: scanMove 3.4s linear infinite;
  pointer-events: none;
}

@keyframes scanMove {
  from { transform: translateY(-100%); }
  to { transform: translateY(360%); }
}

.landmark {
  position: absolute;
  width: 13px;
  height: 13px;
  border-radius: 999px;
  background: rgba(255, 92, 153, 0.9);
  box-shadow: 0 0 14px rgba(255, 92, 153, 0.8);
}

.lm-1 { left: 41%; top: 27%; }
.lm-2 { right: 41%; top: 27%; }
.lm-3 { left: 50%; top: 42%; background: #36f3ff; }
.lm-4 { left: 38%; top: 47%; }
.lm-5 { right: 38%; top: 47%; }
.lm-6 { left: 50%; top: 58%; background: #19c88d; }
.lm-7 { left: 45%; top: 66%; }
.lm-8 { right: 45%; top: 66%; }

.hud {
  position: absolute;
  z-index: 3;
  padding: 6px 8px;
  color: #36f3ff;
  background: rgba(8, 13, 22, 0.72);
  font-family: Consolas, monospace;
}

.hud-top { top: 18px; left: 18px; }
.hud-bottom { bottom: 18px; left: 18px; }

.ai-extra-upload {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  color: rgba(233, 247, 255, 0.72);
}

.ai-extra-upload input {
  color: rgba(233, 247, 255, 0.78);
}

.ai-extra-upload img {
  display: none;
  width: 120px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border: 1px solid rgba(54, 243, 255, 0.28);
  border-radius: 8px;
}

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

.ai-score-row div {
  padding: 14px;
  border: 1px solid rgba(112, 151, 183, 0.22);
  border-radius: 8px;
  background: rgba(8, 13, 22, 0.6);
}

.ai-score-row span {
  color: rgba(233, 247, 255, 0.58);
}

.ai-score-row strong {
  display: block;
  margin-top: 8px;
  color: #36f3ff;
  font-size: 28px;
}

.ai-status,
.ai-explain-grid section,
.ai-warning,
.ai-advice {
  margin-top: 18px;
  padding: 18px;
  border-radius: 12px;
  line-height: 1.7;
}

.ai-status {
  color: rgba(233, 247, 255, 0.72);
  background: rgba(54, 243, 255, 0.08);
}

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

.ai-explain-grid section {
  border: 1px solid rgba(54, 243, 255, 0.16);
  background: rgba(8, 13, 22, 0.58);
}

.ai-explain-grid h3,
.ai-warning h3,
.ai-advice h3 {
  color: #e9f7ff;
  margin-bottom: 10px;
}

.ai-explain-grid p,
.ai-warning p,
.ai-advice p {
  color: rgba(233, 247, 255, 0.8);
}

.ai-warning {
  border: 1px solid rgba(255, 78, 116, 0.35);
  background: rgba(88, 0, 32, 0.38);
}

.ai-warning h3 {
  color: #ff6e92;
}

.ai-advice {
  border: 1px solid rgba(255, 196, 66, 0.34);
  background: rgba(75, 35, 5, 0.36);
}

.ai-advice h3,
.ai-advice strong {
  color: #ffd35a;
}

.ai-advice strong {
  display: block;
  margin-top: 12px;
  font-size: 24px;
}

.ai-advice button {
  margin-top: 14px;
  border: 0;
  border-radius: 8px;
  padding: 10px 14px;
  color: #061018;
  background: #ffd35a;
  cursor: pointer;
  font-weight: 900;
}

.ai-metrics .metric-card {
  color: #e9f7ff;
  border-color: rgba(112, 151, 183, 0.22);
  background: rgba(8, 13, 22, 0.72);
}

.ai-metrics .metric-note,
.ai-metrics .metric-detail {
  color: rgba(233, 247, 255, 0.72);
}

.ai-metrics .metric-detail strong,
.ai-metrics .metric-top strong {
  color: #e9f7ff;
}

.ai-color-grid .color-card {
  border-color: rgba(112, 151, 183, 0.22);
  background: rgba(8, 13, 22, 0.72);
  box-shadow: none;
}

.ai-color-grid .color-card strong {
  color: #e9f7ff;
}

.ai-color-grid .color-card span {
  color: #36f3ff;
}

.ai-color-grid .color-card p {
  color: rgba(233, 247, 255, 0.72);
}

.ai-color-grid .color-bar {
  background: rgba(233, 247, 255, 0.12);
}

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

.facial-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.facial-detail-grid article {
  padding: 18px;
  border: 1px solid rgba(112, 151, 183, 0.22);
  border-radius: 12px;
  background: rgba(8, 13, 22, 0.72);
}

.facial-detail-grid span {
  color: rgba(233, 247, 255, 0.58);
}

.facial-detail-grid strong {
  display: block;
  margin-top: 8px;
  color: #36f3ff;
  font-size: 22px;
}

.facial-detail-grid p {
  margin-top: 10px;
  color: rgba(233, 247, 255, 0.74);
  line-height: 1.6;
}

.light-detail-grid article {
  border-color: var(--line);
  background: #fff;
  box-shadow: var(--shadow);
}

.light-detail-grid span {
  color: var(--muted);
}

.light-detail-grid strong {
  color: var(--gold);
}

.light-detail-grid p {
  color: var(--muted);
}

.makeup-upload canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.ai-services article {
  padding: 18px;
}

.ai-services span {
  color: #36f3ff;
  font-weight: 800;
}

.ai-services strong {
  display: block;
  margin-top: 10px;
  color: #ffd35a;
  font-size: 22px;
}

.ai-services p {
  margin-top: 10px;
  color: rgba(233, 247, 255, 0.74);
  line-height: 1.65;
}

.ai-notice {
  padding: 16px;
  color: rgba(233, 247, 255, 0.72);
}

@media (max-width: 1080px) {
  .ai-hero,
  .ai-board {
    grid-template-columns: 1fr;
  }

  .ai-board,
  .ai-hero {
    display: grid;
  }

  .ai-client-bar,
  .facial-detail-grid,
  .ai-services {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ai-target {
    min-width: 0;
  }
}

@media (max-width: 700px) {
  .ai-dashboard {
    padding: 14px;
  }

  .ai-title h1 {
    font-size: 24px;
  }

  .ai-client-bar,
  .ai-score-row,
  .ai-explain-grid,
  .facial-detail-grid,
  .ai-services {
    grid-template-columns: 1fr;
  }
}
