/* Homepage components. Shared checkout/catalog styles stay in main.css. */
.home-page {
  --bg: #faf9f7;
  --ink: #252321;
  --muted: #68635f;
  --border: #e7e3df;
  --panel: #f3f0ec;
  background: var(--bg);
  font-size: 15px;
  line-height: 1.6;
}
.home-page :is(a, button) { -webkit-tap-highlight-color: transparent; }
.home-page :is(a, button):focus-visible { outline: 2px solid var(--accent-strong); outline-offset: 4px; }
.home-page :is(a, button) { transition: color 160ms ease, background-color 160ms ease, transform 160ms ease; }
.home-page :is(button, .fm-hero__button, .home-product__details):active { transform: scale(.98); }

/* Supplied artwork is always displayed in full. */
.fm-hero { padding: 16px 16px 0; }
.fm-hero__inner { max-width: 1248px; margin-inline: auto; }
.fm-hero__image { display: block; width: 100%; height: auto; border-radius: 16px; }
.fm-hero__actions, .home-order__actions { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; margin-top: 16px; }
.fm-hero__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 20px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
}
.fm-hero__button--primary { background: var(--accent-strong); border-color: var(--accent-strong); color: #fff; }
.home-content { max-width: 1280px; margin: 0 auto; padding: 24px 16px 32px; display: grid; gap: 24px; }

/* Benefits are compact rows, not separate panels. */
.home-benefits { display: grid; gap: 0; }
.home-benefit { display: grid; grid-template-columns: 36px minmax(0, 1fr); align-items: start; gap: 12px; padding: 16px 0; }
.home-benefit + .home-benefit { border-top: 1px solid var(--border); }
.home-benefit > div { grid-column: 2; grid-row: 1; }
.home-benefit__icon { grid-column: 1; grid-row: 1; display: grid; place-items: center; width: 36px; height: 36px; color: var(--ink); font-size: 21px; }
.home-benefit--support .home-benefit__icon { color: #287347; }
.home-benefit h4 { margin: 0 0 4px; font-size: 15px; font-weight: 700; line-height: 1.5; }
.home-benefit p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6; }

/* One readable shopping card per row on phones. */
.home-products { min-width: 0; }
.home-section-heading { display: grid; gap: 16px; margin-bottom: 16px; }
.home-section-heading h3, .home-order h2 { margin: 0; font-size: clamp(22px, 2.2vw, 28px); line-height: 1.3; letter-spacing: -.025em; font-weight: 700; }
.home-section-heading p { margin: 8px 0 0; color: var(--muted); font-size: 14px; }
.home-categories { display: inline-flex; justify-self: start; flex-wrap: wrap; gap: 4px; padding: 4px; background: #eeebe7; border-radius: 10px; }
.home-category { padding: 6px 10px; font-size: 12px; font-weight: 600; color: var(--muted); }
.home-category:first-child { background: #fff; border-radius: 7px; color: var(--ink); }
.home-product-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.home-product { min-width: 0; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--border); border-radius: 16px; overflow: hidden; }
.home-product__visual { padding: 12px 12px 0; }
.home-product__visual img { width: 100%; height: auto; aspect-ratio: 5 / 4; object-fit: cover; border-radius: 12px; }
.home-product__body { padding: 16px; display: flex; flex: 1; flex-direction: column; gap: 8px; }
.home-product__body p, .home-product__body h4 { margin: 0; }
.home-product__tag { color: var(--muted); font-size: 12px; }
.home-product__body h4 { font-size: 18px; font-weight: 700; line-height: 1.4; letter-spacing: -.015em; }
.home-product__description { color: var(--muted); font-size: 14px; line-height: 1.65; }
.home-product__footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; margin-top: auto; padding-top: 12px; }
.home-product__price { font-size: 14px; font-weight: 600; }
.home-product__details { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 0 8px 8px; color: var(--accent-strong); font-size: 14px; font-weight: 700; white-space: nowrap; }

.home-order { padding: 24px; border-radius: 18px; background: #eee9e2; }
.home-order__copy p { margin: 12px 0 0; color: var(--muted); font-size: 15px; }
.home-order__actions .fm-hero__button:not(.fm-hero__button--primary) { border-color: transparent; }

/* Footer keeps every original link; JS progressively enhances the groups. */
.home-page .site-footer { padding: 32px 0 24px; border-top: 1px solid var(--border); background: #fff; color: var(--ink); }
.home-page .site-shell--footer { max-width: 1280px; padding: 0 16px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; }
.home-page .footer__intro { display: grid; grid-template-columns: minmax(0, 1fr) 44px; column-gap: 12px; align-items: start; padding-bottom: 24px; }
.home-page .footer__intro > :is(.footer__logo, p) { grid-column: 1 / -1; }
.home-page .footer__contact-actions { grid-column: 1; }
.home-page .footer__intro > .home-chat-dock { grid-column: 2; grid-row: 3 / 5; align-self: center; }
.home-page .footer__logo { padding: 0; min-height: 44px; border: 0; background: transparent; }
.home-page .footer__logo-image { height: 40px; max-width: 172px; }
.home-page .footer__intro p { max-width: 360px; margin: 16px 0 12px; color: var(--muted); font-size: 14px; }
.home-page .footer__contact-actions { gap: 0; }
.home-page .footer__contact-actions a { min-height: 44px; padding: 8px 0; font-size: 14px; font-weight: 500; color: var(--ink); background: transparent; }
.home-page .footer__contact-actions i { color: var(--muted); }
.home-page .footer__withdrawal-button { grid-column: 1; min-height: 44px; padding: 10px 14px; margin-top: 12px; border: 1px solid var(--border); border-radius: 10px; background: #f7f5f2; color: var(--ink) !important; font-size: 13px; font-weight: 600; }
.home-page :is(.footer__nav, .footer__company, .footer__address) { display: block; padding: 0; border-top: 1px solid var(--border); }
.home-page .footer__heading { margin: 0; padding: 16px 0; text-transform: none; letter-spacing: 0; color: var(--ink); font-size: 15px; font-weight: 600; }
.home-footer-toggle { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 52px; border: 0; background: transparent; color: inherit; padding: 0; font: inherit; text-align: left; cursor: pointer; }
.home-footer-toggle::after { content: ''; width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); margin: 0 4px 4px 16px; }
.home-footer-toggle[aria-expanded="true"]::after { transform: rotate(225deg); margin-bottom: 0; }
.home-footer-panel { padding-bottom: 16px; }
.home-footer-panel[hidden] { display: none; }
.home-page .footer__nav a { display: flex; align-items: center; min-height: 44px; padding: 8px 0; width: 100%; color: var(--muted); font-size: 14px; font-weight: 500; }
.home-page .footer__company-list { gap: 8px; }
.home-page .footer__company-list div { grid-template-columns: minmax(104px, .8fr) minmax(0, 1fr); gap: 12px; padding: 0; }
.home-page .footer__company-list dt, .home-page .footer__company-list dd { color: var(--muted); font-size: 13px; font-weight: 500; }
.home-page .footer__address address { color: var(--muted); font-size: 14px; font-weight: 500; }
.home-page .footer__social { margin-top: 12px; gap: 8px; }
.home-page .footer__social a { width: 44px; height: 44px; background: #f7f5f2; color: var(--ink); border-radius: 10px; }
.home-page .footer__legal { max-width: 1248px; margin: 24px auto 0; padding: 24px 16px 0; text-align: left; border-top: 1px solid var(--border); color: var(--muted); }
.home-page .footer__legal-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; margin-bottom: 16px; }
.home-page .footer__legal-links a { display: flex; align-items: center; min-height: 44px; padding: 8px 0; font-size: 13px; font-weight: 500; line-height: 1.5; color: var(--muted); }
.home-page .footer__legal small { max-width: 420px; font-size: 12px; }
.home-page .footer__avora-logo { margin: 16px 0 0; min-height: 44px; }
.home-page .footer__avora-logo img { height: 28px; }

/* On compact screens the contact dock has its own footer space, so it
   cannot obscure product actions. Wide screens have a floating side rail. */
.home-chat-dock { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; padding: 0; }
.home-chat { display: inline-flex; justify-content: center; align-items: center; width: 44px; height: 44px; border-radius: 50%; color: #fff; font-size: 21px; box-shadow: 0 3px 10px #25232114; }
.home-page .home-chat--messenger,
.home-page .home-chat--messenger:hover { background: #fff; color: #1877f2; }
.home-page .home-chat--whatsapp,
.home-page .home-chat--whatsapp:hover { background: #25d366; color: #fff; }
.home-page.cart-drawer-open .home-chat-dock { visibility: hidden; }

@media (max-width: 1100px) {
}
@media (min-width: 600px) {
  .fm-hero__actions { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 560px; margin: 20px auto 0; }
  .home-order__actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-page .footer__legal-links { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; }
}
@media (min-width: 760px) {
  .fm-hero { padding-top: 24px; }
  .home-content { padding-top: 32px; padding-bottom: 48px; gap: 40px; }
  .home-benefits { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
  .home-benefit { padding: 8px 0; gap: 8px; }
  .home-benefit + .home-benefit { border-top: 0; }
  .home-product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .home-section-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 24px; }
  .home-categories { flex-shrink: 0; }
  .home-product__body { padding: 20px; }
  .home-order { display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, .65fr); align-items: center; gap: 32px; padding: 32px; }
  .home-order__actions { grid-template-columns: minmax(0, 1fr); margin-top: 0; }
  .home-page .site-footer { padding-top: 40px; }
  .home-page .site-shell--footer { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 24px; }
  .home-page .footer__intro { grid-column: 1 / -1; padding-bottom: 0; }
  .home-page :is(.footer__nav, .footer__company, .footer__address) { border-top: 0; }
  .home-page .footer__heading { padding: 0 0 16px; }
  .home-footer-toggle { min-height: 0; cursor: default; }
  .home-footer-toggle::after { display: none; }
}
@media (min-width: 1101px) {
  .home-product-grid { gap: 24px; }
  .home-page .site-shell--footer { grid-template-columns: 1.25fr 1fr 1fr .9fr; gap: 32px; }
  .home-page .footer__intro { grid-column: auto; }
  .home-page .footer__company-list div { grid-template-columns: 1fr; gap: 0; }
  .home-page .footer__legal-links { display: flex; justify-content: flex-start; flex-wrap: wrap; gap: 0 24px; }
}
@media (min-width: 1400px) {
  .home-page .footer__intro { grid-template-columns: minmax(0, 1fr); }
  .home-chat-dock { position: fixed; right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); padding: 0; background: transparent; z-index: 15; }
}
@media (hover: hover) and (pointer: fine) {
  .fm-hero__button:hover { background: #e9e4df; color: var(--ink); }
  .fm-hero__button--primary:hover { background: #83195f; color: #fff; }
  .home-product__details:hover { text-decoration: underline; text-underline-offset: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-page *, .home-page *::before, .home-page *::after { transition: none !important; scroll-behavior: auto !important; }
}
