/* ==========================================================================
   คู่มือ Digital ID (WeLPRU) — มหาวิทยาลัยราชภัฏลำปาง
   สไตล์ชุดเดียวกับคู่มือ MFA (homepage_manual/mfa-app)
   ========================================================================== */
:root {
  --arch-navy-950: #0F1E36;
  --arch-navy-900: #162B4C;
  --arch-navy-800: #1B365D;
  --arch-navy-700: #234575;
  --arch-navy-600: #2D568E;
  --arch-navy-100: #E6EEF7;
  --arch-navy-50: #F3F7FB;
  --arch-teal-900: #153E3C;
  --arch-teal-800: #1B4F4C;
  --arch-teal-700: #236B67;
  --arch-teal-600: #2B7F7A;
  --arch-teal-100: #E3F1F0;
  --arch-teal-50: #F2F8F7;
  --stone-accent-700: #786246;
  --stone-accent-500: #9C8260;
  --stone-accent-200: #E6DDD0;
  --stone-accent-50: #F9F7F3;
  --slate-blue-700: #255785;
  --slate-blue-600: #2E6DA4;
  --slate-blue-50: #F0F5FA;

  --bg: #F6F7F9;
  --surface: #FFFFFF;
  --surface-alt: #F1F3F6;
  --border: #E2E7EE;
  --border-strong: #CBD4E1;
  --ink: #141C2B;
  --ink-secondary: #3E4C63;
  --muted: #64748B;

  /* โทนหน้าคู่มือย่อย (เหมือนหน้า mfa-365.html) */
  --brand: #1f4e5b;
  --brand-dark: #163a44;
  --brand-light: #e7f0f2;
  --accent: #a67c46;
  --success: #1f6f54;
  --success-soft: #e6f4ee;
  --danger: #c53030;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 9999px;
  --shadow-xs: 0 1px 2px rgba(20, 28, 43, 0.04);
  --shadow-sm: 0 2px 8px -2px rgba(20, 28, 43, 0.05), 0 1px 3px rgba(20, 28, 43, 0.03);
  --shadow-md: 0 10px 24px -6px rgba(20, 28, 43, 0.06), 0 2px 6px -2px rgba(20, 28, 43, 0.03);
  --shadow-lg: 0 18px 36px -10px rgba(22, 43, 76, 0.09), 0 4px 12px -4px rgba(20, 28, 43, 0.04);
  --font-heading: "Bai Jamjuree", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Sarabun", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.72;
  color: var(--ink);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-heading); }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 640px) { .container { padding: 0 24px; } }
@media (min-width: 1024px) { .container { padding: 0 32px; } }
.skip-link { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 14px; border-radius: 8px; z-index: 999; }
.skip-link:focus { left: 12px; }

