:root {
  --bg: #0e0906;
  --bg-soft: #17100a;
  --card: rgba(31, 20, 12, 0.84);
  --card-solid: #1a110b;
  --text: #f6efe6;
  --muted: #cdbba8;
  --line: rgba(220, 190, 146, 0.16);
  --primary: #b9853b;
  --primary-2: #e2c17c;
  --accent: #8fd0aa;
  --danger: #cf6b6b;
  --warning: #d9b45f;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Noto Serif TC", "Noto Sans TC", "Microsoft JhengHei", system-ui, sans-serif;
  color: var(--text);
  background:
    linear-gradient(rgba(14, 9, 6, 0.72), rgba(14, 9, 6, 0.9)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1800' height='1200' viewBox='0 0 1800 1200'%3E%3Cdefs%3E%3CradialGradient id='moon' cx='78%25' cy='18%25' r='16%25'%3E%3Cstop offset='0%25' stop-color='%23ecd2a2' stop-opacity='.95'/%3E%3Cstop offset='35%25' stop-color='%23e3c588' stop-opacity='.32'/%3E%3Cstop offset='100%25' stop-color='%23e3c588' stop-opacity='0'/%3E%3C/radialGradient%3E%3ClinearGradient id='sky' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0%25' stop-color='%23170f0b'/%3E%3Cstop offset='55%25' stop-color='%23110d0a'/%3E%3Cstop offset='100%25' stop-color='%230a0807'/%3E%3C/linearGradient%3E%3Cfilter id='blur'%3E%3CfeGaussianBlur stdDeviation='10'/%3E%3C/filter%3E%3C/defs%3E%3Crect width='1800' height='1200' fill='url(%23sky)'/%3E%3Crect width='1800' height='1200' fill='url(%23moon)'/%3E%3Cg opacity='.26'%3E%3Ccircle cx='1390' cy='200' r='76' fill='%23f1ddb7'/%3E%3Cpath d='M1320 168 q58 34 122 4 q-40 62-118 70 q31-34-4-74z' fill='%23170f0b' fill-opacity='.18'/%3E%3C/g%3E%3Cg opacity='.20'%3E%3Cpath d='M120 170 C360 130 430 190 670 140 C930 90 1050 165 1270 135' fill='none' stroke='%23d1aa66' stroke-width='3' stroke-linecap='round'/%3E%3Cpath d='M860 235 C1060 190 1240 242 1480 198' fill='none' stroke='%23d1aa66' stroke-width='2' stroke-linecap='round'/%3E%3Cpath d='M190 305 C390 260 520 320 710 280' fill='none' stroke='%238fd0aa' stroke-width='2' stroke-linecap='round'/%3E%3C/g%3E%3Cg opacity='.52' filter='url(%23blur)'%3E%3Cpath d='M0 850 Q230 640 450 760 T880 720 T1240 690 T1800 780 L1800 1200 L0 1200Z' fill='%23110f0e'/%3E%3Cpath d='M0 925 Q250 760 540 860 T1040 820 T1800 925 L1800 1200 L0 1200Z' fill='%23090706'/%3E%3C/g%3E%3Cg opacity='.34'%3E%3Cpath d='M152 758 C248 610 326 560 362 408 C402 570 468 620 556 784' fill='none' stroke='%232f2016' stroke-width='20' stroke-linecap='round'/%3E%3Cpath d='M1420 750 C1488 600 1560 552 1582 420 C1608 565 1656 618 1722 774' fill='none' stroke='%232f2016' stroke-width='18' stroke-linecap='round'/%3E%3Cpath d='M950 744 C1010 610 1088 556 1116 428 C1143 570 1196 622 1268 774' fill='none' stroke='%232f2016' stroke-width='15' stroke-linecap='round'/%3E%3C/g%3E%3Cg opacity='.22'%3E%3Cpath d='M1532 184 L1532 720' stroke='%23c89f5a' stroke-width='4'/%3E%3Cpath d='M1532 228 q-84 52 0 104 q82 50 0 104 q-76 52 0 104' fill='none' stroke='%23c89f5a' stroke-width='3'/%3E%3C/g%3E%3Cg opacity='.28'%3E%3Cpath d='M111 1080 L160 865 L205 1080' fill='none' stroke='%2388ba95' stroke-width='5' stroke-linecap='round'/%3E%3Cpath d='M160 930 L236 895' stroke='%2388ba95' stroke-width='3.5' stroke-linecap='round'/%3E%3Cpath d='M166 972 L246 945' stroke='%2388ba95' stroke-width='3.5' stroke-linecap='round'/%3E%3Cpath d='M1640 1100 L1678 890 L1714 1100' fill='none' stroke='%2388ba95' stroke-width='5' stroke-linecap='round'/%3E%3Cpath d='M1676 945 L1613 916' stroke='%2388ba95' stroke-width='3.5' stroke-linecap='round'/%3E%3Cpath d='M1670 988 L1596 966' stroke='%2388ba95' stroke-width='3.5' stroke-linecap='round'/%3E%3C/g%3E%3Cg opacity='.16'%3E%3Cpath d='M900 1040 q42-175 130-250 q82 68 106 250' fill='%23251914'/%3E%3Crect x='966' y='934' width='25' height='106' fill='%23180f0a'/%3E%3Cpath d='M890 790 q18-42 58-28 q28 12 26 42 q-4 34-42 46 q-40 12-42-20 q-1-18 0-40z' fill='%23b24e38' fill-opacity='.36'/%3E%3C/g%3E%3Cg opacity='.20'%3E%3Cpath d='M236 215 q20-20 40 0' stroke='%23e7cf9b' stroke-width='2' stroke-linecap='round'/%3E%3Cpath d='M270 202 q14-13 28 0' stroke='%23e7cf9b' stroke-width='2' stroke-linecap='round'/%3E%3Cpath d='M305 217 q15-14 30 0' stroke='%23e7cf9b' stroke-width='2' stroke-linecap='round'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  line-height: 1.65;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(226, 193, 124, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(226, 193, 124, 0.03) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.75), transparent 82%);
  z-index: -2;
}

