/* =====================================================
   Medical Practice Website Styles (v1.7 – FULL FIXED)
   - Red / Blue / White theme
   - Hero image blur, cards, buttons, forms, footer
   - Floating WhatsApp button
   - Uniform Navbar + animation
   - Fully responsive and functional
===================================================== */

/* ---------- Theme variables ---------- */
:root {
  --brand-primary: #d32f2f;
  --brand-accent: #0a66c2;
  --bg: #ffffff;
  --bg-alt: #f7f9fc;
  --text: #0b1220;
  --muted: #5c6b80;
  --border: #e5e9f2;
  --focus: #ff6b6b;
  --radius: 14px;
  --shadow: 0 8px 24px rgba(0,0,0,.08);
}

/* ---------- Base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
.container { max-width: 1120px; width: 92%; margin: 0 auto; }
.section { padding: 80px 0; scroll-margin-top: 92px; }
.section.alt { background: var(--bg-alt); }

/* ---------- Accessibility ---------- */
.skip-link {
  position: absolute; left: -999px; top: auto; width: 1px; height: 1px; overflow: hidden;
}
.skip-link:focus {
  position: static; width: auto; height: auto;
  padding: .5rem 1rem;
  background: var(--focus);
  color: #111;
  border-radius: 8px;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0;
  z-index: 1000;
  background: transparent;
  padding: 24px 0;
  transition: all .3s ease;
}
.header-wrap {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 72px;
}
.brand img { width: 200px; transition: transform .3s ease; }

/* Hamburger */
.nav-toggle {
  display: none; /* desktop hidden */
  flex-direction: column;
  justify-content: space-between;
  width: 35px;
  height: 25px;
  cursor: pointer;
  border: none;
  background: transparent;
  z-index: 2000;
  position: relative;
}
.nav-toggle .bar {
  height: 3px;
  width: 100%;
  background-color: #D32F2F;
  border-radius: 2px;
  transition: all 0.3s ease;
}
.nav-toggle .bar + .bar { margin-top: 5px; }
/* Hamburger animation */
.nav-toggle.open .bar:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-toggle.open .bar:nth-child(2) { opacity: 0; }
.nav-toggle.open .bar:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

.site-nav ul {
  display: flex; list-style: none; gap: .5rem;
  margin: 0; padding: 0;
}
.site-nav a {
  padding: .55rem .9rem;
  border-radius: 10px;
  text-decoration: none;
  color: #000 !important;
  position: relative;
}
.site-nav a:hover { color: var(--brand-primary) !important; }
.site-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -4px;
  width: 0%;
  height: 2px;
  background: var(--brand-primary);
  transition: width 0.3s ease;
}
.site-nav a:hover::after,
.site-nav a.active::after,
.site-nav a[aria-current="page"]::after { width: 100%; }

.site-header.scrolled {
  background: rgba(255,255,255,.95);
  padding: 12px 0;
  box-shadow: 0 6px 18px rgba(0,0,0,.15);
}
.site-header.scrolled .brand img { transform: scale(.85); }