/* ---------- inline UI tokens ---------- */
.ui-quote {
  display: inline-block; background: var(--surface-alt); border: 1px solid var(--border-strong);
  color: var(--ink); font-weight: 600; padding: 0.02rem 0.5rem; border-radius: 5px; font-size: 0.94em; line-height: 1.6;
}
.btn-indicator {
  display: inline-flex; align-items: center; gap: 0.25rem; background: var(--brand); color: #fff; font-weight: 600;
  padding: 0.04rem 0.6rem; border-radius: 5px; font-size: 0.9em; line-height: 1.6;
}
.btn-indicator.is-green { background: #167a62; }
.code-tag {
  font-family: var(--mono); background: var(--brand-light); color: var(--brand-dark); border: 1px solid #cde0e5;
  padding: 0.06rem 0.45rem; border-radius: 5px; font-weight: 600; font-size: 0.88em; word-break: break-all;
}
.num-dot {
  display: inline-grid; place-items: center; width: 1.45em; height: 1.45em; border-radius: 50%;
  background: #dc2626; color: #fff; font-weight: 700; font-size: 0.78em; line-height: 1; vertical-align: 0.12em; margin-right: 0.15em;
  font-family: var(--font-heading);
}

/* ==========================================================================
   หน้าแรก (index.html)
   ========================================================================== */
.top-accent-bar {
  height: 3px;
  background: linear-gradient(90deg, var(--arch-navy-800) 0%, var(--arch-navy-700) 55%, var(--stone-accent-500) 55%, var(--stone-accent-500) 62%, var(--arch-teal-700) 62%, var(--arch-teal-600) 100%);
}
.site-nav {
  position: sticky; top: 0; z-index: 100; background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; padding: 8px 0; }
.brand-link { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; min-width: 0; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 10px; background: var(--arch-navy-800); display: grid; place-items: center;
  flex-shrink: 0; box-shadow: var(--shadow-xs); border: 1px solid rgba(255, 255, 255, 0.12); color: #fff;
}
.brand-titles { display: flex; flex-direction: column; min-width: 0; }
.brand-th { font-family: var(--font-heading); font-weight: 700; font-size: clamp(0.95rem, 1.9vw, 1.08rem); line-height: 1.25; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-en { font-family: var(--font-heading); font-weight: 500; font-size: 0.72rem; letter-spacing: 0.06em; color: var(--muted); text-transform: uppercase; }
.header-nav { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.nav-item {
  font-family: var(--font-heading); font-size: 0.88rem; font-weight: 500; color: var(--ink-secondary); text-decoration: none;
  padding: 8px 16px; border-radius: var(--radius-sm); transition: background-color .18s ease, color .18s ease;
}
.nav-item:hover { background-color: var(--surface-alt); color: var(--arch-navy-800); }
.nav-item--primary { background: var(--arch-navy-800); color: #fff; font-weight: 600; }
.nav-item--primary:hover { background: var(--arch-navy-900); color: #fff; }
@media (max-width: 760px) { .nav-hide-sm { display: none; } }

.hero {
  position: relative; overflow: hidden; background: linear-gradient(180deg, #FFFFFF 0%, #F6F7F9 100%);
  padding: 40px 0 48px; border-bottom: 1px solid var(--border);
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(to right, rgba(27, 54, 93, 0.03) 1px, transparent 1px), linear-gradient(to bottom, rgba(27, 54, 93, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.65) 0%, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.65) 0%, transparent 90%);
  pointer-events: none;
}
@media (min-width: 1024px) { .hero { padding: 48px 0 64px; } }
.hero-layout { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr; gap: 32px; align-items: center; }
@media (min-width: 980px) { .hero-layout { grid-template-columns: 1fr 1fr; gap: 40px; } }
.audience-pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: var(--radius-pill);
  background: var(--arch-teal-50); border: 1px solid rgba(35, 107, 103, 0.2); color: var(--arch-teal-800);
  font-family: var(--font-heading); font-size: 0.84rem; font-weight: 600; margin-bottom: 16px;
}
.audience-indicator { width: 7px; height: 7px; border-radius: 50%; background: var(--arch-teal-700); flex-shrink: 0; }
.hero-heading { font-size: clamp(1.7rem, 3.4vw, 2.5rem); font-weight: 700; line-height: 1.3; letter-spacing: -0.015em; color: var(--ink); margin: 0 0 16px; }
.hero-heading .c1 { color: var(--arch-navy-800); }
.hero-heading .c2 { color: var(--slate-blue-700); }
.hero-lead { font-size: clamp(1rem, 1.3vw, 1.12rem); color: var(--ink-secondary); margin: 0 0 24px; max-width: 62ch; }
.feature-tags { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 24px; }
.feature-tag {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: var(--radius-sm); background: var(--surface);
  border: 1px solid var(--border); font-family: var(--font-heading); font-size: 0.85rem; font-weight: 500; color: var(--ink-secondary);
}
.hero-cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.btn-main {
  display: inline-flex; align-items: center; gap: 10px; padding: 13px 24px; border-radius: var(--radius-sm); background: var(--arch-navy-800);
  color: #fff; font-family: var(--font-heading); font-size: 0.95rem; font-weight: 600; text-decoration: none; box-shadow: var(--shadow-xs);
  transition: background-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.btn-main:hover { background: var(--arch-navy-900); transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: var(--radius-sm); background: var(--surface);
  border: 1px solid var(--border-strong); color: var(--ink-secondary); font-family: var(--font-heading); font-size: 0.92rem; font-weight: 500; text-decoration: none;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease;
}
.btn-ghost:hover { background: var(--surface-alt); border-color: var(--arch-navy-700); color: var(--arch-navy-800); }
.btn-main:focus-visible, .btn-ghost:focus-visible, .nav-item:focus-visible, .btn-action:focus-visible { outline: 2px solid var(--arch-navy-700); outline-offset: 3px; }

.hero-artwork-card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 16px; box-shadow: var(--shadow-md); }
@media (min-width: 640px) { .hero-artwork-card { padding: 20px; } }
.browser-frame { border: 1px solid var(--border-strong); border-radius: 12px; overflow: hidden; background: #fff; }
.browser-bar { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: #eef1f5; border-bottom: 1px solid var(--border); }
.browser-dots { display: flex; gap: 6px; }
.browser-dots i { width: 9px; height: 9px; border-radius: 50%; background: #cbd4e1; display: block; }
.browser-url {
  flex: 1; display: flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--border); border-radius: 999px;
  padding: 3px 12px; font-size: 0.8rem; color: var(--ink-secondary); font-family: var(--mono); overflow: hidden; white-space: nowrap;
}
.browser-url svg { flex-shrink: 0; color: #1f6f54; }
.hero-artwork-footer {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 12px;
  padding: 12px 4px 0; border-top: 1px solid var(--border); font-size: 0.84rem; color: var(--muted);
}
.verified-chip {
  display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-heading); font-size: 0.78rem; font-weight: 600; color: var(--arch-teal-800);
  background: var(--arch-teal-50); border: 1px solid var(--arch-teal-100); padding: 4px 12px; border-radius: var(--radius-pill);
}

/* flow (3 steps) */
.flow-section { padding: 48px 0 8px; }
.section-heading-wrap { text-align: center; max-width: 760px; margin: 0 auto 40px; }
.eyebrow-badge {
  display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-heading); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.04em;
  color: var(--arch-navy-800); background: var(--arch-navy-50); border: 1px solid var(--arch-navy-100); padding: 5px 14px; border-radius: var(--radius-pill); margin-bottom: 12px;
}
.section-title { font-size: clamp(1.48rem, 2.6vw, 2.1rem); font-weight: 700; line-height: 1.32; letter-spacing: -0.01em; color: var(--ink); margin: 0 0 12px; }
.section-desc { font-size: 1.02rem; color: var(--muted); margin: 0; }
.flow-grid { display: grid; grid-template-columns: 1fr; gap: 16px; counter-reset: flow; }
@media (min-width: 860px) { .flow-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; } }
.flow-item { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 22px 22px 20px; box-shadow: var(--shadow-xs); }
.flow-num {
  display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--arch-navy-800); color: #fff;
  font-family: var(--font-heading); font-weight: 700; margin-bottom: 10px;
}
.flow-item:nth-child(2) .flow-num { background: var(--slate-blue-700); }
.flow-item:nth-child(3) .flow-num { background: var(--arch-teal-700); }
.flow-item h3 { margin: 0 0 6px; font-size: 1.08rem; font-weight: 600; }
.flow-item p { margin: 0; font-size: 0.95rem; color: var(--ink-secondary); }
.flow-item .flow-files { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 6px; }

/* manuals */
.manuals-section { position: relative; padding: 48px 0 64px; }
.manual-card {
  position: relative; display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius-lg); border: 1px solid var(--border);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.manual-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.manual-card--navy { border-top: 3px solid var(--arch-navy-800); }
.manual-card--teal { border-top: 3px solid var(--arch-teal-700); }
.manual-card--feature { margin-bottom: 32px; }
@media (min-width: 900px) { .manual-card--feature { flex-direction: row; } .manual-card--feature .manual-visual { flex: 0 0 46%; border-bottom: none; border-right: 1px solid var(--border); } }
.manuals-grid { display: grid; grid-template-columns: 1fr; gap: 24px; align-items: stretch; }
@media (min-width: 860px) { .manuals-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; } }
.group-label {
  display: flex; align-items: center; gap: 10px; font-family: var(--font-heading); font-weight: 600; font-size: 1rem; color: var(--ink-secondary); margin: 0 0 14px;
}
.group-label::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.manual-visual {
  position: relative; padding: 52px 20px 20px; display: flex; align-items: center; justify-content: center; border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, #F4F7FB 0%, #FFFFFF 100%); min-height: 230px;
}
.manual-card--teal .manual-visual { background: linear-gradient(180deg, #F2F8F7 0%, #FFFFFF 100%); }
.manual-visual img.shot { border-radius: 10px; border: 1px solid var(--border-strong); box-shadow: var(--shadow-md); max-height: 260px; width: auto; }
.card-number-pill {
  position: absolute; top: 16px; left: 16px; display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-heading); font-size: 0.78rem;
  font-weight: 600; padding: 4px 12px; border-radius: var(--radius-sm); color: #fff; background: var(--arch-navy-800);
}
.manual-card--teal .card-number-pill { background: var(--arch-teal-700); }
.card-platform-pill {
  position: absolute; top: 16px; right: 16px; font-family: var(--font-heading); font-size: 0.75rem; font-weight: 500; padding: 4px 11px;
  border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); color: var(--ink-secondary);
}
.manual-content { display: flex; flex-direction: column; flex: 1; padding: 24px; }
@media (min-width: 640px) { .manual-content { padding: 30px; } }
.manual-title { font-size: clamp(1.15rem, 1.85vw, 1.34rem); font-weight: 700; line-height: 1.42; color: var(--ink); margin: 0 0 10px; }
.manual-summary { font-size: 0.97rem; color: var(--ink-secondary); margin: 0 0 18px; }
.manual-checklist { list-style: none; padding: 0; margin: 0 0 22px; display: flex; flex-direction: column; gap: 10px; }
.manual-checklist li { display: flex; align-items: flex-start; gap: 10px; font-size: 0.94rem; color: var(--ink-secondary); }
.check-dot {
  width: 20px; height: 20px; border-radius: 6px; display: inline-grid; place-items: center; flex-shrink: 0; margin-top: 3px;
  background: var(--arch-navy-50); color: var(--arch-navy-800); border: 1px solid var(--arch-navy-100);
}
.manual-card--teal .check-dot { background: var(--arch-teal-50); color: var(--arch-teal-700); border-color: var(--arch-teal-100); }
.manual-cta-area { margin-top: auto; padding-top: 8px; }
.btn-action {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; min-height: 62px; padding: 14px 20px;
  border-radius: var(--radius-md); text-decoration: none; font-family: var(--font-heading); font-size: clamp(0.94rem, 1.25vw, 1.02rem);
  font-weight: 600; line-height: 1.42; color: #fff; transition: background-color .18s ease, transform .16s ease, box-shadow .18s ease;
  background: var(--arch-navy-800); box-shadow: 0 6px 16px -4px rgba(27, 54, 93, 0.28);
}
.btn-action:hover { background: var(--arch-navy-900); box-shadow: 0 10px 22px -4px rgba(27, 54, 93, 0.36); }
.manual-card--teal .btn-action { background: var(--arch-teal-700); box-shadow: 0 6px 16px -4px rgba(35, 107, 103, 0.26); }
.manual-card--teal .btn-action:hover { background: var(--arch-teal-800); }
.btn-action-icon {
  width: 38px; height: 38px; border-radius: var(--radius-sm); background: rgba(255, 255, 255, 0.14); border: 1px solid rgba(255, 255, 255, 0.2);
  display: grid; place-items: center; flex-shrink: 0; transition: transform .18s ease;
}
.btn-action:hover .btn-action-icon { transform: translate(2px, -2px); }
.link-caption { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 10px; font-size: 0.79rem; color: var(--muted); word-break: break-all; text-align: center; }

/* prep */
.prep-section { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 48px 0 64px; }
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 24px; }
.prep-card { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 24px; display: flex; flex-direction: column; gap: 10px; transition: border-color .2s ease, background-color .2s ease; }
.prep-card:hover { border-color: var(--border-strong); background: var(--surface); }
.prep-icon { width: 46px; height: 46px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); display: grid; place-items: center; color: var(--arch-navy-800); }
.step-label { align-self: flex-start; font-family: var(--font-heading); font-size: 0.76rem; font-weight: 600; color: var(--arch-navy-800); background: var(--arch-navy-50); border: 1px solid var(--arch-navy-100); padding: 3px 11px; border-radius: var(--radius-sm); }
.prep-card h3 { font-size: 1.08rem; font-weight: 600; color: var(--ink); margin: 0; }
.prep-card p { font-size: 0.95rem; color: var(--ink-secondary); margin: 0; }
.security-callout {
  margin-top: 32px; background: var(--stone-accent-50); border: 1px solid var(--stone-accent-200); border-left: 4px solid var(--stone-accent-700);
  border-radius: var(--radius-md); padding: 20px 24px; display: flex; align-items: flex-start; gap: 16px;
}
.callout-badge { width: 42px; height: 42px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--stone-accent-200); display: grid; place-items: center; color: var(--stone-accent-700); flex-shrink: 0; }
.callout-body h3 { font-size: 1rem; font-weight: 600; color: var(--ink); margin: 0 0 4px; }
.callout-body p, .callout-body li { margin: 0; font-size: 0.94rem; color: var(--ink-secondary); }
.callout-body ul { margin: 6px 0 0; padding-left: 1.2rem; }
@media (max-width: 600px) { .security-callout { flex-direction: column; padding: 16px; } .btn-action { padding: 14px 16px; gap: 12px; } }

