/* ORRANET storefront — customer facing, mobile first */

:root {
  --store-accent: #25d366;
  --store-dark: #075e54;
  --store-bg: #f7f7f5;
  --store-surface: #ffffff;
  --store-text: #111b21;
  --store-muted: #667781;
  --store-border: #e2e5e0;
}

* {
  box-sizing: border-box;
}

html {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: "Segoe UI", Helvetica, Arial, sans-serif;
  color: var(--store-text);
  background: var(--store-bg);
  padding-bottom: 90px; /* leaves room for the floating WhatsApp button */
  max-width: 100%;
  overflow-x: hidden;
}

a {
  color: inherit;
}

/* Header */

.store-header {
  background: var(--store-accent);
  color: #fff;
  padding: 16px 16px 14px;
}

.store-header__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.store-header__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

/* Fixed rectangle box so any logo, whatever its real size or shape,
   always displays at the same footprint in the header. */
.store-header__logo-rect {
  width: 120px;
  height: 40px;
  object-fit: contain;
  object-position: left center;
  flex-shrink: 0;
}

.store-header__logo-rect--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: var(--store-accent);
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
}

.store-header__divider {
  width: 1px;
  height: 28px;
  background: rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
}

.store-header__tagline {
  min-width: 0;
  overflow: hidden;
}

.store-header__business-name {
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.store-header__description-short {
  font-size: 11px;
  color: #dff5ee;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.store-header__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.store-menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  cursor: pointer;
  padding: 0;
}

.store-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border-radius: 24px;
  padding: 10px 16px;
}

.store-search__icon {
  color: var(--store-muted);
  flex-shrink: 0;
}

.store-search input[type="text"] {
  flex: 1;
  border: none;
  outline: none;
  font-size: 13px;
  color: var(--store-text);
  background: transparent;
  min-width: 0;
}

.store-search input[type="text"]::placeholder {
  color: var(--store-muted);
}

/* Search bar max width on desktop */
@media (min-width: 700px) {
  .store-search {
    max-width: 560px;
    margin: 0 auto; /* centers it within the header */
  }
}
/* Slide-in menu */

.store-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  z-index: 105;
}

.store-menu-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}

.store-menu {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 80%;
  max-width: 300px;
  background: #fff;
  transform: translateX(100%);
  transition: transform 0.28s ease;
  z-index: 110;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.store-menu.is-open {
  transform: translateX(0);
}

.store-menu__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  background: var(--store-accent);
  color: #fff;
}

.store-menu__title {
  font-size: 15px;
  font-weight: 700;
}

.store-menu__close {
  background: none;
  border: none;
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.store-menu__section {
  padding: 16px 20px;
}

.store-menu__section-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--store-muted);
  margin-bottom: 8px;
}

.store-menu__link {
  display: block;
  padding: 12px 0;
  font-size: 14px;
  color: var(--store-text);
  text-decoration: none;
  border-bottom: 1px solid var(--store-border);
}

.store-menu__link.is-active {
  color: var(--store-accent);
  font-weight: 700;
}

.store-menu__footer {
  padding: 20px;
  border-top: 1px solid var(--store-border);
  margin-top: 8px;
}

.store-menu__cta {
  display: block;
  text-align: center;
  padding: 13px 16px;
  border-radius: 24px;
  background: var(--store-accent);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 360px) {
  .store-header {
    padding: 12px 12px 12px;
  }

  .store-header__logo-rect {
    width: 80px;
    height: 32px;
  }

  .store-header__business-name {
    font-size: 13px;
  }

  .store-header__description-short {
    font-size: 10px;
  }

  .store-header__divider {
    display: none;
  }

  .store-content {
    padding: 16px 10px;
  }

  .store-grid {
    gap: 8px;
  }
}

/* Category filter */

.store-categories {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding: 16px 16px 14px;
  background: var(--store-surface);
  border-bottom: 1px solid var(--store-border);
  -webkit-overflow-scrolling: touch;
}

.store-categories::-webkit-scrollbar {
  display: none;
}

.store-category-item {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  width: 60px;
}

.store-category-item__icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #eef6f0;
  color: var(--store-accent);
}

.store-category-item__icon-wrap.is-active {
  background: var(--store-accent);
  color: #fff;
}

.store-category-item__label {
  font-size: 11px;
  font-weight: 500;
  color: var(--store-text);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
}

.store-category-item__label.is-active {
  font-weight: 700;
  border-bottom-color: var(--store-accent);
}

/* Product grid */

.store-content {
  padding: 20px 14px;
}

.store-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  min-width: 0;
}

.store-product {
  display: block;
  background: var(--store-surface);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  border: 1px solid var(--store-border);
  min-width: 0;
}

