
@import url('https://fonts.googleapis.com/css2?family=Prompt:wght@300;400;500;600;700&display=swap');

:root {
  --sage: #789b88;
  --sage-dark: #527763;
  --cream: #fbf8f0;
  --white: #ffffff;
  --text: #39443e;
  --muted: #78837c;
  --pink: #f4dce0;
  --lavender: #e9e4f3;
  --mint: #e7f0e9;
  --border: #e8e9e2;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Prompt', sans-serif;
  background: var(--cream);
  color: var(--text);
  line-height: 1.7;
}

button {
  font: inherit;
  cursor: pointer;
}

.site-header {
  background: rgba(255,255,255,.94);
  padding: 16px 7%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 21px;
  font-weight: 600;
  color: var(--sage-dark);
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--mint);
  display: grid;
  place-items: center;
  font-size: 23px;
}

.page {
  width: min(1100px, 90%);
  margin: auto;
  padding: 35px 0 110px;
}

.hero {
  background: linear-gradient(120deg, #e6efe7, #f7eee9);
  border-radius: 28px;
  padding: 55px 7%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  min-height: 300px;
}

.hero-content {
  max-width: 650px;
}

.eyebrow {
  color: var(--sage-dark);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 12px;
}

.hero h1 {
  font-size: clamp(27px, 4vw, 40px);
  line-height: 1.4;
  margin-bottom: 12px;
}

.hero p {
  color: #5f6d64;
  margin-bottom: 24px;
  max-width: 600px;
}

.primary-btn {
  background: var(--sage-dark);
  color: white;
  border: 0;
  border-radius: 30px;
  padding: 12px 25px;
  transition: .2s;
}

.primary-btn:hover {
  background: #405f4e;
  transform: translateY(-2px);
}

.hero-flower {
  font-size: 100px;
  min-width: 120px;
  text-align: center;
}

.section {
  margin-top: 42px;
}

.section-heading {
  margin-bottom: 20px;
}

.section-heading h2 {
  font-size: 23px;
  font-weight: 600;
}

.section-heading p {
  color: var(--muted);
  font-size: 14px;
}

.care-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.care-card {
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 22px 15px;
  background: white;
  text-align: center;
  transition: .2s;
  color: var(--text);
}

.care-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(60,80,65,.09);
}

.care-icon {
  width: 65px;
  height: 65px;
  margin: 0 auto 14px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-size: 30px;
}

.care-card h3 {
  font-size: 15px;
  font-weight: 500;
}

