/* Shared PWA controls, then mobile storefront and Commerce Studio refinements. */
:root {
  --app-tabs-height: 68px;
}
[hidden] {
  display: none !important;
}
html {
  scroll-padding-top: 100px;
}
.app-tabbar {
  display: none;
}
.mobile-menu {
  max-width: 440px;
}
.mobile-menu a {
  display: block;
  padding: 15px 0;
  border-bottom: 1px solid #d8d0c1;
}
.mobile-menu-title {
  font:
    32px Georgia,
    serif;
  margin: 20px 0;
}
.mobile-menu .text-button {
  min-height: 44px;
}
.mobile-menu form {
  margin-top: 15px;
}
.mobile-menu-actions {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}
body:has(dialog[open]) {
  overflow: hidden;
}
.pwa-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 20px;
  border: 1px solid var(--navy, #0b1830);
  background: var(--navy, #0b1830);
  color: #fff;
  font:
    14px/1.5 Arial,
    sans-serif;
  cursor: pointer;
  border-radius: var(--radius, 0);
}
.pwa-link {
  background: none;
  border: 0;
  color: inherit;
  padding: 12px;
  min-height: 44px;
  text-decoration: underline;
  text-underline-offset: 4px;
  cursor: pointer;
}
.pwa-close {
  width: 44px;
  height: 44px;
  position: absolute;
  right: 12px;
  top: 12px;
  border: 0;
  background: transparent;
  color: inherit;
  font:
    28px Arial,
    sans-serif;
  cursor: pointer;
}
.install-promo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  padding: 32px 5%;
  border-top: 1px solid #d7cebd;
  background: #eee9df;
}
.install-promo > div {
  flex: 1;
}
.install-promo img {
  border-radius: 16px;
}
.install-promo h2 {
  font:
    28px/1.2 Georgia,
    serif;
  margin: 0 0 8px;
}
.install-promo p {
  margin: 0;
  font-size: 14px;
}
.install-dialog {
  position: fixed;
  width: min(480px, calc(100vw - 32px));
  max-width: 480px;
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 40px 32px 28px;
  background: #f7f4ed;
  color: #172335;
  border: 1px solid #d0c3a8;
  text-align: left;
  border-radius: 12px;
  overflow-y: auto;
}
.install-dialog::backdrop,
.mobile-menu::backdrop {
  background: #09182aaa;
  backdrop-filter: blur(3px);
}
.install-icon {
  display: block;
  border-radius: 16px;
  margin-bottom: 25px;
}
.install-eyebrow {
  font:
    11px/1.5 Arial,
    sans-serif;
  letter-spacing: 0.15em;
  color: #826d45;
}
.install-dialog h2 {
  font:
    40px/1.08 Georgia,
    serif;
  letter-spacing: -0.025em;
  margin: 14px 0 20px;
}
.install-description {
  font-size: 15px;
  color: #5e6569;
  line-height: 1.65;
}
.install-action {
  width: 100%;
  margin: 5px 0 18px;
}
#install-instructions p {
  padding: 18px;
  background: #ebe5d9;
  font:
    14px/1.8 Arial,
    sans-serif;
}
.install-note {
  font:
    12px/1.6 Arial,
    sans-serif;
  color: #656c71;
  margin: 16px 0 0;
}
.connection-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 45;
  padding: 10px max(20px, env(safe-area-inset-right)) 10px
    max(20px, env(safe-area-inset-left));
  background: #eee3c9;
  color: #493a20;
  text-align: center;
  font:
    13px/1.5 Arial,
    sans-serif;
  border-bottom: 1px solid #c9b782;
}
.app-update {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 60;
  width: min(370px, calc(100vw - 40px));
  padding: 18px;
  background: #f7f4ed;
  color: #172335;
  border: 1px solid #bca779;
  box-shadow: 0 6px 30px #0b183022;
  font:
    14px/1.6 Arial,
    sans-serif;
}
.app-update p {
  margin: 0 0 12px;
}
.app-update > div {
  display: flex;
  gap: 8px;
}
.app-standalone [data-install-promo],
.app-standalone [data-install-entry] {
  display: none !important;
}
@media (max-width: 900px) {
  .storefront {
    padding-bottom: calc(var(--app-tabs-height) + env(safe-area-inset-bottom));
  }
  .storefront .header {
    position: sticky;
    top: 0;
    height: calc(72px + env(safe-area-inset-top));
    padding: env(safe-area-inset-top) max(16px, env(safe-area-inset-right)) 0
      max(16px, env(safe-area-inset-left));
    z-index: 30;
    box-shadow: 0 3px 18px #0b183008;
  }
  .storefront .header .left-nav,
  .storefront .header .account-link,
  .storefront .header .bag-link {
    display: none;
  }
  .storefront .mobile-toggle {
    display: grid;
    place-items: center;
  }
  .storefront .header .icon-btn {
    width: 44px;
    height: 44px;
    padding: 11px;
  }
  .storefront .icon-btn svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
  .storefront .brand {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 126px;
    margin: 0;
  }
  .storefront .brand img {
    width: 126px;
    height: 63px;
  }
  .storefront .header .right-nav {
    flex: none;
    margin-left: auto;
  }
  .storefront .announcement {
    font-size: 10px;
    letter-spacing: 0.1em;
    padding: 7px 12px;
  }
  .app-tabbar {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    position: fixed;
    z-index: 40;
    bottom: 0;
    left: 0;
    right: 0;
    height: calc(var(--app-tabs-height) + env(safe-area-inset-bottom));
    padding: 0 max(8px, env(safe-area-inset-right)) env(safe-area-inset-bottom)
      max(8px, env(safe-area-inset-left));
    background: var(--paper, #f7f4ed);
    border-top: 1px solid #17233522;
    box-shadow: 0 -4px 24px #0b183007;
  }
  .app-tabbar > a,
  .app-tabbar > button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    position: relative;
    min-width: 0;
    border: 0;
    background: transparent;
    text-decoration: none;
    color: #686e73;
    font:
      11px/1.2 Arial,
      sans-serif;
    cursor: pointer;
  }
  .app-tabbar svg {
    display: block;
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.45;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
  .app-tabbar [aria-current="page"] {
    color: var(--navy, #0b1830);
    font-weight: 700;
  }
  .app-tabbar [aria-current="page"]::before {
    content: "";
    position: absolute;
    top: 0;
    width: 28px;
    height: 2px;
    background: var(--gold, #a68a55);
  }
  .tab-icon {
    position: relative;
  }
  .tab-count {
    position: absolute;
    top: -7px;
    left: 13px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 9px;
    background: var(--navy, #0b1830);
    color: #fff;
    font:
      10px/16px Arial,
      sans-serif;
  }
  .storefront .toast {
    bottom: calc(var(--app-tabs-height) + env(safe-area-inset-bottom) + 12px);
    width: max-content;
    max-width: calc(100vw - 32px);
    text-align: center;
  }
  .storefront .connection-banner {
    top: calc(72px + env(safe-area-inset-top));
  }
  .storefront .app-update {
    bottom: calc(var(--app-tabs-height) + env(safe-area-inset-bottom) + 12px);
  }
  .mobile-menu {
    margin: 0 auto 0 0;
    width: min(88vw, 380px);
    max-width: 380px;
    height: 100dvh;
    max-height: 100dvh;
    padding: max(30px, env(safe-area-inset-top)) 25px
      max(30px, env(safe-area-inset-bottom));
    border: 0;
    overflow: auto;
  }
  .storefront .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .storefront .product-detail,
  .storefront .bag-layout,
  .storefront .checkout-layout,
  .storefront .account-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 30px;
  }
  .storefront .product-info h1 {
    font-size: clamp(30px, 7vw, 40px);
  }
  .storefront .thumbnails {
    overflow-x: auto;
    padding-bottom: 5px;
  }
  .storefront .thumbnails button {
    flex: 0 0 68px;
  }
  .storefront .quantity-add {
    gap: 12px;
    align-items: stretch;
  }
  .storefront .quantity-add .quantity {
    flex: 0 0 70px;
    margin: 0;
  }
  .storefront .quantity-add input {
    height: 100%;
  }
  .storefront .product-info {
    scroll-margin-top: calc(90px + env(safe-area-inset-top));
  }
  .storefront .filter-controls {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
  }
  .storefront .filter-controls input[type="search"] {
    grid-column: 1 / -1;
  }
  .storefront .filter-controls input,
  .storefront .filter-controls select {
    width: 100%;
    max-width: none;
  }
  .storefront input:not([type="checkbox"]):not([type="radio"]),
  .storefront select,
  .storefront textarea {
    font-size: 16px;
    min-height: 48px;
  }
  .storefront .shop-filters {
    min-width: 0;
    flex-wrap: wrap;
  }
  .storefront .card-copy h3 {
    font-size: clamp(18px, 4vw, 23px);
    overflow-wrap: anywhere;
  }
  .storefront .card-bottom .text-button {
    min-height: 44px;
    width: 100%;
    margin-top: 12px;
    border: 1px solid #a68a5566;
    font-size: 13px;
  }
  .storefront .card-bottom {
    display: block;
  }
  .storefront .summary-card {
    padding: 24px;
  }
  .storefront .bag-item {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 15px;
  }
  .storefront .bag-item > strong {
    grid-column: 2;
    font-size: 15px;
    margin-top: -10px;
  }
  .storefront .bag-item > img {
    width: 72px;
    height: 96px;
  }
  .storefront .bag-item .text-button {
    min-height: 44px;
  }
  .storefront .order-row {
    flex-wrap: wrap;
  }
  .storefront .breadcrumb,
  .storefront .summary-row,
  .storefront .order-row {
    overflow-wrap: anywhere;
  }
  .install-promo {
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 18px;
    padding: 28px 6%;
  }
  .install-promo img {
    width: 56px;
    height: 56px;
    border-radius: 13px;
  }
  .install-promo h2 {
    font-size: 25px;
  }
  .install-promo > button {
    grid-column: 1 / -1;
    width: 100%;
  }
  .install-dialog {
    width: 100%;
    max-width: 540px;
    margin: auto auto 0;
    max-height: calc(100dvh - env(safe-area-inset-top) - 12px);
    border-radius: 18px 18px 0 0;
    padding: 32px 25px max(28px, env(safe-area-inset-bottom));
  }
  .storefront #search-dialog {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100dvh;
    max-width: none;
    max-height: 100dvh;
    margin: 0;
    padding: max(75px, env(safe-area-inset-top)) 24px
      max(30px, env(safe-area-inset-bottom));
    border: 0;
  }
  .storefront #search-dialog h2 {
    font-size: 34px;
  }
  .storefront #search-dialog form {
    display: grid;
    gap: 12px;
  }
  .storefront #search-dialog label {
    margin: 0;
  }
  .storefront #search-dialog .close {
    min-width: 44px;
    min-height: 44px;
    top: max(14px, env(safe-area-inset-top));
  }
  .app-keyboard .app-tabbar,
  .app-keyboard .app-update {
    display: none;
  }
  .admin-page .admin-topbar {
    padding-top: env(safe-area-inset-top);
    height: calc(58px + env(safe-area-inset-top));
  }
  .admin-page .sidebar {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    height: 100dvh;
  }
  .admin-page #admin-main {
    padding-bottom: calc(25px + env(safe-area-inset-bottom));
  }
  .admin-page input,
  .admin-page select,
  .admin-page textarea {
    font-size: 16px;
  }
  .admin-page .btn,
  .admin-page #admin-menu {
    min-height: 44px;
  }
  .admin-page .app-update {
    bottom: max(16px, env(safe-area-inset-bottom));
  }
}
@media (max-width: 380px) {
  .storefront .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .storefront .span-2 {
    grid-column: auto;
  }
  .storefront .hero-copy h1 {
    font-size: 37px;
  }
  .storefront .section {
    padding-left: 18px;
    padding-right: 18px;
  }
  .storefront .product-service {
    flex-wrap: wrap;
  }
  .storefront .badge {
    max-width: calc(100% - 12px);
    font-size: 10px;
    left: 6px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition-duration: 0s !important;
    animation-duration: 0s !important;
  }
}
@media print {
  .app-tabbar,
  .install-promo,
  .app-update,
  .connection-banner,
  .mobile-menu,
  .install-dialog {
    display: none !important;
  }
  .storefront {
    padding-bottom: 0;
  }
}
.product-app-buy {
  display: none;
}
@media (max-width: 900px) {
  .product-app-buy {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(var(--app-tabs-height) + env(safe-area-inset-bottom));
    z-index: 35;
    padding: 12px max(18px, env(safe-area-inset-right)) 12px
      max(18px, env(safe-area-inset-left));
    background: var(--paper, #f7f4ed);
    border-top: 1px solid #17233522;
  }
  .product-app-buy > div {
    min-width: 0;
  }
  .product-app-buy span {
    display: block;
    max-width: 45vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
  }
  .product-app-buy strong {
    display: block;
    font-size: 15px;
  }
  .product-app-buy .btn {
    min-height: 46px;
    white-space: nowrap;
    padding-inline: 18px;
  }
  .storefront:has(.product-app-buy) {
    padding-bottom: calc(
      var(--app-tabs-height) + env(safe-area-inset-bottom) + 76px
    );
  }
  .storefront:has(.product-app-buy:not([hidden])) .toast,
  .storefront:has(.product-app-buy:not([hidden])) .app-update {
    bottom: calc(var(--app-tabs-height) + env(safe-area-inset-bottom) + 88px);
  }
  .app-keyboard .product-app-buy {
    display: none;
  }
}
@media print {
  .product-app-buy {
    display: none !important;
  }
}
.header-install {
  min-height: 40px;
  padding: 8px 12px;
  background: transparent;
  color: var(--navy, #0b1830);
  border: 1px solid var(--gold, #a68a55);
  font-size: 13px;
  white-space: nowrap;
}
@media (max-width: 1100px) {
  .header .header-install {
    display: none;
  }
}

/* Cards share their grid-row height; actions stay aligned when titles wrap. */
.storefront .product-grid {
  align-items: stretch;
  min-width: 0;
}
.storefront .product-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 100%;
}
.storefront .product-photo {
  flex: 0 0 auto;
  min-width: 0;
}
.storefront .product-photo .badge {
  max-width: calc(100% - 24px);
  white-space: normal;
  overflow-wrap: anywhere;
}
.storefront .card-copy {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-width: 0;
}
.storefront .card-copy h3,
.storefront .card-copy .eyebrow,
.storefront .card-copy .small {
  min-width: 0;
  overflow-wrap: anywhere;
}
.storefront .card-bottom {
  margin-top: auto;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  padding-top: 6px;
}
.storefront .card-bottom .card-price {
  display: block;
  min-width: 0;
  line-height: 1.5;
}
.storefront .card-price small {
  font-size: 0.65em;
  letter-spacing: 0.04em;
  white-space: nowrap;
  opacity: 0.75;
}
.storefront .card-bottom .text-button {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 11px 8px;
  margin-top: 0;
  border: 1px solid var(--line, #d8d0c1);
  line-height: 1.35;
  text-align: center;
}
.storefront .card-bottom .text-button:hover:not(:disabled) {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
}
.footer-business {
  font-size: 13px;
  line-height: 1.8;
}
.footer-business address {
  font-style: normal;
}
.footer-business a,
.footer-business p {
  overflow-wrap: anywhere;
}
.footer-bottom > div {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
}
.checkout-policy-note {
  font-size: 12px;
  line-height: 1.7;
}
.checkout-policy-note a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.checkout-seller {
  margin-top: 22px;
  border-top: 1px solid var(--line, #d8d0c1);
  padding-top: 16px;
  overflow-wrap: anywhere;
}

.policy-hero {
  max-width: var(--width);
  margin: 0 auto;
  padding: 44px 6% 46px;
  border-bottom: 1px solid var(--line, #d8d0c1);
}
.policy-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 12px;
  margin-bottom: 36px;
  color: var(--muted, #64665f);
}
.policy-hero h1 {
  font-family: var(--serif);
  font-size: clamp(34px, 4.3vw, 58px);
  line-height: 1.12;
  max-width: 950px;
  margin: 16px 0 22px;
  overflow-wrap: anywhere;
}
.policy-intro {
  max-width: 720px;
  font-size: 17px;
  line-height: 1.8;
}
.policy-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 30px;
  align-items: center;
  margin-top: 24px;
  font-size: 12px;
  color: var(--muted, #64665f);
}
.policy-meta .text-button {
  min-height: 44px;
  font-size: 12px;
}
.policy-layout {
  display: grid;
  grid-template-columns: minmax(210px, 270px) minmax(0, 760px);
  justify-content: space-between;
  gap: 6%;
  max-width: var(--width);
  padding: 48px 6% 80px;
  margin: auto;
}
.policy-sidebar {
  min-width: 0;
}
.policy-navigation {
  border: 1px solid var(--line, #d8d0c1);
  padding: 18px;
}
.policy-navigation summary,
.policy-contents summary {
  cursor: pointer;
  min-height: 28px;
  font-size: 14px;
  font-weight: 600;
}
.policy-navigation nav {
  display: grid;
  margin-top: 12px;
}
.policy-navigation a {
  padding: 11px 12px;
  font-size: 13px;
  line-height: 1.45;
  border-left: 2px solid transparent;
}
.policy-navigation a[aria-current="page"] {
  background: #eae6dc;
  color: var(--navy);
  border-color: var(--gold);
  font-weight: 600;
}
.policy-navigation a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.policy-contact {
  background: var(--navy);
  color: #fff;
  padding: 26px 22px;
  margin-top: 24px;
  font-size: 13px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}
.policy-contact .eyebrow {
  color: #ddd1b5;
  font-size: 10px;
}
.policy-contact h2 {
  color: #fff;
  font-family: var(--serif);
  font-size: 29px;
  margin: 8px 0 20px;
}
.policy-contact > a {
  display: block;
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
  margin: 12px 0;
}
.policy-contact p {
  margin-top: 20px;
}
.policy-contact address {
  font-style: normal;
}
.policy-document {
  min-width: 0;
}
.policy-contents {
  border-bottom: 1px solid var(--line, #d8d0c1);
  padding-bottom: 18px;
  margin-bottom: 30px;
}
.policy-contents ol {
  padding-left: 22px;
  margin: 14px 0 0;
  font-size: 14px;
  line-height: 2;
}
.policy-section {
  scroll-margin-top: 120px;
  margin-bottom: 36px;
}
.policy-section h2,
.policy-help h2 {
  font-family: var(--serif);
  font-size: 27px;
  line-height: 1.3;
  margin-bottom: 16px;
}
.policy-prose {
  font-size: 15px;
  line-height: 1.9;
  overflow-wrap: anywhere;
}
.policy-prose p {
  margin: 0 0 16px;
}
.policy-prose ul,
.policy-prose ol {
  padding-left: 22px;
  margin: 0 0 18px;
}
.policy-prose li {
  margin-bottom: 10px;
}
.policy-document a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.policy-help {
  padding: 28px;
  border: 1px solid var(--line, #d8d0c1);
  margin-top: 48px;
}
.policy-help p {
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 22px;
}
.policy-help .btn {
  text-decoration: none;
  white-space: normal;
  text-align: center;
}
@media (max-width: 760px) {
  .policy-hero {
    padding: 24px 6% 30px;
  }
  .policy-breadcrumb {
    margin-bottom: 24px;
  }
  .policy-intro {
    font-size: 15px;
  }
  .policy-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
    padding-top: 26px;
  }
  .policy-navigation nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2px;
  }
  .policy-navigation {
    padding: 14px;
  }
  .policy-navigation a {
    padding: 10px 8px;
    font-size: 12px;
  }
  .policy-contact {
    display: none;
  }
  .policy-section h2,
  .policy-help h2 {
    font-size: 24px;
  }
  .policy-help {
    padding: 24px 20px;
  }
}
@media print {
  .policy-breadcrumb,
  .policy-sidebar,
  .policy-meta button,
  .policy-contents,
  .policy-help {
    display: none !important;
  }
  .policy-hero {
    padding: 0 0 20px;
    max-width: none;
  }
  .policy-hero h1 {
    font-size: 28pt;
  }
  .policy-layout {
    display: block;
    padding: 24px 0;
    max-width: none;
  }
  .policy-prose {
    font-size: 10pt;
    line-height: 1.6;
    color: #000;
  }
  .policy-section h2 {
    font-size: 15pt;
    break-after: avoid;
  }
  .policy-prose p,
  .policy-prose li {
    orphans: 3;
    widows: 3;
  }
}
