/* ============================================================
   mobile-home.css
   Mobile-only redesign of the Home page + shared header/footer.
   Everything visual lives inside @media(max-width:720px) so the
   DESKTOP layout is never affected. The small block below only
   hides brand-new mobile-only elements on larger screens.
   Loaded LAST so it wins over earlier mobile rules.
   ============================================================ */

/* Hide the new mobile-only elements on tablet / desktop (unscoped).
   These classes do not exist in the desktop design, so desktop is
   completely unchanged. */
.m-brand,
.m-actions,
.m-home,
.m-tabbar,
.m-more-sheet,
.m-more-backdrop{display:none}

@media(max-width:720px){

  /* ---------- global ---------- */
  body{
    padding-bottom:calc(78px + env(safe-area-inset-bottom))!important;
    background:#faf7ef;
  }

  /* ---------- HEADER ---------- */
  .site-header{
    height:auto;min-height:62px;
    background:#fdfcf7;
    border-bottom:1px solid #ece3d1;
    box-shadow:0 1px 0 rgba(0,0,0,.01);
  }
  /* Undo the pages.css 3-column grid; use a simple flex row instead */
  .site-header .header-inner{
    display:flex!important;grid-template-columns:none!important;
    align-items:center!important;justify-content:space-between!important;
    gap:10px!important;padding:9px 16px!important;
  }
  /* retire the previous mobile header pieces */
  .menu-toggle,
  .mobile-whatsapp,
  .main-nav,
  .header-actions,
  .nav-overlay{display:none!important}

  .site-header .brand{
    flex:0 0 auto!important;width:auto!important;height:auto!important;
    min-width:0!important;overflow:visible!important;
    justify-content:flex-start!important;text-decoration:none!important;
  }
  .site-header .brand>img{display:block!important;width:158px!important;height:64px!important;max-height:64px!important;object-fit:cover;object-position:center 58%}

  /* Desktop-only brand text never shows on mobile */
  .site-header .d-brand-text{display:none!important}

  .site-header .m-brand{display:none!important}
  .site-header .m-brand img{
    display:block!important;width:36px!important;height:36px!important;
    max-height:36px!important;flex:0 0 auto;object-fit:contain!important;
  }
  .site-header .m-brand-text{
    display:flex;flex-direction:column;justify-content:center;line-height:1.02;
  }
  .site-header .m-brand-name{
    font-family:var(--serif);font-weight:600;color:var(--green);
    font-size:26px;letter-spacing:.05em;line-height:1;white-space:nowrap;
  }
  .site-header .m-brand-tag{
    font-family:var(--sans);font-weight:500;color:var(--gold);
    font-size:9px;letter-spacing:.09em;text-transform:uppercase;
    line-height:1.1;white-space:nowrap;margin-top:2px;
  }

  .m-actions{display:flex;align-items:center;gap:10px;flex:0 0 auto}
  .m-wa{
    width:44px;height:44px;border:1.5px solid var(--green);
    border-radius:12px;display:flex;align-items:center;justify-content:center;
    color:var(--green);background:#fff;
  }
  .m-wa svg{width:22px;height:22px}
  .m-book{
    background:var(--green);color:#fff;border-radius:10px;
    padding:12px 22px;font-weight:600;text-decoration:none;font-size:15px;
  }
  .m-book:active{background:var(--green-2)}

  /* ---------- swap desktop home for mobile home ---------- */
  main>.hero,
  main>.trust-strip,
  main>.home-grid,
  main>.testimonials{display:none!important}
  .m-home{display:block;padding:14px 14px 6px}

  /* ---------- HERO CARD ---------- */
  .m-hero{
    position:relative;overflow:hidden;border-radius:16px;
    background:#f3eee1;border:1px solid #ece3d0;
    box-shadow:0 12px 30px rgba(40,30,10,.06);
    min-height:472px;
  }
  .m-hero-photo{position:absolute;top:0;right:0;bottom:0;width:52%}
  .m-hero-photo img{width:100%;height:100%;object-fit:cover;object-position:46% 12%}
  .m-hero-photo::after{
    content:"";position:absolute;inset:0;
    background:linear-gradient(90deg,#f3eee1 2%,rgba(243,238,225,.78) 22%,rgba(243,238,225,0) 54%);
  }
  .m-hero-body{position:relative;z-index:2;padding:22px 18px 22px}
  .m-eyebrow{
    margin:0 0 13px;text-transform:uppercase;letter-spacing:.14em;
    color:var(--gold);font-size:11px;font-weight:700;
  }
  .m-hero-body h1{
    font-family:var(--serif);color:var(--green);font-weight:600;
    font-size:39px;line-height:1.06;margin:0;
  }
  .m-hero-lead{
    color:#3b423c;font-size:14px;line-height:1.55;
    margin:16px 0 22px;max-width:54%;
  }
  .m-hero-cta{display:flex;flex-direction:column;gap:12px;max-width:74%}
  .m-btn{
    display:flex;align-items:center;gap:10px;justify-content:flex-start;
    border-radius:11px;padding:15px 18px;font-weight:600;font-size:14.5px;
    text-decoration:none;white-space:nowrap;
  }
  .m-btn svg{width:18px;height:18px;flex:none}
  .m-btn-primary{background:var(--green);color:#fff}
  .m-btn-primary:active{background:var(--green-2)}
  .m-btn-outline{background:rgba(255,255,255,.9);color:var(--green);border:1.5px solid var(--green)}

  /* ---------- TRUST STRIP ---------- */
  .m-trust{
    display:grid;grid-template-columns:repeat(3,1fr);
    margin:20px 2px 4px;background:#fbf8f0;border:1px solid #efe6d4;
    border-radius:14px;padding:18px 4px;
  }
  .m-trust div{
    display:flex;flex-direction:column;align-items:center;text-align:center;
    gap:9px;padding:2px 8px;border-right:1px solid #ece2cf;
  }
  .m-trust div:last-child{border-right:0}
  .m-trust svg{width:27px;height:27px;color:var(--gold)}
  .m-trust b{font-weight:600;font-size:13.5px;color:#25302a;line-height:1.25}

  /* ---------- SECTION TITLE ---------- */
  .m-sec-title{
    display:flex;align-items:center;justify-content:center;gap:10px;
    margin:28px 0 16px;font-family:var(--serif);color:var(--green);
    font-size:24px;font-weight:600;white-space:nowrap;
  }
  .m-sprig{width:24px;height:14px;color:var(--gold);flex:none}
  .m-sprig.r{transform:scaleX(-1)}

  /* ---------- SERVICE GRID ---------- */
  .m-serv{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
  .m-serv a{
    background:#fff;border:1px solid #efe6d4;border-radius:12px;
    padding:20px 6px 14px;display:flex;flex-direction:column;align-items:center;
    gap:13px;text-decoration:none;box-shadow:0 4px 14px rgba(40,30,10,.04);
  }
  .m-serv a:active{transform:translateY(1px)}
  .m-serv .ic{
    width:58px;height:58px;border:1.5px solid #cdd8cd;border-radius:50%;
    display:flex;align-items:center;justify-content:center;color:var(--green);
  }
  .m-serv .ic svg{width:26px;height:26px}
  .m-serv .ic .num{font-family:var(--serif);font-size:15px;letter-spacing:.02em;color:var(--green)}
  .m-serv span{font-size:13px;color:#25302a;text-align:center;line-height:1.22}

  /* ---------- MEET HRPITA ---------- */
  .m-about{
    display:flex;gap:15px;align-items:stretch;margin:22px 2px 0;
    background:#fbf8f0;border:1px solid #efe6d4;border-radius:14px;padding:16px;
    text-decoration:none;
  }
  .m-about img{width:112px;height:158px;object-fit:cover;border-radius:10px;flex:none}
  .m-about h3{font-family:var(--serif);color:var(--green);font-size:24px;font-weight:600;margin:2px 0 5px}
  .m-about .role{color:var(--gold);font-weight:600;font-size:14px;margin:0 0 8px}
  .m-about p{color:#3b423c;font-size:12.5px;line-height:1.5;margin:0}

  /* ---------- CLIENT EXPERIENCE ---------- */
  .m-quote{
    display:flex;gap:15px;margin:16px 2px 6px;background:#eef3ea;
    border:1px solid #dfe7da;border-radius:14px;padding:18px 16px;position:relative;
  }
  .m-quote .badge{
    flex:none;width:66px;height:66px;border-radius:50%;background:var(--green);
    display:flex;align-items:center;justify-content:center;
  }
  .m-quote .badge svg{width:30px;height:30px;color:var(--gold)}
  .m-quote h3{font-family:var(--serif);color:var(--green);font-size:24px;font-weight:600;margin:0 0 8px}
  .m-quote blockquote{margin:0;font-family:var(--serif);font-style:italic;color:#2c3a30;font-size:16px;line-height:1.42}
  .m-quote .who{color:#3b423c;font-size:13px;margin-top:5px}
  .m-quote .dots{position:absolute;right:16px;bottom:16px;display:flex;gap:6px}
  .m-quote .dots i{width:8px;height:8px;border-radius:50%;background:#c9cfc6}
  .m-quote .dots i:first-child{background:var(--green)}

  /* ---------- BOTTOM TAB BAR ---------- */
  .mobile-action-bar{display:none!important}
  .m-tabbar{
    position:fixed;left:0;right:0;bottom:0;z-index:60;
    background:#fffdf9;border-top:1px solid #efe6d4;
    border-radius:20px 20px 0 0;box-shadow:0 -6px 22px rgba(0,0,0,.07);
    display:grid;grid-template-columns:repeat(5,1fr);align-items:end;
    padding:9px 4px calc(9px + env(safe-area-inset-bottom));
    height:calc(72px + env(safe-area-inset-bottom));
  }
  .m-tabbar a{
    display:flex;flex-direction:column;align-items:center;gap:5px;
    text-decoration:none;color:#7b8078;font-size:10.5px;font-weight:500;
    padding-bottom:2px;
  }
  .m-tabbar a svg{width:23px;height:23px}
  .m-tabbar a.active{color:var(--green)}
  .m-tabbar .tab-appt{color:var(--gold);justify-content:flex-end}
  .m-tabbar .tab-appt .ic{
    width:56px;height:56px;border-radius:50%;background:var(--gold);
    display:flex;align-items:center;justify-content:center;margin-top:-28px;
    box-shadow:0 8px 18px rgba(200,150,40,.42);border:4px solid #fffdf9;
  }
  .m-tabbar .tab-appt .ic svg{width:25px;height:25px;color:#fff}

  /* ---------- MORE SHEET ---------- */
  .m-more-backdrop{
    display:block;position:fixed;inset:0;background:rgba(0,0,0,.42);z-index:150;
    opacity:0;visibility:hidden;transition:.28s;
  }
  .m-more-backdrop.open{opacity:1;visibility:visible}
  .m-more-sheet{
    display:block;position:fixed;left:0;right:0;bottom:0;z-index:200;
    background:#fffdf9;border-radius:20px 20px 0 0;
    padding:14px 20px calc(24px + env(safe-area-inset-bottom));
    box-shadow:0 -12px 40px rgba(0,0,0,.22);
    transform:translateY(112%);transition:transform .3s cubic-bezier(.22,1,.36,1);
  }
  .m-more-sheet.open{transform:none}
  .m-more-sheet[hidden],.m-more-backdrop[hidden]{display:none!important}
  .m-more-sheet .grip{width:44px;height:5px;border-radius:3px;background:#e0d8c6;margin:0 auto 12px}
  .m-more-sheet h4{font-family:var(--serif);color:var(--green);font-size:22px;margin:0 0 6px}
  .m-more-sheet a{
    display:flex;align-items:center;gap:13px;padding:14px 4px;
    border-bottom:1px solid #f2ecdd;color:#25302a;text-decoration:none;
    font-weight:500;font-size:15px;
  }
  .m-more-sheet a:last-child{border-bottom:0}
  .m-more-sheet a svg{width:20px;height:20px;color:var(--green);flex:none}
}

/* Extra tightening for the smallest phones */
@media(max-width:390px){
  .m-hero-body h1{font-size:36px}
  .m-hero-lead{font-size:13.5px;max-width:56%}
  .m-serv .ic{width:54px;height:54px}
  .m-serv span{font-size:12px}
  .m-brand-name{font-size:24px}
  .m-book{padding:12px 18px}
}
