@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --primary-color: #1B4332;
  --secondary-color: #2D6A4F;
  --accent-color: #40916C;
  --text-color: #333333;
  --light-gray: #F5F5F5;
  --border-color: #E0E0E0;
  --white: #FFFFFF;
  --container-width: 1200px;
  --border-radius: 8px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--text-color);
  line-height: 1.5;
  background-color: var(--white);
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1rem;
}

/* Top Banner */
.top-banner {
  background-color: var(--primary-color);
  color: var(--white);
  padding: 0.5rem 0;
  font-size: 0.875rem;
}

.top-banner .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.phone-number {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Main Header */
.main-header {
  background-color: var(--white);
  padding: 0.5rem 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  position: relative;
}

.main-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: nowrap;
}

.logo {
  flex: 0 0 auto;
}

.logo img {
  height: 110px;
  width: auto;
  transition: all 0.3s ease;
  cursor: pointer;
  user-select: none;
  position: relative;
  top: 0;
  margin-top: -5px;
}

.logo img:hover {
  transform: scale(1.02);
}

.logo img:active {
  transform: scale(0.98);
}

.search-bar {
  flex: 1 1 300px;
  max-width: 600px;
  min-width: 180px;
  display: flex;
  align-items: center;
  margin: 0 1rem;
  background-color: var(--light-gray);
  border-radius: var(--border-radius);
  padding: 0.5rem;
}

.search-bar input {
  flex: 1;
  border: none;
  background: none;
  padding: 0.5rem;
  font-size: 0.875rem;
  outline: none;
}

.search-bar button {
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
  color: var(--text-color);
}

.header-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex: 0 0 auto;
}

.login-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  border-radius: var(--border-radius);
  font-size: 0.875rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.login-btn:hover {
  background-color: var(--secondary-color);
}

.login-btn i {
  font-size: 1rem;
}

.cart-icon {
  color: var(--text-color);
  text-decoration: none;
  font-size: 1.25rem;
}

.facebook-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  background-color: #1877f2;
  color: var(--white);
  border-radius: 50%;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.facebook-button:hover {
  background-color: #166fe5;
  transform: scale(1.05);
}