.tip-card {
  background: var(--lavender);
  border-radius: 22px;
  padding: 25px 28px;
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.tip-icon {
  font-size: 32px;
}

.tip-card h3 {
  margin-bottom: 5px;
  font-size: 18px;
}

.tip-card p {
  color: #5d5a69;
}

.emergency-card {
  background: #f7e8e8;
  border-radius: 22px;
  padding: 25px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.emergency-card h3 {
  color: #9b5555;
  margin-bottom: 5px;
}

.emergency-card p {
  color: #755f5f;
  font-size: 14px;
}

.emergency-btn {
  background: #a85f5f;
  color: white;
  border: 0;
  border-radius: 25px;
  padding: 10px 20px;
  white-space: nowrap;
}

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(255,255,255,.97);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: center;
  gap: 0;
  padding: 9px 3%;
  z-index: 20;
}

.nav-item {
  flex: 1;
  max-width: 170px;
  border: 0;
  background: transparent;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 12px;
  padding: 5px;
}

.nav-item span {
  font-size: 21px;
}

.nav-item.active {
  color: var(--sage-dark);
  font-weight: 600;
}

.back-btn {
  border: 0;
  background: transparent;
  color: var(--sage-dark);
  margin-bottom: 22px;
}

.guide-panel {
  background: white;
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 25px;
  margin-top: 18px;
}

.guide-panel h2 {
  margin-bottom: 12px;
  font-size: 20px;
}

.guide-step {
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.guide-step:last-child {
  border-bottom: 0;
}

.guide-step h3 {
  font-size: 16px;
  margin-bottom: 4px;
}

.guide-step p, .page-description {
  color: var(--muted);
  font-size: 14px;
}

.notice {
  background: #fff3e2;
  border-radius: 16px;
  padding: 18px;
  margin-top: 20px;
  color: #765c36;
}

.site-footer {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  padding: 25px 10px 5px;
}

@media (max-width: 760px) {
  .site-header {
    padding: 12px 5%;
  }

  .page {
    width: 92%;
    padding-top: 22px;
  }

  .hero {
    padding: 32px 7%;
    min-height: auto;
  }

  .hero-flower {
    font-size: 65px;
    min-width: 65px;
  }

  .care-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .care-card {
    padding: 18px 10px;
  }

  .emergency-card {
    align-items: flex-start;
    flex-direction: column;
  }

  .tip-card {
    padding: 20px;
  }
}

@media (max-width: 390px) {
  .hero-flower {
    display: none;
  }

  .brand {
    font-size: 19px;
  }
}
.hero-mascot {
     width: 280px;
     min-width: 220px;
     display: flex;
     justify-content: center;
     align-items: center;
   }
   
   .hero-mascot img {
     width: 100%;
     height: 280px;
     object-fit: contain;
     display: block;
   }
   
   @media (max-width: 760px) {
     .hero-mascot {
       width: 130px;
       min-width: 110px;
     }
   
     .hero-mascot img {
       height: 150px;
     }
   }
   .care-grid {
     grid-template-columns: repeat(2, 1fr);
     gap: 16px;
   }
   
   .care-card {
     display: flex;
     align-items: center;
     text-align: left;
     gap: 18px;
     padding: 22px;
     min-height: 110px;
     border-radius: 26px;
     box-shadow: 0 4px 15px #00000008;
   }
   
   .care-icon {
     margin: 0;
     flex-shrink: 0;
     width: 75px;
     height: 75px;
   }
   
   .care-card:nth-child(3n + 1) {
     background: #edf5ed;
   }
   
   .care-card:nth-child(3n + 2) {
     background: #f3edf9;
   }
   
   .care-card:nth-child(3n) {
     background: #fce9ee;
   }
   
   .care-card:last-child {
     grid-column: 1 / -1;
   }
   
   @media (max-width: 600px) {
     .care-grid {
       grid-template-columns: 1fr;
     }
   }
   /* แบนเนอร์อุ่นใจ Care */

body {
     background: #faf8f5;
     color: #403849;
   }
   
   .page {
     width: min(1440px, 96%);
     padding-top: 15px;
   }
   
   .home-hero {
     background-image: url("images/unjai-banner.jpg");
     background-size: cover;
     background-position: center;
     background-repeat: no-repeat;
     aspect-ratio: 1536 / 741;
     min-height: 0;
     border-radius: 28px;
     padding: 5%;
     display: flex;
     align-items: center;
     overflow: hidden;
   }
   
   .home-hero .hero-content {
     width: 48%;
     max-width: 650px;
   }
   
   .home-hero .eyebrow {
     display: inline-block;
     background: #e0ede5;
     color: #527f70;
     border: 1px solid #c6dcd0;
     padding: 6px 18px;
     border-radius: 30px;
     margin-bottom: 18px;
   }
   
   .home-hero .welcome-title {
     color: #548f7c;
     font-size: clamp(24px, 3vw, 44px);
     font-weight: 600;
     line-height: 1.4;
   }
   
   .welcome-title span {
     display: block;
     color: #aa96c9;
     font-size: 1.25em;
   }
   
   .home-hero p {
     color: #403849;
     font-size: clamp(13px, 1.3vw, 18px);
     margin-bottom: 24px;
   }
   
   .home-hero .primary-btn {
     background: linear-gradient(
       135deg, #83b5a0, #478a75
     );
     color: white;
     padding: 14px 28px;
     border-radius: 40px;
     box-shadow: 0 5px 15px #52776325;
   }
   
   @media (max-width: 760px) {
     .home-hero {
       aspect-ratio: auto;
       background-size: 100% auto;
       background-position: top center;
       background-color: #eaf3eb;
       padding: 52% 6% 25px;
     }
   
     .home-hero .hero-content {
       width: 100%;
     }
   }
   .care-text {
     flex: 1;
   }
   
   .care-text h3 {
     font-size: 18px;
     font-weight: 600;
     color: #403849;
   }
   
   .care-text p {
     font-size: 13px;
     color: #625c69;
     line-height: 1.6;
     margin-top: 5px;
   }
   
   .care-arrow {
     width: 34px;
     height: 34px;
     border-radius: 50%;
     background: #79ad98;
     color: white;
     display: grid;
     place-items: center;
     flex-shrink: 0;
     font-size: 20px;
   }
   
   .care-card {
     border: 1px solid #e2e9e3;
     box-shadow: 0 4px 12px #52776312;
   }
   
   .care-icon {
     font-size: 42px;
   }
   /* เมนูด้านล่างแบบลอย */

.bottom-nav {
     width: min(760px, 92%);
     left: 50%;
     bottom: 18px;
     transform: translateX(-50%);
     background: rgba(255, 255, 255, 0.97);
     border-radius: 50px;
     border: 1px solid #e2e9e3;
     box-shadow: 0 6px 25px #52776325;
     padding: 12px 20px;
   }
   
   .nav-item {
     color: #51485b;
     font-size: 14px;
   }
   
   .nav-item span {
     font-size: 28px;
   }
   
   .nav-item:not(:last-child) {
     border-right: 1px solid #e5e1e7;
   }
   
   .nav-item.active {
     color: #518f7b;
     font-weight: 600;
   }
   
   .nav-item.active::after {
     content: "";
     width: 65%;
     height: 3px;
     background: #518f7b;
     border-radius: 10px;
   }
   
   .page {
     padding-bottom: 140px;
   }
   .bottom-nav {
     width: min(460px, 92%);
     height: 64px;
     bottom: 12px;
     padding: 5px 12px;
     border-radius: 40px;
     align-items: center;
     box-shadow: 0 4px 15px #52776318;
   }
   
   .nav-item {
     height: 48px;
     font-size: 12px;
     padding: 0 4px;
     line-height: 1.3;
     justify-content: center;
     gap: 3px;
   }
   
   .nav-item span {
     font-size: 23px;
     line-height: 1;
   }
   
   .nav-item.active::after {
     width: 40%;
     height: 2px;
   }
   /* ปรับสำหรับโทรศัพท์ */
@media (max-width: 600px) {

     .page {
       width: 94%;
       padding-top: 12px;
       padding-bottom: 110px;
     }
   
     .home-hero {
       border-radius: 20px;
       padding: 52% 20px 24px;
       background-size: 100% auto;
       background-position: top center;
       aspect-ratio: auto;
       min-height: 0;
     }
   
     .hero-content {
       width: 100%;
       max-width: 100%;
     }
   
     .hero h1 {
       font-size: 26px;
       line-height: 1.4;
     }
   
     .hero p {
       font-size: 15px;
       line-height: 1.7;
     }
   
     .section {
       margin-top: 24px;
     }
   
     .care-grid {
       grid-template-columns: 1fr;
       gap: 12px;
     }
   
     .care-card {
       padding: 16px 12px;
       min-width: 0;
     }
   
     .care-text {
       min-width: 0;
     }
   
     .care-text h3 {
       font-size: 16px;
     }
   
     .care-text p {
       font-size: 13px;
     }
   
     .care-icon {
       width: 55px;
       height: 55px;
       flex-shrink: 0;
     }
   
     .bottom-nav {
       width: 94%;
       height: 64px;
       bottom: calc(10px + env(safe-area-inset-bottom));
     }
   
     .nav-item {
       font-size: 12px;
       height: 48px;
     }
   
     .nav-item span {
       font-size: 23px;
     }
   }
   @media (max-width: 600px) {
     .home-hero {
       background-image: url("images/unjai-banner.jpg");
       background-size: 100% 100%;
       background-position: center;
       background-repeat: no-repeat;
       width: 100%;
       height: auto;
       aspect-ratio: 1536 / 741;
       min-height: 0;
       padding: 3% 5%;
       border-radius: 15px;
       display: flex;
       align-items: center;
       justify-content: flex-start;
       overflow: hidden;
     }
   
     .home-hero .hero-content {
       width: 53%;
       max-width: 53%;
       margin: 0;
       padding: 0;
       position: relative;
       left: auto;
       transform: none;
     }
   
     .home-hero .eyebrow {
       font-size: 8px;
       padding: 3px 6px;
       margin-bottom: 4px;
     }
   
     .home-hero h1 {
       font-size: 14px;
       line-height: 1.3;
       margin-bottom: 5px;
     }
   
     .home-hero h1 span {
       font-size: 18px;
     }
   
     .home-hero p {
       font-size: 9px;
       line-height: 1.4;
       margin-bottom: 7px;
     }
   
     .home-hero .primary-btn {
       font-size: 10px;
       padding: 6px 10px;
       border-radius: 20px;
     }
   }
   @media (max-width: 600px) {
     .home-hero {
       background-image: url("images/unjai-banimages/njai-banner-mobile.jpgner.jpg") !important;
       background-size: 100% 100%;
       background-position: center;
       background-repeat: no-repeat;
     }
   }
   @media (max-width: 600px) {
     .home-hero {
       width: 100%;
       aspect-ratio: auto;
       height: auto;
       min-height: 260px;
       background-size: cover;
       background-position: center;
       padding: 20px 12px;
       border-radius: 18px;
       align-items: center;
     }
   
     .home-hero .hero-content {
       width: 55%;
       max-width: 55%;
       min-width: 0;
       margin: 0;
       padding: 0;
     }
   
     .home-hero .eyebrow {
       font-size: 10px;
       margin-bottom: 8px;
     }
   
     .home-hero h1 {
       font-size: 16px;
       line-height: 1.4;
       margin-bottom: 8px;
     }
   
     .home-hero h1 span {
       font-size: 20px;
     }
   
     .home-hero p {
       font-size: 11px;
       line-height: 1.5;
       margin-bottom: 12px;
     }
   
     .home-hero .primary-btn {
       font-size: 11px;
       padding: 10px 12px;
       white-space: normal;
     }
   }
   @media (max-width: 600px) {
     .home-hero {
       background-image: url("images/unjai-banner.jpg") !important;
       background-size: contain !important;
       background-position: center !important;
       background-repeat: no-repeat;
       background-color: #e7f0e9;
       width: 100%;
       height: auto;
       min-height: 230px;
       aspect-ratio: auto;
       padding: 15px 12px;
       display: flex;
       align-items: center;
       overflow: visible;
     }
   
     .home-hero .hero-content {
       width: 53%;
       max-width: 53%;
       margin: 0;
     }
   
     .home-hero h1 {
       font-size: 14px;
       line-height: 1.3;
     }
   
     .home-hero h1 span {
       font-size: 18px;
     }
   
     .home-hero p {
       font-size: 11px;
       line-height: 1.4;
     }
   
     .home-hero .primary-btn {
       font-size: 11px;
       padding: 10px;
     }
   }
   @media (max-width: 600px) {
     .home-hero {
          background-image: url("images/njai-banner-mobile.jpg");
          background-size: cover;
          background-position: center;
          background-repeat: no-repeat;
          background-color: #eaf3e8;
          aspect-ratio: 3 / 4;
          width: 100%;
          height: auto;
          min-height: 0;
          padding: 24px 14px;
          border-radius: 20px;
          display: flex;
          align-items: center;
          box-sizing: border-box;
      }
   
     .home-hero .hero-content {
       width: 48%;
       max-width: 48%;
       min-width: 0;
       margin: 0;
     }
   
     .home-hero h1 {
       font-size: 20px;
       line-height: 1.4;
     }
   
     .home-hero p {
       font-size: 13px;
       line-height: 1.5;
     }
   
     .home-hero button {
       font-size: 12px;
       padding: 10px 12px;
       white-space: normal;
     }
   }
   @media (max-width: 600px) {
     .home-hero {
         background-image: url("images/njai-banner-mobile.jpg") !important;
         background-size: 100% 100% !important;
         background-position: center !important;
         background-repeat: no-repeat !important;
         aspect-ratio: 3 / 4 !important;
         height: auto !important;
         min-height: 0 !important;
         padding: 20px 14px !important;
         align-items: center !important;
     }
 
     .home-hero .hero-content {
         width: 48% !important;
         max-width: 48% !important;
         margin: 0 !important;
     }
 }
 @media (max-width: 600px) {

     .home-hero {
         padding: 18px 14px !important;
         align-items: center !important;
     }
 
     .home-hero .hero-content {
         width: 45% !important;
         max-width: 45% !important;
         min-width: 0 !important;
         margin: 0 !important;
         transform: translateY(-12px);
     }
 
     .home-hero h1 {
         font-size: clamp(16px, 4.6vw, 22px) !important;
         line-height: 1.35 !important;
         margin: 8px 0 !important;
     }
 
     .home-hero h1 span {
         font-size: 0.85em !important;
     }
 
     .home-hero p {
         font-size: 12px !important;
         line-height: 1.5 !important;
         margin: 8px 0 12px !important;
     }
 
     .home-hero button {
         font-size: 12px !important;
         padding: 10px 12px !important;
         min-height: 44px;
         max-width: 100%;
         border-radius: 25px !important;
         white-space: normal !important;
     }
 }
 @media (max-width: 600px) {
     .home-hero .hero-content {
         width: 44% !important;
         max-width: 44% !important;
         transform: translateY(-20px);
     }
 
     .home-hero h1 {
         font-size: 18px !important;
         line-height: 1.4 !important;
         text-wrap: balance;
         margin: 10px 0 !important;
     }
 
     .home-hero p {
         font-size: 12px !important;
         line-height: 1.6 !important;
     }
 }
 .topic-list {
     display: grid;
     gap: 12px;
     margin-top: 16px;
   }
   
   .topic-card {
     background: #edf3e9;
     border: 1px solid #dce8d8;
     border-radius: 16px;
     padding: 16px;
   }
   
   .topic-card summary {
     font-size: 16px;
     font-weight: 600;
     color: #426653;
     cursor: pointer;
     line-height: 1.6;
   }
   
   .topic-card p {
     font-size: 15px;
     line-height: 1.8;
     margin-top: 12px;
     color: #454545;
   }
   
   @media (max-width: 600px) {
     .topic-card {
       padding: 14px;
     }
   
     .topic-card summary {
       font-size: 16px;
     }
   }
   .topic-content {
     margin-top: 16px;
     font-size: 16px;
     line-height: 1.8;
     color: #454545;
     overflow-wrap: anywhere;
   }
   
   .topic-content h3 {
     font-size: 16px;
     color: #426653;
     margin: 16px 0 8px;
   }
   
   .topic-content ol,
   .topic-content ul {
     padding-left: 22px;
   }
   
   .topic-content li {
     margin-bottom: 10px;
   }
   /* แบนเนอร์หน้ารายละเอียดทั้ง 7 หมวด */

.detail-hero {
     background-size: 100% 100%;
     background-position: center;
     background-repeat: no-repeat;
     background-color: transparent;
     border: none;
     box-shadow: none;
     border-radius: 24px;
     min-height: 260px;
     display: flex;
     align-items: center;
     padding: 24px;
     box-sizing: border-box;
   }
   
   .detail-hero .hero-content {
     width: 52%;
     max-width: 52%;
     margin: 0;
     text-align: left;
   }
   
   .detail-hero h1 {
     font-size: 26px;
     color: #426653;
     line-height: 1.4;
   }
   
   .detail-hero p {
     font-size: 15px;
     line-height: 1.7;
     color: #52665b;
   }
   
   /* สำหรับหน้าจอโทรศัพท์ */
   
   @media (max-width: 600px) {
     .detail-hero {
       min-height: 190px;
       padding: 14px;
       border-radius: 18px;
     }
   
     .detail-hero .hero-content {
       width: 55%;
       max-width: 55%;
     }
   
     .detail-hero h1 {
       font-size: 18px;
     }
   
     .detail-hero p {
       font-size: 12px;
       line-height: 1.5;
     }
   }
   /* แก้แบนเนอร์ไม่ให้รูปโดนบีบ */

.detail-hero {
     width: 100%;
     aspect-ratio: 3 / 1;
     min-height: 0;
     height: auto;
     background-size: contain;
     background-position: center;
     background-repeat: no-repeat;
   }
   
   .detail-hero .hero-content {
     width: 42%;
     max-width: 42%;
     margin-left: 20%;
   }
   
   @media (max-width: 600px) {
     .detail-hero {
       aspect-ratio: 3 / 1;
       min-height: 0;
       padding: 10px;
     }
   
     .detail-hero .hero-content {
       width: 45%;
       max-width: 45%;
       margin-left: 18%;
     }
   
     .detail-hero h1 {
       font-size: 14px;
     }
   
     .detail-hero p {
       font-size: 11px;
     }
   }
   /* ปรับหน้ารายละเอียดทั้ง 7 หมวด */

.detail-hero {
     position: relative;
     width: 100%;
     height: auto;
     min-height: 280px;
     aspect-ratio: auto;
     padding: 28px;
     display: flex;
     align-items: center;
     background-size: auto 100%;
     background-position: right center;
     background-repeat: no-repeat;
     border-radius: 22px;
     overflow: hidden;
     isolation: isolate;
   }
   
   /* พื้นหลังรองข้อความ */
   
   .detail-hero::before {
     content: "";
     position: absolute;
     inset: 0;
     background: linear-gradient(
       to right,
       #faf8f5 0%,
       #faf8f5 35%,
       transparent 65%
     );
     z-index: -1;
   }
   
   /* ซ่อนไอคอนเฉพาะหน้ารายละเอียด */
   
   .detail-hero .care-icon {
     display: none;
   }
   
   /* จัดตำแหน่งข้อความ */
   
   .detail-hero .hero-content {
     width: 52%;
     max-width: 52%;
     margin: 0;
     padding: 0;
     text-align: left;
   }
   
   .detail-hero h1 {
     font-size: clamp(22px, 2.6vw, 30px);
     line-height: 1.45;
     margin: 0 0 12px;
     color: #405c4b;
   }
   
   .detail-hero p {
     font-size: 16px;
     line-height: 1.8;
     margin: 0;
     color: #52665b;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
   
     .detail-hero {
       display: block;
       height: auto;
       min-height: 0;
       aspect-ratio: auto;
       padding: calc((100vw - 32px) / 3)
                18px 20px;
       background-size: 100% auto;
       background-position: top center;
       background-color: #f4f0f7;
       border-radius: 18px;
     }
   
     .detail-hero::before {
       display: none;
     }
   
     .detail-hero .hero-content {
       width: 100%;
       max-width: 100%;
       margin: 0;
       padding: 12px 0 0;
       text-align: left;
     }
   
     .detail-hero h1 {
       font-size: 21px;
       line-height: 1.5;
       margin-bottom: 8px;
     }
   
     .detail-hero p {
       font-size: 15px;
       line-height: 1.7;
     }
   }
   /* ตกแต่งการ์ดหัวข้อการดูแล */

.page:has(.detail-hero) .topic-list {
     display: grid;
     gap: 14px;
   }
   
   .page:has(.detail-hero) .topic-card {
     background: #ffffff;
     border: 1px solid #e1e6e0;
     border-radius: 16px;
     overflow: hidden;
     box-shadow: 0 3px 10px #00000006;
   }
   
   /* รูปแบบหัวข้อ */
   
   .page:has(.detail-hero) .topic-card summary {
     display: flex;
     align-items: center;
     justify-content: space-between;
     gap: 12px;
     padding: 18px 20px;
     font-size: 16px;
     font-weight: 600;
     line-height: 1.6;
     color: #40554b;
     cursor: pointer;
     list-style: none;
   }
   
   /* ซ่อนลูกศรเดิม */
   
   .page:has(.detail-hero) summary::-webkit-details-marker {
     display: none;
   }
   
   /* สีพาสเทลสลับกัน */
   
   .page:has(.detail-hero) .topic-card:nth-child(4n+1) summary {
     background: #e7f0e9;
   }
   
   .page:has(.detail-hero) .topic-card:nth-child(4n+2) summary {
     background: #eee7f5;
   }
   
   .page:has(.detail-hero) .topic-card:nth-child(4n+3) summary {
     background: #f8efdf;
   }
   
   .page:has(.detail-hero) .topic-card:nth-child(4n+4) summary {
     background: #f5e5eb;
   }
   
   /* ลูกศรแบบใหม่ */
   
   .page:has(.detail-hero) .topic-card summary::after {
     content: "";
     width: 8px;
     height: 8px;
     flex-shrink: 0;
     border-right: 2px solid #648773;
     border-bottom: 2px solid #648773;
     transform: rotate(45deg);
     transition: transform 0.25s ease;
     margin-right: 4px;
   }
   
   .page:has(.detail-hero) .topic-card[open] summary::after {
     transform: rotate(225deg);
   }
   
   /* เนื้อหาด้านใน */
   
   .page:has(.detail-hero) .topic-content {
     background: #ffffff;
     padding: 20px;
     font-size: 16px;
     line-height: 1.8;
     color: #46534b;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .page:has(.detail-hero) .topic-card summary {
       font-size: 15px;
       padding: 16px;
     }
   
     .page:has(.detail-hero) .topic-content {
       font-size: 15px;
       padding: 16px;
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .page:has(.detail-hero) .topic-card summary::after {
       transition: none;
     }
   }
   /* ตกแต่งกล่องข้อควรระวัง */

.page:has(.detail-hero) .notice {
     background: #fff3df;
     border: 1px solid #eddbb9;
     border-radius: 20px;
     padding: 22px;
     margin-top: 20px;
     box-shadow: 0 4px 12px rgba(161, 123, 66, 0.07);
     color: #796344;
   }
   
   .page:has(.detail-hero) .notice strong {
     display: flex;
     align-items: center;
     gap: 12px;
     font-size: 18px;
     color: #80613c;
     margin-bottom: 12px;
   }
   
   .page:has(.detail-hero) .notice strong::before {
     content: "⚠";
     display: inline-flex;
     align-items: center;
     justify-content: center;
     width: 38px;
     height: 38px;
     flex-shrink: 0;
     background: #f7e2bc;
     color: #a17b42;
     border-radius: 12px;
     font-size: 22px;
   }
   
   .page:has(.detail-hero) .notice p {
     font-size: 16px;
     line-height: 1.8;
     margin: 0;
     color: #796344;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .page:has(.detail-hero) .notice {
       padding: 18px;
       border-radius: 16px;
     }
   
     .page:has(.detail-hero) .notice strong {
       font-size: 17px;
     }
   
     .page:has(.detail-hero) .notice p {
       font-size: 15px;
     }
   }
   /* ตกแต่งกล่องสิ่งที่ควรสังเกตหลังการดูแล */

.page:has(.detail-hero) .notice + .guide-panel {
     background: #e7f0e9;
     border: 1px solid #d6e5d8;
     border-radius: 20px;
     padding: 22px;
     margin-top: 20px;
     box-shadow: 0 4px 12px rgba(82, 123, 97, 0.07);
   }
   
   .page:has(.detail-hero) .notice + .guide-panel h2 {
     display: flex;
     align-items: center;
     gap: 12px;
     font-size: 18px;
     line-height: 1.5;
     color: #42664f;
     margin: 0 0 12px;
   }
   
   .page:has(.detail-hero) .notice + .guide-panel h2::before {
     content: "✓";
     display: inline-flex;
     align-items: center;
     justify-content: center;
     width: 38px;
     height: 38px;
     flex-shrink: 0;
     background: #cfe2d4;
     color: #527b61;
     border-radius: 12px;
     font-size: 22px;
   }
   
   .page:has(.detail-hero) .notice + .guide-panel p {
     font-size: 16px;
     line-height: 1.8;
     color: #52665b;
     margin: 0;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .page:has(.detail-hero) .notice + .guide-panel {
       padding: 18px;
       border-radius: 16px;
     }
   
     .page:has(.detail-hero) .notice + .guide-panel h2 {
       font-size: 17px;
     }
   
     .page:has(.detail-hero) .notice + .guide-panel p {
       font-size: 15px;
     }
   }
   /* Soft Hover หน้ารายละเอียดการดูแล */

.page:has(.detail-hero) .topic-card {
     transition: transform 0.2s ease,
                 box-shadow 0.2s ease;
   }
   
   /* ลูกเล่นเมื่อใช้เมาส์ */
   
   @media (hover: hover) and (pointer: fine) {
     .page:has(.detail-hero) .topic-card:not([open]):hover {
       transform: translateY(-3px);
       box-shadow: 0 7px 15px rgba(66, 102, 79, 0.12);
     }
   }
   
   /* ลูกเล่นเมื่อกดหรือสัมผัส */
   
   .page:has(.detail-hero) .topic-card summary {
     transition: transform 0.15s ease;
   }
   
   .page:has(.detail-hero) .topic-card summary:active {
     transform: scale(0.985);
   }
   
   /* รองรับผู้ที่ไม่ต้องการภาพเคลื่อนไหว */
   
   @media (prefers-reduced-motion: reduce) {
     .page:has(.detail-hero) .topic-card,
     .page:has(.detail-hero) .topic-card summary {
       transition: none;
       transform: none !important;
     }
   }
   /* Smooth Accordion */

.page:has(.detail-hero)
.topic-card[open] .topic-content {
  animation: careContentFade 0.35s ease-out;
}

@keyframes careContentFade {
  from {
    opacity: 0;
    transform: translateY(-7px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* รองรับผู้ที่ไม่ต้องการภาพเคลื่อนไหว */

@media (prefers-reduced-motion: reduce) {
  .page:has(.detail-hero)
  .topic-card[open] .topic-content {
    animation: none;
  }
}
/* Fade In ตอนเข้าหน้ารายละเอียด */

.page:has(.detail-hero) {
     animation: carePageFade 0.5s ease-out;
   }
   
   @keyframes carePageFade {
     from {
       opacity: 0;
       transform: translateY(8px);
     }
   
     to {
       opacity: 1;
       transform: translateY(0);
     }
   }
   
   /* รองรับผู้ที่ไม่ต้องการภาพเคลื่อนไหว */
   
   @media (prefers-reduced-motion: reduce) {
     .page:has(.detail-hero) {
       animation: none;
     }
   }
/* แบนเนอร์หน้าฉุกเฉิน */

.emergency-hero {
     background: #f9e9ed;
     border-radius: 22px;
     overflow: hidden;
     margin-bottom: 24px;
   }
   
   .emergency-banner {
     display: block;
     width: 100%;
     height: auto;
   }
   
   .emergency-heading {
     padding: 24px 28px;
   }
   
   .emergency-heading h2 {
     font-size: clamp(24px, 3vw, 32px);
     color: #99515e;
     font-weight: 700;
     line-height: 1.4;
     margin: 0 0 8px;
   }
   
   .emergency-heading p {
     font-size: 16px;
     line-height: 1.8;
     color: #79575d;
     margin: 0;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .emergency-hero {
       border-radius: 18px;
       margin-bottom: 18px;
     }
   
     .emergency-heading {
       padding: 16px 18px 20px;
     }
   
     .emergency-heading h2 {
       font-size: 24px;
     }
   
     .emergency-heading p {
       font-size: 15px;
     }
   }
   /* จัดวางแบนเนอร์ฉุกเฉินแบบใหม่ */

.emergency-hero {
     position: relative;
     background: #faf8f5;
     border-radius: 22px;
     overflow: hidden;
     margin-bottom: 24px;
   }
   
   .emergency-banner {
     display: block;
     width: 100%;
     height: auto;
   }
   
   .emergency-heading {
     position: absolute;
     top: 50%;
     left: 5%;
     transform: translateY(-50%);
     width: 36%;
     padding: 0;
   }
   
   .emergency-heading h2 {
     font-size: clamp(22px, 2.8vw, 32px);
     color: #99515e;
     margin-bottom: 8px;
   }
   
   .emergency-heading p {
     font-size: 16px;
     line-height: 1.7;
     color: #79575d;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .emergency-heading {
       position: static;
       transform: none;
       width: 100%;
       padding: 16px 18px 20px;
     }
   
     .emergency-heading h2 {
       font-size: 24px;
     }
   
     .emergency-heading p {
       font-size: 15px;
     }
   }
   /* ปรับขนาดตัวอักษรแบนเนอร์ฉุกเฉิน */

.emergency-heading h2 {
     font-size: clamp(24px, 2.6vw, 32px);
     font-weight: 700;
     line-height: 1.4;
     margin-bottom: 8px;
   }
   
   .emergency-heading p {
     font-size: clamp(16px, 1.5vw, 18px);
     line-height: 1.7;
     overflow-wrap: break-word;
     margin: 0;
   }
   
   /* สำหรับ iPad และแท็บเล็ต */
   
   @media (min-width: 601px) and (max-width: 1100px) {
     .emergency-heading {
       left: 5%;
       width: 36%;
     }
   
     .emergency-heading h2 {
       font-size: clamp(24px, 2.7vw, 28px);
     }
   
     .emergency-heading p {
       font-size: 16px;
     }
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .emergency-heading {
       position: static;
       transform: none;
       width: 100%;
       padding: 16px 18px 20px;
     }
   
     .emergency-heading h2 {
       font-size: clamp(22px, 5.5vw, 24px);
       margin-bottom: 6px;
     }
   
     .emergency-heading p {
       font-size: 16px;
       line-height: 1.7;
     }
   }
   
   /* แท็บเล็ตขนาดเล็ก ป้องกันข้อความล้นรูป */
   
   @media (min-width: 601px) and (max-width: 767px) {
     .emergency-heading {
       position: static;
       transform: none;
       width: 100%;
       padding: 18px 20px;
     }
   }
   /* ปรับการจัดวางแบนเนอร์ฉุกเฉิน */

.emergency-hero {
     position: relative;
     border-radius: 22px;
     overflow: hidden;
     margin-top: 0;
     margin-bottom: 20px;
     background: #faf8f5;
   }
   
   .emergency-banner {
     display: block;
     width: 100%;
     height: auto;
     aspect-ratio: 2.8 / 1;
     object-fit: cover;
     object-position: center;
   }
   
   .emergency-heading {
     position: absolute;
     top: 50%;
     left: 5%;
     transform: translateY(-50%);
     width: 37%;
     padding: 0;
     text-align: left;
   }
   
   .emergency-heading h2 {
     font-size: clamp(28px, 3.5vw, 42px);
     font-weight: 700;
     line-height: 1.3;
     color: #87404e;
     margin: 0 0 12px;
   }
   
   .emergency-heading p {
     font-size: clamp(17px, 1.9vw, 22px);
     font-weight: 500;
     line-height: 1.6;
     color: #67434c;
     margin: 0;
   }
   
   /* สำหรับ iPad และแท็บเล็ต */
   
   @media (min-width: 768px) and (max-width: 1100px) {
     .emergency-heading h2 {
       font-size: 34px;
     }
   
     .emergency-heading p {
       font-size: 18px;
     }
   }
   
   /* สำหรับโทรศัพท์และหน้าจอขนาดเล็ก */
   
   @media (max-width: 767px) {
     .emergency-hero {
       border-radius: 18px;
       background: #f9e9ed;
     }
   
     .emergency-banner {
       aspect-ratio: auto;
       height: auto;
       object-fit: contain;
     }
   
     .emergency-heading {
       position: static;
       transform: none;
       width: 100%;
       padding: 18px 20px 22px;
     }
   
     .emergency-heading h2 {
       font-size: 28px;
       margin-bottom: 8px;
     }
   
     .emergency-heading p {
       font-size: 17px;
       line-height: 1.7;
     }
   }
   /* กล่องแจ้งเหตุฉุกเฉิน */

.emergency-alert {
     background: #fbe8eb;
     border: 1px solid #e8bfc5;
     border-radius: 22px;
     padding: 26px;
     margin: 20px 0;
     box-shadow: 0 4px 14px rgba(166, 77, 91, 0.08);
   }
   
   .emergency-alert h2 {
     font-size: clamp(20px, 2.4vw, 28px);
     color: #93434c;
     margin: 0 0 14px;
     line-height: 1.5;
   }
   
   .emergency-message {
     font-size: clamp(17px, 1.8vw, 20px);
     font-weight: 500;
     line-height: 1.8;
     color: #79434c;
     margin: 0 0 20px;
   }
   
   /* ปุ่มโทร 1669 */
   
   .emergency-call {
     display: flex;
     flex-direction: column;
     align-items: center;
     justify-content: center;
     gap: 6px;
     background: #b65363;
     color: #ffffff;
     border-radius: 18px;
     padding: 22px 16px;
     text-decoration: none;
     text-align: center;
     box-shadow: 0 4px 10px rgba(166, 77, 91, 0.15);
   }
   
   .emergency-number {
     font-size: clamp(36px, 5vw, 52px);
     font-weight: 700;
     line-height: 1.3;
     color: #ffffff;
   }
   
   .emergency-call-text {
     font-size: clamp(16px, 1.8vw, 19px);
     line-height: 1.6;
     color: #ffffff;
   }
   
   .emergency-hint {
     font-size: 14px;
     color: #87545e;
     text-align: center;
     margin: 12px 0 0;
   }
   
   .emergency-call:focus-visible {
     outline: 3px solid #79434c;
     outline-offset: 4px;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .emergency-alert {
       padding: 18px;
       border-radius: 18px;
     }
   
     .emergency-alert h2 {
       font-size: 22px;
     }
   
     .emergency-message {
       font-size: 16px;
     }
   
     .emergency-call {
       padding: 20px 12px;
     }
   
     .emergency-number {
       font-size: 38px;
     }
   
     .emergency-call-text {
       font-size: 16px;
     }
   }
   /* กล่องสัญญาณอันตราย */

.emergency-signs {
     background: #ffffff;
     border: 1px solid #ead4da;
     border-radius: 22px;
     padding: 26px;
     margin: 20px 0;
     box-shadow: 0 4px 14px rgba(166, 77, 91, 0.06);
   }
   
   .emergency-signs h2 {
     display: flex;
     align-items: center;
     gap: 12px;
     font-size: clamp(22px, 2.5vw, 28px);
     font-weight: 700;
     line-height: 1.5;
     color: #87404e;
     margin: 0 0 20px;
   }
   
   .emergency-signs h2::before {
     content: "♡";
     display: flex;
     align-items: center;
     justify-content: center;
     width: 44px;
     height: 44px;
     flex-shrink: 0;
     background: #f5dce3;
     border-radius: 12px;
     color: #a64d5b;
     font-size: 30px;
   }
   
   /* รายการสัญญาณอันตราย */
   
   .emergency-sign-list {
     display: grid;
     gap: 12px;
     list-style: none;
     padding: 0;
     margin: 0;
   }
   
   .emergency-sign-list li {
     display: flex;
     align-items: center;
     gap: 12px;
     background: #fcf0f2;
     border: 1px solid #f3dfe4;
     border-radius: 14px;
     padding: 16px 18px;
     font-size: clamp(17px, 1.8vw, 20px);
     font-weight: 500;
     line-height: 1.7;
     color: #69434c;
   }
   
   .emergency-sign-list li::before {
     content: "!";
     display: flex;
     align-items: center;
     justify-content: center;
     width: 24px;
     height: 24px;
     flex-shrink: 0;
     border: 2px solid #b65363;
     border-radius: 50%;
     color: #b65363;
     font-size: 15px;
     font-weight: 700;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
     .emergency-signs {
       padding: 18px;
       border-radius: 18px;
     }
   
     .emergency-signs h2 {
       font-size: 20px;
       gap: 10px;
     }
   
     .emergency-signs h2::before {
       width: 38px;
       height: 38px;
     }
   
     .emergency-sign-list li {
       font-size: 16px;
       padding: 14px 12px;
     }
   }
   /* =========================
   แบนเนอร์หน้าเกี่ยวกับเรา
========================= */

.about-hero {
     position: relative;
     overflow: hidden;
     border-radius: 22px;
     background: #e7efe5;
     margin-bottom: 24px;
   }
   
   .about-banner {
     display: block;
     width: 100%;
     height: auto;
   }
   
   .about-heading {
     position: absolute;
     top: 50%;
     left: 6%;
     transform: translateY(-50%);
     width: 44%;
     text-align: left;
   }
   
   .about-eyebrow {
     font-size: clamp(15px, 1.6vw, 19px);
     font-weight: 500;
     color: #527663;
     margin-bottom: 10px;
   }
   
   .about-heading h1 {
     font-size: clamp(30px, 4vw, 48px);
     font-weight: 700;
     color: #385849;
     line-height: 1.3;
     margin: 0 0 10px;
   }
   
   .about-heading h2 {
     font-size: clamp(18px, 2.2vw, 26px);
     font-weight: 600;
     color: #527663;
     line-height: 1.5;
     margin: 0 0 12px;
   }
   
   .about-heading p {
     font-size: clamp(16px, 1.7vw, 20px);
     color: #52675b;
     line-height: 1.8;
     margin: 0;
   }
   
   /* สำหรับ iPad */
   
   @media (min-width: 768px) and (max-width: 1100px) {
   
     .about-heading {
       left: 5%;
       width: 45%;
     }
   
     .about-heading h1 {
       font-size: 36px;
     }
   
     .about-heading h2 {
       font-size: 21px;
     }
   
     .about-heading p {
       font-size: 17px;
     }
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
   
     .about-hero {
       border-radius: 18px;
     }
   
     .about-heading {
       position: static;
       transform: none;
       width: 100%;
       padding: 22px 20px 26px;
       box-sizing: border-box;
     }
   
     .about-eyebrow {
       font-size: 15px;
     }
   
     .about-heading h1 {
       font-size: 32px;
     }
   
     .about-heading h2 {
       font-size: 21px;
     }
   
     .about-heading p {
       font-size: 17px;
       line-height: 1.8;
     }
   }
/* =========================
   ความตั้งใจของเรา
========================= */

.about-mission {
     background: #ffffff;
     border-radius: 22px;
     padding: 28px;
     margin: 20px 0;
     box-shadow: 0 4px 16px rgba(82, 118, 99, 0.05);
   }
   
   .about-mission h2 {
     display: flex;
     align-items: center;
     gap: 12px;
     font-size: clamp(22px, 2.5vw, 28px);
     font-weight: 700;
     color: #456957;
     line-height: 1.5;
     margin: 0 0 12px;
   }
   
   .about-mission h2 svg {
     width: 30px;
     height: 30px;
     flex-shrink: 0;
     color: #65927b;
   }
   
   .about-mission p {
     font-size: clamp(17px, 1.8vw, 20px);
     line-height: 1.8;
     color: #58645c;
     margin: 0;
   }
   
   /* =========================
      กล่องคุณค่าของอุ่นใจ Care
   ========================= */
   
   .about-values {
     display: grid;
     grid-template-columns: repeat(2, minmax(0, 1fr));
     gap: 16px;
     margin: 20px 0;
   }
   
   .about-value {
     border-radius: 22px;
     padding: 28px 20px;
     text-align: center;
     display: flex;
     flex-direction: column;
     align-items: center;
     justify-content: center;
   }
   
   .value-knowledge {
     background: #eee8f5;
     color: #74628c;
   }
   
   .value-care {
     background: #f5e3e7;
     color: #995f72;
   }
   
   .about-value svg {
     width: 36px;
     height: 36px;
     margin-bottom: 16px;
   }
   
   .about-value h3 {
     font-size: clamp(19px, 2.2vw, 25px);
     font-weight: 600;
     line-height: 1.5;
     color: inherit;
     margin: 0 0 6px;
   }
   
   .about-value p {
     font-size: clamp(16px, 1.7vw, 19px);
     line-height: 1.7;
     color: inherit;
     margin: 0;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
   
     .about-mission {
       padding: 20px;
       border-radius: 18px;
     }
   
     .about-mission h2 {
       font-size: 22px;
     }
   
     .about-mission p {
       font-size: 17px;
     }
   
     .about-values {
       grid-template-columns: 1fr;
       gap: 12px;
     }
   
     .about-value {
       padding: 24px 16px;
       border-radius: 18px;
     }
   
     .about-value h3 {
       font-size: 21px;
     }
   
     .about-value p {
       font-size: 16px;
     }
   }
   /* =========================
   ข้อมูลโครงการนวัตกรรม
========================= */

.about-project {
     background: #ffffff;
     border: 1px solid #dce6db;
     border-radius: 22px;
     padding: 28px;
     margin: 20px 0;
     box-shadow: 0 4px 16px rgba(82, 118, 99, 0.05);
   }
   
   .about-project h2 {
     display: flex;
     align-items: center;
     gap: 14px;
     font-size: clamp(22px, 2.5vw, 28px);
     font-weight: 700;
     line-height: 1.5;
     color: #456957;
     margin: 0 0 20px;
   }
   
   .about-project-icon {
     display: flex;
     align-items: center;
     justify-content: center;
     width: 48px;
     height: 48px;
     flex-shrink: 0;
     border-radius: 14px;
     background: #e5eee5;
     color: #527663;
   }
   
   .about-project-icon svg {
     width: 30px;
     height: 30px;
   }
   
   .about-project-info {
     border-top: 1px solid #e1e8df;
     padding: 20px 0;
   }
   
   .about-project-info:last-child {
     padding-bottom: 0;
   }
   
   .about-project-info h3 {
     font-size: clamp(16px, 1.7vw, 19px);
     font-weight: 600;
     color: #527663;
     margin: 0 0 12px;
   }
   
   .about-course-code {
     font-size: clamp(23px, 2.5vw, 28px);
     font-weight: 700;
     color: #385849;
     margin: 0 0 6px;
   }
   
   .about-course-name {
     font-size: clamp(18px, 2vw, 22px);
     font-weight: 500;
     color: #456957;
     line-height: 1.7;
     margin: 0 0 4px;
   }
   
   .about-course-en {
     font-size: clamp(15px, 1.6vw, 18px);
     color: #718377;
     line-height: 1.7;
     margin: 0;
   }
   
   .about-developer {
     font-size: clamp(17px, 1.8vw, 20px);
     font-weight: 400;
     color: #456957;
     line-height: 1.8;
     margin: 0;
     white-space: normal;
     overflow-wrap: break-word;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 600px) {
   
     .about-project {
       padding: 20px;
       border-radius: 18px;
     }
   
     .about-project h2 {
       font-size: 21px;
       gap: 10px;
     }
   
     .about-project-icon {
       width: 40px;
       height: 40px;
     }
   
     .about-project-icon svg {
       width: 26px;
       height: 26px;
     }
   
     .about-course-code {
       font-size: 24px;
     }
   
     .about-course-name {
       font-size: 18px;
     }
   
     .about-course-en {
       font-size: 15px;
     }
   
     .about-developer {
       font-size: 17px;
     }
   }
   /* =========================
   ลูกเล่นแบนเนอร์หน้าหลัก
========================= */

.home-hero {
     position: relative;
     isolation: isolate;
   }
   
   /* หัวใจลอยดุ๊กดิ๊ก */
   
   .home-hero::before {
     content: "♡";
     position: absolute;
     top: 30%;
     right: 38%;
     font-size: clamp(20px, 3vw, 36px);
     font-weight: 600;
     color: #d995ae;
     pointer-events: none;
     z-index: 2;
     animation: aunjaiHeart 3s ease-in-out infinite;
   }
   
   /* ประกายวิบวับ */
   
   .home-hero::after {
     content: "✦";
     position: absolute;
     top: 12%;
     right: 8%;
     font-size: clamp(18px, 3vw, 32px);
     color: #d7b66e;
     pointer-events: none;
     z-index: 2;
     animation: aunjaiSparkle 2.5s ease-in-out infinite;
   }
   
   /* การเคลื่อนไหวของหัวใจ */
   
   @keyframes aunjaiHeart {
     0%, 100% {
       transform: translateY(0) rotate(-10deg);
       opacity: 0.65;
     }
   
     50% {
       transform: translateY(-9px) rotate(8deg);
       opacity: 1;
     }
   }
   
   /* การเคลื่อนไหวของประกาย */
   
   @keyframes aunjaiSparkle {
     0%, 100% {
       transform: scale(0.7);
       opacity: 0.25;
     }
   
     50% {
       transform: scale(1.2);
       opacity: 1;
     }
   }
   
   /* ปรับตำแหน่งสำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
     .home-hero::before {
       top: 12%;
       right: 38%;
       font-size: 24px;
     }
   
     .home-hero::after {
       top: 8%;
       right: 8%;
       font-size: 22px;
     }
   }
   
   /* รองรับผู้ที่ไม่ต้องการภาพเคลื่อนไหว */
   
   @media (prefers-reduced-motion: reduce) {
     .home-hero::before,
     .home-hero::after {
       animation: none;
     }
   }
   /* เพิ่มความชัดของหัวใจและประกายดาว */

.home-hero::before {
     top: 18%;
     right: 40%;
     font-size: clamp(30px, 4vw, 48px);
     color: #d57599;
     text-shadow: 0 0 8px #ffffff;
     animation: aunjaiHeart 2.6s ease-in-out infinite;
   }
   
   .home-hero::after {
     top: 10%;
     right: 8%;
     font-size: clamp(28px, 4vw, 46px);
     color: #d9ad50;
     text-shadow:
       0 0 10px #ffe7a1,
       0 0 4px #ffffff;
     animation: aunjaiSparkle 1.9s ease-in-out infinite;
   }
   
   @keyframes aunjaiHeart {
     0%, 100% {
       transform: translateY(5px) rotate(-12deg);
       opacity: 0.85;
     }
   
     50% {
       transform: translateY(-15px) rotate(12deg);
       opacity: 1;
     }
   }
   
   @keyframes aunjaiSparkle {
     0%, 100% {
       transform: scale(0.8);
       opacity: 0.7;
     }
   
     50% {
       transform: scale(1.3);
       opacity: 1;
     }
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
     .home-hero::before {
       top: 10%;
       right: 40%;
       font-size: 32px;
     }
   
     .home-hero::after {
       top: 8%;
       right: 8%;
       font-size: 30px;
     }
   }
   
   /* ลดการเคลื่อนไหวตามการตั้งค่าของผู้ใช้ */
   
   @media (prefers-reduced-motion: reduce) {
     .home-hero::before,
     .home-hero::after {
       animation: none;
     }
   }
   /* =========================
   หัวใจและประกายวิบวับ
========================= */

/* ปิดลูกเล่นสองดวงแบบเดิม */

.home-hero::before,
.home-hero::after {
  content: none;
}

/* พื้นที่สำหรับลูกเล่น */

.home-hero {
  position: relative;
  overflow: hidden;
}

.home-effects {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
}

.floating-heart,
.floating-star {
  position: absolute;
  display: block;
  line-height: 1;
  font-weight: 700;
}

/* หัวใจสีชมพู */

.floating-heart {
  color: #dc82a4;
  text-shadow: 0 0 6px #ffffff;
  animation: homeHeartFloat 3s ease-in-out infinite;
}

.heart-1 {
  top: 17%;
  right: 36%;
  font-size: 42px;
}

.heart-2 {
  top: 43%;
  right: 7%;
  font-size: 25px;
  animation-delay: -1s;
}

.heart-3 {
  top: 66%;
  right: 34%;
  font-size: 32px;
  animation-delay: -2s;
}

/* ประกายดาวสีทอง */

.floating-star {
  color: #d8ad50;
  text-shadow:
    0 0 8px #fff5cc,
    0 0 5px #ffffff;
  animation: homeStarTwinkle 2.5s ease-in-out infinite;
}

.star-1 {
  top: 10%;
  right: 12%;
  font-size: 38px;
}

.star-2 {
  top: 9%;
  right: 29%;
  font-size: 28px;
  animation-delay: -0.6s;
}

.star-3 {
  top: 58%;
  right: 5%;
  font-size: 30px;
  animation-delay: -1.2s;
}

.star-4 {
  top: 81%;
  right: 22%;
  font-size: 24px;
  animation-delay: -1.8s;
}

/* หัวใจลอยขึ้นลง */

@keyframes homeHeartFloat {
  0%, 100% {
    transform: translateY(5px) rotate(-12deg);
    opacity: 0.65;
  }

  50% {
    transform: translateY(-18px) rotate(12deg);
    opacity: 1;
  }
}

/* ดาววิบวับ */

@keyframes homeStarTwinkle {
  0%, 100% {
    transform: scale(0.65);
    opacity: 0.4;
  }

  50% {
    transform: scale(1.25);
    opacity: 1;
  }
}

/* สำหรับโทรศัพท์ */

@media (max-width: 767px) {

  .floating-heart {
    font-size: 25px;
  }

  .floating-star {
    font-size: 23px;
  }

  .heart-1 {
    top: 12%;
    right: 38%;
  }

  .heart-2 {
    top: 25%;
    right: 7%;
  }

  .star-1 {
    top: 5%;
    right: 10%;
  }

  .star-2 {
    top: 5%;
    right: 32%;
  }

  .heart-3,
  .star-3,
  .star-4 {
    display: none;
  }
}

/* รองรับผู้ที่ไม่ต้องการภาพเคลื่อนไหว */

@media (prefers-reduced-motion: reduce) {
  .floating-heart,
  .floating-star {
    animation: none;
  }
}
/* =========================
   ช่องค้นหาหน้าหลัก
========================= */

.home-search {
     margin: 24px 0 28px;
   }
   
   .search-box {
     display: flex;
     align-items: center;
     gap: 14px;
     padding: 16px 20px;
     background: #ffffff;
     border: 1.5px solid #d2e0d4;
     border-radius: 18px;
     box-shadow: 0 4px 15px rgba(82, 118, 99, 0.07);
     transition: border-color 0.2s, box-shadow 0.2s;
   }
   
   .search-box svg {
     width: 26px;
     height: 26px;
     color: #527663;
     flex-shrink: 0;
   }
   
   .search-box input {
     width: 100%;
     min-width: 0;
     border: none;
     outline: none;
     background: transparent;
     font-family: inherit;
     font-size: 18px;
     color: #385849;
   }
   
   .search-box input::placeholder {
     color: #788b7e;
   }
   
   .search-box:focus-within {
     border-color: #83ad91;
     box-shadow: 0 0 0 4px rgba(131, 173, 145, 0.15);
   }
   
   .search-label {
     font-size: 15px;
     color: #627b6a;
     margin: 14px 0 10px;
   }
   
   .search-suggestions {
     display: flex;
     flex-wrap: wrap;
     gap: 8px;
   }
   
   .search-suggestions button {
     border: 1px solid #dce7dc;
     background: #e7efe5;
     color: #456957;
     border-radius: 30px;
     padding: 9px 16px;
     font-family: inherit;
     font-size: 15px;
     cursor: pointer;
     transition: background 0.2s, transform 0.2s;
   }
   
   .search-suggestions button:hover {
     background: #d5e5d6;
     transform: translateY(-2px);
   }
   
   .search-suggestions button:active {
     transform: scale(0.96);
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
     .home-search {
       margin: 18px 0 24px;
     }
   
     .search-box {
       padding: 14px;
       border-radius: 15px;
       gap: 10px;
     }
   
     .search-box input {
       font-size: 16px;
     }
   
     .search-box svg {
       width: 22px;
       height: 22px;
     }
   
     .search-suggestions button {
       font-size: 14px;
       padding: 8px 13px;
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .search-box,
     .search-suggestions button {
       transition: none;
     }
   
     .search-suggestions button:hover,
     .search-suggestions button:active {
       transform: none;
     }
   }
   /* =========================
   ผลการค้นหา
========================= */

#searchResults {
     margin-top: 18px;
   }
   
   #searchResults[hidden] {
     display: none;
   }
   
   .search-count {
     color: #527663;
     font-size: 16px;
     font-weight: 600;
     margin-bottom: 12px;
   }
   
   .search-result {
     display: flex;
     align-items: center;
     gap: 14px;
     width: 100%;
     padding: 16px;
     margin-bottom: 10px;
     background: #ffffff;
     border: 1px solid #dce6db;
     border-radius: 16px;
     font-family: inherit;
     text-align: left;
     cursor: pointer;
     transition: background 0.2s;
   }
   
   .search-result:hover {
     background: #edf4eb;
   }
   
   .search-result-icon {
     display: flex;
     align-items: center;
     justify-content: center;
     width: 48px;
     height: 48px;
     flex-shrink: 0;
     border-radius: 14px;
     background: #e7efe5;
     font-size: 26px;
   }
   
   .search-result-text {
     flex: 1;
     min-width: 0;
   }
   
   .search-result-text strong {
     display: block;
     font-size: 18px;
     color: #385849;
     line-height: 1.5;
   }
   
   .search-result-text small {
     display: block;
     font-size: 14px;
     color: #718377;
     margin-top: 5px;
   }
   
   .search-result-arrow {
     color: #527663;
     font-size: 24px;
   }
   
   .search-empty {
     padding: 28px 20px;
     text-align: center;
     background: #ffffff;
     border-radius: 18px;
     color: #527663;
   }
   
   .search-empty span {
     font-size: 40px;
     color: #d995ae;
   }
   
   .search-empty h3 {
     margin: 8px 0;
   }
   
   .search-empty p {
     font-size: 16px;
   }
   
   .topic-card {
     scroll-margin-top: 100px;
   }
   
   @media (max-width: 767px) {
   
     .search-result {
       padding: 13px;
       gap: 10px;
     }
   
     .search-result-text strong {
       font-size: 16px;
     }
   
     .search-result-text small {
       font-size: 13px;
     }
   
     .search-result-icon {
       width: 42px;
       height: 42px;
       font-size: 23px;
     }
   
   }
   /* =========================
   ผลการค้นหา
========================= */

#searchResults {
     margin-top: 18px;
   }
   
   #searchResults[hidden] {
     display: none;
   }
   
   .search-count {
     color: #527663;
     font-size: 16px;
     font-weight: 600;
     margin-bottom: 12px;
   }
   
   .search-result {
     display: flex;
     align-items: center;
     gap: 14px;
     width: 100%;
     padding: 16px;
     margin-bottom: 10px;
     background: #ffffff;
     border: 1px solid #dce6db;
     border-radius: 16px;
     font-family: inherit;
     text-align: left;
     cursor: pointer;
     transition: background 0.2s;
   }
   
   .search-result:hover {
     background: #edf4eb;
   }
   
   .search-result-icon {
     display: flex;
     align-items: center;
     justify-content: center;
     width: 48px;
     height: 48px;
     flex-shrink: 0;
     border-radius: 14px;
     background: #e7efe5;
     font-size: 26px;
   }
   
   .search-result-text {
     flex: 1;
     min-width: 0;
   }
   
   .search-result-text strong {
     display: block;
     font-size: 18px;
     color: #385849;
     line-height: 1.5;
   }
   
   .search-result-text small {
     display: block;
     font-size: 14px;
     color: #718377;
     margin-top: 5px;
   }
   
   .search-result-arrow {
     color: #527663;
     font-size: 24px;
   }
   
   .search-empty {
     padding: 28px 20px;
     text-align: center;
     background: #ffffff;
     border-radius: 18px;
     color: #527663;
   }
   
   .search-empty span {
     font-size: 40px;
     color: #d995ae;
   }
   
   .search-empty h3 {
     margin: 8px 0;
   }
   
   .search-empty p {
     font-size: 16px;
   }
   
   .topic-card {
     scroll-margin-top: 100px;
   }
   
   @media (max-width: 767px) {
   
     .search-result {
       padding: 13px;
       gap: 10px;
     }
   
     .search-result-text strong {
       font-size: 16px;
     }
   
     .search-result-text small {
       font-size: 13px;
     }
   
     .search-result-icon {
       width: 42px;
       height: 42px;
       font-size: 23px;
     }
   
   }
   /* ตำแหน่งหัวใจและดาวรอบตัวน้องบนมือถือ */

