/* ===== Hayah Medical Lab — shared styles ===== */
:root {
  --brand: #0f6a8b;
  --brand-dark: #0a4a63;
  --brand-deep: #073246;
  --brand-light: #e7f4f9;
  --accent: #c8161d;
  --accent-dark: #a01016;
  --wa: #25d366;
  --wa-dark: #1da851;
  --ink: #12222c;
  --muted: #5b6f7b;
  --line: #dbe7ec;
  --bg: #f6fafc;
  --card: #ffffff;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(7, 50, 70, .10);
  --shadow-lg: 0 20px 50px rgba(7, 50, 70, .18);
  --header-h: 72px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  font-family: "Cairo", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 .5em; }
p { margin: 0 0 1em; }

/* Language switching: hide the inactive language */
html[lang="ar"] body [lang="en"],
html[lang="en"] body [lang="ar"] { display: none !important; }
.ltr { direction: ltr; unicode-bidi: embed; display: inline-block; }

.container { width: min(1180px, 100% - 32px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55em;
  padding: .8em 1.4em; border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; font-size: 1rem; transition: transform .15s, background .2s, box-shadow .2s;
  white-space: nowrap;
}
.btn svg { width: 1.25em; height: 1.25em; flex: none; }
.btn:hover { transform: translateY(-2px); }
.btn-wa { background: var(--wa); color: #fff; box-shadow: 0 8px 20px rgba(37, 211, 102, .35); }
.btn-wa:hover { background: var(--wa-dark); }
.btn-call { background: var(--accent); color: #fff; box-shadow: 0 8px 20px rgba(200, 22, 29, .3); }
.btn-call:hover { background: var(--accent-dark); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-ghost { border-color: rgba(255, 255, 255, .7); color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, .12); }
.btn-outline { border-color: var(--brand); color: var(--brand); background: transparent; }
.btn-outline:hover { background: var(--brand-light); }
.btn-sm { padding: .55em 1em; font-size: .92rem; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: rgba(255, 255, 255, .92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .container { height: 100%; display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; flex: none; }
.brand img { width: 48px; height: 48px; border-radius: 12px; object-fit: cover; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 1.15rem; color: var(--brand-dark); }
.brand-text small { font-size: .78rem; color: var(--muted); }

.main-nav { margin-inline-start: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.main-nav a {
  display: block; padding: .45em .8em; border-radius: 10px; font-weight: 600; color: var(--ink);
  transition: background .2s, color .2s;
}
.main-nav a:hover, .main-nav a.active { background: var(--brand-light); color: var(--brand); }

.header-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  border: none; flex: none; transition: transform .15s;
}
.icon-btn:hover { transform: scale(1.07); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn.call { background: var(--accent); color: #fff; }
.icon-btn.wa { background: var(--wa); color: #fff; }
.lang-toggle {
  height: 44px; padding: 0 14px; border-radius: 999px; border: 2px solid var(--brand);
  background: #fff; color: var(--brand); font-weight: 800;
}
.lang-toggle:hover { background: var(--brand-light); }
.menu-toggle { display: none; background: var(--brand-light); color: var(--brand); }

/* ===== Hero ===== */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, .12), transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(200, 22, 29, .18), transparent 45%),
    linear-gradient(135deg, #1580a6 0%, var(--brand) 45%, var(--brand-deep) 100%);
}
.hero::before {
  content: ""; position: absolute; inset: 0; opacity: .18; pointer-events: none;
  background-image:
    radial-gradient(circle, #9fe3ff 2px, transparent 2.5px),
    linear-gradient(35deg, transparent 49.5%, rgba(159, 227, 255, .6) 50%, transparent 50.5%);
  background-size: 90px 90px, 180px 180px;
}
.hero .container {
  position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px;
  align-items: center; padding-block: 72px 88px;
}
.badge {
  display: inline-flex; align-items: center; gap: .5em; padding: .35em 1em; border-radius: 999px;
  background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .25);
  font-weight: 600; font-size: .92rem; margin-bottom: 18px;
}
.badge .dot { width: 8px; height: 8px; border-radius: 50%; background: #5df29a; box-shadow: 0 0 0 4px rgba(93, 242, 154, .25); }
.hero h1 { font-size: clamp(2.1rem, 5vw, 3.6rem); font-weight: 900; margin-bottom: .25em; }
.hero h1 .hl { color: #ffd4d6; }
.hero .tagline { font-size: clamp(1.15rem, 2.4vw, 1.5rem); font-weight: 700; opacity: .95; margin-bottom: .6em; }
.hero .lead { font-size: 1.08rem; opacity: .9; max-width: 560px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 28px; padding: 0; list-style: none; font-weight: 600; }
.hero-points li { display: flex; align-items: center; gap: .45em; }
.hero-points svg { width: 20px; height: 20px; color: #5df29a; flex: none; }

.hero-visual { position: relative; }
.hero-visual .main-img {
  border-radius: 26px; box-shadow: var(--shadow-lg); border: 6px solid rgba(255, 255, 255, .18);
  aspect-ratio: 1 / 1; object-fit: cover; width: 100%;
}
.float-card {
  position: absolute; background: #fff; color: var(--ink); border-radius: 16px; padding: 12px 16px;
  box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 12px; font-weight: 700;
}
.float-card .ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex: none; }
.float-card .ic svg { width: 22px; height: 22px; }
.float-card small { display: block; font-weight: 500; color: var(--muted); font-size: .8rem; }
.float-card.one { bottom: -18px; inset-inline-start: -24px; }
.float-card.one .ic { background: #ffe8e9; color: var(--accent); }
.float-card.two { top: 24px; inset-inline-end: -20px; }
.float-card.two .ic { background: #e3f9ec; color: #16a34a; }

.wave { position: absolute; bottom: -1px; left: 0; width: 100%; height: 60px; color: var(--bg); }

/* ===== Sections ===== */
section { padding-block: 80px; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 44px; }
.eyebrow {
  display: inline-block; color: var(--accent); font-weight: 800; font-size: .9rem;
  letter-spacing: .04em; margin-bottom: 6px;
}
.section-head h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); color: var(--brand-deep); font-weight: 900; }
.section-head p { color: var(--muted); font-size: 1.05rem; }
.alt { background: #fff; }

/* Features strip */
.features { margin-top: -50px; position: relative; z-index: 2; padding: 0; }
.features-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.feature {
  background: #fff; border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow);
  display: flex; gap: 14px; align-items: flex-start;
}
.feature .ic {
  width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; flex: none;
  background: var(--brand-light); color: var(--brand);
}
.feature .ic svg { width: 26px; height: 26px; }
.feature h3 { font-size: 1.05rem; margin-bottom: .2em; }
.feature p { font-size: .92rem; color: var(--muted); margin: 0; }

/* Services */
.services-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; }
.service {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px;
  transition: transform .2s, box-shadow .2s, border-color .2s; position: relative; overflow: hidden;
}
.service::after {
  content: ""; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px;
  background: linear-gradient(var(--brand), var(--accent)); opacity: 0; transition: opacity .2s;
}
.service:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.service:hover::after { opacity: 1; }
.service .ic {
  width: 54px; height: 54px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 14px;
  background: linear-gradient(135deg, var(--brand-light), #fff); color: var(--brand); border: 1px solid var(--line);
}
.service .ic svg { width: 28px; height: 28px; }
.service h3 { font-size: 1.08rem; color: var(--brand-deep); margin-bottom: .3em; }
.service p { font-size: .93rem; color: var(--muted); margin: 0; }

/* Packages */
.packages-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; align-items: start; }
.pkg {
  background: #fff; border-radius: 22px; box-shadow: var(--shadow); overflow: hidden;
  display: flex; flex-direction: column; border: 2px solid transparent; position: relative;
}
.pkg.featured { border-color: var(--accent); }
.pkg-ribbon {
  position: absolute; top: 16px; inset-inline-end: 16px; background: var(--accent); color: #fff;
  font-size: .78rem; font-weight: 800; padding: .25em .8em; border-radius: 999px;
}
.pkg-top { padding: 26px 24px 20px; background: linear-gradient(135deg, var(--brand), var(--brand-deep)); color: #fff; }
.pkg-name { font-size: 1.4rem; font-weight: 900; direction: ltr; text-align: start; margin: 0; }
.pkg-count { opacity: .9; font-weight: 600; }
.pkg-price { display: flex; align-items: baseline; gap: 8px; margin-top: 12px; }
.pkg-price strong { font-size: 2.6rem; font-weight: 900; line-height: 1; }
.pkg-price span { font-weight: 700; opacity: .9; }
.pkg-body { padding: 20px 24px 24px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.pkg-groups { display: flex; flex-direction: column; gap: 10px; }
.pkg-group h4 { font-size: .95rem; color: var(--brand-dark); margin: 0 0 6px; display: flex; align-items: center; gap: 6px; }
.pkg-group h4::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  font-size: .8rem; padding: .2em .65em; border-radius: 8px; background: var(--brand-light);
  color: var(--brand-deep); font-weight: 600; direction: ltr;
}
.pkg-more { max-height: 230px; overflow: hidden; position: relative; transition: max-height .4s ease; }
.pkg-more.collapsible::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 70px;
  background: linear-gradient(transparent, #fff); pointer-events: none; transition: opacity .3s;
}
.pkg-more.open { max-height: 2000px; }
.pkg-more.open::after { opacity: 0; }
.link-btn { background: none; border: none; color: var(--brand); font-weight: 700; padding: 0; text-align: start; }
.link-btn:hover { text-decoration: underline; }
.pkg-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; }
.pkg-actions .btn { flex: 1 1 auto; }
.pkg-note { text-align: center; color: var(--muted); margin-top: 26px; font-size: .95rem; }

/* Home sampling */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.split img { border-radius: 24px; box-shadow: var(--shadow-lg); width: 100%; }
.check-list { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 12px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; font-weight: 600; }
.check-list svg { width: 26px; height: 26px; color: #fff; background: var(--wa); border-radius: 50%; padding: 4px; flex: none; }
.split h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); color: var(--brand-deep); font-weight: 900; }

/* Doctor */
.doctor {
  background: linear-gradient(135deg, var(--brand-deep), var(--brand)); color: #fff; border-radius: 28px;
  padding: 44px; display: grid; grid-template-columns: auto 1fr; gap: 36px; align-items: center; box-shadow: var(--shadow-lg);
}
.doctor-avatar {
  width: 150px; height: 150px; border-radius: 50%; background: #fff; display: grid; place-items: center;
  overflow: hidden; border: 6px solid rgba(255, 255, 255, .25);
}
.doctor-avatar img { width: 100%; height: 100%; object-fit: cover; }
.doctor h3 { font-size: 1.7rem; font-weight: 900; }
.doctor ul { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 8px; }
.doctor li { display: flex; gap: 10px; align-items: center; font-weight: 600; }
.doctor li::before { content: ""; width: 10px; height: 10px; background: var(--accent); border-radius: 3px; flex: none; }

/* Gallery */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 210px; grid-auto-flow: dense; gap: 14px; }
.gallery button {
  border: none; padding: 0; border-radius: 16px; overflow: hidden; position: relative; background: #ddd;
}
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery button:hover img { transform: scale(1.06); }
.gallery .tall { grid-row: span 2; }
.gallery .wide { grid-column: span 2; }
.gallery .cap {
  position: absolute; inset-inline: 0; bottom: 0; padding: 30px 14px 10px; color: #fff; font-weight: 700;
  font-size: .92rem; background: linear-gradient(transparent, rgba(0, 0, 0, .65)); text-align: start;
}

/* Contact */
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
.contact-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px;
  display: flex; flex-direction: column; gap: 10px;
}
.contact-card .ic { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; color: #fff; }
.contact-card .ic svg { width: 26px; height: 26px; }
.contact-card h3 { font-size: 1.05rem; margin: 4px 0 0; color: var(--brand-deep); }
.contact-card .num { font-size: 1.25rem; font-weight: 800; direction: ltr; text-align: start; color: var(--ink); }
.contact-card .row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; }
.bg-wa { background: var(--wa); }
.bg-call { background: var(--accent); }
.bg-brand { background: var(--brand); }

/* CTA band */
.cta-band {
  background: linear-gradient(135deg, var(--accent), #8f0c12); color: #fff; border-radius: 26px; padding: 40px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px;
}
.cta-band h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin: 0; font-weight: 900; }
.cta-band p { margin: 6px 0 0; opacity: .9; }
.cta-band .btn-wa { box-shadow: none; }
.cta-band .row { display: flex; flex-wrap: wrap; gap: 12px; }
.btn-white { background: #fff; color: var(--accent); }

/* Location page */
.page-hero {
  color: #fff; padding-block: 56px 70px; position: relative; overflow: hidden;
  background: linear-gradient(135deg, #1580a6, var(--brand-deep));
}
.page-hero h1 { font-size: clamp(1.9rem, 4.5vw, 3rem); font-weight: 900; }
.page-hero p { opacity: .9; font-size: 1.08rem; max-width: 640px; margin: 0; }
.breadcrumb { font-size: .9rem; opacity: .85; margin-bottom: 10px; }
.breadcrumb a { text-decoration: underline; }
.map-layout { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; margin-top: -40px; position: relative; }
.map-frame {
  background: #fff; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg);
  min-height: 460px; border: 6px solid #fff;
}
.map-frame iframe { width: 100%; height: 100%; min-height: 460px; border: 0; display: block; border-radius: 18px; }
.info-card { background: #fff; border-radius: 24px; padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 18px; }
.info-item { display: flex; gap: 14px; align-items: flex-start; }
.info-item .ic { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--brand-light); color: var(--brand); }
.info-item .ic svg { width: 24px; height: 24px; }
.info-item h3 { font-size: 1rem; margin: 0 0 2px; color: var(--brand-deep); }
.info-item p { margin: 0; color: var(--muted); }
.info-item a.num { font-weight: 800; color: var(--ink); direction: ltr; display: inline-block; }
.info-card .btns { display: grid; gap: 10px; }
.landmarks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.landmarks figure { margin: 0; background: #fff; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); }
.landmarks img { width: 100%; height: 240px; object-fit: cover; }
.landmarks figcaption { padding: 12px 16px; font-weight: 700; color: var(--brand-deep); }

/* ===== Footer ===== */
.site-footer { background: var(--brand-deep); color: #cfe3ec; padding-block: 56px 24px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 36px; }
.site-footer h4 { color: #fff; font-size: 1.05rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer .brand-text strong { color: #fff; }
.site-footer .brand-text small { color: #9ec3d3; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 36px; padding-top: 20px; text-align: center; font-size: .88rem; color: #9ec3d3; }

/* ===== Floating contact buttons ===== */
.fab-stack { position: fixed; bottom: 20px; inset-inline-end: 20px; z-index: 60; display: flex; flex-direction: column; gap: 12px; }
.fab {
  width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center; color: #fff;
  box-shadow: 0 10px 25px rgba(0, 0, 0, .25); transition: transform .2s; position: relative;
}
.fab:hover { transform: scale(1.08); }
.fab svg { width: 30px; height: 30px; }
.fab.wa { background: var(--wa); }
.fab.wa::before {
  content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--wa);
  animation: pulse 2s infinite; z-index: -1;
}
.fab.call { background: var(--accent); }
@keyframes pulse { 0% { transform: scale(1); opacity: .6; } 100% { transform: scale(1.6); opacity: 0; } }

/* Mobile bottom contact bar */
.mobile-bar { display: none; }

/* ===== Lightbox ===== */
.lightbox {
  position: fixed; inset: 0; z-index: 100; background: rgba(4, 20, 28, .92);
  display: none; align-items: center; justify-content: center; padding: 20px;
}
.lightbox.open { display: flex; }
.lightbox img { max-height: 90vh; max-width: min(1000px, 100%); border-radius: 12px; object-fit: contain; }
.lightbox .close {
  position: absolute; top: 16px; inset-inline-end: 16px; width: 48px; height: 48px; border-radius: 50%;
  background: #fff; border: none; font-size: 26px; line-height: 1; color: var(--ink);
}

/* Reveal animation */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .fab.wa::before { animation: none; }
}

/* ===== Responsive ===== */
@media (max-width: 1080px) {
  .main-nav a { padding: .45em .55em; font-size: .95rem; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 920px) {
  .menu-toggle { display: grid; }
  .main-nav {
    position: fixed; top: var(--header-h); inset-inline: 0; background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow); transform: translateY(-120%); transition: transform .3s; z-index: -1; margin: 0;
  }
  .main-nav.open { transform: none; }
  .main-nav ul { flex-direction: column; padding: 12px 16px 18px; }
  .main-nav a { padding: .8em 1em; font-size: 1.05rem; }
  .header-actions { margin-inline-start: auto; }

  .hero .container { grid-template-columns: 1fr; padding-block: 48px 90px; gap: 40px; }
  .hero-visual { max-width: 440px; margin-inline: auto; width: 100%; }
  .float-card.one { inset-inline-start: 0; }
  .float-card.two { inset-inline-end: 0; }
  .split { grid-template-columns: 1fr; gap: 28px; }
  .doctor { grid-template-columns: 1fr; text-align: center; padding: 32px 22px; }
  .doctor-avatar { margin-inline: auto; }
  .doctor ul { justify-items: center; }
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 180px; }
  .map-layout { grid-template-columns: 1fr; }
  .landmarks { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 600px) {
  :root { --header-h: 64px; }
  section { padding-block: 56px; }
  .brand img { width: 42px; height: 42px; }
  .brand-text small { display: none; }
  .header-actions .icon-btn.wa { display: none; }
  .icon-btn, .lang-toggle { height: 40px; }
  .icon-btn { width: 40px; }
  .lang-toggle { padding: 0 10px; }
  .hero-cta .btn { flex: 1 1 100%; }
  .features { margin-top: -40px; }
  .features-grid { grid-template-columns: 1fr; gap: 12px; }
  .packages-grid { grid-template-columns: 1fr; }
  .gallery { grid-auto-rows: 140px; gap: 10px; }
  .gallery .wide { grid-column: span 2; }
  .landmarks { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .cta-band { padding: 28px 22px; }
  .cta-band .row, .cta-band .row .btn { width: 100%; }
  .map-frame, .map-frame iframe { min-height: 340px; }

  /* Swap floating buttons for a bottom bar on phones */
  .fab-stack { display: none; }
  .mobile-bar {
    display: grid; grid-template-columns: 1fr 1fr; gap: 8px; position: fixed; bottom: 0; inset-inline: 0; z-index: 60;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line);
    box-shadow: 0 -6px 20px rgba(0, 0, 0, .08);
  }
  .mobile-bar .btn { width: 100%; padding: .75em 1em; box-shadow: none; }
  body { padding-bottom: 72px; }
}
