/* ============================================================
   Senior Home Health Care — style.css
   ============================================================ */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600&family=Fraunces:ital,wght@0,400;0,600;1,400&display=swap');

/* ── CSS Variables ───────────────────────────────────────── */
:root {
  --primary:        #2a6496;
  --primary-light:  #d6e8f5;
  --primary-hover:  #1f4f77;
  --accent:         #4caf82;
  --accent-light:   #d8f3e6;
  --bg:             #f4f8fb;
  --white:          #ffffff;
  --card-bg:        #ffffff;
  --border:         #dce8f0;
  --text:           #1a2e3b;
  --muted:          #5a7a8e;
  --footer-bg:      #f0f5f9;

  --font-sans:      'DM Sans', sans-serif;
  --font-serif:     'Fraunces', serif;
  --radius:         12px;
  --radius-lg:      20px;
  --radius-xl:      28px;
  --transition:     0.2s ease;
  --shadow-sm:      0 1px 3px rgba(42,100,150,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:      0 4px 16px rgba(42,100,150,0.10), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg:      0 8px 32px rgba(42,100,150,0.13), 0 4px 8px rgba(0,0,0,0.05);
}

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

/* ── Utilities ───────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
.section-title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  font-weight: 600;
  color: var(--text);
  line-height: 1.2;
}
.section-sub {
  font-size: 1.05rem;
  color: var(--muted);
  margin-top: 12px;
  line-height: 1.7;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
  border: 2px solid transparent;
}
.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}
.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--border);
}
.btn-outline:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  transform: translateY(-1px);
}

/* ── Header ──────────────────────────────────────────────── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
  transition: opacity var(--transition);
}
.logo:hover { opacity: 0.85; }
.logo-icon {
  width: 38px;
  height: 38px;
  background: var(--primary-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background var(--transition);
}
.logo:hover .logo-icon { background: #c0daf0; }
.logo-icon svg { width: 22px; height: 22px; stroke: var(--primary); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Desktop nav */
.desktop-nav { display: flex; align-items: center; gap: 32px; }
.desktop-nav a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
  transition: color var(--transition);
}
.desktop-nav a:hover { color: var(--primary); }

/* Services dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown-trigger {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
  transition: color var(--transition);
}
.nav-dropdown-trigger:hover { color: var(--primary); }
.nav-dropdown-trigger svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2.5; transition: transform var(--transition); }
.nav-dropdown.open .nav-dropdown-trigger svg { transform: rotate(180deg); }
.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  min-width: 210px;
  overflow: hidden;
  z-index: 200;
}
.nav-dropdown.open .dropdown-menu { display: block; }
.dropdown-menu a {
  display: block;
  padding: 12px 20px;
  font-size: 0.9rem;
  color: var(--text);
  font-weight: 500;
  transition: background var(--transition), color var(--transition);
}
.dropdown-menu a:hover { background: var(--primary-light); color: var(--primary); }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 6px;
  border-radius: var(--radius);
  transition: background var(--transition);
}
.hamburger:hover { background: var(--primary-light); }
.hamburger span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s ease;
}
.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav overlay */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  background: rgba(26,46,59,0.4);
  backdrop-filter: blur(2px);
}
.mobile-nav.open { display: block; }
.mobile-nav-panel {
  position: absolute;
  top: 0; right: 0;
  width: 300px;
  height: 100%;
  background: var(--white);
  padding: 88px 28px 32px;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}
.mobile-nav.open .mobile-nav-panel { transform: translateX(0); }
.mobile-nav-panel a,
.mobile-nav-panel button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 13px 0;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  background: none;
  font-family: inherit;
  cursor: pointer;
  transition: color var(--transition);
}
.mobile-nav-panel a:hover,
.mobile-nav-panel button:hover { color: var(--primary); }
.mobile-nav-services {
  padding-left: 16px;
  border-left: 3px solid var(--primary-light);
  margin: 4px 0 8px;
}
.mobile-nav-services a {
  font-size: 0.95rem;
  color: var(--muted);
  padding: 9px 0;
  border-bottom: 1px dashed var(--border);
}
.mobile-services-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  padding: 10px 0 4px;
}
.mobile-nav-panel .btn-primary {
  margin-top: 24px;
  width: 100%;
  justify-content: center;
}

