/*
Theme Name: DH Med Clinic
Theme URI: https://dhmed.vn
Author: DH Med Clinic
Description: WordPress theme for Phong kham chuyen khoa Noi - Tim mach DH Med Clinic.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Text Domain: dhmed
*/

:root {
  --dm-blue: #075da3;
  --dm-blue-2: #1f5eb8;
  --dm-cyan: #11a8dc;
  --dm-mint: #dff8f5;
  --dm-mint-2: #edfdfb;
  --dm-ink: #12324a;
  --dm-muted: #617589;
  --dm-line: #d9e8f1;
  --dm-bg: #f6fbfd;
  --dm-white: #ffffff;
  --dm-warning: #f5a524;
  --dm-shadow: 0 18px 50px rgba(7, 93, 163, .12);
  --dm-radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--dm-ink);
  background: var(--dm-white);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
}

a {
  color: var(--dm-blue);
  text-decoration: none;
}

a:hover {
  color: var(--dm-cyan);
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

button,
input,
select,
textarea {
  font: inherit;
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
}

.section {
  padding: 84px 0;
}

.section-soft {
  background: linear-gradient(180deg, #f8fcfe 0%, #effaf9 100%);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 34px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--dm-cyan);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--dm-cyan);
}

h1,
h2,
h3,
h4 {
  margin: 0 0 16px;
  color: var(--dm-ink);
  line-height: 1.18;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(38px, 6vw, 64px);
}

h2 {
  font-size: clamp(30px, 4vw, 44px);
}

h3 {
  font-size: 22px;
}

p {
  margin: 0 0 18px;
}

.lead {
  color: var(--dm-muted);
  font-size: 18px;
}

.btn,
.button,
button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 12px 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--dm-blue);
  color: var(--dm-white);
  font-weight: 800;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.btn:hover,
.button:hover {
  transform: translateY(-2px);
  background: #064f8c;
  color: var(--dm-white);
  box-shadow: 0 12px 26px rgba(7, 93, 163, .22);
}

.btn.secondary {
  background: var(--dm-white);
  color: var(--dm-blue);
  border-color: var(--dm-line);
}

.btn.secondary:hover {
  background: var(--dm-mint-2);
  color: var(--dm-blue);
}

.btn.cyan {
  background: var(--dm-cyan);
}

.site-topbar {
  background: var(--dm-blue);
  color: rgba(255, 255, 255, .92);
  font-size: 14px;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 42px;
}

.topbar-group {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.topbar-group a,
.language-switch a {
  color: var(--dm-white);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(217, 232, 241, .78);
}

.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 26px;
  min-height: 84px;
}

.site-logo img {
  width: 208px;
  max-height: 62px;
  object-fit: contain;
}

.nav-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-menu a {
  color: var(--dm-ink);
  font-weight: 800;
}

.nav-menu a:hover,
.nav-menu .current-menu-item > a {
  color: var(--dm-blue);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius);
  background: var(--dm-white);
  color: var(--dm-blue);
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 690px;
  display: flex;
  align-items: center;
  background: #eef9fb;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(246, 251, 253, .98) 0%, rgba(246, 251, 253, .88) 40%, rgba(246, 251, 253, .2) 72%),
    var(--hero-image) center right / cover no-repeat;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 650px;
  padding: 92px 0 118px;
}

.hero h1 {
  color: #073e71;
}

.hero-actions,
.inline-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 38px;
}

.stat-box {
  padding: 16px;
  border: 1px solid rgba(17, 168, 220, .22);
  border-radius: var(--dm-radius);
  background: rgba(255, 255, 255, .78);
}

.stat-box strong {
  display: block;
  color: var(--dm-blue);
  font-size: 25px;
}

.grid {
  display: grid;
  gap: 22px;
}

.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.card {
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius);
  background: var(--dm-white);
  box-shadow: 0 12px 34px rgba(7, 93, 163, .07);
}

.service-card,
.reason-card,
.post-card,
.testimonial-card {
  padding: 26px;
}

.service-icon,
.reason-icon,
.step-number {
  width: 52px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--dm-radius);
  background: var(--dm-mint);
  color: var(--dm-blue);
  font-size: 25px;
  margin-bottom: 18px;
}

.service-card p,
.reason-card p,
.post-card p,
.testimonial-card p {
  color: var(--dm-muted);
}

.intro-layout {
  display: grid;
  grid-template-columns: .9fr 1.1fr;
  gap: 48px;
  align-items: center;
}

.intro-media {
  position: relative;
}

.intro-media img {
  border-radius: var(--dm-radius);
  box-shadow: var(--dm-shadow);
}

.feature-list {
  display: grid;
  gap: 14px;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--dm-muted);
}

.feature-list li::before {
  content: "✓";
  flex: 0 0 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--dm-mint);
  color: var(--dm-blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
}

.doctor-card {
  overflow: hidden;
}

.doctor-card img {
  width: 100%;
  aspect-ratio: 4 / 4.2;
  object-fit: cover;
  background: #f4fbfc;
}

.doctor-body {
  padding: 24px;
}

.doctor-meta {
  color: var(--dm-cyan);
  font-weight: 800;
  margin-bottom: 8px;
}

.doctor-excerpt {
  color: var(--dm-muted);
  min-height: 78px;
}

.timeline {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  counter-reset: steps;
}

.step-card {
  padding: 24px;
}

.step-number {
  font-weight: 900;
}

.booking-panel {
  display: grid;
  grid-template-columns: .78fr 1.22fr;
  gap: 34px;
  align-items: stretch;
}