body::after {
  content: "霓閣";
  position: fixed;
  right: clamp(12px, 7vw, 100px);
  top: 120px;
  color: rgba(226, 193, 124, 0.05);
  font-size: clamp(80px, 18vw, 240px);
  font-weight: 900;
  writing-mode: vertical-rl;
  letter-spacing: 0.08em;
  user-select: none;
  pointer-events: none;
  z-index: -1;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(16px);
  background: rgba(14, 9, 6, 0.65);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, #6b431d, var(--primary-2));
  box-shadow: 0 0 28px rgba(226, 193, 124, 0.18);
  color: #1b1109;
  font-size: 20px;
  font-weight: 900;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.nav-links a {
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--muted);
  transition: .2s ease;
}

.nav-links a:hover {
  color: var(--text);
  background: rgba(255,255,255,0.05);
}

.hero {
  padding: 82px 0 48px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 24px;
  align-items: center;
}

.hero-copy {
  max-width: 840px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  color: #f4e6c8;
  background: rgba(185, 133, 59, 0.14);
  border: 1px solid rgba(226, 193, 124, 0.28);
  border-radius: 999px;
  font-size: 14px;
}

.hero h1 {
  margin: 18px 0 14px;
  font-size: clamp(42px, 8vw, 76px);
  line-height: 1.02;
  letter-spacing: -1.8px;
}

