/* ============================================================
   GYEOL Dermatology — showcase demo
   Theme: light-locked (clinical porcelain + deep eucalyptus)
   Shape rule: containers 18px / interactive pill / images 18px
   ============================================================ */

:root {
  --bg: #f7f8f7;
  --surface: #ffffff;
  --ink: #17201d;
  --muted: #5b6663;
  --line: #e4e8e6;
  --accent: #0e6e5c;
  --accent-deep: #0a5546;
  --accent-soft: #e3efeb;
  --accent-ink: #10382f;
  --radius: 18px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --container: 1200px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  font-family: "Pretendard Variable", Pretendard, -apple-system, "Hiragino Sans", "PingFang SC", sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.01em;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  padding: 14px 28px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  transition: transform 0.25s var(--ease), background 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-primary {
  background: var(--accent);
  color: #f4faf8;
  box-shadow: 0 8px 24px rgba(14, 110, 92, 0.22);
}
.btn-primary:hover { background: var(--accent-deep); transform: translateY(-2px); }
.btn-ghost {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-deep); transform: translateY(-2px); }
.btn-nav { padding: 10px 20px; font-size: 14px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(247, 248, 247, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--accent-ink); }
.brand-mark { width: 30px; height: 30px; color: var(--accent); }
.brand-name { font-size: 17px; font-weight: 700; letter-spacing: -0.02em; }
.nav-links { display: flex; gap: 28px; }
.nav-links a {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.2s var(--ease);
}
.nav-links a:hover { color: var(--accent-deep); }
.nav-right { display: flex; align-items: center; gap: 14px; }

