/*
Theme Name: Hisse MD
Theme URI: https://hissemd.com
Author: Emilio B Hisse, MD, PA
Description: Bilingual medical-practice theme matching the Hisse MD Astro site with an integrated WordPress blog.
Version: 0.1.0
Requires at least: 6.4
Requires PHP: 8.1
Text Domain: hissemd
*/

:root {
  --navy: #0c2340;
  --navy-deep: #071628;
  --teal: #1a5f7a;
  --teal-soft: #e8f2f6;
  --accent: #c56a17;
  --accent-hover: #a65610;
  --paper: #f6f3ee;
  --white: #fff;
  --ink: #1b1f24;
  --muted: #4d5663;
  --line: #d7d0c6;
  --danger: #8a1f1f;
  --shadow: 0 18px 40px rgba(12, 35, 64, .12);
  --radius: 14px;
  --max: 70rem;
  --font-serif: "Source Serif 4", Georgia, serif;
  --font-sans: "Source Sans 3", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--font-sans);
  font-size: 1.125rem;
  line-height: 1.65;
}
img { max-width: 100%; height: auto; }
a { color: var(--teal); }
a:hover { color: var(--navy); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.wrap { width: min(var(--max), calc(100% - 2rem)); margin-inline: auto; }
.skip-link {
  position: absolute;
  left: .75rem;
  top: -40rem;
  z-index: 100;
  padding: .7rem 1rem;
  background: var(--white);
  color: var(--navy);
}
.skip-link:focus { top: .75rem; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(246, 243, 238, .94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.5rem;
  padding-block: .6rem;
}
.brand {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 44px;
  color: var(--navy);
  text-decoration: none;
}
.brand-name { font: 650 1.15rem/1.2 var(--font-serif); letter-spacing: .01em; }
.brand-tag { color: var(--muted); font-size: .85rem; }
.site-nav { display: flex; align-items: center; gap: .9rem; }
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--navy);
  font-weight: 600;
  text-decoration: none;
}
.site-nav .current-menu-item > a,
.site-nav a[aria-current="page"] { color: var(--accent); }
.menu { display: flex; align-items: center; gap: .9rem; margin: 0; padding: 0; list-style: none; }
.header-actions { display: flex; align-items: center; gap: .6rem; }
.lang-switch {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 .75rem;
  color: var(--navy);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid var(--accent);
}
.menu-toggle {
  display: none;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--navy);
  font: 700 1rem var(--font-sans);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: .7rem 1.15rem;
  border: 2px solid transparent;
  border-radius: 999px;
  font: 700 1rem var(--font-sans);
  text-decoration: none;
  cursor: pointer;
}
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--white); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--white); }
.btn-secondary { border-color: rgba(255, 255, 255, .7); color: var(--white); }
.btn-secondary:hover { background: var(--white); color: var(--navy); }
.btn-ghost { background: var(--white); border-color: var(--navy); color: var(--navy); }
.btn-ghost:hover { background: var(--navy); color: var(--white); }

