/*
Theme Name: Voda i Moloko
Theme URI: https://example.com/
Author: Codex
Description: Custom WooCommerce theme for the Voda i Moloko catalog.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 8.0
Text Domain: voda-moloko
*/

:root {
  --vm-blue: #5f9fce;
  --vm-blue-dark: #2f6f9e;
  --vm-blue-soft: #eaf4fc;
  --vm-ink: #1d2a36;
  --vm-muted: #758596;
  --vm-line: #dce7f0;
  --vm-bg: #f6faff;
  --vm-card: #ffffff;
  --vm-green: #28b66f;
  --vm-yellow: #ffc94a;
  --vm-red: #ee5e5e;
  --vm-shadow: 0 14px 34px rgba(31, 73, 105, .09);
  --vm-radius: 8px;
  --vm-container: 1180px;
  font-family: Inter, Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--vm-ink);
  background: var(--vm-bg);
  font-family: Inter, Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  height: auto;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
}

.vm-container {
  width: min(calc(100% - 32px), var(--vm-container));
  margin: 0 auto;
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.vm-topbar {
  background: #ffffff;
  border-bottom: 1px solid var(--vm-line);
}

.vm-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .96);
  border-bottom: 1px solid var(--vm-line);
  backdrop-filter: blur(12px);
}

.vm-header__row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: center;
  min-height: 74px;
}

.vm-logo {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  font-weight: 800;
  color: var(--vm-blue-dark);
  white-space: nowrap;
}

.vm-logo__mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: #fff;
  background: var(--vm-blue);
  border-radius: 8px;
  font-size: 18px;
}

.vm-nav {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.vm-nav a {
  padding: 10px 12px;
  border-radius: 8px;
  color: #31485c;
  font-size: 14px;
  font-weight: 600;
}

.vm-nav a:hover,
.vm-nav .current-menu-item > a {
  color: var(--vm-blue-dark);
  background: var(--vm-blue-soft);
}

.vm-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.vm-icon-link,
.vm-cart-link {
  display: inline-grid;
  min-width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
  color: var(--vm-blue-dark);
  font-weight: 700;
}

.vm-cart-link {
  grid-auto-flow: column;
  gap: 8px;
  padding: 0 12px;
}

.vm-btn,
.button,
button.single_add_to_cart_button,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  background: var(--vm-blue-dark);
  box-shadow: none;
  cursor: pointer;
  font-weight: 750;
  line-height: 1;
  text-align: center;
}

.vm-btn:hover,
.button:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
  background: #215e87;
}

.vm-btn--light {
  color: var(--vm-blue-dark);
  background: #fff;
  border: 1px solid var(--vm-line);
}

.vm-btn--light:hover {
  background: var(--vm-blue-soft);
}

.vm-hero {
  padding: 44px 0 34px;
  background:
    radial-gradient(circle at 82% 20%, rgba(255, 201, 74, .32), transparent 30%),
    linear-gradient(135deg, #ffffff 0%, #eff8ff 58%, #dcefff 100%);
  border-bottom: 1px solid var(--vm-line);
}

.vm-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 40px;
  align-items: center;
}