@media (max-width: 767px) {

     .home-hero .heart-1 {
       top: 48%;
       right: 48%;
       font-size: 28px;
     }
   
     .home-hero .heart-2 {
       top: 61%;
       right: 5%;
       font-size: 24px;
     }
   
     .home-hero .star-1 {
       top: 43%;
       right: 7%;
       font-size: 26px;
     }
   
     .home-hero .star-2 {
       top: 76%;
       right: 43%;
       font-size: 23px;
     }
   
     @keyframes homeHeartFloat {
       0%, 100% {
         transform: translateY(3px) rotate(-8deg);
         opacity: 0.75;
       }
   
       50% {
         transform: translateY(-5px) rotate(8deg);
         opacity: 1;
       }
     }
   
   }
   /* จัดลูกเล่นบนโทรศัพท์ใหม่ */

@media (max-width: 767px) {

     .home-hero .heart-1 {
       display: none;
     }
   
     .home-hero .heart-2 {
       top: 66%;
       right: 5%;
       font-size: 22px;
     }
   
     .home-hero .star-1 {
       top: 33%;
       right: 14%;
       font-size: 24px;
     }
   
     .home-hero .star-2 {
       top: 79%;
       right: 15%;
       font-size: 20px;
     }
   
     .home-hero .floating-heart {
       animation-name: mobileHeartFloat;
     }
   
   }
   
   @keyframes mobileHeartFloat {
     0%, 100% {
       transform: translateY(0);
       opacity: 0.7;
     }
   
     50% {
       transform: translateY(-5px);
       opacity: 1;
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .home-hero .floating-heart {
       animation: none;
     }
   }
   /* น้องอุ่นใจเฝ้าช่องค้นหา */

.home-search {
     padding-top: 100px;
   }
   
   .search-box {
     position: relative;
     overflow: visible;
   }
   
   .search-mascot {
     position: absolute;
     width: 230px;
     height: auto;
     right: 0;
     bottom: calc(100% - 18px);
     z-index: 2;
     pointer-events: none;
     transform-origin: center bottom;
     animation: mascotWiggle 3s ease-in-out infinite;
   }
   
   /* ขยับดุ๊กดิ๊ก */
   
   @keyframes mascotWiggle {
     0%, 100% {
       transform: translateY(0) rotate(-3deg);
     }
   
     50% {
       transform: translateY(-6px) rotate(3deg);
     }
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
   
     .home-search {
       padding-top: 75px;
     }
   
     .search-mascot {
       width: 175px;
       right: -5px;
       bottom: calc(100% - 14px);
     }
   
   }
   
   /* รองรับผู้ที่ไม่ต้องการภาพเคลื่อนไหว */
   
   @media (prefers-reduced-motion: reduce) {
     .search-mascot {
       animation: none;
     }
   }
   /* จัดช่องค้นหาใหม่ */

.home-search {
     display: flex !important;
     flex-direction: column !important;
     align-items: stretch !important;
     gap: 12px;
     width: 100%;
     padding-top: 85px;
     margin-top: 10px;
     box-sizing: border-box;
     overflow: visible;
   }
   
   .home-search .search-box {
     position: relative;
     width: 100%;
     min-width: 0;
     display: flex;
     align-items: center;
     overflow: visible;
   }
   
   .search-box input {
     flex: 1;
     width: 100%;
     min-width: 0;
     font-size: 16px;
   }
   
   .search-mascot {
     position: absolute;
     width: 150px;
     height: auto;
     right: 15px;
     bottom: calc(100% - 8px);
     max-width: none;
     pointer-events: none;
     z-index: 3;
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
     .home-search {
       padding-top: 65px;
       margin-top: 5px;
       gap: 10px;
     }
   
     .search-mascot {
       width: 130px;
       right: 12px;
       bottom: calc(100% - 6px);
     }
   }
   /* ปรับน้องอุ่นใจให้เกาะขอบช่องค้นหา */

.home-search {
     padding-top: 110px;
     margin-top: 8px;
   }
   
   .home-search .search-box .search-mascot {
     position: absolute;
     width: 260px;
     height: auto;
     max-width: none;
     right: 20px;
     bottom: calc(100% - 12px);
     transform-origin: center bottom;
     animation: searchPeek 3s ease-in-out infinite;
     pointer-events: none;
     z-index: 3;
   }
   
   /* เอียงตัวเบา ๆ ไม่ลอยขึ้นลง */
   
   @keyframes searchPeek {
     0%, 100% {
       transform: rotate(-2deg);
     }
   
     50% {
       transform: rotate(2deg);
     }
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
     .home-search {
       padding-top: 95px;
       margin-top: 5px;
     }
   
     .home-search .search-box .search-mascot {
       width: 200px;
       right: 8px;
       bottom: calc(100% - 10px);
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .home-search .search-box .search-mascot {
       animation: none;
     }
   }
   /* ให้น้องอุ่นใจซ้อนทับขอบช่องค้นหา */

.home-search .search-box {
     position: relative;
     overflow: visible;
   }
   
   .home-search .search-box .search-mascot {
     top: auto !important;
     bottom: calc(100% - 25px) !important;
     right: 20px;
     z-index: 10;
     animation: none;
   }
   
   @media (max-width: 767px) {
     .home-search .search-box .search-mascot {
       bottom: calc(100% - 20px) !important;
       right: 10px;
     }
   }
   /* น้องอุ่นใจดุ๊กดิ๊กเกาะขอบช่องค้นหา */

.home-search .search-box .search-mascot {
     transform-origin: center bottom;
     animation: aunjaiWiggle 2.5s ease-in-out infinite !important;
   }
   
   @keyframes aunjaiWiggle {
     0%, 100% {
       transform: rotate(-4deg);
     }
   
     25% {
       transform: rotate(3deg);
     }
   
     50% {
       transform: rotate(-2deg);
     }
   
     75% {
       transform: rotate(4deg);
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .home-search .search-box .search-mascot {
       animation: none !important;
     }
   }
   /* จัดช่องค้นหาหน้าหลักใหม่ */

.home-search {
     display: block !important;
     margin: 12px 0 24px;
     padding: 35px 0 0 !important;
   }
   
   .home-search .search-box {
     position: relative;
     display: flex;
     align-items: center;
     width: 100%;
     min-height: 64px;
     padding: 14px 18px;
     border: 1.5px solid #a8c3ad;
     border-radius: 22px;
     background: #fff;
     overflow: visible;
     box-shadow: 0 4px 12px rgba(75, 105, 85, 0.07);
   }
   
   .home-search .search-box input {
     flex: 1;
     width: 100%;
     min-width: 0;
     padding-right: 105px;
     font-size: 16px;
     background: transparent;
   }
   
   .home-search .search-box .search-mascot {
     position: absolute;
     width: 220px;
     height: auto;
     right: 0;
     top: auto !important;
     bottom: -12px !important;
     z-index: 10;
     pointer-events: none;
     transform-origin: center bottom;
     animation: aunjaiWiggle 2.5s ease-in-out infinite !important;
   }
   
   /* โทรศัพท์ */
   
   @media (max-width: 767px) {
     .home-search {
       margin-top: 8px;
       padding-top: 25px !important;
     }
   
     .home-search .search-box {
       min-height: 58px;
       border-radius: 18px;
       padding: 12px;
     }
   
     .home-search .search-box input {
       font-size: 16px;
       padding-right: 80px;
     }
   
     .home-search .search-box .search-mascot {
       width: 170px;
       right: -5px;
       bottom: -10px !important;
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .home-search .search-box .search-mascot {
       animation: none !important;
     }
   }
   /* ขยับน้องอุ่นใจให้ชิดริมขวา */

.home-search .search-box .search-mascot {
     right: -25px !important;
   }
   
   @media (max-width: 767px) {
     .home-search .search-box .search-mascot {
       right: -30px !important;
     }
   }
   /* ตกแต่งการ์ดหมวดหมู่หน้าหลัก */

.page:has(.home-hero) .care-grid {
     display: grid;
     grid-template-columns: repeat(2, minmax(0, 1fr));
     gap: 16px;
   }
   
   .page:has(.home-hero) .care-card {
     border-radius: 22px;
     padding: 20px 16px;
     border: 1px solid rgba(110, 145, 120, 0.15);
     box-shadow: 0 4px 12px rgba(65, 90, 75, 0.07);
     transition: transform 0.25s ease,
                 box-shadow 0.25s ease;
   }
   
   .page:has(.home-hero) .care-text {
     min-width: 0;
     line-height: 1.6;
   }
   
   .page:has(.home-hero) .care-arrow {
     flex-shrink: 0;
     transition: transform 0.25s ease;
   }
   
   @media (hover: hover) {
     .page:has(.home-hero) .care-card:hover {
       transform: translateY(-4px);
       box-shadow: 0 8px 20px rgba(65, 90, 75, 0.12);
     }
   
     .page:has(.home-hero) .care-card:hover .care-arrow {
       transform: translateX(4px);
     }
   }
   
   .page:has(.home-hero) .care-card:active {
     transform: scale(0.98);
   }
   
   /* สำหรับโทรศัพท์ */
   
   @media (max-width: 767px) {
     .page:has(.home-hero) .care-grid {
       grid-template-columns: 1fr;
       gap: 12px;
     }
   
     .page:has(.home-hero) .care-card {
       padding: 16px 14px;
       border-radius: 18px;
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     .page:has(.home-hero) .care-card,
     .page:has(.home-hero) .care-arrow {
       transition: none;
       transform: none !important;
     }
   }
   /* ตกแต่งกล่องเมื่อค้นหาไม่พบ */

.search-empty {
     background: #f0eaf6;
     border: 1px solid #e3d8ed;
     border-radius: 20px;
     padding: 18px 14px !important;
     margin: 14px 0;
     text-align: center;
   }
   
   .search-empty span {
     display: block;
     font-size: 26px;
     color: #b18cc3;
     margin-bottom: 6px;
   }
   
   .search-empty h3 {
     color: #725984;
     font-size: 16px;
     margin: 4px 0;
   }
   
   .search-empty p {
     color: #82758b;
     font-size: 14px;
     line-height: 1.6;
     margin: 4px 0;
   }
   /* ปุ่มปรับขนาดการแสดงผล */

.site-header {
     display: flex;
     align-items: center;
     justify-content: space-between;
     flex-wrap: wrap;
     gap: 8px;
   }
   
   .font-controls {
     display: flex;
     align-items: center;
     gap: 5px;
     margin-left: auto;
   }
   
   .font-controls button {
     min-width: 36px;
     min-height: 36px;
     padding: 5px;
     border: 1px solid #c5d8c9;
     border-radius: 10px;
     background: #e7f0e9;
     color: #52745e;
     font-size: 14px;
     font-weight: 600;
     cursor: pointer;
   }
   
   .font-controls button:active {
     background: #c5d8c9;
   }
   
   .font-controls button:focus-visible {
     outline: 2px solid #52745e;
     outline-offset: 2px;
   }
   /* ตกแต่งปุ่มกลับขึ้นด้านบน */

#backToTop {
     position: fixed;
     right: 22px;
     bottom: calc(90px + env(safe-area-inset-bottom));
     width: 48px;
     height: 48px;
     border: 2px solid #ffffff;
     border-radius: 50%;
     background: #719b82;
     color: #ffffff;
     font-size: 26px;
     font-weight: bold;
     cursor: pointer;
     z-index: 999;
     box-shadow: 0 4px 15px rgba(70, 110, 85, 0.22);
   
     opacity: 0;
     visibility: hidden;
     pointer-events: none;
     transform: translateY(12px);
     transition: all 0.25s ease;
   }
   
   #backToTop.show {
     opacity: 1;
     visibility: visible;
     pointer-events: auto;
     transform: translateY(0);
   }
   
   #backToTop:active {
     transform: scale(0.92);
   }
   
   #backToTop:focus-visible {
     outline: 2px solid #426751;
     outline-offset: 3px;
   }
   
   @media (max-width: 767px) {
     #backToTop {
       right: 16px;
       width: 46px;
       height: 46px;
     }
   }
   
   @media (prefers-reduced-motion: reduce) {
     #backToTop {
       transition: none;
     }
   }
   /* รูปแบบเนื้อหาการพยาบาล */

