/* ===================== Allianz Ayudhya Agent Site ===================== */

:root {
  --navy: #001b4d;
  --blue-dark: #00205b;
  --blue: #0038a8;
  --blue-mid: #1a56c4;
  --blue-light: #eaf1fb;
  --blue-pale: #f4f8fd;
  --gold: #f4a300;
  --gold-dark: #d98c00;
  --ink: #1c2430;
  --ink-soft: #5b6472;
  --line-green: #06c755;
  --white: #ffffff;
  --border: #e1e8f2;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 12px 30px -14px rgba(0, 32, 91, 0.28);
  --shadow-sm: 0 6px 16px -8px rgba(0, 32, 91, 0.22);
  --max: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Noto Sans Thai", "Kanit", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: "Kanit", "Noto Sans Thai", sans-serif;
  color: var(--blue-dark);
  line-height: 1.3;
  margin: 0 0 .5em;
}

p { margin: 0 0 1em; color: var(--ink-soft); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { margin: 0; padding: 0; list-style: none; }

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 88px 0; }
.section--tight { padding: 56px 0; }
.section--alt { background: var(--blue-pale); }
.section--navy {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--blue-dark), var(--navy));
  color: var(--white);
}
.section--navy::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--section-bg, none);
  background-size: cover;
  background-position: center 30%;
  opacity: .22;
  z-index: 0;
}
.section--navy > .container { position: relative; z-index: 1; }

.section--light-bg {
  position: relative;
  overflow: hidden;
}
.section--light-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--section-bg-light, none);
  background-size: cover;
  background-position: center 20%;
  opacity: .2;
  z-index: 0;
}
.section--light-bg > .container { position: relative; z-index: 1; }
.section--navy h2, .section--navy h3, .section--navy p { color: var(--white); }
.section--navy p { color: rgba(255,255,255,.78); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--gold-dark);
  background: rgba(244, 163, 0, .12);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}
.section--navy .eyebrow { color: var(--gold); background: rgba(244,163,0,.18); }

.section-head {
  max-width: 680px;
  margin: 0 auto 48px;
  text-align: center;
}
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }
.section-head p { font-size: 1.05rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: .98rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: var(--blue-dark); box-shadow: var(--shadow-sm); }
.btn-gold:hover { background: var(--gold-dark); }
.btn-outline { border-color: rgba(255,255,255,.6); color: var(--white); }
.btn-outline:hover { background: rgba(255,255,255,.12); }
.btn-navy { background: var(--blue-dark); color: var(--white); }
.btn-navy:hover { background: var(--navy); }
.btn-line { background: var(--line-green); color: var(--white); }
.btn-line:hover { background: #05b34c; }
.btn-ghost { border-color: var(--border); color: var(--blue-dark); background: var(--white); }
.btn-ghost:hover { border-color: var(--blue); background: var(--blue-light); }
.btn-sm { padding: 10px 20px; font-size: .88rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: "Kanit", sans-serif;
  font-weight: 700;
  color: var(--blue-dark);
  font-size: 1.05rem;
}
.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.brand-mark svg { width: 22px; height: 22px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text small { font-weight: 500; color: var(--ink-soft); font-size: .72rem; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}
.nav-links a {
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  color: var(--ink);
  transition: background .15s ease, color .15s ease;
}
.nav-links a:hover, .nav-links a.active {
  background: var(--blue-light);
  color: var(--blue);
}

.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-tel {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--blue-dark);
  font-size: .95rem;
}
.nav-tel svg { width: 18px; height: 18px; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span { width: 24px; height: 2.5px; background: var(--blue-dark); border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 640px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: var(--white);
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(0,20,60,.92) 8%, rgba(0,32,91,.78) 42%, rgba(0,32,91,.35) 75%, rgba(0,32,91,.15) 100%);
}
.hero-content { position: relative; z-index: 2; max-width: 620px; padding: 120px 0 90px; }
.hero-content .eyebrow { background: rgba(244,163,0,.2); color: var(--gold); }
.hero h1 {
  color: var(--white);
  font-size: clamp(2.1rem, 4.4vw, 3.1rem);
  margin-bottom: 18px;
}
.hero p.lead {
  color: rgba(255,255,255,.88);
  font-size: 1.12rem;
  max-width: 540px;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.hero-stats {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
  margin-top: 56px;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,.22);
  max-width: 620px;
}
.hero-stats div strong { display: block; font-size: 1.5rem; font-family: "Kanit"; color: var(--gold); }
.hero-stats div span { font-size: .85rem; color: rgba(255,255,255,.8); }

/* ---------- Family banner (home) ---------- */
.family-banner {
  position: relative;
  min-height: 460px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: var(--white);
}
.family-banner-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 30%;
}
.family-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,20,60,.75) 0%, rgba(0,32,91,.55) 45%, rgba(0,20,60,.85) 100%);
}
.family-banner-content {
  position: relative;
  z-index: 2;
  max-width: 620px;
  padding: 70px 0;
  text-align: center;
  margin: 0 auto;
}
.family-banner-content h2 { color: var(--white); font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
.family-banner-content p { color: rgba(255,255,255,.88); font-size: 1.05rem; }
.family-banner-content .eyebrow { background: rgba(244,163,0,.2); color: var(--gold); }
.family-banner-content .btn { margin-top: 8px; }

/* ---------- Page header (non-home) ---------- */
.page-header {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--blue-dark), var(--navy));
  color: var(--white);
  padding: 70px 0 60px;
  text-align: center;
}
.page-header::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--page-bg, none);
  background-size: cover;
  background-position: center 25%;
  opacity: .24;
  z-index: 0;
}
.page-header .container { position: relative; z-index: 1; }
.page-header h1 { color: var(--white); font-size: clamp(1.9rem, 4vw, 2.6rem); }
.page-header p { color: rgba(255,255,255,.82); max-width: 560px; margin: 0 auto; }

