/* ==========================================================
   warranty-style.css — ตรวจสอบประกัน (full-hero redesign)
   Apple HIG, orange accent. Uses design-tokens.css (via header).
   ========================================================== */

/* ══════════════════════════════════════════
   HERO — full screen, centered search
══════════════════════════════════════════ */
.wg-hero {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 82vh;
  padding: calc(var(--nav-h) + 40px) 20px 64px;
  text-align: center;
  background: linear-gradient(180deg, var(--bg-page) 0%, var(--bg-surface-alt) 100%);
  transition: background .3s ease, min-height .3s ease;
}
[data-theme="dark"] .wg-hero { background: linear-gradient(180deg, #000 0%, #0c0c0e 100%); }
.wg-hero.is-compact { min-height: 0; padding-bottom: 48px; }

/* grid pattern — fades at center, gently breathes */
.wg-hero::before {
  content: '';
  position: absolute; inset: 0; z-index: 0;
  background-image:
    linear-gradient(rgba(252,116,4,0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(252,116,4,0.08) 1px, transparent 1px);
  background-size: 54px 54px;
  -webkit-mask-image: radial-gradient(ellipse 68% 60% at 50% 42%, transparent 16%, black 70%);
  mask-image: radial-gradient(ellipse 68% 60% at 50% 42%, transparent 16%, black 70%);
  pointer-events: none;
}
[data-theme="dark"] .wg-hero::before {
  background-image:
    linear-gradient(rgba(252,116,4,0.13) 1px, transparent 1px),
    linear-gradient(90deg, rgba(252,116,4,0.13) 1px, transparent 1px);
}
@media (prefers-reduced-motion: no-preference) {
  .wg-hero::before { animation: wgGridBreathe 7s ease-in-out infinite; }
}
@keyframes wgGridBreathe {
  0%, 100% { opacity: .7; background-size: 54px 54px; }
  50%      { opacity: 1;  background-size: 56px 56px; }
}

.wg-orb { position: absolute; border-radius: 50%; pointer-events: none; filter: blur(80px); z-index: 0; }
.wg-orb-1 { width: 520px; height: 520px; background: radial-gradient(circle, rgba(252,116,4,.10) 0%, transparent 70%); top: -160px; right: -120px; }
.wg-orb-2 { width: 380px; height: 380px; background: radial-gradient(circle, rgba(252,116,4,.06) 0%, transparent 70%); bottom: -120px; left: -90px; }
[data-theme="dark"] .wg-orb-1 { background: radial-gradient(circle, rgba(252,116,4,.22) 0%, transparent 70%); }
[data-theme="dark"] .wg-orb-2 { background: radial-gradient(circle, rgba(252,116,4,.11) 0%, transparent 70%); }

.wg-hero-inner { position: relative; z-index: 1; width: 100%; max-width: 660px; }

.wg-eyebrow {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 16px; border-radius: var(--r-full);
  background: var(--bg-surface); border: 1px solid var(--border);
  font-size: var(--text-xs); font-weight: 700; letter-spacing: .04em;
  color: var(--accent); margin-bottom: 22px;
  box-shadow: var(--shadow-xs);
}
.wg-eyebrow .material-symbols-rounded { font-size: 16px; }
[data-theme="dark"] .wg-eyebrow { background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.10); }
/* shine sweep across the badge */
.wg-eyebrow::after {
  content: ''; position: absolute; top: 0; left: -60%; width: 50%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(252,116,4,.25), transparent);
  transform: skewX(-20deg);
}
@media (prefers-reduced-motion: no-preference) {
  .wg-eyebrow::after { animation: wgShine 4.5s ease-in-out infinite; }
}
@keyframes wgShine { 0%, 60% { left: -60%; } 85%, 100% { left: 130%; } }

.wg-title {
  font-size: clamp(2.1rem, 5vw, 3.4rem);
  font-weight: 700; letter-spacing: -.035em; line-height: 1.08;
  color: var(--text-primary); margin: 0 0 16px;
}
[data-theme="dark"] .wg-title { color: #fff; }
.wg-lead {
  font-size: var(--text-lg); color: var(--text-secondary);
  line-height: 1.6; margin: 0 auto 34px; max-width: 520px;
}

/* big centered search pill */
.wg-search {
  position: relative;
  display: flex; align-items: center; gap: 8px;
  max-width: 560px; margin: 0 auto;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-strong);
  border-radius: var(--r-full);
  padding: 8px 8px 8px 20px;
  box-shadow: 0 4px 24px rgba(0,0,0,.07);
  transition: border-color .2s, box-shadow .2s;
}
.wg-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-light), 0 8px 28px rgba(252,116,4,.12); }
[data-theme="dark"] .wg-search { background: #1c1c1e; box-shadow: none; }
.wg-search-ico { font-size: 24px; color: var(--text-tertiary); flex-shrink: 0; }
.wg-search-input {
  flex: 1; min-width: 0; border: none; background: transparent;
  padding: 12px 6px; color: var(--text-primary);
  font-size: var(--text-base); font-family: var(--font);
}
.wg-search-input:focus { outline: none; }
.wg-search-input::placeholder { color: var(--text-tertiary); }
.wg-search-btn {
  flex-shrink: 0; border: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 13px 26px; border-radius: var(--r-full);
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff; font-size: var(--text-sm); font-weight: 700; font-family: var(--font);
  box-shadow: 0 4px 16px var(--accent-shadow);
  transition: box-shadow .2s, transform .15s;
}
.wg-search-btn:hover { box-shadow: 0 8px 28px var(--accent-shadow); transform: translateY(-1px); }
.wg-search-btn .material-symbols-rounded { font-size: 20px; }

/* honeypot */
.wg-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }

/* example formats */
.wg-examples {
  display: flex; align-items: center; justify-content: center;
  gap: 8px; flex-wrap: wrap; margin-top: 18px;
  font-size: var(--text-xs); color: var(--text-tertiary);
}
.wg-ex-label { font-weight: 600; }
.wg-ex {
  font-family: monospace; font-size: var(--text-xs); font-weight: 700;
  padding: 4px 10px; border-radius: var(--r-full);
  background: var(--accent-light); color: var(--accent-dark);
  letter-spacing: .5px;
}
[data-theme="dark"] .wg-ex { color: #ffb056; }
.wg-ex-sep { opacity: .85; }

/* trust row */
.wg-trust {
  display: flex; align-items: center; justify-content: center;
  gap: 22px; flex-wrap: wrap; margin-top: 30px;
}
.wg-trust span {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: var(--text-sm); font-weight: 600; color: var(--text-secondary);
}
.wg-trust .material-symbols-rounded { font-size: 18px; color: var(--accent); }

/* ══════════════════════════════════════════
   RESULTS container
══════════════════════════════════════════ */
.wg-results { background: var(--bg-surface-alt); padding: 40px 20px; transition: background .3s ease; }
[data-theme="dark"] .wg-results { background: #0a0a0c; }
.wg-results-inner { max-width: 620px; margin: 0 auto; }

/* notices */
.wp-rate, .wp-err {
  display: flex; align-items: center; gap: 10px;
  border-radius: 16px; padding: 15px 18px; margin-bottom: 18px;
  font-size: var(--text-sm);
}
.wp-err  { background: rgba(220,38,38,.08); border: 1px solid rgba(220,38,38,.25); color: #dc2626; }
.wp-rate { background: var(--accent-light); border: 1px solid rgba(252,116,4,.25); color: var(--accent-dark); }
[data-theme="dark"] .wp-rate { color: #ffb056; }
.wp-rate .material-symbols-rounded, .wp-err .material-symbols-rounded { flex-shrink: 0; }

/* result card */
.wp-result { border-radius: 22px; overflow: hidden; box-shadow: 0 8px 32px rgba(0,0,0,.12); }
[data-theme="dark"] .wp-result { box-shadow: 0 8px 32px rgba(0,0,0,.45); }
.wp-result-header { padding: 28px; color: #fff; position: relative; overflow: hidden; }
.wp-result-header::before { content: ''; position: absolute; right: -30px; top: -30px; width: 180px; height: 180px; border-radius: 50%; background: rgba(255,255,255,.08); }
.wp-result-header::after  { content: ''; position: absolute; right: 40px; bottom: -50px; width: 120px; height: 120px; border-radius: 50%; background: rgba(255,255,255,.05); }
.wp-rh-top { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; position: relative; z-index: 1; }
.wp-rh-icon { width: 52px; height: 52px; border-radius: 14px; background: rgba(255,255,255,.2); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.wp-rh-icon .material-symbols-rounded { font-size: 28px; }
.wp-rh-no { font-size: var(--text-xs); font-family: monospace; opacity: .85; letter-spacing: .5px; }
.wp-rh-device { font-size: 1.25rem; font-weight: 800; line-height: 1.2; }
.wp-rh-label { font-size: var(--text-sm); opacity: .85; margin-top: 2px; }
.wp-days-strip { display: flex; align-items: center; gap: 20px; position: relative; z-index: 1; background: rgba(0,0,0,.15); border-radius: 14px; padding: 16px 20px; }
.wp-days-big { font-size: 3rem; font-weight: 900; line-height: 1; }
.wp-days-unit { font-size: var(--text-sm); opacity: .85; }
.wp-days-info { flex: 1; }
.wp-days-bar-bg { background: rgba(255,255,255,.2); border-radius: 20px; height: 6px; margin: 8px 0 4px; overflow: hidden; }
.wp-days-bar { height: 100%; border-radius: 20px; background: rgba(255,255,255,.9); }
.wp-days-dates { display: flex; justify-content: space-between; font-size: var(--text-xs); opacity: .8; }

.wp-result-body { background: var(--bg-surface); padding: 24px 28px; }
[data-theme="dark"] .wp-result-body { background: #1c1c1e; }
.wp-section-title { font-size: var(--text-xs); font-weight: 800; text-transform: uppercase; letter-spacing: .6px; color: var(--text-tertiary); margin-bottom: 12px; display: flex; align-items: center; gap: 6px; }
.wp-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin-bottom: 4px; }
.wp-info-row { padding: 10px 0; border-bottom: 1px solid var(--border); display: flex; flex-direction: column; gap: 2px; }
.wp-info-row:nth-child(odd) { padding-right: 20px; }
.wp-info-row:nth-child(even) { padding-left: 20px; border-left: 1px solid var(--border); }
.wp-info-row.full { grid-column: 1/-1; padding-right: 0; padding-left: 0; border-left: none; }
.wp-info-label { font-size: var(--text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: .4px; color: var(--text-tertiary); }
.wp-info-val { font-size: var(--text-sm); font-weight: 600; color: var(--text-primary); }

.wp-claim { background: var(--bg-surface-alt); border: 1px solid var(--border); border-radius: 14px; padding: 14px 16px; margin-bottom: 8px; }
[data-theme="dark"] .wp-claim { background: #232325; }
.wp-claim-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; gap: 8px; flex-wrap: wrap; }
.wp-claim-no { font-size: var(--text-xs); font-family: monospace; font-weight: 700; color: var(--text-secondary); }
.wp-claim-date { font-size: var(--text-xs); color: var(--text-tertiary); }
.wp-claim-badge { font-size: var(--text-xs); font-weight: 700; padding: 2px 10px; border-radius: 20px; }
.wp-claim-badge.resolved { background: rgba(5,150,105,.15); color: #059669; }
.wp-claim-badge.rejected { background: rgba(220,38,38,.15); color: #dc2626; }
.wp-claim-issue { font-size: var(--text-sm); color: var(--text-primary); }
.wp-claim-resolution { margin-top: 8px; padding: 8px 12px; background: var(--bg-surface); border-left: 3px solid var(--accent); border-radius: 6px; font-size: var(--text-sm); color: var(--text-primary); }

.wp-cta { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.wp-cta-btn { flex: 1; min-width: 140px; padding: 13px 16px; border-radius: 14px; border: none; font-size: var(--text-sm); font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; transition: background .15s, transform .15s, border-color .15s, color .15s; }
.wp-cta-primary { background: #06c755; color: #fff; }
.wp-cta-primary:hover { background: #05a847; transform: translateY(-1px); }
.wp-cta-secondary { background: var(--bg-surface-alt); color: var(--text-primary); border: 1px solid var(--border-strong); }
.wp-cta-secondary:hover { border-color: var(--accent); color: var(--accent); }

.wp-store-badge { display: flex; align-items: center; gap: 12px; padding: 14px 18px; background: var(--bg-surface-alt); border: 1px solid var(--border); border-radius: 14px; margin-top: 16px; }
[data-theme="dark"] .wp-store-badge { background: #232325; }
.wp-store-logo { width: 40px; height: 40px; border-radius: 12px; background: linear-gradient(135deg, var(--accent), var(--accent-dark)); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.wp-store-logo .material-symbols-rounded { font-size: 20px; color: #fff; }
.wp-store-name { font-weight: 800; font-size: var(--text-sm); color: var(--text-primary); }
.wp-store-sub { font-size: var(--text-xs); color: var(--text-secondary); }
.wp-store-link { margin-left: auto; font-size: var(--text-xs); color: var(--accent); text-decoration: none; white-space: nowrap; font-weight: 600; }
.wp-void-box { background: rgba(220,38,38,.07); border: 1px solid rgba(220,38,38,.22); border-radius: 14px; padding: 14px 18px; margin-top: 16px; display: flex; gap: 10px; align-items: flex-start; }

/* ══════════════════════════════════════════
   Shared section bits
══════════════════════════════════════════ */
.wg-section-inner { max-width: 980px; margin: 0 auto; }
.wg-section-head { text-align: center; margin-bottom: 44px; }
.wg-section-label { display: inline-block; font-size: var(--text-xs); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; }
.wg-section-head h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; letter-spacing: -.02em; color: var(--text-primary); margin: 0; }
[data-theme="dark"] .wg-section-head h2 { color: #fff; }

/* ── CLAIM STEPS — connected flow line (no cards) ── */
.wg-steps { padding: 84px 20px; background: var(--bg-page); }
[data-theme="dark"] .wg-steps { background: #000; }
.wg-flow {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding-top: 8px;
}
/* the horizontal connecting line behind the dots */
.wg-flow-line {
  position: absolute;
  top: 35px; left: 16.66%; right: 16.66%;
  height: 2px;
  background: var(--border-strong);
  z-index: 0;
}
.wg-flow-progress {
  position: absolute; inset: 0 100% 0 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-dark));
  animation: wgFlowFill 2.4s var(--ease) forwards;
  animation-delay: .3s;
}
@keyframes wgFlowFill { to { inset: 0 0 0 0; } }

.wg-flow-step { position: relative; z-index: 1; text-align: center; }
.wg-flow-dot {
  width: 70px; height: 70px; margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 2px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  transition: border-color .3s var(--ease), background .3s var(--ease), transform .3s var(--ease);
}
.wg-flow-dot .material-symbols-rounded { font-size: 30px; color: var(--text-tertiary); transition: color .3s var(--ease); }
[data-theme="dark"] .wg-flow-dot { background: #0c0c0e; }
/* dots light up in sequence */
.wg-flow-step:nth-child(2) .wg-flow-dot { animation: wgDotOn .4s ease forwards .9s; }
.wg-flow-step:nth-child(3) .wg-flow-dot { animation: wgDotOn .4s ease forwards 1.6s; }
.wg-flow-step:nth-child(4) .wg-flow-dot { animation: wgDotOn .4s ease forwards 2.3s; }
@keyframes wgDotOn {
  from { border-color: var(--border-strong); }
  to {
    border-color: var(--accent);
    background: var(--accent);
    box-shadow: 0 8px 24px var(--accent-shadow);
  }
}
.wg-flow-step:nth-child(2) .wg-flow-dot .material-symbols-rounded { animation: wgIcoOn .4s ease forwards .9s; }
.wg-flow-step:nth-child(3) .wg-flow-dot .material-symbols-rounded { animation: wgIcoOn .4s ease forwards 1.6s; }
.wg-flow-step:nth-child(4) .wg-flow-dot .material-symbols-rounded { animation: wgIcoOn .4s ease forwards 2.3s; }
@keyframes wgIcoOn { to { color: #fff; } }
@media (prefers-reduced-motion: reduce) {
  .wg-flow-progress { animation: none; inset: 0 0 0 0; }
  .wg-flow-dot { border-color: var(--accent); background: var(--accent); }
  .wg-flow-dot .material-symbols-rounded { color: #fff; }
}

.wg-flow-k { display: block; font-size: var(--text-xs); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.wg-flow-text h3 { font-size: var(--text-lg); font-weight: 700; color: var(--text-primary); margin: 0 0 8px; }
.wg-flow-text p { font-size: var(--text-sm); color: var(--text-secondary); line-height: 1.6; margin: 0 auto; max-width: 240px; }

/* ── FAQ — minimal list (no boxes) ── */
.wg-faq { padding: 84px 20px; background: var(--bg-surface-alt); }
[data-theme="dark"] .wg-faq { background: #0a0a0c; }
.wg-faq-inner { max-width: 720px; }
.wg-faq-list { display: flex; flex-direction: column; border-top: 1px solid var(--border); }
.wg-faq-item { border-bottom: 1px solid var(--border); }
.wg-faq-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 22px 4px; cursor: pointer; list-style: none;
  font-size: var(--text-lg); font-weight: 600; color: var(--text-primary);
  transition: color .2s;
}
.wg-faq-item summary:hover { color: var(--accent); }
.wg-faq-item summary::-webkit-details-marker { display: none; }
.wg-faq-chev {
  color: var(--text-tertiary); flex-shrink: 0;
  width: 30px; height: 30px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-surface);
  transition: transform .3s var(--ease), background .2s, color .2s;
}
[data-theme="dark"] .wg-faq-chev { background: rgba(255,255,255,.06); }
.wg-faq-item[open] .wg-faq-chev { transform: rotate(180deg); color: #fff; background: var(--accent); }
.wg-faq-ans { padding: 0 4px 22px; font-size: var(--text-base); color: var(--text-secondary); line-height: 1.75; max-width: 620px; }
/* smooth open */
.wg-faq-item[open] .wg-faq-ans { animation: wgFaqReveal .28s var(--ease); }
@keyframes wgFaqReveal { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 760px) {
  .wg-flow { grid-template-columns: 1fr; gap: 0; }
  .wg-flow-line { display: none; }
  .wg-flow-step { display: flex; gap: 16px; text-align: left; padding: 16px 0; align-items: flex-start; }
  .wg-flow-dot { margin: 0; width: 52px; height: 52px; flex-shrink: 0; }
  .wg-flow-dot .material-symbols-rounded { font-size: 24px; }
  .wg-flow-text p { margin: 0; max-width: none; }
  .wg-trust { gap: 14px; }
}
@media (max-width: 520px) {
  .wg-search { flex-wrap: nowrap; padding: 6px 6px 6px 16px; }
  .wg-search-btn { padding: 12px 16px; }
  .wg-search-btn span:last-child { display: none; }
  .wp-info-grid { grid-template-columns: 1fr; }
  .wp-info-row:nth-child(even) { padding-left: 0; border-left: none; }
  .wp-info-row:nth-child(odd) { padding-right: 0; }
  .wp-days-big { font-size: 2.2rem; }
  .wg-examples { font-size: 11px; }
}