/* faq (shared) */
.faq-section { padding: 48px 0 56px; scroll-margin-top: 80px; }
.faq-list { display: flex; flex-direction: column; gap: 14px; max-width: 980px; margin: 0 auto; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-xs); overflow: hidden; transition: border-color .18s ease, box-shadow .18s ease; }
.faq-item:hover { border-color: var(--border-strong); }
.faq-item[open] { border-color: #b7cfd5; box-shadow: var(--shadow-md); }
.faq-question {
  list-style: none; cursor: pointer; padding: 18px 22px; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  font-family: var(--font-heading); font-size: 1.05rem; font-weight: 600; color: var(--ink); line-height: 1.45; user-select: none;
}
.faq-question::-webkit-details-marker { display: none; }
.faq-question:hover { background-color: #fafcfc; }
.faq-question:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }
.faq-item[open] .faq-question { background-color: #f7fafb; border-bottom: 1px solid var(--border); color: var(--brand-dark); }
.faq-q-left { display: flex; align-items: flex-start; gap: 12px; }
.faq-q-badge { min-width: 30px; height: 30px; border-radius: 8px; background: var(--brand-light); color: var(--brand); font-size: 0.86rem; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.faq-item[open] .faq-q-badge { background: var(--brand); color: #fff; }
.faq-chevron { width: 20px; height: 20px; color: var(--muted); flex-shrink: 0; transition: transform .2s ease; }
.faq-item[open] .faq-chevron { transform: rotate(180deg); color: var(--brand); }
.faq-answer { padding: 18px 22px 22px; color: var(--ink-secondary); font-size: 1rem; line-height: 1.78; }
@media (min-width: 768px) { .faq-answer { padding-left: 64px; padding-right: 32px; } }
.faq-answer p { margin: 0 0 10px; } .faq-answer p:last-child { margin-bottom: 0; }
.faq-answer ul, .faq-answer ol { margin: 6px 0 10px; padding-left: 1.3rem; display: grid; gap: 6px; }

/* footer (shared) */
.site-footer { background: #141E30; color: #CBD5E1; padding: 48px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 32px; padding-bottom: 32px; border-bottom: 1px solid rgba(255, 255, 255, 0.09); }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1.25fr 1fr; } }
.footer-heading { font-family: var(--font-heading); font-size: 1.05rem; font-weight: 600; color: #F8FAFC; margin: 0 0 8px; }
.footer-sub { font-size: 0.9rem; color: #94A3B8; margin: 0 0 16px; }
.footer-info-list, .footer-nav-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; font-size: 0.92rem; color: #CBD5E1; }
.footer-nav-list a { color: #E2E8F0; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.footer-nav-list a:hover { color: #fff; text-decoration: underline; }
.footer-nav-list .muted { color: #94A3B8; }
.footer-bottom { padding-top: 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; font-size: 0.84rem; color: #94A3B8; }

/* ==========================================================================
   หน้าคู่มือย่อย (create / adobe / foxit / ipad / android)
   ========================================================================== */
.max-w { max-width: 80rem; margin-left: auto; margin-right: auto; padding-left: 1.25rem; padding-right: 1.25rem; }
@media (min-width: 768px) { .max-w { padding-left: 2rem; padding-right: 2rem; } }
.doc-header { background: linear-gradient(180deg, #17343e 0%, #1f4653 100%); color: #fff; border-bottom: 2px solid #c49e69; position: relative; overflow: hidden; }
.doc-header::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px), linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
}
.doc-header-inner { position: relative; padding-top: 1.6rem; padding-bottom: 2.1rem; display: flex; flex-direction: column; gap: 1.4rem; }
@media (min-width: 1024px) { .doc-header-inner { flex-direction: row; align-items: center; justify-content: space-between; } }
.back-link { position: relative; display: inline-flex; align-items: center; gap: 6px; color: #cddce0; text-decoration: none; font-size: 0.9rem; font-family: var(--font-heading); padding-top: 1.1rem; }
.back-link:hover { color: #fff; text-decoration: underline; }
.uni-brand { display: flex; align-items: flex-start; gap: 1.1rem; }
.uni-crest { width: 54px; height: 54px; border-radius: 12px; background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.16); display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: #e5c697; }
.uni-badge-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-bottom: 0.45rem; }
.badge-pill { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.2rem 0.75rem; border-radius: 999px; font-family: var(--font-heading); font-size: 0.78rem; font-weight: 600; background: rgba(196, 158, 105, 0.16); color: #f3dfc1; border: 1px solid rgba(196, 158, 105, 0.35); }
.badge-pill-blue { background: rgba(255, 255, 255, 0.09); color: #d8eaee; border-color: rgba(255, 255, 255, 0.2); }
.doc-title { margin: 0; font-size: 1.5rem; font-weight: 600; letter-spacing: -0.01em; line-height: 1.38; color: #f8fafb; }
@media (min-width: 768px) { .doc-title { font-size: 1.85rem; } }
.doc-subtitle { margin: 0.45rem 0 0; color: #cddce0; font-size: 1.02rem; line-height: 1.6; }
.header-meta-card { background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.14); border-radius: var(--radius-md); padding: 1rem 1.25rem; min-width: 285px; }
.header-meta-title { font-family: var(--font-heading); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; color: #e5c697; font-weight: 600; margin-bottom: 0.4rem; }
.header-meta-line { font-size: 0.94rem; color: #eef4f6; margin: 0.2rem 0; display: flex; align-items: center; gap: 0.45rem; }
.header-meta-line svg { color: #e5c697; flex-shrink: 0; }

.quick-nav-bar { position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
.quick-nav-inner { display: flex; align-items: center; gap: 0.45rem; padding-top: 0.65rem; padding-bottom: 0.65rem; overflow-x: auto; scrollbar-width: thin; }
.step-nav-chip {
  display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.38rem 0.85rem; border-radius: 999px; font-family: var(--font-heading); font-size: 0.84rem;
  font-weight: 500; color: var(--ink-secondary); text-decoration: none; background: transparent; border: 1px solid var(--border); white-space: nowrap;
  transition: background-color .18s ease, color .18s ease, border-color .18s ease;
}
.step-nav-chip:hover, .step-nav-chip:focus-visible, .step-nav-chip.is-active { background: var(--brand-light); color: var(--brand-dark); border-color: #b7cfd5; outline: none; }

.doc-main { padding-bottom: 1rem; }
.intro-grid { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin-top: 2rem; margin-bottom: 2.25rem; }
@media (min-width: 900px) { .intro-grid { grid-template-columns: 1.3fr 1fr; } }
.info-box { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 1.5rem 1.75rem; box-shadow: var(--shadow-xs); }
.info-box-accent { background: #fcfbf8; border-color: #e6dfd3; border-left: 4px solid var(--accent); }
.info-box h2 { margin: 0 0 0.65rem; font-size: 1.12rem; font-weight: 600; color: var(--ink); display: flex; align-items: center; gap: 0.55rem; line-height: 1.4; }
.info-box h2 svg { color: var(--brand); flex-shrink: 0; }
.info-box-accent h2 svg { color: var(--accent); }
.info-box p { margin: 0 0 0.6rem; color: var(--ink-secondary); }
.info-list { margin: 0.4rem 0 0; padding-left: 1.2rem; display: grid; gap: 0.45rem; color: var(--ink-secondary); }
.file-list { list-style: none; margin: 0.6rem 0 0; padding: 0; display: grid; gap: 0.55rem; }
.file-item { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 0.6rem 0.9rem; font-size: 0.95rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }
.file-item strong { color: var(--ink); }

.part-heading { display: flex; align-items: center; gap: 0.9rem; margin: 2.6rem 0 1.25rem; scroll-margin-top: 4.75rem; }
.part-heading:first-of-type { margin-top: 0.5rem; }
.part-tag { font-family: var(--font-heading); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.03em; color: #fff; background: var(--brand); padding: 0.3rem 0.8rem; border-radius: 8px; white-space: nowrap; }
.part-title { margin: 0; font-size: 1.32rem; font-weight: 600; color: var(--ink); line-height: 1.4; }
.part-sub { margin: -0.6rem 0 1.25rem; color: var(--muted); font-size: 0.98rem; }

.steps-container { display: flex; flex-direction: column; gap: 1.6rem; padding-bottom: 2rem; }
.step-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-xs); overflow: hidden; transition: box-shadow .2s ease, border-color .2s ease; scroll-margin-top: 4.75rem; }
.step-card:hover { box-shadow: var(--shadow-md); border-color: var(--border-strong); }
.step-grid { display: grid; grid-template-columns: 1fr; }
@media (min-width: 900px) { .step-grid { grid-template-columns: 1fr 1fr; align-items: stretch; } }
.step-card.no-media .step-grid { grid-template-columns: 1fr; }
.step-content { padding: 1.6rem; display: flex; flex-direction: column; gap: 1.1rem; }
@media (min-width: 768px) { .step-content { padding: 2rem 2.2rem; } }
.step-header { display: flex; align-items: flex-start; gap: 1rem; }
.step-number-badge { min-width: 44px; height: 44px; padding: 0 0.65rem; border-radius: 10px; background: var(--brand); color: #fff; font-family: var(--font-heading); font-weight: 600; font-size: 1.02rem; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.step-number-badge.final-step { background: var(--success); }
.step-category { font-family: var(--font-heading); font-size: 0.78rem; font-weight: 600; letter-spacing: 0.03em; color: var(--brand); margin-bottom: 0.2rem; }
.step-title { margin: 0; font-size: 1.22rem; font-weight: 600; color: var(--ink); line-height: 1.42; }
.step-body { color: var(--ink-secondary); font-size: 1.02rem; line-height: 1.78; }
.step-body p { margin: 0 0 0.75rem; } .step-body p:last-child { margin-bottom: 0; }
.step-body a { color: var(--brand); text-underline-offset: 3px; }
.step-list { margin: 0.5rem 0 0; padding-left: 1.3rem; display: grid; gap: 0.55rem; }
.step-list li { padding-left: 0.2rem; }
.step-note { margin-top: 0.4rem; background: #fffbeb; border: 1px solid #f3e1a8; border-radius: var(--radius-sm); padding: 0.7rem 0.95rem; font-size: 0.95rem; color: #6b4f0e; }
.step-note.is-info { background: var(--slate-blue-50); border-color: #cfdcec; color: #22466e; }
.step-note.is-danger { background: #fdf3f3; border-color: #f2c6c6; color: #7f1d1d; }
.step-media { background: var(--surface-alt); border-top: 1px solid var(--border); padding: 1.3rem; display: flex; flex-direction: column; justify-content: center; align-items: center; }
@media (min-width: 900px) { .step-media { border-top: none; border-left: 1px solid var(--border); padding: 1.6rem; } }
.image-trigger-wrapper {
  width: 100%; border-radius: var(--radius-md); overflow: hidden; border: 1px solid var(--border-strong); background: #fff; box-shadow: var(--shadow-sm);
  cursor: zoom-in; position: relative; padding: 0; display: block; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.image-trigger-wrapper:hover, .image-trigger-wrapper:focus-visible { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--brand); outline: 2px solid var(--brand); outline-offset: 2px; }
.step-img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: contain; background: #f1f3f6; }
.zoom-overlay-badge { position: absolute; bottom: 0.7rem; right: 0.7rem; background: rgba(24, 35, 40, 0.78); color: #fff; padding: 0.32rem 0.8rem; border-radius: 999px; font-size: 0.8rem; font-weight: 500; display: inline-flex; align-items: center; gap: 0.35rem; pointer-events: none; font-family: var(--font-heading); }
.image-trigger-wrapper:hover .zoom-overlay-badge { background: var(--brand); }
.media-caption { margin-top: 0.75rem; font-size: 0.88rem; color: var(--muted); text-align: center; width: 100%; }

.critical-warning-box { margin: 0.5rem 0 2.5rem; background: #fdf6f6; border: 1.5px solid #e28888; border-left: 5px solid var(--danger); border-radius: 14px; padding: 1.4rem 1.6rem; display: flex; align-items: flex-start; gap: 1.1rem; }
.critical-warning-icon { width: 44px; height: 44px; border-radius: 10px; background: #fbe9e9; color: var(--danger); display: flex; align-items: center; justify-content: center; flex-shrink: 0; border: 1px solid #f5c6c6; }
.critical-warning-title { margin: 0 0 0.4rem; font-size: 1.15rem; font-weight: 700; color: #9b2c2c; line-height: 1.38; }
.critical-warning-text { margin: 0 0 0.5rem; color: #632121; font-size: 1rem; line-height: 1.75; }
.critical-warning-text:last-child { margin-bottom: 0; }
@media (max-width: 600px) { .critical-warning-box { flex-direction: column; } }

.next-nav { margin: 0.5rem 0 3rem; }
.next-nav h2 { font-size: 1.25rem; font-weight: 600; margin: 0 0 1rem; }
.next-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 1rem; }
.next-card { display: flex; flex-direction: column; gap: 0.25rem; padding: 1.05rem 1.2rem; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; text-decoration: none; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.next-card:hover { border-color: var(--brand); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.next-card .k { font-family: var(--font-heading); font-size: 0.76rem; font-weight: 600; color: var(--brand); letter-spacing: 0.03em; }
.next-card .t { font-family: var(--font-heading); font-weight: 600; color: var(--ink); }
.next-card .d { font-size: 0.9rem; color: var(--muted); }
.next-card.is-current { border-style: dashed; opacity: 0.7; pointer-events: none; }

/* image modal */
.image-modal-backdrop { position: fixed; inset: 0; z-index: 200; background: rgba(20, 30, 35, 0.84); backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; padding: 1rem; opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s ease; }
.image-modal-backdrop.is-open { opacity: 1; visibility: visible; }
.image-modal-dialog { position: relative; max-width: 84rem; width: 100%; background: #fff; border-radius: 14px; box-shadow: 0 24px 48px -12px rgba(15, 23, 28, 0.45); overflow: hidden; transform: scale(0.97); transition: transform .2s ease; display: flex; flex-direction: column; max-height: 94vh; }
.image-modal-backdrop.is-open .image-modal-dialog { transform: scale(1); }
.modal-top-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.85rem 1.2rem; background: #17343e; color: #fff; }
.modal-title-group { display: flex; align-items: center; gap: 0.7rem; min-width: 0; }
.modal-step-tag { background: rgba(255, 255, 255, 0.14); color: #f3dfc1; border: 1px solid rgba(255, 255, 255, 0.2); font-family: var(--font-heading); font-weight: 600; font-size: 0.78rem; padding: 0.18rem 0.65rem; border-radius: 6px; white-space: nowrap; }
.modal-title-text { margin: 0; font-size: 1rem; font-weight: 600; color: #f8fafb; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modal-close-btn { background: rgba(255, 255, 255, 0.1); color: #fff; border: 1px solid rgba(255, 255, 255, 0.18); width: 38px; height: 38px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.modal-close-btn:hover, .modal-close-btn:focus-visible { background: #c93b3b; border-color: #c93b3b; outline: none; }
.modal-body { padding: 1rem; background: var(--surface-alt); overflow: auto; display: flex; align-items: center; justify-content: center; }
.modal-full-img { display: block; max-width: 100%; max-height: 78vh; width: auto; height: auto; border-radius: 8px; box-shadow: var(--shadow-md); border: 1px solid var(--border-strong); background: #fff; }
.modal-footer-bar { padding: 0.7rem 1.2rem; background: #fff; border-top: 1px solid var(--border); font-size: 0.9rem; color: var(--muted); display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.modal-nav { display: inline-flex; gap: 0.5rem; }
.modal-nav button { border: 1px solid var(--border-strong); background: #fff; border-radius: 8px; padding: 0.25rem 0.75rem; cursor: pointer; font-family: var(--font-heading); color: var(--ink-secondary); }
.modal-nav button:hover { border-color: var(--brand); color: var(--brand); }

.doc-footer { border-top: 1px solid var(--border); background: var(--surface); }
.doc-footer-inner { padding-top: 1.6rem; padding-bottom: 1.6rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem; font-size: 0.9rem; color: var(--muted); }
.doc-footer a { color: var(--brand); }

@keyframes softPulse { 0%, 100% { transform: scale(1); opacity: 0.14; } 50% { transform: scale(1.08); opacity: 0.26; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }
/* signature status legend */
.sig-legend { display: grid; gap: .45rem; margin: .8rem 0 .2rem; padding: .75rem .9rem; background: #f6f8fb; border: 1px solid #e3e8ef; border-radius: 12px; font-size: .95em; }
.sig-legend .row { display: flex; gap: .6rem; align-items: flex-start; }
.sig-legend .sl { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; flex: none; font-size: 13px; line-height: 1; margin-top: 2px; }
.sig-legend .sl.ok { background: #1e9e4a; } .sig-legend .sl.warn { background: #e0a800; } .sig-legend .sl.bad { background: #d93025; }

@media print {
  .site-nav, .quick-nav-bar, .zoom-overlay-badge, .image-modal-backdrop, .next-nav, .hero-cta-row { display: none !important; }
  .step-card { break-inside: avoid; box-shadow: none; }
  body { background: #fff; }
}