/* ---------- Cards / Grids ---------- */
.grid {
  display: grid;
  gap: 26px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }

.icon-box {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: var(--blue-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: var(--blue);
}
.icon-box svg { width: 26px; height: 26px; }

.card h3 { font-size: 1.12rem; margin-bottom: 8px; }
.card p { margin-bottom: 0; font-size: .95rem; }

/* ---------- About split ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.split img { border-radius: var(--radius); box-shadow: var(--shadow); }
.check-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 14px;
  color: var(--ink-soft);
}
.check-list svg { flex-shrink: 0; width: 22px; height: 22px; color: var(--blue); margin-top: 2px; }

/* ---------- Plan cards ---------- */
.plan-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}
.plan-tab {
  padding: 10px 22px;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: var(--white);
  font-weight: 700;
  font-size: .92rem;
  color: var(--ink-soft);
  cursor: pointer;
}
.plan-tab.active { background: var(--blue); border-color: var(--blue); color: var(--white); }

.plan-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform .18s ease, box-shadow .18s ease;
}
.plan-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.plan-tag {
  align-self: flex-start;
  font-size: .74rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--blue-light);
  color: var(--blue);
  letter-spacing: .02em;
}
.plan-tag.tag-life { background: rgba(244,163,0,.16); color: var(--gold-dark); }
.plan-card h3 { font-size: 1.15rem; margin-bottom: 2px; }
.plan-card .plan-desc { font-size: .93rem; flex-grow: 1; }
.plan-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.plan-actions .btn { flex: 1; }

/* ---------- Contact channels strip ---------- */
.contact-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.contact-tile {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 28px 24px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.contact-tile .icon-box { margin: 0 auto 16px; }
.contact-tile h3 { font-size: 1.05rem; }
.contact-tile .big { font-family: "Kanit"; font-size: 1.3rem; color: var(--blue-dark); font-weight: 700; margin: 6px 0 16px; }

/* ---------- Articles ---------- */
.article-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.article-cover {
  height: 210px;
  background-size: cover;
  background-position: center;
  position: relative;
}
.article-cover .plan-tag { position: absolute; top: 18px; left: 18px; background: var(--white); }
.article-body { padding: 26px; }
.article-meta { font-size: .82rem; color: var(--ink-soft); margin-bottom: 10px; display: flex; gap: 14px; }
.article-body h3 { font-size: 1.28rem; }
.article-excerpt { font-size: .96rem; }
.article-full {
  display: none;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px dashed var(--border);
  font-size: .96rem;
  color: var(--ink-soft);
}
.article-full.open { display: block; }
.article-full h4 { color: var(--blue-dark); font-size: 1.02rem; margin: 20px 0 8px; }
.article-full ul { margin: 0 0 14px; padding-left: 0; }
.article-full li { position: relative; padding-left: 22px; margin-bottom: 8px; }
.article-full li::before {
  content: "";
  position: absolute; left: 0; top: 9px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--gold);
}
.read-toggle {
  margin-top: 18px;
  background: none;
  border: none;
  color: var(--blue);
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
}
.read-toggle svg { width: 16px; height: 16px; transition: transform .2s ease; }
.read-toggle.open svg { transform: rotate(180deg); }