.store-product__image {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #f0efec;
}

.store-product__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.store-product__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--store-muted);
}

.store-product__stock-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(17, 27, 33, 0.75);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 10px;
}

.store-product__info {
  padding: 10px;
}

.store-product__name {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.store-product__price-old {
  display: block;
  text-decoration: line-through;
  color: var(--store-muted);
  font-size: 11px;
}

.store-product__price-current {
  font-weight: 700;
  font-size: 14px;
  color: var(--store-accent);
}

/* Pagination */

.store-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 4px 4px;
}

.store-pagination__link {
  padding: 8px 16px;
  border-radius: 20px;
  background: var(--store-accent);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.store-pagination__link--disabled {
  background: #f0efec;
  color: var(--store-muted);
}

.store-pagination__status {
  font-size: 12px;
  color: var(--store-muted);
  white-space: nowrap;
}

/* Empty state */

.store-empty {
  text-align: center;
  padding: 48px 24px 40px;
  color: var(--store-muted);
}

.store-empty__art {
  position: relative;
  display: inline-block;
  margin-bottom: 24px;
}

.store-empty__bag {
  color: var(--store-accent);
}

.store-empty__spark {
  position: absolute;
  font-size: 20px;
  color: var(--store-accent);
  opacity: 0.6;
}

.store-empty__spark--left {
  top: 10px;
  left: -22px;
  transform: rotate(-15deg);
}

.store-empty__spark--note {
  position: absolute;
  top: -6px;
  right: -70px;
  width: 90px;
  font-size: 12px;
  font-family: "Segoe Script", "Comic Sans MS", cursive;
  color: var(--store-accent);
  opacity: 0.85;
  transform: rotate(6deg);
  text-align: left;
  line-height: 1.3;
}

.store-empty__heading {
  font-size: 20px;
  font-weight: 700;
  color: var(--store-text);
  margin: 0 0 8px;
}

.store-empty__hint {
  font-size: 13px;
  max-width: 280px;
  margin: 0 auto 20px;
  line-height: 1.5;
}

.store-empty__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 28px;
  border-radius: 24px;
  background: var(--store-accent);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

/* Footer */

.store-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px 16px 32px;
  font-size: 12px;
  color: var(--store-muted);
}

.store-footer__line {
  width: 40px;
  height: 1px;
  background: var(--store-border);
}

/* Floating WhatsApp button */

.store-whatsapp-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: #25d366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  text-decoration: none;
}

/* Not found page */

.not-found {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
}

.not-found__logo {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--store-dark);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 22px;
  margin-bottom: 16px;
}

.not-found h1 {
  font-size: 18px;
  margin: 0 0 8px;
}

.not-found p {
  color: var(--store-muted);
  font-size: 14px;
  max-width: 320px;
}

@media (min-width: 600px) {
  .store-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 900px) {
  .store-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .store-content {
    max-width: 960px;
    margin: 0 auto;
    padding: 24px 16px;
  }

  .store-categories {
    max-width: 960px;
    margin: 0 auto;
  }
}

/* Product detail page */

.product-header {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--store-accent);
  color: #fff;
  padding: 14px 16px;
}

