/* ============================================================
   อัตแพทย์พัทยา — Natural Health Journal
   Design system / shared stylesheet
   Direction: botanical apothecary × modern clinic
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Trirong:ital,wght@0,400;0,500;0,600;1,400&family=IBM+Plex+Sans+Thai:wght@400;500;600;700&family=Chonburi&display=swap');

:root{
  /* palette */
  --ink:      #192F34;   /* deep blue-black — text */
  --forest:   #246B78;   /* primary teal-blue */
  --forest-d: #173F4A;   /* deep sea blue */
  --sage:     #88ADB3;   /* grey-blue */
  --moss:     #DFEAEB;   /* misty blue section */
  --paper:    #F3F7F7;   /* soft blue-white bg */
  --paper-d:  #E7F0F0;
  --amber:    #D89045;   /* warm orange accent */
  --amber-d:  #B9752F;
  --clay:     #C56A3A;   /* secondary warm */
  --line:     #CBDBDD;   /* hairline */
  --white:    #FBFDFD;

  --shadow-sm: 0 1px 3px rgba(25,47,52,.06), 0 6px 20px rgba(25,47,52,.05);
  --shadow-md: 0 10px 40px rgba(25,47,52,.10);

  --maxw: 1440px;
  --radius: 4px;
  --radius-lg: 14px;

  --f-display: 'Trirong', 'IBM Plex Sans Thai', serif;
  --f-body: 'IBM Plex Sans Thai', system-ui, sans-serif;
  --f-brand: 'Chonburi', 'Trirong', serif;
}