.care-steps {
     list-style: none;
     counter-reset: care-step;
     padding: 0;
     margin: 16px 0;
   }
   
   .care-steps > li {
     counter-increment: care-step;
     position: relative;
     padding: 16px 14px 16px 48px;
     margin-bottom: 12px;
     background: #f3f7f2;
     border: 1px solid #e0ebe0;
     border-radius: 16px;
     line-height: 1.8;
   }
   
   .care-steps > li::before {
     content: counter(care-step);
     position: absolute;
     left: 12px;
     top: 16px;
     width: 26px;
     height: 26px;
     display: flex;
     align-items: center;
     justify-content: center;
     border-radius: 50%;
     background: #d5e6d7;
     color: #426751;
     font-weight: bold;
   }
   
   .care-steps strong {
     display: block;
     color: #426751;
     margin-bottom: 5px;
   }
   
   .care-steps p {
     margin: 0;
     line-height: 1.8;
   }
   
   .care-warning {
     background: #fbf1dc;
     border: 1px solid #efdfba;
     border-radius: 16px;
     padding: 16px;
     margin-top: 18px;
     color: #80642f;
     line-height: 1.8;
   }
   
   .care-warning p {
     margin: 6px 0 0;
   }
   /* ขยายพื้นที่เนื้อหาบนโทรศัพท์ */