/* Hero Section */
.hero-section {
  background-color: #F8F9FA;
  padding: 3rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.hero-content {
  flex: 1;
  padding: 2rem;
}

.hero-content h2 {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.buy-now {
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  padding: 1rem 2rem;
  border-radius: var(--border-radius);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.buy-now:hover {
  background-color: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(27, 67, 50, 0.15);
}

.buy-now:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(27, 67, 50, 0.1);
}

/* Add a subtle indicator that shows this is a scroll-down button */
.buy-now::after {
  content: '↓';
  position: absolute;
  right: 1rem;
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.3s ease;
}

.buy-now:hover::after {
  opacity: 1;
  transform: translateY(0);
}

.hero-image {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-image img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
}

/* Filters Section */
.filters-section {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 2rem;
}

.filters {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
}

.filter-select,
.sort-select {
  padding: 0.5rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  background-color: var(--white);
  font-size: 0.875rem;
  cursor: pointer;
  outline: none;
}

/* Products Section */
.products-section {
  padding: 2rem 0;
}

.section-title {
  font-size: 1.5rem;
  margin-bottom: 2rem;
  color: var(--primary-color);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

/* Product Card: Only image area is square, info/buttons below */
.product-card {
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.product-image-wrapper {
  width: 100%;
  aspect-ratio: 1/1;
  overflow: hidden;
  background: #f8f8f8;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
  display: block;
}

.product-info {
  padding: 1rem;
  position: relative;
  flex: 0 0 auto;
}

.wishlist-icon {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background-color: var(--white);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.product-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 1rem 0;
}

.price {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--primary-color);
}

.rating {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  color: #FFB800;
}

.rating span {
  color: var(--text-color);
  font-size: 0.875rem;
  margin-left: 0.5rem;
}

.purchase-btn {
  width: 100%;
  padding: 0.75rem;
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  border-radius: var(--border-radius);
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.purchase-btn:hover {
  background-color: var(--secondary-color);
}

/* Payment Methods Dropdown */
.dropdown {
  margin-top: 1rem;
  padding: 1.5rem;
  border-top: 1px solid var(--border-color);
  background-color: var(--white);
  border-radius: 0 0 var(--border-radius) var(--border-radius);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.dropdown h3 {
  font-size: 1rem;
  color: var(--text-color);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.main-options {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.main-option-btn {
  flex: 1;
  min-width: 0;
  padding: 0.75rem 1rem;
  background-color: var(--light-gray);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-color);
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
}

.main-option-btn:hover {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: var(--white);
}

.main-option-btn.active {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: var(--white);
}

.sub-options {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0.5rem 0;
}

.bank-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  vertical-align: middle;
  margin-left: 8px;
}

.sub-option {
  padding: 0.75rem;
  border-radius: var(--border-radius);
  background-color: var(--white);
  border: 1px solid var(--border-color);
  text-align: center;
  font-weight: 500;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.sub-option:hover {
  background-color: var(--light-gray);
  border-color: var(--primary-color);
  color: var(--primary-color);
}

/* Bank-specific styles */
.sub-option[onclick*="საქართველოს ბანკი"] {
  border-color: #ff5b37;
  color: #ff5b37;
}

.sub-option[onclick*="საქართველოს ბანკი"]:hover {
  background-color: #fff1ef;
}

.sub-option[onclick*="თიბისი"] {
  border-color: #00a3e0;
  color: #00a3e0;
}

.sub-option[onclick*="თიბისი"]:hover {
  background-color: #e6f6fc;
}

.sub-option[onclick*="ნაწილ-ნაწილ"] {
  border-color: #ff8c00;
  color: #ff8c00;
}

.sub-option[onclick*="ნაწილ-ნაწილ"]:hover {
  background-color: #fff4e6;
}

.sub-option[onclick*="განაწილება"] {
  border-color: #2b76dc;
  color: #2b76dc;
}

.sub-option[onclick*="განაწილება"]:hover {
  background-color: #edf4fc;
}

.sub-option[onclick*="TBC card"] {
  border-color: #00a3e0;
  color: #00a3e0;
}

.sub-option[onclick*="TBC card"]:hover {
  background-color: #e6f6fc;
}

.sub-option[onclick*="BoG card"] {
  border-color: #ff5b37;
  color: #ff5b37;
}

.sub-option[onclick*="BoG card"]:hover {
  background-color: #fff1ef;
}

/* Responsive adjustments for payment methods */
@media (max-width: 1024px) {
  .main-options {
    gap: 0.4rem;
  }

  .main-option-btn {
    padding: 0.5rem 0.6rem;
    font-size: 0.75rem;
  }
}

@media (max-width: 768px) {
  .dropdown {
    padding: 1rem;
  }

  .main-options {
    flex-direction: column;
    gap: 0.5rem;
  }

  .main-option-btn {
    padding: 0.6rem;
    font-size: 0.85rem;
    white-space: normal;
    text-overflow: unset;
    overflow: visible;
  }
}

/* Footer */
footer {
  background-color: var(--light-gray);
  padding: 2rem 0;
  margin-top: 4rem;
  text-align: center;
  color: var(--text-color);
}

/* Updated Detailed Footer Section for modern, left-aligned, 3-column layout */
.detailed-footer {
  background: var(--light-gray);
  padding: 2.5rem 0 1.5rem 0;
  color: var(--text-color);
  font-size: 1rem;
  margin-top: 0;
}
.detailed-footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  align-items: flex-start;
  margin-bottom: 1.5rem;
}
.detailed-footer .footer-col {
  text-align: left;
}
.detailed-footer .footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.detailed-footer .footer-col ul li {
  margin-bottom: 1.1rem;
  font-weight: 500;
  cursor: default;
  transition: color 0.2s;
  font-size: 1.05rem;
}
.detailed-footer .footer-col ul li:last-child {
  margin-bottom: 0;
}
.detailed-footer .contact-info {
  font-size: 1rem;
}
.footer-contact-row {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin: 0.7rem 0 0.7rem 0;
  flex-wrap: wrap;
}
.footer-contact-row span {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  font-size: 1.08rem;
}
.footer-icon {
  display: inline-block;
  width: 30px;
  height: 30px;
  background: none;
  border-radius: 50%;
  vertical-align: middle;
  margin-right: 0.5rem;
  text-align: center;
  line-height: 30px;
  font-size: 1.7rem;
}
.footer-icon.phone::before { content: '\260E'; }
.footer-icon.email::before { content: '\2709'; }
.footer-icon.email {
  font-size: 1.7rem;
  width: 30px;
  height: 30px;
  line-height: 30px;
  margin-right: 0.5rem;
}
.footer-address {
  font-size: 1rem;
  color: var(--text-color);
  margin-bottom: 0.2rem;
  margin-top: 0.5rem;
  font-weight: 400;
}
.payment-methods .footer-pay-images {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin-top: 0.7rem;
}
.payment-methods .footer-pay-images img {
  height: 22px !important;
  width: auto;
  object-fit: contain;
  background: none;
  box-shadow: none;
  border-radius: 0;
}
.detailed-footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.98rem;
  border-top: 1px solid var(--border-color);
  padding-top: 1.2rem;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.2rem;
}
.footer-lang {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

@media (max-width: 900px) {
  .detailed-footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
  }
}
@media (max-width: 600px) {
  .detailed-footer {
    padding: 1.2rem 0 0.7rem 0;
    font-size: 0.95rem;
  }
  .detailed-footer-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .detailed-footer .footer-col {
    text-align: left;
    margin-bottom: 1.2rem;
  }
  .payment-methods .footer-pay-images {
    gap: 0.7rem;
  }
  .payment-methods .footer-pay-images img {
    height: 28px !important;
    max-width: 90%;
  }
  .footer-contact-row span {
    font-size: 1rem;
  }
  .footer-address {
    font-size: 0.95rem;
  }
  .detailed-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.9rem;
    margin-top: 0.7rem;
  }
  .product-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

/* Responsive single-row header layout */
.main-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: nowrap;
}
.logo {
  flex: 0 0 auto;
}
.search-bar {
  flex: 1 1 300px;
  max-width: 600px;
  min-width: 180px;
  display: flex;
  align-items: center;
  margin: 0 1rem;
}
.header-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex: 0 0 auto;
}
@media (max-width: 900px) {
  .main-header .container {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .logo {
    flex: 0 0 auto;
    min-width: 0;
  }
  .header-actions {
    flex: 0 0 auto;
    min-width: 0;
  }
  .search-bar {
    flex: 1 1 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0.3rem 0 0 0;
    order: 2;
  }
  .logo, .header-actions {
    order: 1;
  }
}



/* Base Styles */
html {
  scroll-behavior: smooth;
}

/* Debug Section Styles */
.debug-section {
  background-color: #f8f9fa;
  border-top: 1px solid var(--border-color);
  padding: 2rem 0;
  margin-top: 2rem;
}

.debug-section h2 {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.debug-info {
  background: var(--white);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.debug-info h3 {
  color: var(--text-color);
  margin: 1.5rem 0 1rem 0;
  font-size: 1.1rem;
}

.debug-info h3:first-child {
  margin-top: 0;
}

.debug-info ol {
  margin-left: 1.5rem;
  line-height: 1.6;
}

.debug-info li {
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.debug-info code {
  background-color: var(--light-gray);
  padding: 0.2rem 0.4rem;
  border-radius: 3px;
  font-family: 'Courier New', monospace;
  font-size: 0.9rem;
}

.debug-btn {
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s ease;
  margin: 1rem 0;
}

.debug-btn:hover {
  background-color: var(--secondary-color);
}

.debug-output {
  margin-top: 1.5rem;
  padding: 1rem;
  background-color: var(--light-gray);
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
}

.debug-output h4 {
  color: var(--primary-color);
  margin: 0 0 0.5rem 0;
  font-size: 1rem;
}

.debug-output pre {
  background-color: var(--white);
  padding: 1rem;
  border-radius: 4px;
  overflow-x: auto;
  font-size: 0.85rem;
  line-height: 1.4;
  border: 1px solid #e0e0e0;
  margin: 0.5rem 0 1rem 0;
}

.debug-output p {
  color: #d32f2f;
  margin: 0;
  font-weight: 500;
}

.footer-link-btn {
  background: none;
  border: none;
  color: var(--primary-color);
  font-weight: 500;
  text-decoration: none;
  padding: 0;
  border-radius: 0;
  margin-bottom: 0;
  transition: color 0.2s, text-decoration 0.2s;
}
.footer-link-btn:hover {
  color: var(--secondary-color);
  text-decoration: underline;
  background: none;
  border: none;
}

.contact-info > div:first-child,
.payment-methods > div:first-child {
  font-weight: 700;
}

.home-logo-link {
  display: block;
  width: fit-content;
  margin: 2rem auto 1rem 2rem;
}
.home-logo {
  height: 110px;
  width: auto;
  display: block;
  cursor: pointer;
}
.home-logo-link:hover .home-logo {
  opacity: 0.85;
}
@media (max-width: 700px) {
  .home-logo-link {
    margin: 1rem auto 0.5rem 1rem;
  }
  .home-logo {
    height: 80px;
  }
}
