/* BuyFlowers SG v4.0 — clean breakpoint ownership for header/footer/mobile nav. */

/* ---------- Utility bar ---------- */
.util{background:var(--emerald-deep);color:#D8E6DF}
.util .wrap{display:flex!important;align-items:center;justify-content:center!important;min-height:34px}
.util .left{display:block!important;margin:0;text-align:center;font-size:12px;line-height:1.35}
.util .partner,.util .util-proof{display:none!important}

/* ---------- Header: desktop default ---------- */
.site-header-v40{position:sticky;top:0;z-index:70;background:rgba(255,252,248,.97);border-bottom:1px solid rgba(22,17,15,.09);box-shadow:0 8px 28px rgba(22,17,15,.035);backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px)}
.site-header-v40 .nav{position:relative;display:flex!important;align-items:center!important;height:70px!important;min-height:70px!important;gap:22px!important}
.site-header-v40 .brand{display:flex!important;align-items:center;flex:none}
.site-header-v40 .custom-brand-logo{display:block;max-width:174px!important;max-height:40px!important;width:auto!important;height:auto!important}

/* Explicit ownership: desktop navigation only. */
.site-header-v40 .site-navigation{display:block!important;position:static!important;flex:0 1 auto;min-width:0;background:transparent!important;border:0!important;box-shadow:none!important;padding:0!important;max-height:none!important;overflow:visible!important}
.site-header-v40 .site-navigation>.menu{display:flex!important;align-items:center!important;flex-direction:row!important;gap:5px!important;margin:0!important;padding:0!important;border:0!important;list-style:none!important}
.site-header-v40 .site-navigation>.menu>li{display:block!important;width:auto!important;margin:0!important;padding:0!important}
.site-header-v40 .site-navigation>.menu a{display:inline-flex!important;align-items:center;min-height:36px;padding:0 10px!important;border:0!important;border-radius:9px;color:#403B37!important;font-size:13.5px;font-weight:650;line-height:1!important;text-decoration:none;opacity:1!important;white-space:nowrap;transition:background .16s ease,color .16s ease}
.site-header-v40 .site-navigation>.menu a:hover{background:#F1EBE4!important;color:var(--emerald)!important}
.site-header-v40 .menu-explore-item{display:flex!important;align-items:center}
.site-header-v40 .explore-toggle{appearance:none;display:inline-flex!important;align-items:center;gap:5px;min-height:36px;padding:0 10px!important;border:1px solid transparent!important;border-radius:9px;background:transparent!important;color:var(--emerald)!important;font:inherit;font-size:13.5px!important;font-weight:700!important;line-height:1;cursor:pointer}
.site-header-v40 .explore-toggle:hover,.site-header-v40 .explore-toggle[aria-expanded="true"]{background:#EAF1ED!important;border-color:rgba(15,76,58,.12)!important;color:var(--emerald)!important}
.site-header-v40 .explore-toggle svg{transition:transform .16s ease}
.site-header-v40 .explore-toggle[aria-expanded="true"] svg{transform:rotate(180deg)}

/* Occasions: Singapore-first upcoming event dropdown. */
.site-header-v40 .menu-occasions-item{position:relative!important;display:flex!important;align-items:center}
.site-header-v40 .occasion-menu{position:relative}
.site-header-v40 .occasion-menu>summary{list-style:none;display:inline-flex;align-items:center;gap:5px;min-height:36px;padding:0 10px;border:1px solid transparent;border-radius:9px;color:#403B37;font-size:13.5px;font-weight:700;line-height:1;white-space:nowrap;cursor:pointer;transition:background .16s ease,color .16s ease,border-color .16s ease}
.site-header-v40 .occasion-menu>summary::-webkit-details-marker{display:none}
.site-header-v40 .occasion-menu>summary::marker{display:none;content:""}
.site-header-v40 .occasion-menu>summary:hover,.site-header-v40 .occasion-menu[open]>summary{background:#F1EBE4;border-color:rgba(15,76,58,.10);color:var(--emerald)}
.site-header-v40 .occasion-menu>summary svg{transition:transform .16s ease}
.site-header-v40 .occasion-menu[open]>summary svg{transform:rotate(180deg)}
.site-header-v40 .occasion-dropdown{position:absolute;top:calc(100% + 12px);left:50%;z-index:160;width:330px;transform:translateX(-50%);padding:10px;border:1px solid rgba(22,17,15,.10);border-radius:15px;background:#FFFDFB;box-shadow:0 22px 48px rgba(22,17,15,.16)}
.site-header-v40 .occasion-dropdown::before{content:"";position:absolute;left:0;right:0;top:-12px;height:12px}
.site-header-v40 .occasion-dropdown-head{padding:5px 8px 9px}
.site-header-v40 .occasion-dropdown-head strong{display:block;color:var(--ink);font-size:13.5px;line-height:1.3}
.site-header-v40 .occasion-dropdown-head span{display:block;margin-top:3px;color:#7B746E;font-size:11.5px;line-height:1.35}
.site-header-v40 .occasion-event-list{border-top:1px solid rgba(22,17,15,.08);border-bottom:1px solid rgba(22,17,15,.08)}
.site-header-v40 .occasion-dropdown .occasion-event{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;align-items:center!important;gap:14px!important;width:100%!important;min-height:0!important;padding:9px 8px!important;border-radius:8px!important;color:#292522!important;font-size:12.75px!important;font-weight:600!important;line-height:1.25!important;white-space:normal!important}
.site-header-v40 .occasion-dropdown .occasion-event+.occasion-event{border-top:1px solid rgba(22,17,15,.06)!important}
.site-header-v40 .occasion-dropdown .occasion-event:hover{background:#F5F0EA!important;color:var(--emerald)!important}
.site-header-v40 .occasion-event time{color:#827A73;font-size:11.5px;font-weight:600;font-variant-numeric:tabular-nums;white-space:nowrap}
.site-header-v40 .occasion-dropdown .occasion-all-link{display:flex!important;align-items:center!important;justify-content:space-between!important;width:100%!important;min-height:36px!important;margin-top:7px;padding:0 8px!important;color:var(--emerald)!important;font-size:12px!important;font-weight:750!important}

/* Never expose drawer tools on desktop. */
.site-header-v40 .mobile-nav-tools{display:none!important}
.site-header-v40 .mobile-guide-cta{display:none!important}
.site-header-v40 .menu-btn{display:none!important}

.site-header-v40 .header-actions{display:flex!important;align-items:center;gap:9px;margin-left:auto;flex:none}
.site-header-v40 .header-actions .header-search{display:flex!important;align-items:center;gap:8px;width:218px;min-height:40px;margin:0!important;padding:8px 12px!important;border:1px solid rgba(22,17,15,.12)!important;border-radius:11px!important;background:#fff!important;color:#6F6963;box-shadow:none!important}
.site-header-v40 .header-actions .header-search:focus-within{border-color:rgba(15,76,58,.38)!important;box-shadow:0 0 0 3px rgba(15,76,58,.07)!important}
.site-header-v40 .header-actions .header-search input{display:block!important;width:100%!important;min-width:0;border:0!important;outline:0!important;background:transparent!important;box-shadow:none!important;padding:0!important;color:var(--ink)!important;font-family:inherit;font-size:12.75px!important}
.site-header-v40 .header-guide-cta{display:inline-flex!important;align-items:center;gap:7px;min-height:40px;padding:0 15px!important;border-radius:11px!important;background:var(--emerald)!important;color:#fff!important;font-size:12.25px!important;font-weight:700;text-decoration:none;white-space:nowrap;box-shadow:none!important}
.site-header-v40 .header-guide-cta:hover{background:var(--emerald-deep)!important;color:#fff!important}

/* Explore panel */
.site-header-v40 .explore-panel{position:absolute;left:0;right:0;top:100%;z-index:120;background:#FCF9F5;border-top:1px solid rgba(22,17,15,.08);border-bottom:1px solid var(--line);box-shadow:0 30px 64px rgba(22,17,15,.16);max-height:min(76vh,760px);overflow:auto}
.site-header-v40 .explore-panel[hidden]{display:none!important}
.site-header-v40 .explore-shell{padding-top:24px;padding-bottom:28px}

/* ---------- Compressed desktop ---------- */
@media (max-width:1180px) and (min-width:901px){
  .site-header-v40 .nav{gap:14px!important}
  .site-header-v40 .custom-brand-logo{max-width:158px!important}
  .site-header-v40 .site-navigation>.menu{gap:2px!important}
  .site-header-v40 .site-navigation>.menu a,.site-header-v40 .explore-toggle{padding-left:8px!important;padding-right:8px!important;font-size:13px!important}
  .site-header-v40 .header-actions .header-search{display:none!important}
  .site-header-v40 .header-guide-cta{min-height:38px;padding:0 13px!important}
}

/* ---------- Mobile / tablet header ---------- */
@media (max-width:900px){
  .util{display:none!important}
  .site-header-v40 .nav{height:62px!important;min-height:62px!important;gap:12px!important}
  .site-header-v40 .custom-brand-logo{max-width:150px!important;max-height:36px!important}

  /* Closed state: only logo + hamburger. */
  .site-header-v40 .site-navigation{display:none!important}
  .site-header-v40 .header-actions{display:none!important}
  .site-header-v40 .menu-btn{display:flex!important;align-items:center;justify-content:center;width:42px;height:42px;margin-left:auto!important;padding:0!important;border:1px solid rgba(22,17,15,.11)!important;border-radius:11px;background:#fff!important;box-shadow:0 1px 0 rgba(22,17,15,.03);cursor:pointer}

  /* Open state: one drawer, never desktop actions. */
  .site-header-v40 .nav.menu-open .site-navigation{display:block!important;position:absolute!important;left:0!important;right:0!important;top:100%!important;z-index:130!important;max-height:calc(100vh - 62px)!important;overflow:auto!important;padding:14px 18px 18px!important;border-top:1px solid rgba(22,17,15,.07)!important;border-bottom:1px solid rgba(22,17,15,.10)!important;background:#FCF9F5!important;box-shadow:0 22px 44px rgba(22,17,15,.14)!important}
  .site-header-v40 .nav.menu-open .site-navigation>.menu{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:3px!important;padding:0 0 12px!important;border-bottom:1px solid rgba(22,17,15,.09)!important}
  .site-header-v40 .nav.menu-open .site-navigation>.menu>li{display:block!important;width:100%!important}
  .site-header-v40 .nav.menu-open .site-navigation>.menu a{display:flex!important;width:100%!important;min-height:42px;padding:0 10px!important;font-size:14px!important}
  .site-header-v40 .nav.menu-open .menu-occasions-item{display:block!important}
  .site-header-v40 .nav.menu-open .occasion-menu{width:100%}
  .site-header-v40 .nav.menu-open .occasion-menu>summary{display:flex!important;width:100%!important;min-height:42px!important;justify-content:space-between;padding:0 10px!important;font-size:14px!important}
  .site-header-v40 .nav.menu-open .occasion-dropdown{position:static;top:auto;left:auto;width:100%;transform:none;margin:3px 0 8px;padding:8px;border-radius:11px;box-shadow:none;background:#fff}
  .site-header-v40 .nav.menu-open .occasion-dropdown::before{display:none}
  .site-header-v40 .nav.menu-open .occasion-dropdown .occasion-event{min-height:38px!important;padding:8px!important;font-size:12.75px!important}
  .site-header-v40 .nav.menu-open .menu-explore-item{display:block!important}
  .site-header-v40 .nav.menu-open .explore-toggle{display:flex!important;width:100%!important;min-height:42px;justify-content:space-between;padding:0 10px!important;font-size:14px!important}
  .site-header-v40 .nav.menu-open .mobile-nav-tools{display:block!important;padding-top:12px!important}
  .site-header-v40 .mobile-nav-search{display:grid!important;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:10px;min-height:46px;padding:0 13px!important;border:1px solid rgba(22,17,15,.12)!important;border-radius:11px;background:#fff!important;color:#6F6963}
  .site-header-v40 .mobile-nav-search input{display:block!important;width:100%!important;min-width:0;border:0!important;outline:0!important;box-shadow:none!important;background:transparent!important;padding:8px 0!important;color:var(--ink)!important;font-family:inherit;font-size:13px!important}

  .site-header-v40 .explore-panel{top:62px;max-height:calc(100vh - 62px)}
}

@media (max-width:760px){
  .site-header-v40 .nav.menu-open .mobile-bottom-covered{display:none!important}
}

/* ---------- Footer v3.9 retained, without repeating primary nav ---------- */
.site-footer-v39>.wrap{padding-top:52px}
.site-footer-v39 .footer-primary{grid-template-columns:minmax(260px,1.55fr) repeat(3,minmax(140px,.82fr));gap:48px}
.site-footer-v39 .footer-brand-block p{max-width:44ch!important}
.site-footer-v39 .footer-nav-col h5{color:#F1ECE8}
.site-footer-v39 .footer-nav-col a{width:auto;max-width:230px}
.site-footer-v39 .footer-directory{margin-top:4px}
.site-footer-v39 .footer-directory-toolbar-v39{grid-template-columns:minmax(280px,430px) minmax(0,1fr);align-items:center}
.site-footer-v39 .footer-directory-toolbar-v39>p{margin:0;color:#837B75;font-size:12px;line-height:1.55;text-align:right}
.site-footer-v39 .footer-index-groups{margin-top:3px}

@media(max-width:980px){
  .site-footer-v39 .footer-primary{grid-template-columns:1.3fr 1fr 1fr;gap:34px}
  .site-footer-v39 .footer-nav-col:last-child{display:block}
  .site-footer-v39 .footer-brand-block{grid-column:1/-1}
  .site-footer-v39 .footer-directory-toolbar-v39{grid-template-columns:1fr}
  .site-footer-v39 .footer-directory-toolbar-v39>p{text-align:left;max-width:58ch}
}

/* ---------- Sticky bottom navigation: mobile only ---------- */
.bf-mobile-bottom-nav{display:none!important}
@media(max-width:760px){
  .site-footer-v39>.wrap{padding-top:40px;padding-bottom:20px}
  .site-footer-v39 .footer-primary{grid-template-columns:1fr 1fr;gap:30px 22px}
  .site-footer-v39 .footer-brand-block{grid-column:1/-1}
  .bf-sticky-flower-cta{display:none!important}
  body{padding-bottom:calc(74px + env(safe-area-inset-bottom))!important}
  .bf-mobile-bottom-nav{position:fixed!important;left:0;right:0;bottom:0;z-index:150;display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));min-height:66px;padding:5px 7px calc(5px + env(safe-area-inset-bottom));border-top:1px solid rgba(22,17,15,.11);background:rgba(255,252,248,.98);box-shadow:0 -12px 34px rgba(22,17,15,.11);backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}
  .bf-mobile-bottom-nav a{position:relative;display:flex;min-width:0;min-height:56px;align-items:center;justify-content:center;flex-direction:column;gap:4px;border-radius:11px;color:#6D6660;font-size:10.5px;font-weight:700;line-height:1;text-align:center;text-decoration:none}
  .bf-mobile-bottom-nav .bf-mobile-bottom-primary{color:var(--emerald);background:#EAF1ED}
  .bf-mobile-bottom-nav .bf-mobile-bottom-primary:after{content:"";position:absolute;top:5px;right:calc(50% - 17px);width:6px;height:6px;border-radius:50%;background:var(--coral)}
}

@media(max-width:520px){
  .site-footer-v39 .footer-primary{grid-template-columns:1fr}
  .site-footer-v39 .footer-brand-block{grid-column:auto}
  .bf-mobile-bottom-nav{padding-left:4px;padding-right:4px}
  .bf-mobile-bottom-nav a{font-size:10px}
}

@media(prefers-reduced-motion:reduce){
  .site-header-v40 *, .bf-mobile-bottom-nav a{transition:none!important}
}

/* Compact query-free footer v4.1 */
.site-footer-fast{background:#151b18;color:#d9dfdc}
.site-footer-fast>.wrap{padding-top:54px;padding-bottom:24px}
.footer-fast-grid{display:grid;grid-template-columns:1.5fr repeat(3,1fr);gap:48px}
.footer-fast-name{display:inline-block;color:#fff!important;font-family:Georgia,"Times New Roman",serif;font-size:24px;font-weight:700}
.footer-fast-brand p{max-width:430px;margin:12px 0;color:#9eaaa4;font-size:13px;line-height:1.65}
.footer-fast-method{color:#d9dfdc!important;font-size:12px;font-weight:700}
.footer-fast-col{display:flex;flex-direction:column;gap:9px}
.footer-fast-col strong{margin-bottom:4px;color:#fff;font-size:12px;text-transform:uppercase;letter-spacing:.06em}
.footer-fast-col a{color:#aeb8b3!important;font-size:12.5px}
.footer-fast-partner{margin-top:34px;padding:14px 0;border-top:1px solid #2b332f;border-bottom:1px solid #2b332f;color:#aeb8b3;font-size:12.5px}
.footer-fast-partner a{color:#fff!important;font-weight:750}
.footer-fast-bottom{display:flex;align-items:center;justify-content:space-between;gap:20px;padding-top:22px;color:#7f8c85;font-size:11px}
.footer-fast-bottom nav{display:flex;gap:16px}
.footer-fast-bottom a{color:#9aa69f!important}
@media(max-width:860px){.footer-fast-grid{grid-template-columns:1.3fr 1fr 1fr;gap:30px}.footer-fast-col:last-child{grid-column:2/4}}
@media(max-width:700px){.footer-fast-grid{grid-template-columns:1fr 1fr;gap:30px 22px}.footer-fast-brand{grid-column:1/-1}.footer-fast-col:last-child{grid-column:auto}.footer-fast-bottom{align-items:flex-start;flex-direction:column}}
@media(max-width:480px){.footer-fast-grid{grid-template-columns:1fr}}