@media (max-width: 767px) {

     .page:has(.detail-hero) {
       padding-left: 12px;
       padding-right: 12px;
     }
   
     .page:has(.detail-hero) .guide-panel {
       padding: 12px;
     }
   
     .topic-content {
       padding: 14px 10px !important;
     }
   
     .topic-content .care-steps {
       width: 100%;
       padding: 0 !important;
       margin: 12px 0 !important;
     }
   
     .topic-content .care-steps > li {
       padding: 14px 12px 14px 38px !important;
       margin-bottom: 10px;
       border-radius: 14px;
     }
   
     .care-steps > li::before {
       left: 8px;
       top: 14px;
       width: 23px;
       height: 23px;
     }
   
     .care-steps > li > strong {
       font-size: 16px;
     }
   
     .care-steps p {
       font-size: 15px;
       line-height: 1.7;
     }
   
     .care-warning,
     .care-emergency-alert {
       padding: 14px 12px;
     }
   }
   /* รายการย่อยในเนื้อหาการดูแล */

.care-steps > li > ul {
     list-style: disc;
     padding-left: 18px;
     margin: 8px 0;
   }
   
   .care-steps > li > ul > li {
     margin-bottom: 8px;
     line-height: 1.7;
   }
   
   /* กล่องแจ้งเตือนฉุกเฉิน */
   
   .care-emergency-alert {
     background: #fceced;
     border: 1px solid #eac5ca;
     border-radius: 16px;
     padding: 16px;
     margin-top: 14px;
     color: #943e49;
     line-height: 1.8;
   }
   
   .care-emergency-alert p {
     margin: 8px 0 14px;
   }
   
   .care-emergency-call {
     display: flex;
     align-items: center;
     justify-content: center;
     min-height: 48px;
     padding: 12px;
     border-radius: 12px;
     background: #b84c5c;
     color: #ffffff;
     font-size: 18px;
     font-weight: bold;
     text-decoration: none;
   text-decoration:none;
}
/* ตกแต่งกล่องข้อแนะนำภายในเนื้อหา */