.booking-copy {
  padding: 34px;
  border-radius: var(--dm-radius);
  background: var(--dm-blue);
  color: var(--dm-white);
}

.booking-copy h2,
.booking-copy p {
  color: var(--dm-white);
}

.booking-form {
  padding: 30px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.form-field.full {
  grid-column: 1 / -1;
}

.form-field label {
  display: block;
  margin-bottom: 7px;
  color: var(--dm-ink);
  font-weight: 800;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--dm-line);
  border-radius: var(--dm-radius);
  padding: 11px 13px;
  color: var(--dm-ink);
  background: var(--dm-white);
}

.form-field textarea {
  min-height: 112px;
  resize: vertical;
}

.form-message {
  margin-top: 14px;
  font-weight: 800;
}

.form-message.success {
  color: #138a58;
}

.form-message.error {
  color: #b42318;
}

.testimonial-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 44px) / 3);
  gap: 22px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 8px;
}

.testimonial-card {
  scroll-snap-align: start;
}

.stars {
  color: var(--dm-warning);
  font-size: 18px;
  margin-bottom: 12px;
}

.post-card img {
  width: calc(100% + 52px);
  max-width: none;
  margin: -26px -26px 22px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--dm-radius) var(--dm-radius) 0 0;
}

.page-hero {
  padding: 84px 0 58px;
  background: linear-gradient(135deg, #f5fbfe 0%, #e9faf8 100%);
  border-bottom: 1px solid var(--dm-line);
}

.rich-content {
  color: var(--dm-muted);
}

.rich-content h2,
.rich-content h3 {
  color: var(--dm-ink);
  margin-top: 34px;
}

.rich-content ul {
  padding-left: 22px;
}

.package-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.segmented {
  display: inline-flex;
  border: 1px solid var(--dm-line);
  border-radius: 999px;
  padding: 4px;
  background: var(--dm-white);
}

.segmented button {
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--dm-muted);
  padding: 10px 16px;
  cursor: pointer;
  font-weight: 800;
}

.segmented button.is-active {
  background: var(--dm-blue);
  color: var(--dm-white);
}

.package-card {
  margin-bottom: 18px;
  overflow: hidden;
}

.package-summary {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 20px;
  width: 100%;
  padding: 22px 24px;
  border: 0;
  background: var(--dm-white);
  color: var(--dm-ink);
  cursor: pointer;
  text-align: left;
}

.package-price {
  color: var(--dm-blue);
  font-size: 22px;
  font-weight: 900;
}

.package-content {
  display: none;
  border-top: 1px solid var(--dm-line);
  padding: 0 24px 24px;
}

.package-card.is-open .package-content {
  display: block;
}

.package-group {
  margin-top: 22px;
}

.package-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.package-table th,
.package-table td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--dm-line);
  text-align: left;
}

.contact-layout {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 32px;
}

.contact-box {
  padding: 28px;
}

.map-frame {
  width: 100%;
  min-height: 420px;
  border: 0;
  border-radius: var(--dm-radius);
}

.site-footer {
  background: #073e71;
  color: rgba(255, 255, 255, .82);
  padding: 60px 0 26px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr .8fr .8fr 1.2fr;
  gap: 28px;
}

.site-footer h3,
.site-footer h4,
.site-footer a {
  color: var(--dm-white);
}

.footer-logo {
  width: 220px;
  background: var(--dm-white);
  border-radius: var(--dm-radius);
  padding: 10px;
  margin-bottom: 18px;
}

.footer-list {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 36px;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: 14px;
}

.floating-actions {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 60;
  display: grid;
  gap: 10px;
}

.float-btn {
  width: 54px;
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--dm-white);
  background: var(--dm-blue);
  box-shadow: 0 10px 26px rgba(7, 93, 163, .28);
  font-size: 22px;
  font-weight: 900;
}

.float-btn.zalo {
  background: var(--dm-cyan);
  font-size: 16px;
}

.single-article {
  max-width: 820px;
  margin: 0 auto;
}

@media (max-width: 1024px) {
  .grid-4,
  .timeline {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-3,
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .intro-layout,
  .booking-panel,
  .contact-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .topbar-inner {
    align-items: flex-start;
    flex-direction: column;
    padding: 10px 0;
  }

  .header-inner {
    grid-template-columns: auto auto;
    justify-content: space-between;
  }

  .header-cta {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .site-nav {
    grid-column: 1 / -1;
    display: none;
    width: 100%;
  }

  .site-nav.is-open {
    display: block;
  }

  .nav-menu {
    align-items: stretch;
    flex-direction: column;
    gap: 0;
    padding: 12px 0 20px;
  }

  .nav-menu a {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid var(--dm-line);
  }

  .hero {
    min-height: auto;
  }

  .hero::before {
    background:
      linear-gradient(180deg, rgba(246, 251, 253, .98) 0%, rgba(246, 251, 253, .9) 62%, rgba(246, 251, 253, .5) 100%),
      var(--hero-image) center bottom / cover no-repeat;
  }

  .hero-content {
    padding: 62px 0 330px;
  }

  .hero-stats,
  .grid-2,
  .grid-3,
  .grid-4,
  .timeline,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .testimonial-strip {
    grid-auto-columns: min(86vw, 360px);
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .package-summary {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .section {
    padding: 58px 0;
  }

  .section-head {
    display: block;
  }

  .site-logo img {
    width: 176px;
  }

  .hero-content {
    padding-bottom: 280px;
  }

  .btn {
    width: 100%;
  }
}