.vm-kicker {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 14px;
  color: var(--vm-blue-dark);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.vm-title {
  max-width: 650px;
  margin: 0 0 18px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: .95;
  font-weight: 900;
}

.vm-lead {
  max-width: 610px;
  margin: 0 0 24px;
  color: #4d6276;
  font-size: 18px;
}

.vm-hero__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.vm-hero__visual {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.vm-product-tile {
  min-height: 162px;
  padding: 18px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--vm-shadow);
}

.vm-product-tile:nth-child(2) {
  transform: translateY(28px);
}

.vm-product-tile__image {
  position: relative;
  display: grid;
  height: 84px;
  margin-bottom: 12px;
  place-items: center;
  border-radius: 8px;
  background: linear-gradient(160deg, #e9f4ff, #ffffff);
  color: var(--vm-blue-dark);
  overflow: hidden;
}

.vm-product-tile__image span {
  display: block;
  width: 38px;
  height: 62px;
  border: 3px solid currentColor;
  border-radius: 9px 9px 6px 6px;
  background: linear-gradient(#fff 0 35%, #d8ecfb 35% 100%);
}

.vm-product-tile__image--milk span {
  background: linear-gradient(#fff 0 30%, #f7fbff 30% 100%);
}

.vm-product-tile__image--water span {
  width: 30px;
  background: linear-gradient(#fff 0 24%, #9ed1f0 24% 100%);
}

.vm-product-tile__image--coffee span {
  width: 54px;
  height: 44px;
  border-radius: 7px 7px 12px 12px;
  background: linear-gradient(#744b2b 0 60%, #d9b38b 60% 100%);
}

.vm-product-tile__image--syrup span {
  width: 34px;
  background: linear-gradient(#fff 0 22%, #ffc94a 22% 100%);
}

.vm-section {
  padding: 42px 0;
}

.vm-section--white {
  background: #fff;
}

.vm-section__head {
  display: flex;
  gap: 18px;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 22px;
}

.vm-section__head h2,
.vm-page-title {
  margin: 0;
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.1;
}

.vm-section__head p {
  max-width: 520px;
  margin: 0;
  color: var(--vm-muted);
}

.vm-category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.vm-category-card {
  min-height: 142px;
  padding: 18px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--vm-shadow);
}

.vm-category-card__icon {
  position: relative;
  width: 46px;
  height: 46px;
  display: grid;
  margin-bottom: 18px;
  place-items: center;
  border-radius: 8px;
  background: var(--vm-blue-soft);
  color: var(--vm-blue-dark);
  font-size: 24px;
}

.vm-category-card__icon::before,
.vm-category-card__icon::after {
  content: "";
  position: absolute;
  background: currentColor;
  border-radius: 6px;
}

.vm-category-card__icon::before {
  width: 16px;
  height: 26px;
  left: 12px;
  top: 10px;
  opacity: .72;
}

.vm-category-card__icon::after {
  width: 14px;
  height: 18px;
  right: 10px;
  bottom: 9px;
  opacity: .35;
}

.vm-category-card h3 {
  margin: 0 0 6px;
  font-size: 18px;
}

.vm-category-card p {
  margin: 0;
  color: var(--vm-muted);
  font-size: 14px;
}

.vm-benefits {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.vm-benefit {
  padding: 18px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.vm-benefit strong {
  display: block;
  margin-bottom: 6px;
}

.vm-benefit span {
  color: var(--vm-muted);
  font-size: 14px;
}

.vm-faq {
  display: grid;
  gap: 10px;
}

.vm-faq details {
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.vm-faq summary {
  padding: 16px 18px;
  cursor: pointer;
  font-weight: 750;
}

.vm-faq p {
  margin: 0;
  padding: 0 18px 18px;
  color: var(--vm-muted);
}

.vm-page {
  padding: 38px 0 52px;
}

.vm-content {
  max-width: 850px;
}

.vm-catalog-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.vm-sidebar {
  position: sticky;
  top: 94px;
  padding: 18px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.vm-sidebar h2,
.vm-sidebar h3 {
  margin: 0 0 14px;
  font-size: 18px;
}

.vm-filter-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.vm-filter-list a {
  display: flex;
  justify-content: space-between;
  padding: 9px 10px;
  border-radius: 8px;
  color: #3a5064;
  font-size: 14px;
}

.vm-filter-list a:hover {
  background: var(--vm-blue-soft);
  color: var(--vm-blue-dark);
}

.vm-shop-top {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.woocommerce-result-count,
.woocommerce-ordering {
  margin: 0;
  color: var(--vm-muted);
  font-size: 14px;
}

.woocommerce-ordering select,
.input-text,
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
input[type="number"],
input[type="search"],
textarea,
select {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
  color: var(--vm-ink);
}

.search-form {
  display: flex;
  gap: 10px;
  align-items: center;
}

.search-form label {
  min-width: min(320px, 100%);
}

.products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.product,
.vm-product-card {
  position: relative;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--vm-shadow);
}

.product img,
.vm-product-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  margin-bottom: 14px;
  border-radius: 8px;
  background: #f4f8fb;
}

.woocommerce-loop-product__title,
.vm-product-card h3 {
  min-height: 44px;
  margin: 0 0 8px;
  color: var(--vm-ink);
  font-size: 16px;
  line-height: 1.35;
}

.price {
  display: block;
  margin-bottom: 12px;
  color: var(--vm-blue-dark);
  font-size: 17px;
  font-weight: 850;
}

.onsale,
.vm-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  padding: 5px 8px;
  border-radius: 8px;
  color: #fff;
  background: var(--vm-green);
  font-size: 12px;
  font-weight: 800;
}

.vm-product,
.single-product div.product {
  display: grid;
  grid-template-columns: minmax(0, 520px) minmax(0, 1fr);
  gap: 42px;
  align-items: start;
}

.woocommerce-product-gallery,
.vm-product__gallery {
  padding: 22px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.summary.entry-summary {
  padding: 24px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.product_title {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.05;
}

.quantity {
  display: inline-flex;
  max-width: 110px;
  margin-right: 10px;
}

.quantity input {
  text-align: center;
}

.woocommerce-tabs,
.related.products {
  margin-top: 34px;
}

.woocommerce-tabs ul.tabs {
  display: flex;
  gap: 8px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.woocommerce-tabs ul.tabs a {
  display: block;
  padding: 10px 14px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
  font-weight: 750;
}

.woocommerce-tabs .panel {
  padding: 20px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.shop_table,
.woocommerce-checkout-review-order-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.shop_table th,
.shop_table td {
  padding: 14px;
  border-bottom: 1px solid var(--vm-line);
  text-align: left;
}

.shop_table tr:last-child th,
.shop_table tr:last-child td {
  border-bottom: 0;
}

.cart-collaterals,
.woocommerce-checkout #order_review,
.woocommerce-billing-fields,
.woocommerce-shipping-fields,
.woocommerce-additional-fields {
  padding: 20px;
  border: 1px solid var(--vm-line);
  border-radius: 8px;
  background: #fff;
}

.woocommerce-checkout .col2-set {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.woocommerce-checkout-review-order {
  margin-top: 18px;
}

.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  margin: 0 0 18px;
  padding: 14px 16px;
  border: 1px solid var(--vm-line);
  border-left: 4px solid var(--vm-blue-dark);
  border-radius: 8px;
  background: #fff;
  list-style-position: inside;
}

.vm-footer {
  padding: 34px 0 26px;
  background: #fff;
  border-top: 1px solid var(--vm-line);
}

.vm-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 24px;
}

.vm-footer h2,
.vm-footer h3 {
  margin: 0 0 12px;
  font-size: 16px;
}

.vm-footer p,
.vm-footer a {
  color: var(--vm-muted);
  font-size: 14px;
}

.vm-footer ul {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.vm-footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--vm-line);
  color: var(--vm-muted);
  font-size: 13px;
}

.vm-mobile-toggle {
  display: none;
}

@media (max-width: 1020px) {
  .vm-header__row,
  .vm-hero__grid,
  .vm-product,
  .vm-catalog-layout,
  .woocommerce-checkout .col2-set {
    grid-template-columns: 1fr;
  }

  .vm-nav {
    justify-content: flex-start;
  }

  .vm-sidebar {
    position: static;
  }

  .vm-category-grid,
  .vm-benefits,
  .products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .vm-footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .vm-container {
    width: min(calc(100% - 22px), var(--vm-container));
  }

  .vm-header__row {
    grid-template-columns: 1fr auto auto;
    gap: 12px;
    min-height: auto;
    padding: 12px 0;
  }

  .vm-mobile-toggle {
    display: inline-grid;
  }

  .vm-nav {
    display: none;
    grid-column: 1 / -1;
    width: 100%;
    padding: 10px 0;
  }

  .vm-nav.is-open {
    display: grid;
  }

  .vm-actions {
    justify-content: end;
  }

  .search-form {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .vm-hero {
    padding-top: 30px;
  }

  .vm-hero__visual,
  .vm-category-grid,
  .vm-benefits,
  .products,
  .vm-footer__grid {
    grid-template-columns: 1fr;
  }

  .vm-product-tile:nth-child(2) {
    transform: none;
  }

  .vm-section__head,
  .vm-shop-top,
  .vm-footer__bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .shop_table th,
  .shop_table td {
    padding: 10px;
  }
}