.gradient-text {
  background: linear-gradient(100deg, #fff6de, #e2c17c 42%, #b9853b 78%, #8fd0aa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p {
  max-width: 760px;
  margin: 0 0 26px;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 26px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  font-weight: 700;
  transition: .2s ease;
}

.btn-primary {
  color: #1a110b;
  background: linear-gradient(135deg, var(--primary-2), var(--primary));
  box-shadow: 0 16px 40px rgba(185, 133, 59, 0.22);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 54px rgba(185, 133, 59, 0.28);
}

.btn-ghost {
  color: var(--text);
  border-color: var(--line);
  background: rgba(255,255,255,0.05);
}

.btn-ghost:hover {
  border-color: rgba(226,193,124,0.25);
  background: rgba(255,255,255,0.08);
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-badges span {
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
  color: #ecdcbc;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--line);
}

.card {
  border: 1px solid rgba(226, 193, 124, 0.14);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(34, 22, 14, 0.86), rgba(21, 14, 9, 0.82));
  box-shadow: var(--shadow);
}

.hero-scroll {
  padding: 24px;
  position: relative;
  overflow: hidden;
}

.hero-scroll::before {
  content: "";
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(226, 193, 124, .13);
  border-radius: 22px;
  pointer-events: none;
}

.scroll-head {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
}

.seal,
.feature-seal {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  color: #1b120a;
  background: linear-gradient(135deg, #e2c17c, #b9853b);
  font-size: 26px;
  font-weight: 900;
}

.scroll-head strong {
  display: block;
  font-size: 22px;
}

.scroll-head p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.scroll-lines {
  display: grid;
  gap: 10px;
}

.scroll-lines a {
  display: block;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255,255,255,.045);
  border: 1px solid var(--line);
  color: #ecdcbc;
  transition: .18s ease;
}

.scroll-lines a:hover {
  transform: translateX(4px);
  border-color: rgba(226,193,124,.35);
}

section {
  padding: 42px 0;
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 18px;
  margin-bottom: 22px;
}

.section-title h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -1px;
}

.section-title p {
  max-width: 560px;
  margin: 0;
  color: var(--muted);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.about-card,
.table-card {
  padding: 24px;
}

.about-card h3 {
  margin: 0 0 10px;
  font-size: 22px;
}

.about-card p {
  margin: 0;
  color: var(--muted);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.tag {
  padding: 8px 11px;
  border-radius: 999px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--line);
  color: #ecdcbc;
  font-size: 13px;
}

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

.tool-card {
  padding: 20px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(226, 193, 124, 0.15);
  background: linear-gradient(180deg, rgba(47,31,17,0.72), rgba(18,12,7,0.72));
  cursor: pointer;
  transition: .22s ease;
  min-height: 154px;
}

.tool-card:hover,
.tool-card.active {
  transform: translateY(-4px);
  border-color: rgba(226,193,124,0.35);
  box-shadow: 0 20px 55px rgba(185,133,59,0.12);
}

.tool-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(185,133,59,0.28), rgba(226,193,124,0.18));
  font-size: 24px;
}

.tool-card h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.tool-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.calculator-wrap {
  margin-top: 20px;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 18px;
  align-items: start;
}

.panel {
  padding: 22px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.04);
}

.panel h3 {
  margin: 0 0 14px;
  font-size: 22px;
}

.form-grid {
  display: grid;
  gap: 14px;
}

.field label {
  display: block;
  margin-bottom: 7px;
  color: #ecdcbc;
  font-size: 14px;
  font-weight: 700;
}

.field input,
.field select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  color: var(--text);
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 13px;
  outline: none;
  transition: .18s ease;
}

.field input:focus,
.field select:focus,
.search-input:focus {
  border-color: rgba(226,193,124,0.5);
  box-shadow: 0 0 0 4px rgba(185,133,59,0.08);
}

.result-box {
  padding: 22px;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(142, 199, 161, 0.2);
  background:
    linear-gradient(135deg, rgba(142,199,161,0.08), rgba(185,133,59,0.08)),
    rgba(0, 0, 0, 0.18);
  min-height: 100%;
}

.result-label {
  color: var(--muted);
  font-size: 14px;
}

.result-main {
  margin: 8px 0 10px;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -1px;
  word-break: break-word;
}

.result-sub,
.mini-note {
  white-space: pre-line;
}

.result-sub {
  color: #efe1c6;
}

