/* 出通告小助手：薄荷綠主題
   版面結構參考「奕鈞老師工作坊」（玻璃卡片＋Noto Sans TC＋900 字重大標題），
   配色改為淺色薄荷綠。 */

:root {
  /* 薄荷綠淺色調：白底透薄荷，同深色版一樣有由深到淺嘅層次，但整體清新。 */
  --page-bg: linear-gradient(160deg, #f2fbf6 0%, #ddf6ec 38%, #c7f0e4 72%, #b9ecec 100%);
  --glass-bg: rgba(255, 255, 255, .72);
  --glass-border: rgba(16, 132, 106, .16);
  --glass-hover: rgba(255, 255, 255, .92);
  --field-bg: #ffffff;
  --text: #0d3b2e;
  --text-soft: #2f6d5b;
  --text-muted: #4a7a69;
  --accent: #0f9d76;
  --accent-deep: #0b7a5c;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --transition: all .25s cubic-bezier(.4, 0, .2, 1);
}

* { box-sizing: border-box; }

html { color-scheme: light; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--page-bg) fixed;
  color: var(--text);
  font-family: "Noto Sans TC", Inter, -apple-system, "PingFang TC",
               "Microsoft JhengHei", sans-serif;
  font-size: 17px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

/* ── 頂部列 ───────────────────────────────────────────── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .8rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--glass-border);
}

.topbar .mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(140deg, #6ee7c0, #7dd3d8);
  font-size: 1.05rem;
  flex: none;
}

.topbar .name { font-weight: 700; letter-spacing: -.01em; }
.topbar .spacer { flex: 1; }

.topbar a {
  color: var(--text-soft);
  text-decoration: none;
  font-size: .92rem;
  transition: var(--transition);
}

.topbar a:hover { color: var(--accent-deep); }

/* ── 版心 ─────────────────────────────────────────────── */
.wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: clamp(1.6rem, 5vw, 3rem) clamp(1rem, 4vw, 2rem) 4rem;
}

.wrap.narrow { max-width: 460px; }

/* ── Hero ─────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .35rem .95rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .8);
  border: 1px solid var(--glass-border);
  font-size: .85rem;
  color: var(--text-soft);
}

.badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px rgba(15, 157, 118, .55);
}

h1 {
  font-size: clamp(2rem, 6vw, 2.9rem);
  font-weight: 900;
  letter-spacing: -.02em;
  line-height: 1.2;
  margin: 1rem 0 .4rem;
}

h1 .accent {
  background: linear-gradient(100deg, var(--accent), #0e9488);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  color: var(--text-soft);
  font-size: 1.02rem;
  margin: 0 0 1.8rem;
  max-width: 46rem;
}

/* ── 卡片 ─────────────────────────────────────────────── */
.card {
  background: var(--glass-bg);
  backdrop-filter: blur(8px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 6px 20px rgba(11, 90, 70, .07);
  padding: 1.4rem clamp(1rem, 3vw, 1.6rem);
  margin-bottom: 1.2rem;
}

.card > .eyebrow {
  display: block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin-bottom: .1rem;
}

.card > h2 {
  font-size: 1.12rem;
  font-weight: 700;
  margin: 0 0 .3rem;
  letter-spacing: -.01em;
}

/* ── 提示條 ───────────────────────────────────────────── */
.notice-box {
  border-radius: var(--radius-md);
  padding: .85rem 1.1rem;
  font-size: .93rem;
  margin-bottom: 1.2rem;
  border: 1px solid;
}

.notice-box.warn {
  background: #fff8e6;
  border-color: #f2d492;
  color: #8a5a08;
}

.notice-box.warn b { color: #6b4405; }

.notice-box.error {
  background: #fdecef;
  border-color: #f0adb9;
  color: #a11d38;
  font-weight: 600;
}

.notice-box.info {
  background: #e7f8f3;
  border-color: #9fdcc9;
  color: #0b6b52;
}

/* ── 表單 ─────────────────────────────────────────────── */
label {
  display: block;
  margin-top: .9rem;
  font-size: .93rem;
  font-weight: 500;
  color: var(--text-soft);
}

input, textarea, select {
  width: 100%;
  margin-top: .3rem;
  padding: .6rem .75rem;
  font-size: 1rem;
  font-family: inherit;
  color: var(--text);
  background: var(--field-bg);
  border: 1px solid #c5ddd4;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

input::placeholder, textarea::placeholder { color: var(--text-muted); }

input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(15, 157, 118, .18);
}

textarea { min-height: 6.5rem; resize: vertical; line-height: 1.6; }

select option { background: #ffffff; color: var(--text); }

.row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: .45rem;
  margin-top: .3rem;
}

@media (max-width: 640px) {
  .row { grid-template-columns: 1fr 1fr; }
}

.session-row {
  margin-top: 1rem;
  padding-top: .9rem;
  border-top: 1px dashed rgba(16, 132, 106, .18);
}

.session-row:first-of-type { border-top: 0; padding-top: 0; }
.session-row.hidden { display: none; }

.session-no {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .06em;
  color: var(--accent-deep);
}

.en-only { display: none; }
body.bilingual .en-only { display: block; }

.hint {
  font-size: .85rem;
  color: var(--text-muted);
  margin: .45rem 0 0;
  line-height: 1.6;
}

/* ── 按鈕 ─────────────────────────────────────────────── */
button, .btn {
  display: inline-block;
  font-family: inherit;
  font-size: 1.02rem;
  font-weight: 700;
  color: #ffffff;
  background: linear-gradient(120deg, var(--accent-deep), #0b7d75);
  box-shadow: 0 4px 14px rgba(11, 122, 92, .3);
  border: 0;
  border-radius: var(--radius-md);
  padding: .8rem 2rem;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

button:hover, .btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

button:disabled {
  background: #cfe3dc;
  color: #7d9c92;
  box-shadow: none;
  cursor: wait;
  transform: none;
  filter: none;
}

button.ghost {
  background: #ffffff;
  color: var(--accent-deep);
  border: 1px solid rgba(15, 157, 118, .45);
  box-shadow: none;
  font-size: .93rem;
  font-weight: 600;
  padding: .5rem 1.1rem;
  margin-top: 1rem;
}

button.ghost:hover { background: #eafaf4; transform: none; }

button.ghost:disabled {
  color: var(--text-muted);
  border-color: #d6e7e0;
  background: #f4f9f7;
  box-shadow: none;
  cursor: default;
}

.submit-row { margin-top: 1.6rem; }

/* ── 下載連結（結果頁）────────────────────────────────── */
a.dl {
  display: block;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 1rem 1.2rem;
  margin-bottom: .8rem;
  color: var(--text);
  text-decoration: none;
  transition: var(--transition);
}

a.dl:hover {
  background: var(--glass-hover);
  border-color: var(--accent);
  transform: translateY(-1px);
}

a.dl .lang { font-weight: 700; color: var(--accent-deep); }

a.dl .name {
  display: block;
  font-size: .84rem;
  color: var(--text-muted);
  margin-top: .15rem;
  word-break: break-all;
}

.back {
  display: inline-block;
  margin-top: 1.4rem;
  color: var(--accent-deep);
  text-decoration: none;
  font-size: .95rem;
}

.back:hover { text-decoration: underline; }

/* ── 貼上場次 ─────────────────────────────────────────── */
.paste-area {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px dashed rgba(15, 157, 118, .45);
  border-radius: var(--radius-md);
  background: #f4fbf8;
}

.paste-area.hidden { display: none; }

.paste-area textarea {
  min-height: 6rem;
  font-size: .92rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.paste-area button { margin-top: .6rem; }