/* ── Hero ────────────────────────────────────────────────── */
.hero {
  background: linear-gradient(160deg, #e8f2fa 0%, var(--bg) 100%);
  padding: 80px 0 96px;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.02em;
}
.hero-badge span {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  display: inline-block;
}
.hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  font-weight: 600;
  line-height: 1.1;
  color: var(--text);
  margin-bottom: 20px;
}
.hero h1 .highlight { color: var(--primary); }
.hero p {
  font-size: 1.1rem;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 36px;
  max-width: 500px;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-image-wrap {
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3;
  max-height: 480px;
}
.hero-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ── Who We Are ─────────────────────────────────────────── */
.who-we-are {
  background: var(--white);
  padding: 96px 0;
  text-align: center;
}
.who-we-are .section-title { max-width: 640px; margin: 0 auto 16px; }
.who-we-are .section-sub { max-width: 760px; margin: 0 auto; font-size: 1.1rem; }

/* ── Services ────────────────────────────────────────────── */
.services {
  background: var(--bg);
  padding: 96px 0;
  scroll-margin-top: 72px;
}
.services-header { text-align: center; margin-bottom: 56px; }
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.service-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  scroll-margin-top: 96px;
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}
.service-icon {
  width: 56px;
  height: 56px;
  background: var(--primary-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: background var(--transition);
}
.service-card:hover .service-icon { background: var(--accent-light); }
.service-icon svg { width: 28px; height: 28px; stroke: var(--primary); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.service-card h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}
.service-tagline {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.service-card p { font-size: 0.95rem; color: var(--muted); line-height: 1.7; }

/* ── Quote ───────────────────────────────────────────────── */
.quote-section {
  background: var(--primary);
  padding: 96px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.quote-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at top right, rgba(255,255,255,0.06) 0%, transparent 70%);
}
.quote-inner { position: relative; z-index: 1; max-width: 800px; margin: 0 auto; }
.quote-icon {
  width: 52px; height: 52px;
  background: rgba(255,255,255,0.12);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 32px;
}
.quote-icon svg { width: 26px; height: 26px; stroke: #fff; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
blockquote {
  font-family: var(--font-serif);
  font-size: clamp(1.4rem, 3vw, 2.4rem);
  font-style: italic;
  font-weight: 400;
  color: #fff;
  line-height: 1.4;
  margin-bottom: 24px;
}
cite {
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 500;
  color: rgba(255,255,255,0.75);
  font-style: normal;
  letter-spacing: 0.05em;
}

/* ── CTA ─────────────────────────────────────────────────── */
.cta-section {
  background: var(--white);
  padding: 96px 0;
}
.cta-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 64px 48px;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}
.cta-box .section-title { margin-bottom: 16px; }
.cta-box .section-sub { max-width: 560px; margin: 0 auto 36px; }
.cta-arrow { display: inline-block; }

/* ── Footer ──────────────────────────────────────────────── */
footer {
  background: var(--footer-bg);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand .logo { margin-bottom: 12px; }
.footer-brand p { font-size: 0.9rem; color: var(--muted); line-height: 1.7; max-width: 300px; }
.footer-col h4 {
  font-family: var(--font-serif);
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a,
.footer-col ul li span {
  font-size: 0.9rem;
  color: var(--muted);
  transition: color var(--transition);
}
.footer-col ul li a:hover { color: var(--primary); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.footer-bottom p,
.footer-links span { font-size: 0.85rem; color: var(--muted); }
.footer-links { display: flex; gap: 20px; }

/* ── Contact Page ────────────────────────────────────────── */
.page-hero {
  background: linear-gradient(160deg, #e8f2fa 0%, var(--bg) 100%);
  padding: 72px 0 56px;
  text-align: center;
}
.page-hero .section-title { margin-bottom: 14px; }
.page-hero .section-sub { max-width: 560px; margin: 0 auto; }

.contact-section { padding: 64px 0 96px; }
.contact-layout {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 48px;
  align-items: start;
}

/* Form card */
.form-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-sm);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 20px; }
.form-group:last-of-type { margin-bottom: 0; }
label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
input, textarea, select {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}
input:focus, textarea:focus, select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(42,100,150,0.12);
}
textarea { resize: vertical; min-height: 140px; line-height: 1.6; }
.select-wrap { position: relative; }
.select-wrap select { padding-right: 40px; cursor: pointer; }
.select-wrap::after {
  content: '';
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 10px; height: 6px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%235a7a8e' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center;
  pointer-events: none;
}
.field-error {
  font-size: 0.8rem;
  color: #c0392b;
  display: none;
  margin-top: 2px;
}
.field-error.visible { display: block; }
input.invalid, textarea.invalid, select.invalid {
  border-color: #c0392b;
  background: #fdf5f5;
}

/* Success message */
.success-msg {
  display: none;
  background: var(--accent-light);
  border: 1.5px solid var(--accent);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 24px;
  color: #1a6040;
  font-weight: 500;
  font-size: 0.95rem;
}
.success-msg.visible { display: block; }

/* Info cards */
.info-cards { display: flex; flex-direction: column; gap: 16px; }
.info-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition);
}
.info-card:hover { box-shadow: var(--shadow-md); }
.info-card-icon {
  width: 46px; height: 46px;
  background: var(--primary-light);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.info-card-icon svg { width: 22px; height: 22px; stroke: var(--primary); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.info-card h3 { font-family: var(--font-serif); font-size: 0.95rem; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.info-card p { font-size: 0.95rem; font-weight: 500; color: var(--text); margin-bottom: 4px; }
.info-card span { font-size: 0.82rem; color: var(--muted); }

/* ── Animations ──────────────────────────────────────────── */
.fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible { opacity: 1; transform: none; }

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .hero-image-wrap { max-height: 340px; }
  .services-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-layout { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .desktop-nav { display: none; }
  .hamburger { display: flex; }
  .hero { padding: 56px 0 64px; }
  .hero-actions { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }
  .services-grid { grid-template-columns: 1fr; }
  .cta-box { padding: 40px 24px; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .form-card { padding: 24px; }
  blockquote { font-size: 1.4rem; }
}