.mini-note {
  margin-top: 14px;
  padding: 12px;
  border-radius: 14px;
  color: var(--muted);
  background: rgba(255,255,255,0.05);
  font-size: 14px;
}

.feature-card {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 24px;
}

.feature-card h3 {
  margin: 0 0 6px;
  font-size: 22px;
}

.feature-card p {
  margin: 0;
  color: var(--muted);
}

.guide-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 18px;
  align-items: start;
}

.search-card,
.detail-card {
  padding: 22px;
}

.search-input {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  color: var(--text);
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 13px;
  outline: none;
  transition: .18s ease;
  margin-bottom: 14px;
}

.skill-list {
  display: grid;
  gap: 10px;
  max-height: 520px;
  overflow: auto;
  padding-right: 4px;
}

.skill-item {
  width: 100%;
  text-align: left;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.04);
  color: var(--text);
  cursor: pointer;
  transition: .18s ease;
}

.skill-item:hover,
.skill-item.active {
  border-color: rgba(226,193,124,0.4);
  background: rgba(185,133,59,0.10);
}

.skill-item strong {
  display: block;
  font-size: 15px;
}

.skill-item span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.detail-card h3 {
  margin: 0 0 10px;
  font-size: 26px;
}

.muted {
  color: var(--muted);
}

.detail-meta {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.detail-block {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line);
}

.detail-block h4 {
  margin: 0 0 6px;
  font-size: 15px;
  color: #f0dbb2;
}

.detail-block p {
  margin: 0;
  color: var(--muted);
  white-space: pre-line;
}

.guide-source,
.notice {
  margin-top: 18px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

.guide-source a {
  color: #e2c17c;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.table-wrap {
  overflow-x: auto;
  border-radius: 18px;
  border: 1px solid var(--line);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(226, 193, 124, 0.12);
  text-align: left;
}

th {
  color: #f2ddb6;
  background: rgba(185, 133, 59, 0.15);
}

td {
  color: var(--muted);
}

tr:last-child td {
  border-bottom: 0;
}

.small-table {
  margin-top: 18px;
}

.accordion {
  overflow: hidden;
}

.accordion-toggle {
  width: 100%;
  min-height: 68px;
  padding: 20px 24px;
  border: 0;
  color: var(--text);
  background: transparent;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 800;
  text-align: left;
}

.accordion-toggle b {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #1a110b;
  background: linear-gradient(135deg, var(--primary-2), var(--primary));
  font-size: 20px;
}

.accordion-panel {
  border-top: 1px solid var(--line);
  padding: 22px;
}

.chef-groups {
  display: grid;
  gap: 16px;
}

.chef-group {
  padding: 18px;
  border-radius: 18px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line);
}

.chef-group h3 {
  margin: 0 0 10px;
  font-size: 20px;
  color: #f0dbb2;
}

.chef-list {
  display: grid;
  gap: 10px;
}

.chef-item {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(0,0,0,0.16);
  border: 1px solid rgba(255,255,255,0.06);
}

.chef-item strong {
  color: #f6efe6;
}

.chef-item span {
  color: var(--muted);
}

.site-footer {
  padding: 28px 0 40px;
  text-align: center;
  color: var(--muted);
  border-top: 1px solid var(--line);
  margin-top: 16px;
}

.back-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--text);
  background: rgba(28, 18, 10, 0.86);
  backdrop-filter: blur(12px);
  cursor: pointer;
  opacity: 0;
  transform: translateY(14px);
  transition: .2s ease;
}

.back-top.show {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1100px) {
  .tools-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-grid,
  .grid-2,
  .calculator-wrap,
  .guide-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 960px) {
  .feature-card {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .section-title {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(100% - 28px, 1180px);
  }

  .nav {
    flex-direction: column;
    align-items: start;
  }

  .nav-links {
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero {
    padding-top: 54px;
  }

  .tools-grid {
    grid-template-columns: 1fr;
  }

  body::after {
    display: none;
  }

  table {
    min-width: 720px;
  }
}