.care-steps > li > .care-warning {
     background: #eee9f6;
     border: none;
     border-left: 4px solid #a99ac6;
     border-radius: 12px;
     padding: 14px 16px;
     margin-top: 12px;
     margin-left: -24px;
     color: #61556f;
     line-height: 1.8;
   }
   
   .care-steps > li > .care-warning > strong {
     display: flex;
     align-items: center;
     gap: 8px;
     color: #786496;
     font-size: 16px;
     margin-bottom: 6px;
   }
   
   .care-steps > li > .care-warning > strong::before {
     content: "💡";
     font-size: 19px;
   }
   
   .care-steps > li > .care-warning > p {
     margin: 0;
     color: #61556f;
     line-height: 1.8;
   }
   
   /* ปรับพื้นที่บนมือถือ */
   
   @media (max-width: 767px) {
     .care-steps > li > .care-warning {
       margin-left: -26px;
       padding: 12px 14px;
     }
   }
   /* จัดข้อความเกริ่นนำในเนื้อหาการดูแล */

.care-introduction {
     margin: 12px 0 22px;
     color: #46544a;
     font-size: 16px;
     line-height: 1.85;
     overflow-wrap: break-word;
   }
   
   .care-introduction p {
     margin: 0 0 14px;
     line-height: 1.85;
   }
   
   .care-introduction p:last-child {
     margin-bottom: 0;
   }
   
   @media (max-width: 767px) {
     .care-introduction {
       font-size: 16px;
       line-height: 1.8;
       margin: 10px 0 18px;
     }
   }
   /* ภาพประกอบการจัดท่าผู้ป่วย */

