/*
 * MIYAAR Public Shell v15.5.1
 * Stage 2 — header, footer and global public layout.
 *
 * This layer intentionally keeps legacy origin-* class hooks in the markup for
 * backwards compatibility, but owns the final public-shell presentation.
 */

html[data-miyaar-shell="15.5.1"]{scroll-padding-top:112px}
html[data-miyaar-shell="15.5.1"] body{min-height:100vh;display:flex;flex-direction:column;background:var(--mi-bg);font-family:var(--mi-font)}
html[data-miyaar-shell="15.5.1"] body>main{flex:1;min-width:0}

/* Accessibility */
.mi-skip-link{position:fixed;inset-inline-start:16px;top:10px;z-index:100000;transform:translateY(-150%);padding:10px 14px;border-radius:12px;background:var(--mi-text);color:#fff;text-decoration:none;font-size:13px;font-weight:900;box-shadow:var(--mi-shadow-md);transition:transform var(--mi-duration-fast)}
.mi-skip-link:focus{transform:translateY(0)}

/* Utility row: contact/social context without competing with main navigation. */
.mi-site-utility{border-bottom:1px solid color-mix(in srgb,var(--mi-line) 76%,transparent);background:color-mix(in srgb,var(--mi-surface) 88%,var(--mi-bg));color:var(--mi-muted)}
.mi-site-utility__inner{width:min(var(--mi-container),calc(100% - 36px));min-height:34px;margin-inline:auto;display:flex;align-items:center;justify-content:space-between;gap:18px;font-size:11.5px;font-weight:750}
.mi-site-utility__contact,.mi-site-utility__social{display:flex;align-items:center;gap:14px;min-width:0}
.mi-site-utility a{display:inline-flex;align-items:center;gap:6px;color:var(--mi-muted);text-decoration:none;white-space:nowrap;transition:color var(--mi-duration-fast)}
.mi-site-utility a:hover{color:var(--mi-brand)}
.mi-site-utility__social{gap:5px}
.mi-site-utility__social a{width:26px;height:26px;justify-content:center;border-radius:8px}
.mi-site-utility__social a:hover{background:var(--mi-brand-soft)}

/* Main header */
html[data-miyaar-shell="15.5.1"] .mi-site-header.site-header{position:sticky!important;top:0!important;z-index:var(--mi-z-dropdown)!important;padding:0!important;border:0!important;border-bottom:1px solid color-mix(in srgb,var(--mi-line) 82%,transparent)!important;background:color-mix(in srgb,var(--mi-surface) 94%,transparent)!important;backdrop-filter:blur(20px) saturate(1.18)!important;-webkit-backdrop-filter:blur(20px) saturate(1.18)!important;box-shadow:0 8px 24px rgba(15,23,42,.035)!important}
html[data-miyaar-shell="15.5.1"] .mi-site-header__inner.site-container{width:min(var(--mi-container),calc(100% - 36px))!important;min-height:76px!important;margin-inline:auto!important;display:grid!important;grid-template-columns:auto minmax(0,1fr) auto!important;align-items:center!important;gap:clamp(20px,2.8vw,38px)!important;padding:0!important}

/* Brand */
html[data-miyaar-shell="15.5.1"] .mi-site-brand.brand{min-width:0!important;max-width:290px;display:flex!important;align-items:center!important;gap:11px!important;color:var(--mi-text)!important;text-decoration:none!important}
html[data-miyaar-shell="15.5.1"] .mi-site-brand.brand img{display:block;width:auto!important;max-width:154px;height:47px!important;object-fit:contain!important;object-position:right center!important}
html[data-miyaar-shell="15.5.1"] .mi-site-brand .brand-mark{width:45px!important;height:45px!important;border-radius:15px!important;background:linear-gradient(135deg,var(--mi-brand),var(--mi-accent))!important;box-shadow:0 10px 24px color-mix(in srgb,var(--mi-brand) 18%,transparent)}
.mi-site-brand__copy{min-width:0}
html[data-miyaar-shell="15.5.1"] .mi-site-brand__copy strong{display:block;font-size:15.5px;line-height:1.45;font-weight:900;color:var(--mi-text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
html[data-miyaar-shell="15.5.1"] .mi-site-brand__copy small{display:block;max-width:210px;margin-top:1px;font-size:10.5px;line-height:1.45;font-weight:650;color:var(--mi-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* Navigation: understated pill states, strong hierarchy, no decorative clutter. */
html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav{display:flex!important;align-items:center!important;justify-content:center!important;gap:2px!important;min-width:0!important}
html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav a{position:relative;min-height:40px;display:inline-flex;align-items:center;justify-content:center;padding:8px 11px!important;border-radius:12px!important;color:var(--mi-text-soft)!important;background:transparent!important;text-decoration:none!important;font-size:13px!important;font-weight:800!important;white-space:nowrap;transition:background var(--mi-duration-fast),color var(--mi-duration-fast)}
html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav a:hover{background:var(--mi-brand-softer)!important;color:var(--mi-brand-strong)!important}
html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav a.is-active{background:var(--mi-brand-soft)!important;color:var(--mi-brand-strong)!important}
html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav a.is-active::after{content:"";position:absolute;inset-inline:11px;bottom:3px;height:2px;border-radius:99px;background:var(--mi-brand)}

/* Actions */
html[data-miyaar-shell="15.5.1"] .mi-site-actions.header-actions{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:7px!important;min-width:max-content}
.mi-header-icon{position:relative;width:42px;height:42px;display:grid;place-items:center;border:1px solid var(--mi-line);border-radius:13px;background:var(--mi-surface);color:var(--mi-text-soft);text-decoration:none;box-shadow:var(--mi-shadow-xs);transition:background var(--mi-duration-fast),border-color var(--mi-duration-fast),color var(--mi-duration-fast),transform var(--mi-duration-fast)}
.mi-header-icon:hover{transform:translateY(-1px);border-color:color-mix(in srgb,var(--mi-brand) 24%,var(--mi-line));background:var(--mi-brand-softer);color:var(--mi-brand)}
.mi-header-icon.is-current{border-color:color-mix(in srgb,var(--mi-brand) 32%,var(--mi-line));background:var(--mi-brand-soft);color:var(--mi-brand-strong);box-shadow:0 0 0 3px color-mix(in srgb,var(--mi-brand) 8%,transparent)}
html[data-miyaar-shell="15.5.1"] .mi-site-actions .button{min-height:42px!important;padding-inline:15px!important;border-radius:13px!important;gap:7px!important;font-size:12.5px!important;box-shadow:none!important;transform:none!important}
html[data-miyaar-shell="15.5.1"] .mi-site-actions .button.primary{background:var(--mi-brand)!important;border-color:var(--mi-brand)!important;color:#fff!important}
html[data-miyaar-shell="15.5.1"] .mi-site-actions .button.primary:hover{background:var(--mi-brand-strong)!important;border-color:var(--mi-brand-strong)!important}
html[data-miyaar-shell="15.5.1"] .mi-site-actions .button.ghost{background:var(--mi-surface)!important;border-color:var(--mi-line)!important;color:var(--mi-text)!important}
html[data-miyaar-shell="15.5.1"] .mi-site-actions .button.ghost:hover{background:var(--mi-brand-softer)!important;border-color:color-mix(in srgb,var(--mi-brand) 25%,var(--mi-line))!important;color:var(--mi-brand-strong)!important}
html[data-miyaar-shell="15.5.1"] .origin-cart-badge{top:-5px!important;left:-5px!important;border-color:var(--mi-surface)!important}

/* Mobile trigger / panel */
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu.mobile-menu{display:none!important;position:relative!important;margin:0!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu>summary{width:44px!important;height:44px!important;display:grid!important;place-items:center!important;border:1px solid var(--mi-line)!important;border-radius:13px!important;background:var(--mi-surface)!important;color:var(--mi-text)!important;box-shadow:var(--mi-shadow-xs)!important;cursor:pointer!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu>summary:hover{background:var(--mi-brand-softer)!important;border-color:color-mix(in srgb,var(--mi-brand) 22%,var(--mi-line))!important;color:var(--mi-brand)!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu[open]>summary{background:var(--mi-brand-soft)!important;color:var(--mi-brand-strong)!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu .mobile-menu-panel{position:absolute!important;top:52px!important;left:0!important;right:auto!important;width:min(360px,calc(100vw - 24px))!important;max-height:min(620px,calc(100vh - 100px));overflow:auto;padding:10px!important;border:1px solid var(--mi-line)!important;border-radius:20px!important;background:var(--mi-surface)!important;box-shadow:var(--mi-shadow-lg)!important;z-index:calc(var(--mi-z-dropdown) + 2)!important;display:grid!important;gap:3px!important}
.mi-mobile-menu__brand{display:flex;align-items:center;gap:10px;padding:8px 9px 12px;margin-bottom:4px;border-bottom:1px solid var(--mi-line)}
.mi-mobile-menu__brand strong{display:block;font-size:13px;color:var(--mi-text)}
.mi-mobile-menu__brand small{display:block;margin-top:1px;font-size:10px;color:var(--mi-muted)}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu .mobile-menu-panel>a{min-height:43px;display:flex!important;align-items:center!important;gap:9px!important;padding:9px 11px!important;border-radius:11px!important;color:var(--mi-text-soft)!important;text-decoration:none!important;font-size:12.5px!important;font-weight:800!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu .mobile-menu-panel>a:hover,html[data-miyaar-shell="15.5.1"] .mi-mobile-menu .mobile-menu-panel>a.is-active{background:var(--mi-brand-soft)!important;color:var(--mi-brand-strong)!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu .mobile-menu-panel>a.mobile-primary{margin-top:4px;background:var(--mi-brand)!important;color:#fff!important}
html[data-miyaar-shell="15.5.1"] .mi-mobile-menu .mobile-menu-panel>a.mobile-primary i{color:#fff!important}
.mi-mobile-menu__section{padding:9px 11px 3px;color:var(--mi-muted);font-size:10px;font-weight:900}

/* Main content baseline. Page-specific redesign remains opt-in in later stages. */
.mi-public-main{display:block;min-width:0}

/* Footer */
html[data-miyaar-shell="15.5.1"] .mi-site-footer.site-footer{position:relative;margin-top:0;padding:0!important;border:0!important;background:linear-gradient(145deg,color-mix(in srgb,var(--mi-brand) 24%,#07191d),#071a20 58%,color-mix(in srgb,var(--mi-accent) 15%,#07191d))!important;color:#e9f2f3!important;overflow:hidden}
html[data-miyaar-shell="15.5.1"] .mi-site-footer.site-footer::before{content:"";position:absolute;width:440px;height:440px;inset-inline-start:-190px;top:-260px;border-radius:50%;background:color-mix(in srgb,var(--mi-brand) 20%,transparent);filter:blur(2px);pointer-events:none}
html[data-miyaar-shell="15.5.1"] .mi-site-footer.site-footer::after{content:"";position:absolute;width:340px;height:340px;inset-inline-end:-180px;bottom:-240px;border-radius:50%;background:color-mix(in srgb,var(--mi-accent) 16%,transparent);pointer-events:none}
.mi-site-footer__main{position:relative;z-index:1;width:min(var(--mi-container),calc(100% - 36px));margin-inline:auto;padding:58px 0 42px;display:grid;grid-template-columns:minmax(270px,1.35fr) repeat(3,minmax(145px,.65fr));gap:clamp(28px,4vw,58px)}
.mi-site-footer__brand{min-width:0}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .footer-brand{display:flex!important;min-width:0!important;max-width:360px!important;align-items:center!important;gap:12px!important;color:#fff!important;text-decoration:none!important}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .footer-brand img{width:auto!important;max-width:165px!important;height:52px!important;object-fit:contain!important;object-position:right center!important}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .footer-brand .brand-mark{background:rgba(255,255,255,.12)!important;color:#fff!important;border:1px solid rgba(255,255,255,.12)!important;box-shadow:none!important}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .footer-brand strong{display:block;color:#fff!important;font-size:16px!important;line-height:1.45}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .footer-brand small{display:block;max-width:250px;margin-top:2px;color:#9fb5b9!important;font-size:10.5px!important;white-space:normal!important;line-height:1.6}
.mi-site-footer__description{max-width:420px;margin:20px 0 0!important;color:#b9cacc!important;font-size:13px!important;line-height:1.95!important}
.mi-site-footer__closing{display:block;max-width:410px;margin-top:16px;color:#f7fbfb;font-size:12px;font-weight:900;line-height:1.8}
.mi-site-footer__column h4{margin:2px 0 15px;color:#fff;font-size:13px;font-weight:900}
.mi-site-footer__links{display:grid;gap:9px}
.mi-site-footer__links a{width:max-content;max-width:100%;display:inline-flex;align-items:center;gap:7px;color:#b9cacc;text-decoration:none;font-size:12px;font-weight:650;line-height:1.6;transition:color var(--mi-duration-fast),transform var(--mi-duration-fast)}
.mi-site-footer__links a:hover{color:#fff;transform:translateX(-2px)}
.mi-site-footer__contact{display:grid;gap:9px}
.mi-site-footer__contact a,.mi-site-footer__contact span{display:flex;align-items:flex-start;gap:8px;color:#b9cacc;text-decoration:none;font-size:12px;line-height:1.75;word-break:break-word}
.mi-site-footer__contact a:hover{color:#fff}
.mi-site-footer__contact i{width:16px;margin-top:5px;color:color-mix(in srgb,var(--mi-brand) 65%,#fff);text-align:center}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .social-row{display:flex!important;gap:6px!important;margin-top:14px!important;flex-wrap:wrap!important}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .social-row a{width:34px!important;height:34px!important;padding:0!important;display:grid!important;place-items:center!important;border:1px solid rgba(255,255,255,.11)!important;border-radius:10px!important;background:rgba(255,255,255,.045)!important;color:#dce8e9!important;text-decoration:none!important}
html[data-miyaar-shell="15.5.1"] .mi-site-footer .social-row a:hover{background:rgba(255,255,255,.095)!important;color:#fff!important;border-color:rgba(255,255,255,.2)!important}
.mi-site-footer__bottom{position:relative;z-index:1;border-top:1px solid rgba(255,255,255,.09)}
.mi-site-footer__bottom-inner{width:min(var(--mi-container),calc(100% - 36px));min-height:64px;margin-inline:auto;display:flex;align-items:center;justify-content:space-between;gap:20px;color:#829b9f;font-size:11px;line-height:1.6}
.mi-site-footer__bottom-links{display:flex;align-items:center;gap:14px;flex-wrap:wrap}
.mi-site-footer__bottom-links a{color:#91a7aa;text-decoration:none}
.mi-site-footer__bottom-links a:hover{color:#fff}

/* Admin toolbar co-existence. Its middleware adds top:38px to .site-header. */
body:has(.miyaar-admin-toolbar) .mi-site-utility{position:relative}

@media(max-width:1120px){
  html[data-miyaar-shell="15.5.1"] .mi-site-header__inner.site-container{grid-template-columns:auto 1fr auto!important;gap:18px!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav{justify-content:flex-start!important;overflow:hidden}
  html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav a{padding-inline:8px!important;font-size:12px!important}
  .mi-site-brand__copy small{display:none!important}
  .mi-site-footer__main{grid-template-columns:minmax(260px,1.2fr) repeat(2,minmax(150px,.7fr))}
  .mi-site-footer__contact-column{grid-column:2/-1}
}

@media(max-width:940px){
  html[data-miyaar-shell="15.5.1"]{scroll-padding-top:84px}
  .mi-site-utility{display:none}
  html[data-miyaar-shell="15.5.1"] .mi-site-header__inner.site-container{min-height:70px!important;grid-template-columns:minmax(0,1fr) auto auto!important;gap:9px!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-brand.brand{max-width:min(260px,60vw)!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-brand.brand img{max-width:136px!important;height:43px!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-nav.main-nav{display:none!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-actions.header-actions{margin-inline-start:0!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-actions .mi-header-icon:not(.origin-cart-action){display:none!important}
  html[data-miyaar-shell="15.5.1"] .mi-mobile-menu.mobile-menu{display:block!important}
  .mi-site-footer__main{grid-template-columns:1.2fr 1fr 1fr;padding-top:48px;gap:32px}
  .mi-site-footer__brand{grid-column:1/-1}
  .mi-site-footer__contact-column{grid-column:auto}
}

@media(max-width:700px){
  html[data-miyaar-shell="15.5.1"] .mi-site-header__inner.site-container{width:min(100% - 24px,var(--mi-container))!important;grid-template-columns:minmax(0,1fr) auto!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-actions.header-actions{display:none!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-brand.brand{max-width:70vw!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-brand__copy strong{font-size:14px}
  .mi-site-footer__main{width:min(100% - 28px,var(--mi-container));grid-template-columns:1fr 1fr;gap:28px 24px;padding:42px 0 34px}
  .mi-site-footer__brand{grid-column:1/-1}
  .mi-site-footer__contact-column{grid-column:1/-1}
  .mi-site-footer__bottom-inner{width:min(100% - 28px,var(--mi-container));padding:18px 0;flex-direction:column;align-items:flex-start;gap:8px}
}

@media(max-width:460px){
  html[data-miyaar-shell="15.5.1"] .mi-site-brand__copy small{display:none!important}
  html[data-miyaar-shell="15.5.1"] .mi-site-brand.brand img{max-width:120px!important;height:40px!important}
  .mi-site-footer__main{grid-template-columns:1fr}
  .mi-site-footer__brand,.mi-site-footer__contact-column{grid-column:auto}
  .mi-site-footer__bottom-links{gap:10px}
}

@media(print){
  .mi-site-utility,.mi-site-header,.mi-site-footer,.mi-skip-link{display:none!important}
}