.lang-switch {
  display: flex;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
}
.lang-btn {
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  padding: 6px 11px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s var(--ease), color 0.2s var(--ease);
}
.lang-btn:hover { color: var(--accent-deep); }
.lang-btn.is-active { background: var(--accent); color: #f4faf8; }

/* ---------- Hero ---------- */
.hero { padding: 72px 0 88px; overflow: hidden; }
.hero-grid {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 56px;
  align-items: center;
}
.hero-title {
  font-size: clamp(38px, 5.2vw, 60px);
  line-height: 1.16;
  font-weight: 800;
  letter-spacing: -0.035em;
}
.hero-title em {
  font-style: italic;
  color: var(--accent);
  padding-bottom: 4px;
}
.hero-sub {
  margin-top: 22px;
  font-size: 18px;
  color: var(--muted);
  max-width: 46ch;
}
.hero-cta { margin-top: 34px; display: flex; gap: 12px; flex-wrap: wrap; }
.hero-media {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(23, 32, 29, 0.14);
  transform: rotate(1.2deg);
}
.hero-media img { width: 100%; height: 520px; object-fit: cover; }

/* ---------- Info strip ---------- */
.info-strip {
  background: var(--surface);
  border-block: 1px solid var(--line);
  padding: 28px 0;
}
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.info-item { display: flex; flex-direction: column; gap: 4px; }
.info-label { font-size: 13px; font-weight: 600; color: var(--accent); }
.info-value { font-size: 15px; font-weight: 500; }

/* ---------- Sections ---------- */
.section { padding: 104px 0; }
.section-head { max-width: 60ch; margin-bottom: 52px; }
.section-head h2, .doctor-copy h2, .global-inner h2, .contact-copy h2 {
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}
.section-head p { margin-top: 14px; font-size: 17px; color: var(--muted); }

/* ---------- Bento ---------- */
.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: 240px;
  gap: 16px;
}
.bento-cell {
  position: relative;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 28px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.bento-cell:hover { transform: translateY(-4px); box-shadow: 0 16px 40px rgba(23, 32, 29, 0.1); }
.bento-cell h3 { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.bento-cell p { margin-top: 8px; font-size: 14.5px; color: var(--muted); line-height: 1.55; }

.cell-large { grid-column: span 4; grid-row: span 2; padding: 0; border: 0; }
.cell-large img, .cell-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.bento-overlay {
  position: relative;
  z-index: 1;
  padding: 28px;
  background: linear-gradient(to top, rgba(12, 22, 19, 0.82) 0%, rgba(12, 22, 19, 0.35) 55%, transparent 100%);
  margin-top: auto;
}
.bento-overlay h3 { color: #fdfefe; }
.bento-overlay p { color: rgba(244, 250, 248, 0.85); }

.cell-tint { grid-column: span 2; background: var(--accent-soft); border-color: transparent; }
.cell-tint h3 { color: var(--accent-ink); }
.bento-cell:nth-child(3) { grid-column: span 2; }
.cell-photo { grid-column: span 3; padding: 0; border: 0; }
.cell-dark { grid-column: span 3; background: var(--accent-ink); border-color: transparent; }
.cell-dark h3 { color: #f4faf8; }
.cell-dark p { color: rgba(227, 239, 235, 0.75); }

/* ---------- Doctor ---------- */
.section-doctor { background: var(--surface); border-block: 1px solid var(--line); }
.doctor-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 64px;
  align-items: center;
}
.doctor-media { border-radius: var(--radius); overflow: hidden; }
.doctor-media img { width: 100%; height: 560px; object-fit: cover; }
.doctor-name { margin-top: 24px; font-size: 20px; }
.doctor-role {
  margin-left: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 4px 12px;
  border-radius: 999px;
  vertical-align: 2px;
}
.doctor-bio { margin-top: 18px; font-size: 16.5px; color: var(--muted); max-width: 58ch; }
.doctor-creds { margin-top: 26px; display: grid; gap: 10px; }
.doctor-creds li {
  padding-left: 24px;
  position: relative;
  font-size: 15px;
  font-weight: 500;
}
.doctor-creds li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 12px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
}
.doctor-note {
  margin-top: 26px;
  font-size: 13.5px;
  color: var(--muted);
  border-left: 2px solid var(--accent);
  padding-left: 14px;
}

/* ---------- FAQ ---------- */
.faq-wrap { max-width: 860px; }
.faq-list { display: grid; gap: 12px; }
.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.25s var(--ease);
}
.faq-item[open] { border-color: var(--accent); }
.faq-item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 26px;
  font-size: 16.5px;
  font-weight: 600;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-icon {
  flex: none;
  width: 14px;
  height: 14px;
  position: relative;
}
.faq-icon::before, .faq-icon::after {
  content: "";
  position: absolute;
  background: var(--accent);
  border-radius: 2px;
  transition: transform 0.3s var(--ease);
}
.faq-icon::before { left: 0; top: 6px; width: 14px; height: 2px; }
.faq-icon::after { left: 6px; top: 0; width: 2px; height: 14px; }
.faq-item[open] .faq-icon::after { transform: scaleY(0); }
.faq-item > p {
  padding: 0 26px 24px;
  color: var(--muted);
  font-size: 15.5px;
  max-width: 68ch;
}

/* ---------- Global care ---------- */
.section-global { background: var(--accent-ink); }
.global-inner h2 { color: #f4faf8; }
.global-inner > p { margin-top: 14px; font-size: 17px; color: rgba(227, 239, 235, 0.72); max-width: 52ch; }
.global-cols {
  margin-top: 52px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}
.global-col { padding: 0 32px; border-left: 1px solid rgba(227, 239, 235, 0.16); }
.global-col:first-child { padding-left: 0; border-left: 0; }
.global-col h3 { color: #e3efeb; font-size: 17px; font-weight: 700; }
.global-col p { margin-top: 8px; color: rgba(227, 239, 235, 0.62); font-size: 14.5px; }

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 6fr 6fr;
  gap: 64px;
  align-items: center;
}
.contact-list { margin: 36px 0 40px; display: grid; gap: 22px; }
.contact-list div { display: grid; grid-template-columns: 92px 1fr; gap: 12px; }
.contact-list dt { font-size: 14px; font-weight: 700; color: var(--accent); padding-top: 2px; }
.contact-list dd { font-size: 15.5px; color: var(--ink); }
.contact-list dd a { font-weight: 600; }
.contact-media { border-radius: var(--radius); overflow: hidden; }
.contact-media img { width: 100%; height: 440px; object-fit: cover; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 40px 0 56px; }
.footer-inner p { font-size: 13.5px; color: var(--muted); }
.footer-legal { margin-top: 8px; font-size: 12.5px; opacity: 0.8; }

/* ---------- Reveal motion ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .bento-cell { transition: none; }
}

/* ---------- Language fade ---------- */
body.lang-fading [data-i18n],
body.lang-fading [data-i18n-html] { opacity: 0.25; transition: opacity 0.18s ease; }
[data-i18n], [data-i18n-html] { transition: opacity 0.18s ease; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .nav-links { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-media { transform: none; }
  .hero-media img { height: 400px; }
  .doctor-grid, .contact-grid { grid-template-columns: 1fr; gap: 40px; }
  .doctor-media img { height: 420px; }
  .bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 220px; }
  .cell-large { grid-column: span 2; }
  .cell-tint, .bento-cell:nth-child(3), .cell-photo, .cell-dark { grid-column: span 1; }
}

@media (max-width: 640px) {
  .section { padding: 72px 0; }
  .brand-name { display: none; }
  .btn-nav { display: none; }
  .info-grid { grid-template-columns: 1fr; gap: 18px; }
  .bento { grid-template-columns: 1fr; grid-auto-rows: minmax(200px, auto); }
  .cell-large, .cell-tint, .bento-cell:nth-child(3), .cell-photo, .cell-dark { grid-column: span 1; }
  .global-cols { grid-template-columns: 1fr; gap: 28px; }
  .global-col { padding: 0; border-left: 0; }
  .contact-list div { grid-template-columns: 1fr; gap: 4px; }
}

/* nav overflow guard */
.nav-links a { white-space: nowrap; }
@media (max-width: 1180px) { .nav-links { display: none; } }


/* ---------- Facility gallery ---------- */
.facility-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.facility-grid figure { margin: 0; }
.facility-grid img { width: 100%; height: 250px; object-fit: cover; border-radius: var(--radius); }
.facility-grid figcaption { margin-top: 12px; }
.fc-t { display: block; font-size: 14.5px; font-weight: 700; }
.fc-d { display: block; font-size: 13.5px; color: var(--muted); margin-top: 2px; }

/* ---------- Global care band ---------- */
.section-gcare { background: var(--accent-soft); }
.gcare-head { max-width: 60ch; margin-bottom: 48px; }
.gcare-head h2 { font-size: clamp(28px, 3.4vw, 40px); font-weight: 800; letter-spacing: -0.03em; line-height: 1.2; }
.gcare-head p { margin-top: 14px; font-size: 17px; color: var(--muted); }
.gcare-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.gcare-col h3 { font-size: 17px; font-weight: 700; color: var(--accent); }
.gcare-col p { margin-top: 8px; font-size: 14.5px; color: var(--muted); line-height: 1.6; }

@media (max-width: 1024px) {
  .facility-grid { grid-template-columns: 1fr; }
  .facility-grid img { height: 220px; }
  .gcare-cols { grid-template-columns: 1fr; gap: 24px; }
}

/* ---------- Care programs ---------- */
.programs { display: grid; grid-template-columns: 5fr 3.5fr 3.5fr; gap: 16px; }
.prog-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; display: flex; flex-direction: column; }
.prog-featured { background: var(--accent-soft); border-color: transparent; }
.prog-card h3 { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; }
.prog-featured h3 { color: var(--accent-ink); }
.prog-card p { margin-top: 10px; font-size: 14.5px; color: var(--muted); line-height: 1.6; }
.prog-tag { margin-top: auto; padding-top: 18px; font-size: 13px; font-weight: 700; color: var(--accent); }
@media (max-width: 1024px) {
  .programs { grid-template-columns: 1fr 1fr; }
  .prog-featured { grid-column: span 2; }
}
@media (max-width: 640px) {
  .programs { grid-template-columns: 1fr; }
  .prog-featured { grid-column: span 1; }
}