*{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  font-family:var(--f-body);
  color:var(--ink);
  background:var(--paper);
  line-height:1.75;
  font-size:17px;
  font-weight:400;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
img{ max-width:100%; display:block; }
a{ color:var(--forest); text-decoration:none; transition:color .2s; }
a:hover{ color:var(--amber-d); }

.wrap{ max-width:var(--maxw); margin:0 auto; padding:0 24px; }
.narrow{ max-width:980px; margin:0 auto; padding:0 24px; }

/* ---------- eyebrow / specimen divider ---------- */
.eyebrow{
  font-size:.78rem; letter-spacing:.28em; text-transform:uppercase;
  color:#8F5619; font-weight:600; margin:0 0 .8rem;
  display:inline-flex; align-items:center; gap:.6rem;
}
.eyebrow::before{
  content:""; width:26px; height:1px; background:var(--amber); display:inline-block;
}
.leaf-rule{
  display:flex; align-items:center; gap:14px; color:var(--sage); margin:2.5rem 0;
}
.leaf-rule::before, .leaf-rule::after{
  content:""; height:1px; background:var(--line); flex:1;
}
.leaf-rule svg{ width:22px; height:22px; flex:none; color:var(--forest); }

/* ---------- headings ---------- */
h1,h2,h3,h4{ font-family:var(--f-display); font-weight:600; line-height:1.2; color:var(--ink); }
h1{ font-size:clamp(34px, 4.3vw, 58px); letter-spacing:-.01em; }
h2{ font-size:clamp(27px, 2.9vw, 40px); }
h3{ font-size:26px; }

/* ============================================================
   HEADER / NAV
   ============================================================ */
.site-header{
  position:sticky; top:0; z-index:50;
  background:rgba(245,241,230,.86);
  backdrop-filter:saturate(150%) blur(10px);
  border-bottom:1px solid var(--line);
}
.nav{
  display:flex; align-items:center; justify-content:space-between;
  height:74px;
}
.brand{ display:flex; align-items:center; gap:12px; }
.brand .mark{
  width:46px; height:46px; border-radius:50%; flex:none;
  background:#ffffff url('logo-selfcarethai.png?v=1') no-repeat 50% 50%;
  background-size:88% 88%;
  box-shadow:0 1px 4px rgba(23,63,74,.15);
}
.brand .mark svg{ display:none; }
.brand .name{ font-family:var(--f-brand); font-size:1.25rem; color:var(--forest-d); line-height:1; }
.brand .name{ letter-spacing:.01em; }
.brand .sub{ font-size:.72rem; letter-spacing:.06em; color:#4F747A; white-space:nowrap; }
@media (max-width:520px){ .brand .sub{ font-size:.66rem; white-space:normal; } }

.nav-links{ display:flex; align-items:center; gap:6px; list-style:none; margin:0; padding:0; }
.nav-links a{
  color:var(--ink); font-weight:500; font-size:16px;
  padding:8px 14px; border-radius:var(--radius); position:relative;
}
.nav-links a:hover{ background:var(--moss); color:var(--forest-d); }
.nav-links a.active{ color:var(--forest-d); }
.nav-links a.active::after{
  content:""; position:absolute; left:14px; right:14px; bottom:2px; height:2px; background:var(--amber);
}
.nav-cta{
  background:var(--forest); color:var(--paper)!important; padding:10px 20px!important;
  border-radius:40px; font-weight:500;
}
.nav-cta:hover{ background:var(--forest-d); color:var(--white)!important; }

/* nav-tighten: 7 items need less room on mid-size screens */
@media (max-width:1100px) and (min-width:681px){
  .nav-links{ gap:2px; }
  .nav-links a{ padding:8px 9px; font-size:15px; }
  .nav-cta{ padding:9px 14px!important; }
}
.nav-toggle{ display:none; background:none; border:0; cursor:pointer; padding:8px; color:var(--ink); }
.nav-toggle svg{ width:26px; height:26px; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn{
  display:inline-flex; align-items:center; gap:10px;
  font-family:var(--f-body); font-weight:500; font-size:16px;
  padding:13px 26px; border-radius:44px; cursor:pointer; border:1px solid transparent;
  transition:transform .15s, background .2s, box-shadow .2s;
}
.btn:hover{ transform:translateY(-2px); }
.btn-primary{ background:var(--forest); color:var(--paper); }
.btn-primary:hover{ background:var(--forest-d); color:var(--white); box-shadow:var(--shadow-md); }
.btn-amber{ background:var(--amber); color:#2a1c07; }
.btn-amber:hover{ background:var(--amber-d); color:var(--white); }
.btn-ghost{ background:transparent; color:var(--forest-d); border-color:var(--forest); }
.btn-ghost:hover{ background:var(--forest); color:var(--paper); }

/* ============================================================
   HERO
   ============================================================ */
.hero{ position:relative; overflow:hidden; padding:64px 0 40px; }
.hero-grid{ display:grid; grid-template-columns:1.05fr .95fr; gap:56px; align-items:center; }
.hero h1{ margin:.2rem 0 1.1rem; }
.hero .lead{ font-size:19px; color:#3A4B4F; max-width:34ch; margin-bottom:1.9rem; }
.hero-actions{ display:flex; gap:14px; flex-wrap:wrap; }
.hero-stats{ display:flex; gap:36px; margin-top:2.6rem; }
.hero-stats .num{ font-family:var(--f-display); font-size:2rem; color:var(--forest-d); line-height:1; }
.hero-stats .lbl{ font-size:.85rem; color:var(--sage); margin-top:4px; }

.hero-visual{
  position:relative; border-radius:var(--radius-lg); overflow:hidden; min-height:420px;
  background:linear-gradient(155deg, #246B78, #173F4A 70%);
  box-shadow:var(--shadow-md);
  display:grid; place-items:center; padding:36px;
}
a.hero-visual{
  padding:0; display:block; min-height:0; background:var(--paper-d);
  border:1px solid rgba(36,107,120,.20);
  transition:box-shadow .25s ease, transform .25s ease;
}
a.hero-visual:hover{ transform:translateY(-2px); box-shadow:0 16px 48px rgba(25,47,52,.16); }
a.hero-visual::after{
  content:""; position:absolute; inset:0; pointer-events:none; border-radius:inherit;
  background:
    linear-gradient(200deg, rgba(36,107,120,.10) 0%, rgba(36,107,120,0) 42%),
    linear-gradient(0deg,   rgba(23,63,74,.14)  0%, rgba(23,63,74,0)  38%);
  box-shadow:inset 0 0 0 1px rgba(251,253,253,.45);
}
.hero-visual img{ width:100%; height:auto; display:block; }
.hero-visual .botanical{ width:100%; height:100%; position:absolute; inset:0; opacity:.9; }
.hero-card{
  position:relative; z-index:2; background:rgba(251,249,243,.94); border-radius:12px;
  padding:26px 28px; max-width:300px; box-shadow:var(--shadow-md);
}
.hero-card .tag{ font-size:.72rem; letter-spacing:.2em; text-transform:uppercase; color:var(--amber-d); font-weight:600; }
.hero-card h3{ margin:.5rem 0 .4rem; font-size:1.2rem; }
.hero-card p{ margin:0; font-size:.92rem; color:#43555A; }

/* ============================================================
   SECTIONS
   ============================================================ */
section{ padding:72px 0; }
.section-head{ max-width:640px; margin-bottom:44px; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }
.section-head p{ color:#4A5B5F; font-size:1.05rem; margin-top:.4rem; }

.bg-moss{ background:var(--moss); }
.bg-forest{ background:var(--forest-d); color:var(--paper); }
.bg-forest h1,.bg-forest h2,.bg-forest h3{ color:var(--white); }
.bg-paper-d{ background:var(--paper-d); }

/* ---------- category chips ---------- */
.chips{ display:flex; flex-wrap:wrap; gap:12px; }
.chip{
  display:inline-flex; align-items:center; gap:8px;
  background:var(--white); border:1px solid var(--line); border-radius:40px;
  padding:9px 18px; font-size:.92rem; font-weight:500; color:var(--ink);
}
.chip:hover{ border-color:var(--forest); color:var(--forest-d); background:var(--moss); }
.chip .dot{ width:8px; height:8px; border-radius:50%; background:var(--amber); }

/* ============================================================
   ARTICLE CARDS
   ============================================================ */
.card-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:28px; }
.card-grid.two{ grid-template-columns:repeat(2,1fr); }
.card{
  background:var(--white); border:1px solid var(--line); border-radius:var(--radius-lg);
  overflow:hidden; display:flex; flex-direction:column; box-shadow:var(--shadow-sm);
  transition:transform .2s, box-shadow .2s;
}
.card:hover{ transform:translateY(-4px); box-shadow:var(--shadow-md); }
.card .thumb{ aspect-ratio:16/9; height:auto; position:relative; overflow:hidden; background:var(--paper-d); }
.card .thumb a{ display:block; width:100%; height:100%; }
.card .thumb img.focus-r{ object-position:50% 50%; }
.card .thumb svg,
.card .thumb img{ width:100%; height:100%; object-fit:cover; display:block; }
.card .body{ padding:22px 24px 26px; display:flex; flex-direction:column; flex:1; }
.card .kicker{ font-size:.74rem; letter-spacing:.14em; text-transform:uppercase; color:#8F5619; font-weight:600; margin-bottom:.5rem; }
.card h3{ font-size:25px; margin:0 0 .6rem; }
.card h3 a{ color:var(--ink); }
.card h3 a:hover{ color:var(--forest-d); }
.card .excerpt{ font-size:.96rem; color:#4B5C60; margin:0 0 1.1rem; }
.card .meta{ margin-top:auto; display:flex; align-items:center; gap:12px; font-size:.84rem; color:var(--sage); }
.card .meta .read{ color:var(--forest); font-weight:600; }

.card.feature{ grid-column:span 3; flex-direction:row; }
.card.feature .thumb{ width:46%; height:auto; aspect-ratio:auto; min-height:300px; }
.card.feature .body{ justify-content:center; padding:40px; }
.card.feature h3{ font-size:34px; }
.card.feature .excerpt{ font-size:1.05rem; }

/* ============================================================
   ARTICLE PAGE
   ============================================================ */
.article-hero{ padding:56px 0 28px; }
.breadcrumb{ font-size:.86rem; color:var(--sage); margin-bottom:1.4rem; }
.breadcrumb a{ color:var(--sage); }
.breadcrumb a:hover{ color:var(--forest); }
.article-hero h1{ margin:.4rem 0 1rem; max-width:26ch; }
.article-meta{ display:flex; align-items:center; gap:18px; color:#4A5B5F; font-size:.92rem; flex-wrap:wrap; }
.article-meta .avatar{ width:42px; height:42px; border-radius:50%; background:var(--forest); color:var(--paper); display:grid; place-items:center; font-family:var(--f-display); font-weight:600; }
.article-meta .avatar-img{ width:52px; height:52px; background:none; border-radius:0; object-fit:contain; }
.article-cover{ border-radius:var(--radius-lg); overflow:hidden; margin:28px 0 8px; box-shadow:var(--shadow-sm); height:420px; }
.article-cover.photo{ height:auto; aspect-ratio:16/9; background:var(--paper-d); border:1px solid rgba(36,107,120,.18); }
.article-cover.photo img{ height:auto; }
.cap{ margin:10px 2px 0; font-size:14.5px; line-height:1.65; color:#5A6B6F; font-style:italic; }
.board-img{ width:100%; height:auto; display:block; margin:26px 0 0; border-radius:var(--radius-lg);
  border:1px solid rgba(36,107,120,.18); background:var(--white); box-shadow:var(--shadow-sm); }
.photo-grid{ display:grid; grid-template-columns:1fr 1fr; gap:18px; margin:26px 0; }
.photo-grid figure{ margin:0; }
.photo-grid img{ width:100%; height:auto; aspect-ratio:3/2; object-fit:cover; display:block;
  border-radius:var(--radius-lg); border:1px solid rgba(36,107,120,.18); background:var(--paper-d); }
.photo-grid figcaption{ margin:8px 2px 0; font-size:14px; line-height:1.6; color:#5A6B6F; font-style:italic; }
.photo-grid.three{ grid-template-columns:repeat(3,1fr); }
@media (max-width:860px){ .photo-grid.three{ grid-template-columns:1fr 1fr; } }
@media (max-width:640px){ .photo-grid, .photo-grid.three{ grid-template-columns:1fr; } }
.article-cover svg,
.article-cover img{ width:100%; height:100%; object-fit:cover; display:block; }

.prose{ font-size:18px; color:#26333A; }
.prose > p{ margin:1.3rem 0; }
.prose h2{ margin:2.6rem 0 1rem; }
.prose h3{ margin:2rem 0 .6rem; font-size:26px; color:var(--forest-d); }
.prose ul,.prose ol{ margin:1.2rem 0; padding-left:1.3rem; }
.prose li{ margin:.5rem 0; }
.prose strong{ color:var(--ink); }
.prose .table-wrap{ overflow-x:auto; margin:26px 0; -webkit-overflow-scrolling:touch; }
.prose table{ width:100%; border-collapse:collapse; font-size:16px; min-width:520px; background:var(--white); }
.prose th, .prose td{ padding:12px 14px; border:1px solid var(--line); text-align:left; vertical-align:top; }
.prose th{ background:var(--forest); color:#fff; font-family:var(--f-body); font-weight:600; }
.prose tbody tr:nth-child(even){ background:var(--paper); }
.prose .refs{ margin-top:40px; padding-top:22px; border-top:2px solid var(--line); font-size:15px; color:#4A5B5F; }
.prose .refs ol{ padding-left:20px; }
.prose .refs li{ margin-bottom:10px; }
.prose .refs a{ color:var(--forest); text-decoration:underline; text-underline-offset:2px; word-break:break-word; }
.prose .refs a:hover{ color:var(--amber-d); }
.prose blockquote{
  margin:2rem 0; padding:20px 28px; border-left:4px solid var(--amber);
  background:var(--moss); border-radius:0 var(--radius) var(--radius) 0;
  font-family:var(--f-display); font-size:1.2rem; font-style:italic; color:var(--forest-d);
}
.prose .lead-p{ font-size:20px; color:#354749; line-height:1.7; }

.callout{
  background:var(--white); border:1px solid var(--line); border-left:4px solid var(--forest);
  border-radius:var(--radius); padding:20px 24px; margin:2rem 0;
}
.callout h3{ font-size:1.05rem; margin:0 0 .5rem; color:var(--forest-d); }
.callout .t{ font-weight:600; color:var(--forest-d); margin-bottom:.4rem; display:flex; align-items:center; gap:8px; }
.callout.warn{ border-left-color:var(--clay); background:#fbf3ee; }
.callout.warn .t{ color:var(--clay); }

/* medical disclaimer banner */
.disclaimer{
  background:#fbf3ee; border:1px solid #e6c9b8; border-radius:var(--radius-lg);
  padding:20px 24px; margin:2.4rem 0; font-size:.95rem; color:#6b3f2a; display:flex; gap:14px;
}
.disclaimer svg{ width:26px; height:26px; flex:none; color:var(--clay); margin-top:2px; }

/* tags + share */
.tag-row{ display:flex; flex-wrap:wrap; gap:10px; margin:2.4rem 0; }
.tag-row .t{ background:var(--moss); color:var(--forest-d); font-size:.85rem; padding:6px 14px; border-radius:30px; }

/* ============================================================
   NEWSLETTER / CTA band
   ============================================================ */
.cta-band{ background:linear-gradient(135deg,var(--forest),var(--forest-d)); color:var(--paper); border-radius:var(--radius-lg); padding:52px 48px; }
.cta-band h2{ color:var(--white); margin:0 0 .6rem; }
.cta-band p{ color:#CFE0E4; margin:0 0 1.6rem; max-width:46ch; }
.subscribe{ display:flex; gap:12px; flex-wrap:wrap; max-width:480px; }
.subscribe input{
  flex:1; min-width:200px; padding:14px 18px; border-radius:44px; border:1px solid rgba(255,255,255,.3);
  background:rgba(255,255,255,.12); color:var(--white); font-family:var(--f-body); font-size:1rem;
}
.subscribe input::placeholder{ color:#BCD2D6; }
.subscribe input:focus{ outline:2px solid var(--amber); }

/* ============================================================
   FORMS (contact)
   ============================================================ */
.form-grid{ display:grid; grid-template-columns:1fr 1fr; gap:20px; }
.field{ display:flex; flex-direction:column; gap:6px; }
.field.full{ grid-column:1 / -1; }
.field label{ font-weight:600; font-size:.92rem; color:var(--forest-d); }
.field input,.field textarea,.field select{
  padding:13px 16px; border:1px solid var(--line); border-radius:var(--radius);
  background:var(--white); font-family:var(--f-body); font-size:1rem; color:var(--ink);
}
.field input:focus,.field textarea:focus,.field select:focus{ outline:2px solid var(--forest); border-color:transparent; }
.field textarea{ resize:vertical; min-height:130px; }

.info-list{ list-style:none; padding:0; margin:0; display:flex; flex-direction:column; gap:22px; }
.info-list li{ display:flex; gap:16px; }
.info-list .ic{ width:44px; height:44px; border-radius:12px; background:var(--moss); display:grid; place-items:center; color:var(--forest-d); flex:none; }
.info-list .ic svg{ width:22px; height:22px; }
.info-list .k{ font-weight:600; color:var(--ink); }
.info-list .v{ color:#4A5B5F; font-size:.96rem; }

/* ============================================================
   ABOUT
   ============================================================ */
.values{ display:grid; grid-template-columns:repeat(3,1fr); gap:24px; }
.value{ background:var(--white); border:1px solid var(--line); border-radius:var(--radius-lg); padding:30px 26px; }
.value .ic{ width:52px; height:52px; border-radius:14px; background:var(--forest); color:var(--paper); display:grid; place-items:center; margin-bottom:16px; }
.value .ic svg{ width:26px; height:26px; }
.value h3{ font-size:1.2rem; margin:0 0 .5rem; }
.value p{ margin:0; color:#4B5C60; font-size:.96rem; }

.team{ display:grid; grid-template-columns:repeat(3,1fr); gap:26px; }
.member{ text-align:center; }
.member .photo{ width:120px; height:120px; border-radius:50%; margin:0 auto 16px; background:linear-gradient(150deg,var(--sage),var(--forest)); display:grid; place-items:center; color:var(--paper); font-family:var(--f-display); font-size:2rem; }
.member h3{ font-size:1.15rem; margin:0 0 .2rem; }
.member .role{ color:var(--amber-d); font-weight:600; font-size:.9rem; }
.member p{ color:#4B5C60; font-size:.92rem; margin:.6rem 0 0; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer{ background:var(--ink); color:#C7D3D6; padding:64px 0 28px; }
.footer-grid{ display:grid; grid-template-columns:1.6fr 1fr 1.1fr 1fr 1.2fr; gap:36px; }
@media (max-width:1100px){ .footer-grid{ grid-template-columns:repeat(4,minmax(0,1fr)); gap:28px; } .footer-grid > div:first-child{ grid-column:1 / -1; } }
.site-footer .brand .name{ color:var(--paper); }
.site-footer .brand .mark{ box-shadow:0 0 0 1px rgba(255,255,255,.18); }
.site-footer p{ color:#9FB2B6; font-size:.94rem; max-width:32ch; }
.site-footer h4{ font-family:var(--f-body); font-size:.82rem; letter-spacing:.16em; text-transform:uppercase; color:var(--sage); margin:0 0 16px; }
.site-footer ul{ list-style:none; padding:0; margin:0; display:flex; flex-direction:column; gap:10px; }
.site-footer a{ color:#C7D3D6; font-size:.95rem; }
.site-footer a:hover{ color:var(--amber); }
.footer-bottom{ border-top:1px solid rgba(255,255,255,.1); margin-top:44px; padding-top:22px; display:flex; justify-content:space-between; gap:16px; flex-wrap:wrap; font-size:.85rem; color:#8FA2A6; }

/* ============================================================
   UTIL / ANIMATION
   ============================================================ */
.reveal{ opacity:0; transform:translateY(24px); transition:opacity .7s ease, transform .7s ease; }
.reveal.in{ opacity:1; transform:none; }

@media (prefers-reduced-motion: reduce){
  *{ animation:none!important; transition:none!important; scroll-behavior:auto!important; }
  .reveal{ opacity:1; transform:none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 940px){
  .hero-grid{ grid-template-columns:1fr; gap:36px; }
  .hero-visual{ min-height:340px; }
  .card-grid, .card-grid.two{ grid-template-columns:1fr 1fr; }
  .card.feature{ flex-direction:column; grid-column:span 3; }
  .card.feature .thumb{ width:100%; aspect-ratio:auto; min-height:220px; }
  .footer-grid{ grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:32px; }
  .footer-grid > div{ min-width:0; }
  .values, .team{ grid-template-columns:1fr; }
}
@media (max-width: 680px){
  body{ font-size:16px; }
  .nav-links{
    position:fixed; inset:74px 0 auto 0; flex-direction:column; align-items:stretch; gap:0;
    background:var(--paper); border-bottom:1px solid var(--line); padding:10px 16px 20px;
    transform:translateY(-130%); transition:transform .3s, visibility .3s;
    visibility:hidden; box-shadow:var(--shadow-md);
  }
  .nav-links.open{ transform:none; visibility:visible; }
  .nav-links a{ padding:14px 12px; border-radius:6px; }
  .nav-links a.active::after{ display:none; }
  .nav-toggle{ display:block; }
  .card-grid, .card-grid.two{ grid-template-columns:1fr; }
  .form-grid{ grid-template-columns:1fr; }
  .cta-band{ padding:36px 26px; }
  .hero-stats{ gap:24px; }
  section{ padding:52px 0; }
  .site-footer a, .footer-bottom span{ overflow-wrap:anywhere; }
}
@media (max-width: 520px){
  .footer-grid{ grid-template-columns:1fr; gap:26px; }
}

/* ===== 5 อ. — หลักคิดของ SelfCareThai ===== */
.five-band{
  background:linear-gradient(180deg, rgba(36,107,120,.05), rgba(36,107,120,.02));
  border-top:1px solid rgba(36,107,120,.14);
  border-bottom:1px solid rgba(36,107,120,.14);
  padding:52px 0; margin:44px 0;
}
.five-head{ text-align:center; max-width:720px; margin:0 auto 30px; padding:0 24px; }
.five-head .eyebrow{ justify-content:center; }
.five-head h2{ margin:.2em 0 .35em; }
.five-head .slogan{
  font-family:'Chonburi', 'Trirong', serif; font-size:clamp(20px,3.2vw,27px);
  line-height:1.5; color:var(--forest-d); margin:0;
}
.five-head .slogan-sub{ margin:12px 0 0; color:#5A6B6F; font-size:15.5px; line-height:1.7; }
.five-grid{
  display:grid; grid-template-columns:repeat(5,1fr); gap:16px;
  max-width:1180px; margin:0 auto; padding:0 24px;
}
.five-grid .o{
  background:var(--white); border:1px solid rgba(36,107,120,.16);
  border-radius:var(--radius-lg); padding:22px 18px 20px;
  box-shadow:var(--shadow-sm); display:flex; flex-direction:column;
}
.five-grid .o .num{
  font-family:'Chonburi','Trirong',serif; font-size:30px; line-height:1;
  color:var(--forest); opacity:.9; margin:0 0 10px;
}
.five-grid .o h3{ font-size:18.5px; margin:0 0 8px; color:var(--ink); }
.five-grid .o p{ font-size:14.6px; line-height:1.72; color:#5A6B6F; margin:0; }
.five-grid .o .quote{
  margin:14px 0 0; padding-top:12px; border-top:1px dashed rgba(36,107,120,.22);
  font-style:italic; font-size:13.8px; line-height:1.68; color:var(--forest-d);
}
/* ดันคำคมไปชิดล่างเสมอ การ์ดทุกใบจึงดูสมดุลแม้เนื้อหายาวไม่เท่ากัน */
.five-grid .o > p:nth-last-of-type(1).quote,
.five-grid .o .quote{ margin-top:auto; }
.five-grid .o p:not(.num):not(.quote){ margin-bottom:4px; }
@media (max-width:1080px){
  .five-grid{ grid-template-columns:repeat(3,1fr); }
  .five-grid .o:nth-child(4){ grid-column:1 / span 1; }
}
@media (max-width:760px){ .five-grid{ grid-template-columns:repeat(2,1fr); } }
@media (max-width:520px){ .five-grid{ grid-template-columns:1fr; } }
.five-note{
  max-width:1180px; margin:24px auto 0; padding:0 24px;
  font-size:13.6px; line-height:1.75; color:#6B7B7F; text-align:center;
}
.sr-only{
  position:absolute!important; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0;
}
.five-head{ margin-bottom:26px; }

/* crop a photo's upper area without editing the file */
.photo-grid .imgclip{
  overflow:hidden; border-radius:var(--radius-lg);
  border:1px solid rgba(36,107,120,.18); background:var(--paper-d);
  aspect-ratio:3/2;
}
.photo-grid .imgclip img{ border:0; border-radius:0; transform:scale(2.4); transform-origin:50% 79%; }

/* ===== แถบคุกกี้ (PDPA) ===== */
.cookie-bar{
  position:fixed; left:0; right:0; bottom:0; z-index:9999;
  background:var(--white); border-top:1px solid rgba(36,107,120,.22);
  box-shadow:0 -6px 24px rgba(23,63,74,.12);
  transform:translateY(110%); transition:transform .25s ease;
}
.cookie-bar.show{ transform:translateY(0); }
.cookie-inner{
  max-width:1180px; margin:0 auto; padding:18px 24px;
  display:flex; align-items:center; gap:22px; flex-wrap:wrap;
}
.cookie-text{
  margin:0; flex:1 1 420px; font-size:14.5px; line-height:1.7; color:#4A5B5F;
}
.cookie-text a{ color:var(--forest-d); text-decoration:underline; }
.cookie-actions{ display:flex; gap:10px; flex:0 0 auto; }
.cookie-actions .btn{ padding:10px 18px; font-size:14.5px; white-space:nowrap; }
@media (max-width:640px){
  .cookie-inner{ padding:16px; gap:14px; }
  .cookie-actions{ width:100%; }
  .cookie-actions .btn{ flex:1; text-align:center; }
}

/* course link chips on homepage category cards */
.course-links{ display:flex; flex-wrap:wrap; gap:8px; margin-top:16px; }
.course-links a{ display:inline-block; padding:9px 15px; border-radius:999px; background:var(--forest,#246B78); color:#fff !important; font-weight:600; font-size:.9rem; text-decoration:none; line-height:1.3; transition:background .15s, transform .15s; }
.course-links a:hover{ background:var(--forest-d,#1d5560); transform:translateY(-1px); }
.course-links a.alt{ background:#fff; color:var(--forest,#246B78) !important; border:1.5px solid var(--forest,#246B78); }
.course-links a.alt:hover{ background:rgba(36,107,120,.08); }

/* principle cards with illustrated banner */
.value.img-card{ padding:0; overflow:hidden; }
.value.img-card img{ display:block; width:100%; height:auto; aspect-ratio:1572/1001; object-fit:cover; }
.value.img-card .body{ padding:18px 22px 22px; }
.value.img-card .body p{ font-size:.92rem; }

.team.two{ grid-template-columns:repeat(2,minmax(0,1fr)); max-width:760px; margin:0 auto; }
@media (max-width:680px){ .team.two{ grid-template-columns:1fr; } }

/* team cards */
.team.two .member{ background:var(--white); border:1px solid var(--line); border-radius:var(--radius-lg); padding:36px 28px 30px; box-shadow:var(--shadow-sm); transition:transform .2s, box-shadow .2s; }
.team.two .member:hover{ transform:translateY(-3px); box-shadow:var(--shadow-md); }
.team.two .photo{ width:88px; height:88px; margin:0 auto 18px; border-radius:50%; display:grid; place-items:center; color:#fff; background:linear-gradient(145deg,#3F8D9B,#1d5560); box-shadow:0 8px 20px rgba(36,107,120,.28); }
.team.two .photo svg{ width:40px; height:40px; }
.team.two h3{ margin:0 0 4px; font-size:1.25rem; }
.team.two .role{ display:inline-block; padding:3px 12px; border-radius:999px; background:rgba(216,144,69,.14); color:#B36B21; font-weight:600; font-size:.82rem; margin-bottom:12px; }
.team.two p{ margin:0; color:#4B5C60; font-size:.95rem; line-height:1.7; }

.team.two .member{ padding:0; overflow:hidden; }
.team.two .member .team-img{ display:block; width:100%; height:auto; aspect-ratio:1572/1001; object-fit:cover; margin-bottom:16px; }
.team.two .member .role{ margin:0 0 10px; }
.team.two .member p{ padding:0 24px 26px; }


/* การ์ด 5 อ. — แถบสี ไอคอน และสีประจำแต่ละ อ. */
.five-grid .o{ position:relative; overflow:hidden; padding-top:26px; border-color:rgba(36,107,120,.12); transition:transform .25s, box-shadow .25s; }
.five-grid .o::before{ content:""; position:absolute; inset:0 0 auto 0; height:5px; background:var(--tint); }
.five-grid .o::after{ content:""; position:absolute; right:-40px; top:-40px; width:140px; height:140px; border-radius:50%; background:var(--tint); opacity:.10; }
.five-grid .o:hover{ transform:translateY(-4px); box-shadow:0 14px 30px rgba(36,107,120,.14); }
.five-grid .o .num{ display:flex; align-items:center; gap:10px; font-size:26px; color:var(--tint-d); opacity:1; }
.five-grid .o .ico{ width:44px; height:44px; border-radius:12px; display:grid; place-items:center; background:color-mix(in srgb, var(--tint) 16%, white); color:var(--tint-d); flex:none; }
.five-grid .o .ico svg{ width:24px; height:24px; }
.five-grid .o .quote{ border-top-color:color-mix(in srgb, var(--tint) 45%, transparent); }
.t1{ --tint:#7FB6D9; --tint-d:#2E6F96; }
.t2{ --tint:#8CC46A; --tint-d:#3E7A22; }
.t3{ --tint:#E7B44E; --tint-d:#9A6A0C; }
.t4{ --tint:#E9A0A8; --tint-d:#A83E4A; }
.t5{ --tint:#4FA9A4; --tint-d:#1F6E6A; }