.care-position-img {
     display: block;
     width: 100%;
     max-width: 480px;
     height: auto;
     margin: 14px auto;
     border-radius: 14px;
     object-fit: contain;
     box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
   }
   
   /* ขนาดภาพบนมือถือ */
   
   @media (max-width: 767px) {
     .care-position-img {
       max-width: 100%;
       margin: 12px auto;
       border-radius: 12px;
     }
   }
   /* การบริหารร่างกายแบบเปิด-ปิด */

.exercise-section {
     width: 100%;
     min-width: 0;
     font-size: 16px;
     line-height: 1.8;
   }
   
   .exercise-section h3 {
     font-size: 19px;
     color: #426751;
     margin: 20px 0 10px;
     line-height: 1.5;
   }
   
   .exercise-section h4 {
     font-size: 16px;
     margin: 16px 0 8px;
   }
   
   .exercise-hint {
     color: #68796d;
     font-size: 14px;
     margin: 0 0 14px;
   }
   
   /* กล่องความสำคัญและวัตถุประสงค์ */
   
   .exercise-intro {
     background: #eee9f6;
     border: 1px solid #e2daed;
     border-radius: 14px;
     color: #61556f;
     margin: 12px 0;
   }
   
   .exercise-intro > summary {
     color: #786496;
   }
   
   /* รายการท่าบริหาร */
   
   .exercise-list {
     display: grid;
     grid-template-columns: minmax(0, 1fr);
     gap: 10px;
     margin: 12px 0 20px;
   }
   
   .exercise-card {
     background: #f3f7f2;
     border: 1px solid #dce8dc;
     border-radius: 14px;
     min-width: 0;
     overflow: hidden;
   }
   
   .exercise-section .exercise-card > summary,
   .exercise-section .exercise-intro > summary {
     display: flex;
     align-items: center;
     gap: 10px;
     padding: 14px;
     min-height: 52px;
     font-size: 16px;
     font-weight: 600;
     line-height: 1.5;
     cursor: pointer;
     list-style: none;
     box-sizing: border-box;
   }
   
   .exercise-card > summary {
     color: #426751;
   }
   
   .exercise-section summary::-webkit-details-marker {
     display: none;
   }
   
   /* ลูกศรเปิด-ปิด */
   
   .exercise-section .exercise-card > summary::after,
   .exercise-section .exercise-intro > summary::after {
     content: "";
     width: 8px;
     height: 8px;
     border-right: 2px solid currentColor;
     border-bottom: 2px solid currentColor;
     transform: rotate(45deg);
     margin-left: auto;
     flex-shrink: 0;
     transition: transform 0.2s ease;
   }
   
   .exercise-section details[open] > summary::after {
     transform: rotate(225deg);
   }
   
   /* เลขลำดับ */
   
   .exercise-number {
     display: inline-flex;
     align-items: center;
     justify-content: center;
     width: 28px;
     height: 28px;
     flex-shrink: 0;
     border-radius: 50%;
     background: #d5e6d7;
     color: #426751;
     font-size: 14px;
     font-weight: bold;
   }
   
   /* เนื้อหาเมื่อกดเปิด */
   
   .exercise-body {
     padding: 4px 16px 16px;
     font-size: 16px;
     line-height: 1.8;
     overflow-wrap: break-word;
   }
   
   .exercise-body p {
     margin: 10px 0;
     line-height: 1.8;
   }
   
   .exercise-body p:last-child {
     margin-bottom: 0;
   }
   
   .exercise-card .exercise-body {
     color: #46544a;
   }
   
   .exercise-card[open] {
     border-color: #b7cfbc;
   }
   
   /* ภาพประกอบสำหรับเพิ่มภายหลัง */
   
   .exercise-body img {
     display: block;
     width: 100%;
     max-width: 480px;
     height: auto;
     border-radius: 12px;
     margin: 10px auto 14px;
   }
   
   /* กล่องส่งเสริมกำลังใจ */
   
   .exercise-encouragement {
     background: #f7e9ed;
     border: 1px solid #efdae2;
     border-radius: 14px;
     padding: 16px;
     margin-top: 20px;
     color: #805e69;
   }
   
   .exercise-encouragement strong {
     color: #966578;
   }
   
   .exercise-encouragement p {
     margin: 8px 0 0;
     line-height: 1.8;
   }
   
   /* การแสดงผลบนมือถือ */
   
   @media (max-width: 767px) {
   
     .exercise-section h3 {
       font-size: 18px;
     }
   
     .exercise-section .exercise-card > summary,
     .exercise-section .exercise-intro > summary {
       padding: 12px;
       font-size: 16px;
     }
   
     .exercise-body {
       padding: 4px 12px 14px;
       font-size: 16px;
     }
   
     .exercise-number {
       width: 26px;
       height: 26px;
     }
   
     .exercise-list {
       gap: 8px;
     }
   
     .exercise-encouragement {
       padding: 14px;
     }
   }
   /* ปรับสีหัวข้อและเนื้อหาให้เป็นสีเดียวกัน */

.exercise-section .exercise-intro,
.exercise-section .exercise-intro > summary,
.exercise-section .exercise-intro[open] > summary,
.exercise-section .exercise-intro > .exercise-body {
  background: #eee9f6 !important;
  color: #61556f !important;
}

.exercise-section .exercise-intro > summary {
  color: #786496 !important;
  border-radius: 14px;
  box-shadow: none !important;
}

.exercise-section .exercise-card,
.exercise-section .exercise-card > summary,
.exercise-section .exercise-card[open] > summary,
.exercise-section .exercise-card > .exercise-body {
  background: #f3f7f2 !important;
  color: #426751 !important;
}

.exercise-section .exercise-card > summary {
  border-radius: 14px;
  box-shadow: none !important;
}

.exercise-section .exercise-body p {
  color: inherit !important;
}

.exercise-section .exercise-intro {
  overflow: hidden;
}