:root{--md-teal:#008d8c;--md-teal-dark:#006f70;--md-teal-light:#71d1cc;--md-navy:#073451}

/* Preserve the live layout. This layer only introduces the approved brand color. */
.brand-lockup{width:fit-content}
.company-brand{gap:14px!important}
.company-brand img{width:84px!important;height:50px!important;object-fit:contain!important;filter:none!important}
.company-brand .md-wordmark{font-size:30px!important;font-weight:700!important;letter-spacing:-.035em;white-space:nowrap;line-height:1}
.company-brand .md-mechanism{color:#fff}
.company-brand .md-diligence{color:var(--md-teal)}
html[data-theme=light] .company-brand .md-mechanism{color:var(--md-navy)!important}
.brand-tagline{margin:-3px 0 0 98px!important;font-size:12px!important;line-height:1.2!important;letter-spacing:.02em!important;text-align:left!important}
html[data-theme=dark] .brand-tagline{color:#b7c3c3!important;font-size:12px!important}
html[data-theme=light] .brand-tagline{color:#4d5c66!important;font-size:12px!important}

header img[src*="/assets/brand/symbol-"]{object-fit:contain;filter:none!important}
html[data-theme=dark] header img[src*="/assets/brand/symbol-"]{content:url('/assets/brand/symbol-on-dark.svg')}
html[data-theme=light] header img[src*="/assets/brand/symbol-"]{content:url('/assets/brand/symbol-color.svg')}
html[data-theme=dark] :is(header nav a,.product-nav a,.moa-ticker a,.home-suggestions a,.site-footer a):hover,
html[data-theme=dark] :is(header nav a,.product-nav a,.moa-ticker a,.home-suggestions a,.site-footer a):focus-visible{color:var(--md-teal-light)!important}
html[data-theme=light] :is(header nav a,.product-nav a,.moa-ticker a,.home-suggestions a,.site-footer a):hover,
html[data-theme=light] :is(header nav a,.product-nav a,.moa-ticker a,.home-suggestions a,.site-footer a):focus-visible{color:var(--md-teal-dark)!important}

.moa-ticker-label{border-bottom:2px solid var(--md-teal)!important}
.moa-ticker-bar{display:none!important}
.moa-ticker-viewport{scrollbar-width:none;-ms-overflow-style:none}
.moa-ticker-viewport::-webkit-scrollbar{display:none;width:0;height:0}
.product-detail{color:var(--md-teal-light)!important}
.diff-mark{color:var(--md-teal-light)!important}
.section-rule{border-color:rgba(0,141,140,.34)!important}
.home-suggestions a{text-decoration-color:var(--md-teal)!important}

html[data-theme=dark] .product-box.product-live:hover,
html[data-theme=dark] a.diff-card:hover{border-color:var(--md-teal)!important;background:#0b1718!important}
html[data-theme=light] .product-detail,
html[data-theme=light] .diff-mark{color:var(--md-teal-dark)!important}
html[data-theme=light] .product-box.product-live:hover,
html[data-theme=light] a.diff-card:hover{border-color:var(--md-teal)!important;background:#f3fbfa!important}

html[data-theme=dark] :is(a,button,input,select,summary):focus-visible{outline-color:var(--md-teal-light)!important}
html[data-theme=light] :is(a,button,input,select,summary):focus-visible{outline-color:var(--md-teal-dark)!important}

@media(max-width:1099px){
  body:has(.brand-lockup){overflow-x:hidden}
  body:has(.brand-lockup)>header{
    display:grid!important;
    grid-template-columns:minmax(0,1fr)!important;
    align-items:start!important;
    gap:8px!important;
    padding:12px 16px 8px!important;
    overflow:visible!important;
  }
  body:has(.brand-lockup) .brand-lockup{width:100%!important;min-width:0!important}
  body:has(.brand-lockup) .company-brand{display:inline-flex!important;gap:8px!important;max-width:100%}
  body:has(.brand-lockup) .company-brand img{width:54px!important;height:34px!important}
  body:has(.brand-lockup) .company-brand .md-wordmark{font-size:20px!important}
  body:has(.brand-lockup) .brand-tagline{
    display:block!important;
    margin:-2px 0 0 62px!important;
    font-size:10px!important;
    line-height:1.2!important;
    white-space:nowrap;
  }
  body:has(.brand-lockup)>header nav{
    display:grid!important;
    grid-template-columns:repeat(4,auto) 36px!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:4px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:visible!important;
    font-size:12px!important;
  }
  body:has(.brand-lockup)>header nav a{
    min-height:36px!important;
    padding:0 2px!important;
    font-size:12px!important;
  }
  body:has(.brand-lockup)>header .theme-toggle{
    width:36px!important;
    min-width:36px!important;
    height:36px!important;
    min-height:36px!important;
    padding:0!important;
    overflow:hidden;
    font-size:0!important;
    line-height:1!important;
  }
  body:has(.brand-lockup)>header .theme-toggle::before{font-size:15px;content:"☾"}
  html[data-theme=dark] body:has(.brand-lockup)>header .theme-toggle::before{content:"☀"}
}

@media(max-width:360px){
  html:has(.brand-lockup),
  body:has(.brand-lockup){overflow-x:hidden;max-width:100%}
  body:has(.brand-lockup)>header{position:relative;padding-left:10px!important;padding-right:10px!important}
  body:has(.brand-lockup) .company-brand img{width:44px!important;height:28px!important}
  body:has(.brand-lockup) .company-brand .md-wordmark{font-size:16px!important}
  body:has(.brand-lockup) .brand-tagline{
    margin-left:52px!important;
    max-width:calc(100% - 44px);
    overflow:hidden;
    font-size:9px!important;
    text-overflow:ellipsis;
  }
  body:has(.brand-lockup)>header .theme-toggle{
    position:absolute!important;
    top:8px!important;
    right:8px!important;
    width:32px!important;
    min-width:32px!important;
    height:32px!important;
    min-height:32px!important;
  }
  body:has(.brand-lockup)>header nav{
    display:flex!important;
    grid-template-columns:none!important;
    justify-content:space-between!important;
    gap:0!important;
    width:100%!important;
    max-width:100%!important;
    padding-right:0!important;
    font-size:10px!important;
  }
  body:has(.brand-lockup)>header nav a{
    flex:0 1 auto;
    min-width:0;
    padding:0!important;
    font-size:10px!important;
    letter-spacing:-.03em;
  }
}

/* Pages without the homepage lockup: allow long service names to wrap without overflow. */
@media(max-width:760px){
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header{
    flex-wrap:wrap!important;
    align-items:center!important;
    row-gap:8px!important;
  }
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header nav{
    display:flex!important;
    flex-wrap:wrap!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:8px!important;
    width:100%!important;
    min-width:0!important;
    font-size:14px!important;
  }
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header nav a{
    padding:0!important;
    white-space:nowrap;
  }
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header .theme-toggle{
    width:36px!important;
    min-width:36px!important;
    height:36px!important;
    min-height:36px!important;
    padding:0!important;
    font-size:0!important;
    line-height:1!important;
    flex:none!important;
  }
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header .theme-toggle::before{
    content:"☾";
    font-size:16px;
    line-height:1;
  }
  html[data-theme=dark] body:not(:has(.brand-lockup)):not(.medicine-search-page)>header .theme-toggle::before{
    content:"☀";
  }
}
@media(max-width:360px){
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header{padding-left:12px!important;padding-right:12px!important}
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header nav{gap:4px!important;font-size:12px!important}
  body:not(:has(.brand-lockup)):not(.medicine-search-page)>header nav a{font-size:12px!important}
}
