/* Airlines Quick Refund — design system. Green & white, premium feel. */
:root {
  --green-900: #06281d;
  --green-800: #0a3d2c;
  --green-700: #0e5138;
  --green-600: #12734c;
  --green-500: #17945f;
  --green-100: #dcf3e7;
  --green-50: #f2faf6;
  --ink: #10201a;
  --muted: #5b6f66;
  --line: #e2ece7;
  --bg: #ffffff;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(6, 40, 29, .05), 0 8px 24px rgba(6, 40, 29, .07);
  --font: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg, canvas { max-width: 100%; }
a { color: var(--green-600); text-decoration: none; }

.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.container.narrow { max-width: 720px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.fine-print { font-size: .82rem; color: var(--muted); margin: 18px 0; }

h1 { font-size: clamp(1.7rem, 4vw, 2.6rem); line-height: 1.15; letter-spacing: -.02em; font-weight: 800; }
h2 { font-size: 1.35rem; letter-spacing: -.01em; }
h3 { font-size: 1.05rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand-name { font-weight: 800; font-size: 1.05rem; color: var(--green-900); letter-spacing: -.01em; }
.brand-accent { color: var(--green-500); }
.main-nav { display: flex; gap: 22px; margin-left: 8px; }
.main-nav a { color: var(--ink); font-weight: 500; font-size: .93rem; }
.main-nav a:hover { color: var(--green-600); }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.lang-picker { position: relative; }
.lang-picker summary {
  list-style: none; cursor: pointer; font-weight: 600; font-size: .85rem;
  padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; color: var(--muted);
}
.lang-picker summary::-webkit-details-marker { display: none; }
.lang-list {
  position: absolute; right: 0; top: 40px; background: #fff; border: 1px solid var(--line);
  border-radius: 10px; box-shadow: var(--shadow); padding: 8px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; width: 220px; z-index: 60;
}
.lang-list a { padding: 6px 8px; border-radius: 6px; font-size: .82rem; text-align: center; color: var(--ink); }
.lang-list a:hover { background: var(--green-50); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; border: 0; cursor: pointer; font-family: inherit;
  font-weight: 600; border-radius: 10px; transition: all .15s ease;
  padding: 12px 22px; font-size: .95rem; text-align: center;
}
.btn-primary { background: var(--green-600); color: #fff; box-shadow: 0 2px 8px rgba(18, 115, 76, .3); }
.btn-primary:hover { background: var(--green-700); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--green-700); border: 1px solid var(--line); }
.btn-ghost:hover { background: var(--green-50); }
.btn-sm { padding: 8px 14px; font-size: .85rem; }
.btn-lg { padding: 15px 30px; font-size: 1.05rem; border-radius: 12px; }
.btn-block { display: block; width: 100%; }
.btn:disabled { opacity: .6; cursor: wait; transform: none; }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1000px 500px at 85% -10%, var(--green-100), transparent 60%),
    linear-gradient(180deg, var(--green-50), #fff 75%);
  padding: 72px 0 64px;
}
.hero-inner { display: grid; grid-template-columns: 1.2fr .8fr; gap: 48px; align-items: center; }
.badge {
  display: inline-block; background: var(--green-100); color: var(--green-800);
  font-size: .78rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px; margin-bottom: 18px;
}
.hero-sub { font-size: 1.15rem; color: var(--muted); margin: 18px 0 28px; max-width: 34em; }
.hero-cta-row { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.hero-note { font-size: .9rem; color: var(--green-700); font-weight: 600; }

.amount-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 10px; transform: rotate(1.5deg);
}
.amount-row {
  display: flex; justify-content: space-between; align-items: center; gap: 18px;
  padding: 16px 18px; border-radius: 10px;
}
.amount-row + .amount-row { border-top: 1px solid var(--line); border-radius: 0; }
.amount-row.highlight { background: var(--green-50); border-top: 1px solid var(--line); }
.amount-dist { font-size: .88rem; color: var(--muted); }
.amount-val { font-weight: 800; font-size: 1.3rem; color: var(--green-700); white-space: nowrap; }

/* ---------- Trust strip ---------- */
.trust-strip { border-block: 1px solid var(--line); background: #fff; }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 18px 20px; }
.trust-item { font-size: .87rem; font-weight: 600; color: var(--green-900); }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-tinted { background: var(--green-50); }
.section-title { text-align: center; font-size: clamp(1.4rem, 3vw, 1.9rem); margin-bottom: 40px; letter-spacing: -.02em; }

.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.step-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 22px; box-shadow: var(--shadow); }
.step-num {
  width: 34px; height: 34px; border-radius: 999px; background: var(--green-600); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 800; margin-bottom: 14px;
}
.step-card h3 { margin-bottom: 8px; }
.step-card p { font-size: .9rem; color: var(--muted); }

.amounts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 8px; }
.amount-tile {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px 22px; text-align: center; color: var(--muted); font-size: .9rem;
}
.amount-tile.featured { border-color: var(--green-500); box-shadow: var(--shadow); }
.amount-big { font-size: 2.1rem; font-weight: 800; color: var(--green-700); margin-bottom: 6px; }
.section .center { margin-top: 34px; }

.faq-item { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq-item summary { cursor: pointer; font-weight: 600; padding: 14px 0; list-style: none; position: relative; padding-right: 30px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 4px; color: var(--green-600); font-weight: 700; font-size: 1.2rem; }
.faq-item[open] summary::after { content: "–"; }
.faq-item p { padding: 0 0 16px; color: var(--muted); font-size: .95rem; }

/* ---------- Forms / cards ---------- */
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 28px; margin-top: 24px;
}
fieldset { border: 0; min-width: 0; }
.field { margin-bottom: 16px; position: relative; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row .field { min-width: 0; }
.field label { display: block; font-weight: 600; font-size: .88rem; margin-bottom: 6px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: 10px;
  font-family: inherit; font-size: .95rem; background: #fff; color: var(--ink);
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(23, 148, 95, .12); }

.ac-list { position: absolute; left: 0; right: 0; top: 100%; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); z-index: 40; display: none; overflow: hidden; }
.ac-list.open { display: block; }
.ac-item { padding: 10px 13px; cursor: pointer; font-size: .9rem; display: flex; gap: 8px; }
.ac-item:hover, .ac-item.sel { background: var(--green-50); }
.ac-iata { font-weight: 700; color: var(--green-700); min-width: 40px; }

.q-label { font-weight: 600; font-size: .92rem; margin: 20px 0 10px; }
.choice-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.choice-grid.three { grid-template-columns: repeat(3, 1fr); }
.choice-grid.two { grid-template-columns: repeat(2, 1fr); }
.choice { display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; }
.choice span {
  display: block; border: 1.5px solid var(--line); border-radius: 10px; padding: 12px 14px;
  font-size: .9rem; transition: all .12s;
}
.choice small { display: block; color: var(--muted); font-size: .8rem; }
.choice input:checked + span { border-color: var(--green-600); background: var(--green-50); box-shadow: 0 0 0 1px var(--green-600); }

.btn-row { display: flex; justify-content: space-between; gap: 12px; margin-top: 26px; }
.error-msg { color: #b3261e; font-size: .88rem; margin-top: 10px; }

/* ---------- Wizard ---------- */
.wizard-head { text-align: center; margin-bottom: 8px; }
.wizard-steps { display: flex; justify-content: center; gap: 8px; list-style: none; margin-top: 20px; counter-reset: ws; }
.wizard-steps li {
  counter-increment: ws; font-size: .82rem; font-weight: 600; color: var(--muted);
  padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff;
}
.wizard-steps li::before { content: counter(ws) ". "; }
.wizard-steps li.active { background: var(--green-600); border-color: var(--green-600); color: #fff; }
.wizard-steps li.done { background: var(--green-100); border-color: var(--green-100); color: var(--green-800); }

/* ---------- Result ---------- */
.result-eligible { text-align: center; padding: 10px 0; }
.result-amount { font-size: 3rem; font-weight: 800; color: var(--green-600); line-height: 1.1; }
.result-per-pax { color: var(--muted); margin-bottom: 18px; }
.result-split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 20px 0; }
.result-split > div { background: var(--green-50); border-radius: 10px; padding: 14px; }
.result-split .lbl { font-size: .8rem; color: var(--muted); }
.result-split .val { font-weight: 800; font-size: 1.2rem; color: var(--green-800); }
.result-warn { background: #fff7e6; border: 1px solid #f5dfae; color: #7a5b13; border-radius: 10px; padding: 12px 14px; font-size: .88rem; text-align: left; margin: 14px 0; }
.result-not { text-align: center; padding: 10px 0; }

/* ---------- Claim form ---------- */
.form-section { margin: 30px 0 12px; font-size: 1.05rem; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.pax-card { border: 1px solid var(--line); border-radius: 10px; padding: 16px; margin-bottom: 12px; background: var(--green-50); }
.pax-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-weight: 700; font-size: .9rem; }
.pax-head button { background: none; border: none; color: #b3261e; cursor: pointer; font-size: .82rem; font-family: inherit; }
.mandate-text { font-size: .88rem; color: var(--muted); background: var(--green-50); border-radius: 10px; padding: 14px; }
.sign-wrap { border: 1.5px dashed var(--green-500); border-radius: 10px; padding: 10px; background: #fff; }
#signPad { width: 100%; height: 180px; touch-action: none; border-radius: 6px; background: #fdfdfb; cursor: crosshair; display: block; }
.consent-row { display: flex; gap: 10px; align-items: flex-start; margin: 20px 0; font-size: .88rem; }
.consent-row input { margin-top: 4px; }

.success-card { text-align: center; }
.success-icon { width: 60px; height: 60px; border-radius: 999px; background: var(--green-600); color: #fff; font-size: 1.8rem; display: flex; align-items: center; justify-content: center; margin: 0 auto 16px; }
.ref-box { font-size: 1.7rem; font-weight: 800; letter-spacing: .05em; color: var(--green-700); background: var(--green-50); border: 1px dashed var(--green-500); border-radius: 10px; padding: 14px; margin: 14px 0; }

/* ---------- Track ---------- */
.status-badge { display: inline-block; font-weight: 700; padding: 8px 16px; border-radius: 999px; background: var(--green-100); color: var(--green-800); margin-bottom: 18px; }
.status-refuse, .status-cloture { background: #fbeaea; color: #8c2822; }
.status-gagne, .status-paye { background: var(--green-600); color: #fff; }
.claim-facts { display: grid; grid-template-columns: auto 1fr; gap: 8px 22px; }
.claim-facts dt { font-weight: 600; color: var(--muted); font-size: .9rem; }
.timeline { list-style: none; margin-top: 14px; }
.timeline li { display: flex; gap: 16px; padding: 10px 0 10px 22px; border-left: 2px solid var(--green-100); position: relative; }
.timeline li::before { content: ""; position: absolute; left: -6px; top: 18px; width: 10px; height: 10px; border-radius: 999px; background: var(--green-500); }
.tl-date { color: var(--muted); font-size: .85rem; min-width: 90px; }
.tl-status { font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer { background: var(--green-900); color: #cfe4da; margin-top: 40px; padding: 44px 0 0; font-size: .88rem; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1.4fr; gap: 30px; padding-bottom: 30px; }
.footer-brand { color: #fff; }
.footer-tagline { margin-top: 8px; opacity: .8; }
.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-links a { color: #cfe4da; }
.footer-links a:hover { color: #fff; }
.footer-company { opacity: .7; font-size: .8rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding: 16px 20px; font-size: .78rem; opacity: .6; }

/* ---------- Cookie banner ---------- */
.cookie-banner {
  position: fixed; bottom: 16px; left: 16px; right: 16px; max-width: 560px; margin: 0 auto;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  padding: 14px 18px; display: flex; gap: 16px; align-items: center; z-index: 100; font-size: .85rem;
}
.cookie-banner[hidden] { display: none; }

/* ---------- Chat widget ---------- */
.chat-widget { position: fixed; bottom: 20px; right: 20px; z-index: 90; }
.chat-toggle {
  width: 56px; height: 56px; border-radius: 999px; border: none; cursor: pointer;
  background: var(--green-600); color: #fff; font-size: 1.5rem;
  box-shadow: 0 4px 16px rgba(6, 40, 29, .3); transition: transform .15s;
}
.chat-toggle:hover { transform: scale(1.06); }
.chat-panel {
  position: absolute; bottom: 70px; right: 0; width: min(360px, calc(100vw - 40px));
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 8px 40px rgba(6, 40, 29, .18); overflow: hidden;
  display: flex; flex-direction: column; height: 460px;
}
.chat-head { background: var(--green-800); color: #fff; padding: 14px 16px; }
.chat-sub { display: block; font-size: .75rem; opacity: .75; }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.chat-msg { max-width: 85%; padding: 9px 13px; border-radius: 14px; font-size: .88rem; white-space: pre-wrap; }
.chat-msg.bot { background: var(--green-50); border: 1px solid var(--line); align-self: flex-start; border-bottom-left-radius: 4px; }
.chat-msg.user { background: var(--green-600); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.chat-input { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.chat-input input { flex: 1; padding: 9px 12px; border: 1.5px solid var(--line); border-radius: 999px; font-family: inherit; font-size: .88rem; }
.chat-input input:focus { outline: none; border-color: var(--green-500); }

/* ---------- Legal ---------- */
.legal h2 { margin: 26px 0 8px; font-size: 1.1rem; }
.legal p { margin-bottom: 10px; }

/* ---------- Admin ---------- */
.admin-body { background: #f4f7f5; min-height: 100vh; }
.admin-top { background: var(--green-900); color: #fff; padding: 0 24px; display: flex; align-items: center; gap: 26px; height: 56px; }
.admin-top a { color: #cfe4da; font-size: .9rem; font-weight: 500; }
.admin-top a:hover, .admin-top a.active { color: #fff; }
.admin-top .spacer { margin-left: auto; }
.admin-main { max-width: 1200px; margin: 28px auto; padding: 0 24px; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 26px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 18px; }
.kpi .lbl { font-size: .8rem; color: var(--muted); font-weight: 600; }
.kpi .val { font-size: 1.6rem; font-weight: 800; color: var(--green-800); }
table.data { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; font-size: .88rem; }
table.data th { text-align: left; padding: 10px 14px; background: var(--green-50); font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
table.data td { padding: 10px 14px; border-top: 1px solid var(--line); }
table.data tr:hover td { background: #fafcfb; }
.chip { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .75rem; font-weight: 700; background: var(--green-100); color: var(--green-800); }
.chip.refuse, .chip.cloture { background: #fbeaea; color: #8c2822; }
.chip.gagne, .chip.paye { background: var(--green-600); color: #fff; }
.admin-login { max-width: 380px; margin: 10vh auto; }
.detail-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; align-items: start; }

/* Admin on mobile: stacked panels, scrollable nav and tables */
@media (max-width: 860px) {
  .detail-grid { grid-template-columns: 1fr; }
  .admin-top { overflow-x: auto; white-space: nowrap; gap: 16px; padding: 0 14px; }
  .admin-main { padding: 0 12px; margin-top: 16px; }
  table.data { display: block; overflow-x: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; gap: 30px; }
  .hero-card { display: none; }
  .steps-grid, .trust-grid, .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .amounts-grid { grid-template-columns: 1fr; }
  .main-nav { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .choice-grid.three { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .steps-grid, .trust-grid, .kpi-grid { grid-template-columns: 1fr; }
  .hero { padding: 44px 0 36px; }
}