/* ---------- HERO ---------- */
.hero.section.hero-enhanced {
  min-height: 100vh;
  padding-top: 140px;
  position: relative;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
}
/* Strong blur LEFT */
.hero.section.hero-enhanced::before {
  content: "";
  position: absolute; inset: 0;
  background: url("assets/img/1.png") center/cover no-repeat;
  filter: blur(34px);
  transform: scale(1.12);
  z-index: 1;
  mask-image: linear-gradient(to right, black 0%, black 40%, rgba(0,0,0,.85) 50%, transparent 65%);
  -webkit-mask-image: linear-gradient(to right, black 0%, black 40%, rgba(0,0,0,.85) 50%, transparent 65%);
}
.hero.section.hero-enhanced::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to right, rgba(0,0,0,.45), rgba(0,0,0,.25) 25%, rgba(0,0,0,.1) 40%, transparent 65%);
  z-index: 2;
}
.hero.section.hero-enhanced .hero-content {
  position: relative;
  z-index: 3;
  max-width: 680px;
  padding: 0 20px;
  margin-left: 60px;
}
.hero-enhanced h1 {
  color: #fff;
  font-size: clamp(2.4rem,4vw,3.2rem);
  text-shadow: 0 4px 14px rgba(0,0,0,.55);
}
.hero-enhanced .lead,
.hero-enhanced .muted {
  color: #fff;
  font-weight: bold;
  text-shadow: 0 3px 12px rgba(0,0,0,.45);
}

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .7rem 1.1rem;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  transition: .2s ease;
}
.btn-primary { background: var(--brand-primary); color: #fff; }
.btn-primary:hover { background:#c12727; }
.btn-outline { border: 2px solid var(--brand-primary); color: var(--brand-primary); }
.btn-outline:hover { background: rgba(10,102,194,.08); }
.btn-accent { background: var(--brand-accent); color: #fff; }

/* ---------- CARDS ---------- */
.cards.three {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 1rem;
}
.card {
  background:#fff;
  border:1px solid var(--border);
  border-radius: var(--radius);
  padding:1.1rem 1.25rem;
  box-shadow: var(--shadow);
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(0,0,0,.12); }
.card h3 { margin-top: .25rem; }

/* ---------- CONTACT FORM ---------- */
.contact-form-wrapper {
  background: #fff;
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: 0 12px 28px rgba(0,0,0,0.12);
  max-width: 600px;
  margin: 0 auto;
}
.contact-form-wrapper h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--brand-primary);
  text-align: center;
}
.contact-form-wrapper p {
  text-align: center;
  color: var(--muted);
  margin-bottom: 2rem;
  line-height: 1.5;
}
.contact-form-wrapper .form-field {
  display: flex; flex-direction: column;
  margin-bottom: 1.25rem;
}
.contact-form-wrapper .form-field label {
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--text);
}
.contact-form-wrapper .form-field input,
.contact-form-wrapper .form-field textarea,
.contact-form-wrapper .form-field select {
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  font-size: 1rem;
  font-family: inherit;
  transition: all 0.3s ease;
}
.contact-form-wrapper .form-field input:focus,
.contact-form-wrapper .form-field textarea:focus,
.contact-form-wrapper .form-field select:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(211,47,47,0.15);
  outline: none;
}
.contact-form-wrapper textarea { min-height: 140px; resize: vertical; }
.contact-form-wrapper .form-actions {
  display: flex; justify-content: flex-end; gap: 1rem; margin-top: 1rem;
}
.contact-form-wrapper .form-actions .btn-primary {
  background: var(--brand-primary);
  color: #fff;
  font-weight: 600;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  transition: all 0.25s ease;
}
.contact-form-wrapper .form-actions .btn-primary:hover {
  background: #c12727;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(211,47,47,0.25);
}
.contact-form-wrapper .form-status {
  margin-top: 0.75rem;
  font-size: 0.95rem;
  color: var(--muted);
  text-align: left;
}

/* ---------- CONTACT LIST ---------- */
.contact-list { list-style:none; padding:0; margin:0 0 1rem; }
.contact-list li { margin:.25rem 0; }

/* ---------- WhatsApp Floating Button ---------- */
.whatsapp-float {
  position: fixed;
  bottom: 20px; right: 20px;
  width: 60px; height: 60px;
  background-color: #25D366;
  color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 30px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
  z-index: 1000;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
}
.whatsapp-float:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.4);
  color: #fff;
}
.whatsapp-float:focus {
  outline: 3px solid rgba(255,255,255,0.8);
  outline-offset: 3px;
}
.whatsapp-float i { line-height: 1; }

/* ---------- FOOTER ---------- */
.site-footer {
  border-top:1px solid var(--border);
  padding:1rem 0;
  background:#fff;
  color: var(--muted);
  text-align:center;
}
.site-footer p { margin:.25rem 0; }

/* ---------- RESPONSIVE ---------- */
@media (max-width:1024px){
  .nav-toggle { display: flex; }
  .site-nav {
    position: absolute;
    top: 100%; left:0; right:0;
    width: 100%;
    max-height: 0;
    overflow: hidden;
    background: #fff;
    flex-direction: column;
    align-items: center;
    transition: max-height 0.3s ease;
    z-index: 999;
  }
  .site-nav.open { max-height: 500px; }
  .site-nav ul { flex-direction: column; gap: 1rem; padding: 1rem 0; }
  .site-nav li a { padding: 0.5rem 1rem; display: block; }
}

@media (max-width:960px){
  .cards.three { grid-template-columns: repeat(2,1fr); }
}

@media (max-width:720px){
  .cards.three { grid-template-columns: 1fr; }
  .hero.section.hero-enhanced .hero-content { margin-left: 0; text-align: left; }
  .contact-form-wrapper { padding: 1.5rem; }
  .contact-form-wrapper .form-actions { flex-direction: column; align-items: stretch; }
  .contact-form-wrapper .form-actions .btn-primary { width: 100%; }
  .site-nav {
    position: fixed; top:72px; left:0; right:0;
    transform: translateY(-120%);
    border-bottom:1px solid var(--border);
  }
  .site-nav.open { transform: translateY(0); }
  .site-nav ul { padding: .75rem; }
  .site-nav a { padding:.9rem 1rem; }
}