.hero {
  padding: 4rem 0 4.5rem;
  color: var(--white);
  background:
    radial-gradient(circle at 80% 10%, rgba(197, 106, 23, .22), transparent 28%),
    linear-gradient(160deg, var(--navy-deep), var(--navy) 55%, var(--teal));
}
.hero-grid { display: grid; gap: 2.5rem; align-items: center; }
.eyebrow {
  display: inline-block;
  margin: 0 0 .8rem;
  color: #f0d2b0;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.hero h1, .page-hero h1, .section h2, .card h2, .card h3, .entry-title {
  font-family: var(--font-serif);
  font-weight: 650;
  line-height: 1.15;
  letter-spacing: -.02em;
}
.hero h1 { margin: 0 0 1rem; font-size: clamp(2.1rem, 5vw, 3.5rem); }
.lede { max-width: 40rem; color: #e6eef3; font-size: 1.2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.6rem 0 1.2rem; }
.hero-meta { display: grid; gap: .35rem; color: #d5e0e8; font-size: 1rem; }
.portrait {
  width: min(100%, 22rem);
  justify-self: center;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 18rem 18rem 1.2rem 1.2rem;
  background: rgba(255,255,255,.06);
  box-shadow: var(--shadow);
}
.portrait img { display: block; width: 100%; aspect-ratio: 4/5; object-fit: cover; object-position: top; }
.page-hero { padding: 3.2rem 0 1.5rem; }
.page-hero h1, .entry-title { margin: 0 0 .8rem; color: var(--navy); font-size: clamp(2rem, 4vw, 3rem); }
.page-hero .lede { color: var(--muted); }

.section { padding: 2.6rem 0; }
.section h2 { margin: 0 0 .8rem; color: var(--navy); font-size: clamp(1.6rem, 3vw, 2.1rem); }
.cards { display: grid; gap: 1rem; }
.card {
  padding: 1.3rem 1.35rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 1px 0 rgba(12,35,64,.04);
}
.card h3 { margin: 0 0 .5rem; color: var(--navy); font-size: 1.25rem; }
.card p:last-child, .prose p:last-child { margin-bottom: 0; }
.split { display: grid; gap: 1.5rem; }
.cta-band { padding: 2rem; border-radius: calc(var(--radius) + 4px); background: var(--navy); color: var(--white); }
.cta-band h2 { color: var(--white); }
.cta-band p { color: #d7e3ea; }
.muted, .entry-meta { color: var(--muted); }
.list { margin: 0; padding-left: 1.2rem; }
.list li + li { margin-top: .45rem; }
.warning { padding: .85rem 1rem; border-left: 4px solid var(--danger); background: #f8ecec; color: var(--danger); }
.prose { max-width: 48rem; }
.prose h2 { margin-top: 2rem; }
.prose h3 { margin-top: 1.7rem; color: var(--navy); font-family: var(--font-serif); }
.note { color: var(--muted); font-size: .98rem; }
.post-list { display: grid; gap: 1rem; list-style: none; margin: 0; padding: 0; }
.post-card { padding: 1.4rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.post-card h2 { margin: 0 0 .4rem; font-size: 1.45rem; }
.post-card h2 a { color: var(--navy); text-decoration: none; }
.post-card h2 a:hover { color: var(--accent); }
.post-card time { color: var(--muted); font-size: .95rem; }
.entry-content ul { padding-left: 1.3rem; }
.entry-content a { overflow-wrap: anywhere; }
.map { width: 100%; min-height: 18rem; border: 0; border-radius: var(--radius); }
.form { display: grid; gap: .9rem; }
.field { display: grid; gap: .35rem; color: var(--navy); font-weight: 700; }
input, textarea {
  width: 100%;
  min-height: 48px;
  padding: .7rem .8rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
}
textarea { min-height: 8rem; resize: vertical; }
.honeypot { position: absolute !important; left: -10000px !important; }
.status { padding: .85rem 1rem; border-radius: 10px; }
.status-ok { background: #e7f4ea; color: #1c4d2a; }
.status-err { background: #f8ecec; color: var(--danger); }

.site-footer { margin-top: 2rem; padding: 2.4rem 0 1.6rem; background: var(--navy-deep); color: #d7e3ea; }
.footer-grid { display: grid; gap: 1.4rem; }
.site-footer a { color: #f4ebe1; }
.site-footer h2 { margin: 0 0 .5rem; color: var(--white); font: 650 1.2rem var(--font-serif); }
.footer-legal { display: flex; flex-wrap: wrap; gap: .8rem 1.2rem; margin-top: 1.6rem; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,.12); font-size: .95rem; }
.mobile-call { display: none; }

@media (min-width: 720px) {
  .cards.cols-2 { grid-template-columns: 1fr 1fr; }
  .cards.cols-4 { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
@media (min-width: 860px) {
  .hero-grid { grid-template-columns: 1.2fr .8fr; }
  .split { grid-template-columns: 1fr 1fr; align-items: start; }
}
@media (min-width: 980px) { .cards.cols-4 { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 780px) {
  .site-nav {
    display: none;
    position: absolute;
    inset: 100% 0 auto;
    padding: .6rem 1rem 1rem;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
  }
  .site-nav.is-open { display: block; }
  .menu { flex-direction: column; align-items: stretch; }
  .menu-toggle { display: inline-flex; }
  .header-actions .btn { display: none; }
  .mobile-call { display: block; position: sticky; bottom: 0; z-index: 15; padding: .7rem 1rem; background: var(--navy); }
  .mobile-call .btn { width: 100%; }
}