.product-header__back {
  font-size: 18px;
  text-decoration: none;
  color: #fff;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}

.product-header__store-name {
  font-size: 14px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-detail {
  padding: 0 0 8px;
}

.product-detail__image {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #f0efec;
}

.product-detail__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-detail__info {
  padding: 18px 16px 8px;
}

.product-detail__category {
  font-size: 12px;
  color: var(--store-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.product-detail__name {
  font-size: 19px;
  font-weight: 700;
  margin: 0 0 10px;
}

.product-detail__price {
  margin-bottom: 16px;
}

.product-detail__price-current {
  font-size: 22px;
  font-weight: 700;
  color: var(--store-accent);
}

.product-detail__description {
  font-size: 14px;
  line-height: 1.6;
  color: var(--store-text);
  margin: 0 0 22px;
}

.product-detail__order-btn {
  display: block;
  width: 100%;
  text-align: center;
  padding: 14px 16px;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  background: #25d366;
  border: none;
  border-radius: 26px;
  text-decoration: none;
  cursor: pointer;
}

.product-detail__order-btn--disabled {
  background: var(--store-border);
  color: var(--store-muted);
  cursor: not-allowed;
}

.store-section-title {
  font-size: 15px;
  font-weight: 700;
  margin: 0 0 14px;
}

@media (min-width: 700px) {
  .product-detail {
    display: flex;
    gap: 32px;
    max-width: 960px;
    margin: 0 auto;
    padding: 24px 16px;
  }

  .product-detail__image {
    flex: 1;
    max-width: 420px;
    border-radius: 12px;
    overflow: hidden;
  }

  .product-detail__info {
    flex: 1;
    padding: 0;
  }
}

/* Cart icon in headers */

.store-cart-link {
  position: absolute;
  top: 20px;
  right: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  text-decoration: none;
}

.store-cart-link--inline {
  position: relative;
  top: 0;
  right: 0;
  margin-left: auto;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.store-cart-link__badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 3px;
  border-radius: 8px;
  background: #ff3b30;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Cart page */

.cart-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.cart-item {
  display: flex;
  gap: 12px;
  background: var(--store-surface);
  border: 1px solid var(--store-border);
  border-radius: 12px;
  padding: 12px;
  align-items: flex-start;
}

.cart-item__image img,
.cart-item__image .store-product__placeholder {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
}

.cart-item__details {
  flex: 1;
  min-width: 0;
}

.cart-item__name {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 2px;
}

.cart-item__unit-price {
  font-size: 12px;
  color: var(--store-muted);
  margin-bottom: 8px;
}

.cart-item__qty-form {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.cart-item__qty-form input {
  width: 56px;
  padding: 6px 8px;
  font-size: 13px;
  border: 1px solid var(--store-border);
  border-radius: 6px;
}

.cart-item__subtotal {
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.btn-link {
  background: none;
  border: none;
  padding: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--store-accent);
  cursor: pointer;
  text-decoration: none;
}

.btn-link--danger {
  color: #d1453b;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 4px;
  border-top: 1px solid var(--store-border);
  margin-bottom: 16px;
  font-size: 15px;
  font-weight: 700;
}

.cart-total__amount {
  color: var(--store-accent);
  font-size: 18px;
}

/* Checkout */

.checkout-summary {
  background: var(--store-surface);
  border: 1px solid var(--store-border);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 20px;
}

.checkout-summary__row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 6px 0;
  color: var(--store-text);
}

.checkout-summary__row--total {
  border-top: 1px solid var(--store-border);
  margin-top: 6px;
  padding-top: 12px;
  font-weight: 700;
  font-size: 15px;
}

.store-alert {
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 16px;
}

.store-alert--error {
  background: #fdeceb;
  color: #d1453b;
  border: 1px solid #f4c7c3;
}

.store-field {
  margin-bottom: 14px;
}

.store-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
}

.store-field input,
.store-field textarea {
  width: 100%;
  padding: 11px 14px;
  font-size: 14px;
  font-family: inherit;
  border: 1px solid var(--store-border);
  border-radius: 8px;
  background: #f7f7f5;
  color: var(--store-text);
}

.store-field textarea {
  resize: vertical;
}

.checkout-payment {
  background: #f7f7f5;
  border-radius: 12px;
  padding: 14px 16px;
  margin: 20px 0;
}

.checkout-payment h3 {
  font-size: 14px;
  margin: 0 0 6px;
}

.checkout-payment p {
  font-size: 13px;
  color: var(--store-muted);
  margin: 0 0 8px;
}

.checkout-payment__details {
  font-size: 14px;
  line-height: 1.6;
}

.checkout-payment__note {
  margin-top: 8px;
  font-size: 12px;
}

.product-detail__cart-form {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

.product-detail__qty-input {
  width: 64px;
  padding: 0 10px;
  border: 1px solid var(--store-border);
  border-radius: 26px;
  text-align: center;
  font-size: 14px;
}

.product-detail__order-btn--secondary {
  background: transparent;
  color: var(--store-accent);
  border: 1px solid var(--store-accent);
}

/* Order confirmation */

.confirmation {
  max-width: 480px;
  margin: 0 auto;
  padding: 40px 20px 60px;
  text-align: center;
}

.confirmation__check {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--store-accent);
  color: #fff;
  font-size: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.confirmation h1 {
  font-size: 20px;
  margin: 0 0 4px;
}

.confirmation__order-number {
  color: var(--store-muted);
  font-size: 13px;
  margin: 0 0 20px;
}

.confirmation__continue {
  display: block;
  margin-top: 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--store-accent);
  text-decoration: none;
}

.gallery-thumbs {
  display: flex;
  gap: 8px;
  padding: 10px 16px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.gallery-thumbs::-webkit-scrollbar {
  display: none;
}

.gallery-thumbs__item {
  position: relative;
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  padding: 0;
  background: #f0efec;
  cursor: pointer;
}

.gallery-thumbs__item.is-active {
  border-color: var(--store-accent);
}

.gallery-thumbs__item img,
.gallery-thumbs__item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-thumbs__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 14px;
  text-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
}

.payment-method-picker {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.payment-method-picker__option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--store-border);
  border-radius: 10px;
  font-size: 13px;
  cursor: pointer;
}

.payment-method-picker__option input {
  width: auto;
}