/* ---------- Contact page ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 50px;
  align-items: start;
}
.contact-grid--single {
  grid-template-columns: 1fr;
  max-width: 640px;
  margin: 0 auto;
}
.contact-photo { position: relative; }
.contact-photo img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; object-fit: cover; }
.contact-photo-badge {
  position: absolute;
  bottom: -18px;
  right: -18px;
  background: var(--white);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.contact-photo-badge .icon-box { margin: 0; width: 42px; height: 42px; background: var(--gold); color: var(--white); }
.contact-photo-badge strong { display: block; font-family: "Kanit"; color: var(--blue-dark); }
.contact-photo-badge span { font-size: .82rem; color: var(--ink-soft); }

.contact-info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 34px;
  box-shadow: var(--shadow-sm);
}
.contact-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}
.contact-row:last-child { border-bottom: none; }
.contact-row h4 { margin: 0 0 4px; font-size: 1rem; color: var(--blue-dark); }
.contact-row p { margin: 0; font-size: .93rem; }
.contact-row a.value, .contact-row p.value { font-weight: 700; color: var(--blue); font-size: 1.05rem; }

.qr-block {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--blue-pale);
  border-radius: var(--radius);
  padding: 22px;
  margin-top: 26px;
}
.qr-block img { width: 120px; height: 120px; border-radius: 12px; border: 4px solid var(--white); box-shadow: var(--shadow-sm); }

.hours-list li { display: flex; justify-content: space-between; padding: 6px 0; font-size: .93rem; color: var(--ink-soft); }
.hours-list li strong { color: var(--ink); }

.map-note {
  margin-top: 22px;
  padding: 18px 20px;
  border-radius: var(--radius-sm);
  background: rgba(0,56,168,.06);
  font-size: .88rem;
  color: var(--ink-soft);
}

/* ---------- CTA banner ---------- */
.cta-banner {
  border-radius: 24px;
  background: linear-gradient(120deg, var(--blue-dark), var(--blue-mid));
  padding: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.cta-banner::after {
  content: "";
  position: absolute;
  right: -60px; top: -60px;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: rgba(244,163,0,.18);
}
.cta-banner h2 { color: var(--white); margin-bottom: 6px; }
.cta-banner p { color: rgba(255,255,255,.85); margin-bottom: 0; }
.cta-actions { display: flex; gap: 14px; flex-wrap: wrap; position: relative; z-index: 1; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: rgba(255,255,255,.7); padding: 60px 0 26px; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.footer-brand .brand { color: var(--white); }
.footer-brand p { color: rgba(255,255,255,.62); font-size: .9rem; margin-top: 14px; }
.site-footer h4 { color: var(--white); font-size: .95rem; margin-bottom: 16px; }
.site-footer ul li { margin-bottom: 10px; font-size: .9rem; }
.site-footer a:hover { color: var(--gold); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 22px;
  font-size: .82rem;
  color: rgba(255,255,255,.5);
}
.footer-disclaimer { font-size: .78rem; color: rgba(255,255,255,.45); margin-top: 14px; line-height: 1.8; }

/* ---------- Floating LINE button ---------- */
.float-line {
  position: fixed;
  bottom: 26px;
  right: 26px;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--line-green);
  color: var(--white);
  padding: 14px 20px;
  border-radius: 999px;
  box-shadow: 0 10px 26px -8px rgba(6,199,85,.55);
  font-weight: 700;
  font-size: .92rem;
}
.float-line svg { width: 20px; height: 20px; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .contact-strip { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .nav-links, .nav-tel-wrap { display: none; }
  .nav-toggle { display: flex; }
  .site-header.open .nav-links {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 68px; left: 0; right: 0;
    background: var(--white);
    padding: 12px 24px 20px;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero { min-height: 560px; text-align: left; }
  .hero-content { padding: 100px 0 70px; }
  .cta-banner { padding: 34px 26px; flex-direction: column; align-items: flex-start; }
  .section { padding: 60px 0; }
  .contact-photo-badge { position: static; margin-top: -40px; margin-left: 16px; width: fit-content; }
}
