/* Reset */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: "Amazon Ember", Arial, sans-serif; background: #eaeded; color: #0f1111; font-size: 14px; -webkit-font-smoothing: antialiased; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
ul { list-style: none; }
img { display: block; }

/* ===== HEADER ===== */
.header { background: #131921; position: sticky; top: 0; z-index: 100; }
.header-inner {
  max-width: 1500px; margin: 0 auto;
  display: flex; align-items: center; padding: 0 12px; height: 60px;
}
.logo {
  padding: 8px 10px; border: none; border-radius: 4px;
  display: flex; align-items: baseline; flex-shrink: 0;
  transition: background 0.2s, transform 0.2s;
}
.logo:hover { background: rgba(255,255,255,0.1); transform: translateY(-1px); }
.logo-main { font-size: 22px; font-weight: 700; color: #fff; letter-spacing: -0.5px; }
.logo-in { font-size: 15px; font-weight: 700; color: #ff9900; }
.deliver-to {
  padding: 8px 10px; border: none; border-radius: 4px;
  color: #fff; flex-shrink: 0; margin-left: 4px;
  cursor: pointer; transition: background 0.2s, transform 0.2s;
}
.deliver-to:hover { background: rgba(255,255,255,0.1); transform: translateY(-1px); }
.deliver-label { display: block; font-size: 11px; color: #ccc; }
.deliver-location { display: block; font-size: 13px; font-weight: 700; }

/* Location Modal */
.loc-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.6);
  z-index: 300; display: none; align-items: center; justify-content: center;
}
.loc-modal-overlay.open { display: flex; }
.loc-modal {
  background: #fff; width: 400px; max-width: 90vw; max-height: 90vh; overflow-y: auto;
  border-radius: 8px; padding: 24px 28px; box-shadow: 0 8px 32px rgba(0,0,0,0.25); color: #0f1111;
}
.loc-modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.loc-modal-header h3 { font-size: 18px; font-weight: 700; }
.loc-close { font-size: 24px; color: #555; line-height: 1; cursor: pointer; background: none; border: none; padding: 4px; }
.loc-close:hover { color: #000; }
.loc-desc { font-size: 13px; color: #565959; margin-bottom: 18px; line-height: 1.5; }
.loc-section { margin-bottom: 0; }
.loc-section label { font-size: 13px; font-weight: 700; display: block; margin-bottom: 8px; }
.loc-input-row { display: flex; gap: 10px; align-items: stretch; }
.loc-input-row input {
  flex: 1; padding: 9px 12px; border: 1px solid #888; border-radius: 4px;
  font-size: 15px; outline: none; min-width: 0;
}
.loc-input-row input:focus { border-color: #e77600; box-shadow: 0 0 0 3px rgba(228,121,17,0.2); }
.loc-apply {
  width: auto !important; display: inline-flex; align-items: center; justify-content: center;
  padding: 9px 22px; flex-shrink: 0; font-size: 13px; font-weight: 600;
  border-radius: 8px; white-space: nowrap;
}
.loc-error { font-size: 12px; color: #cc0c39; margin-top: 6px; }
.loc-divider { text-align: center; margin: 18px 0; position: relative; }
.loc-divider::before {
  content: ''; position: absolute; left: 0; right: 0; top: 50%;
  border-top: 1px solid #ddd;
}
.loc-divider span { background: #fff; padding: 0 14px; position: relative; font-size: 12px; color: #565959; }
.loc-detect {
  width: 100%; padding: 11px; background: #f0f2f2; border: 1px solid #d5d9d9;
  border-radius: 8px; font-size: 14px; cursor: pointer; transition: background 0.15s;
  text-align: center;
}
.loc-detect:hover { background: #e3e6e6; }
.loc-detecting { font-size: 13px; color: #007185; text-align: center; margin-top: 10px; }
.loc-current {
  margin-top: 16px; padding: 10px 14px; background: #f7fce9; border: 1px solid #c3e88d;
  border-radius: 6px; display: flex; justify-content: space-between; align-items: center;
}
.loc-current p { font-size: 13px; margin: 0; }
.loc-current-info { flex: 1; }
.loc-current-detail { font-size: 12px; color: #565959; margin-top: 2px; }
.loc-clear { font-size: 12px; color: #007185; cursor: pointer; background: none; border: none; flex-shrink: 0; }
.loc-clear:hover { text-decoration: underline; }

/* Address Form */
.loc-address-form { margin-top: 4px; }
.loc-field { margin-bottom: 12px; }
.loc-field label { display: block; font-size: 12px; font-weight: 700; margin-bottom: 4px; color: #0f1111; }
.loc-field input {
  width: 100%; padding: 9px 12px; border: 1px solid #888; border-radius: 4px;
  font-size: 14px; outline: none;
}
.loc-field input:focus { border-color: #e77600; box-shadow: 0 0 0 3px rgba(228,121,17,0.2); }
.loc-field input[readonly] { background: #f5f5f5; color: #565959; cursor: default; }
.loc-field-row { display: flex; gap: 12px; }
.loc-field-row .loc-field { flex: 1; }
.loc-save-addr { margin-top: 4px; font-size: 14px; font-weight: 600; padding: 10px; border-radius: 8px; }
.loc-addr-error { font-size: 12px; color: #cc0c39; margin-top: 6px; text-align: center; }

@media (max-width: 480px) {
  .loc-modal { padding: 20px 18px; }
  .loc-input-row { flex-direction: column; }
  .loc-apply { width: 100% !important; }
  .loc-field-row { flex-direction: column; }
}

/* Search */
.search-bar {
  flex: 1; display: flex; height: 42px; margin: 0 12px;
  border-radius: 4px; overflow: hidden;
  box-shadow: 0 0 0 2px #ff9900;
  transition: box-shadow 0.2s;
}
.search-bar:focus-within { box-shadow: 0 0 0 3px #ff9900, 0 2px 8px rgba(255,153,0,0.2); }
.search-select {
  background: #e6e6e6; border: none; padding: 0 8px 0 12px;
  font-size: 12px; color: #555; border-right: 1px solid #cdcdcd;
  cursor: pointer; outline: none;
}
.search-bar input {
  flex: 1; border: none; padding: 0 14px; font-size: 15px;
  outline: none; color: #111;
}
.search-submit {
  background: #febd69; padding: 0 14px;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s;
}
.search-submit:hover { background: #f3a847; }

/* Nav Links */
.nav-link {
  padding: 8px 10px; border: none; border-radius: 4px;
  color: #fff; flex-shrink: 0; white-space: nowrap;
  transition: background 0.2s, transform 0.2s;
}
.nav-link:hover { background: rgba(255,255,255,0.1); transform: translateY(-1px); }
.nav-line1 { display: block; font-size: 11px; color: #ccc; }
.nav-line2 { display: block; font-size: 13px; font-weight: 700; }

/* Cart */
.nav-cart {
  display: flex; align-items: flex-end; gap: 2px;
  padding: 8px 10px; border: none; border-radius: 4px;
  color: #fff; position: relative; flex-shrink: 0;
  transition: background 0.2s, transform 0.2s;
}
.nav-cart:hover { background: rgba(255,255,255,0.1); transform: translateY(-1px); }
.cart-count { position: absolute; top: 2px; left: 24px; color: #ff9900; font-size: 16px; font-weight: 700; }
.cart-text { font-size: 13px; font-weight: 700; margin-bottom: 2px; }

/* ===== SUB NAV ===== */
.subnav { background: #232f3e; }
.subnav-inner {
  max-width: 1500px; margin: 0 auto; padding: 0 12px;
  display: flex; overflow-x: auto; gap: 2px;
}
.subnav-btn {
  padding: 9px 14px; font-size: 13px; color: #ddd;
  white-space: nowrap; border: none; border-radius: 4px;
  transition: background 0.2s, transform 0.2s, color 0.15s; background: none;
}
.subnav-btn:hover { color: #fff; background: rgba(255,255,255,0.1); transform: translateY(-1px); }
.subnav-btn.active { background: rgba(255,255,255,0.15); color: #fff; font-weight: 700; }

/* ===== HERO ===== */
.hero { position: relative; overflow: hidden; }
.hero-bg {
  height: 340px;
  background: linear-gradient(180deg, #c9e8f7 0%, #d4ecf9 40%, #eaeded 100%);
}
.hero-fade {
  position: absolute; bottom: 0; left: 0; right: 0; height: 100px;
  background: linear-gradient(transparent, #eaeded);
}
.hero-content {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.hero-card-main {
  background: #fff; padding: 36px 44px; max-width: 560px; width: 100%;
  border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,0.08);
  text-align: center;
}
.hero-card-main h1 { font-size: 26px; font-weight: 700; color: #0f1111; margin-bottom: 10px; }
.hero-card-main p { font-size: 14px; color: #565959; line-height: 1.6; margin-bottom: 20px; }
.hero-btn { display: inline-block; width: auto; padding: 10px 32px; font-size: 14px; font-weight: 600; border-radius: 20px; }

/* ===== PRODUCTS ===== */
.products-section { max-width: 1500px; margin: 20px auto 0; padding: 0 16px 24px; }
.section-bar {
  background: #fff; padding: 14px 20px;
  display: flex; justify-content: space-between; align-items: center;
  border-bottom: 1px solid #e0e0e0; border-radius: 8px 8px 0 0;
}
.section-bar h2 { font-size: 20px; font-weight: 700; }
.product-count { font-size: 13px; color: #565959; }
.products-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  background: #fff; padding: 8px; gap: 1px;
  border-radius: 0 0 8px 8px;
}

/* Product Card */
.product-card {
  padding: 16px; text-align: center;
  background: #fff; position: relative;
  border: 1px solid transparent; border-radius: 4px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.product-card:hover {
  border-color: #e0e0e0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  z-index: 1;
}
.product-badge {
  position: absolute; top: 10px; left: 10px;
  background: #cc0c39; color: #fff; font-size: 11px; font-weight: 700;
  padding: 3px 8px; border-radius: 3px; z-index: 2; letter-spacing: 0.2px;
}
.product-img {
  width: 160px; height: 160px; object-fit: contain;
  margin: 0 auto 14px; display: block;
  transition: transform 0.25s ease;
}
.product-card:hover .product-img { transform: scale(1.05); }
.product-info { text-align: left; }
.product-name {
  font-size: 14px; color: #007185; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; margin-bottom: 6px; transition: color 0.15s;
}
.product-card:hover .product-name { color: #c7511f; }

/* Rating */
.product-rating { display: flex; align-items: center; gap: 4px; margin-bottom: 6px; }
.stars { display: flex; gap: 0; }
.star { width: 16px; height: 16px; }
.star-filled { color: #de7921; }
.star-empty { color: #ddd; }
.rating-count { font-size: 12px; color: #007185; }

/* Price */
.product-price { margin-bottom: 6px; }
.price-main { display: flex; align-items: flex-start; gap: 1px; }
.price-symbol { font-size: 13px; position: relative; top: 3px; }
.price-whole { font-size: 26px; font-weight: 400; line-height: 1; }
.price-mrp { font-size: 12px; color: #565959; margin-top: 3px; }
.price-mrp-strike { text-decoration: line-through; }
.price-pct { font-size: 12px; color: #cc0c39; font-weight: 600; margin-left: 4px; }
.price-limited { font-size: 12px; color: #cc0c39; font-weight: 700; margin-bottom: 2px; }
.delivery-info { font-size: 12px; color: #565959; margin-top: 6px; }
.delivery-free { color: #0f1111; font-weight: 700; }

/* Buttons */
.btn-amazon-yellow {
  display: block; width: 100%; padding: 8px 10px;
  background: #ffd814; border: 1px solid #fcd200;
  border-radius: 20px; font-size: 13px; text-align: center;
  color: #0f1111; cursor: pointer; transition: background 0.15s;
}
.btn-amazon-yellow:hover { background: #f7ca00; }
.btn-amazon-orange {
  display: block; width: 100%; padding: 8px 10px;
  background: #ffa41c; border: 1px solid #ff8f00;
  border-radius: 20px; font-size: 13px; text-align: center;
  color: #0f1111; cursor: pointer; transition: background 0.15s;
}
.btn-amazon-orange:hover { background: #fa8900; }
.product-actions { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.affiliate-tag { font-size: 11px; color: #565959; margin-top: 6px; }

/* No Results */
.no-results {
  text-align: center; padding: 60px 20px; background: #fff;
  border-radius: 0 0 8px 8px; color: #565959;
}
.no-results p { font-size: 18px; font-weight: 600; color: #0f1111; margin: 12px 0 4px; }
.no-results span { font-size: 13px; }

/* ===== CART SIDEBAR ===== */
.cart-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 200; display: none; }
.cart-overlay.open { display: block; }
.cart-sidebar {
  position: fixed; top: 0; right: -400px; width: 380px; max-width: 92vw;
  height: 100vh; background: #fff; z-index: 201;
  display: flex; flex-direction: column;
  box-shadow: -4px 0 16px rgba(0,0,0,0.15);
  transition: right 0.3s ease;
}
.cart-sidebar.open { right: 0; }
.cart-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 20px; border-bottom: 1px solid #ddd;
}
.cart-header h2 { font-size: 18px; font-weight: 700; }
.cart-header button { font-size: 28px; color: #555; line-height: 1; transition: color 0.15s; }
.cart-header button:hover { color: #0f1111; }
.cart-items { flex: 1; overflow-y: auto; padding: 0 20px; }
.cart-item { display: flex; gap: 14px; padding: 16px 0; border-bottom: 1px solid #eee; }
.cart-item img { width: 80px; height: 80px; object-fit: contain; border-radius: 4px; }
.cart-item-info { flex: 1; }
.cart-item-name { font-size: 14px; color: #007185; margin-bottom: 4px; line-height: 1.3; }
.cart-item-stock { font-size: 12px; color: #007600; margin-bottom: 4px; }
.cart-item-price { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.cart-item-qty {
  display: inline-flex; align-items: center; border: 1px solid #ddd;
  border-radius: 8px; overflow: hidden;
}
.cart-item-qty button {
  width: 34px; height: 32px; font-size: 16px;
  display: flex; align-items: center; justify-content: center;
  background: #f0f2f2; border: none; transition: background 0.15s;
}
.cart-item-qty button:hover { background: #e3e6e6; }
.cart-item-qty span {
  width: 40px; text-align: center; font-size: 14px;
  border-left: 1px solid #ddd; border-right: 1px solid #ddd;
  line-height: 32px; background: #fff;
}
.cart-item-actions { margin-top: 8px; display: flex; gap: 8px; font-size: 12px; }
.cart-item-actions button { color: #007185; cursor: pointer; background: none; border: none; transition: color 0.15s; }
.cart-item-actions button:hover { text-decoration: underline; color: #c7511f; }
.cart-item-actions span { color: #ddd; }
.cart-empty { text-align: center; padding: 48px 0; color: #565959; }
.cart-footer { padding: 16px 20px; border-top: 1px solid #ddd; background: #fafafa; }
.cart-subtotal { font-size: 16px; margin-bottom: 12px; }
.cart-checkout { font-size: 14px; padding: 10px; }

/* ===== FOOTER ===== */
.back-to-top {
  display: block; text-align: center; padding: 14px;
  background: #37475a; color: #fff; font-size: 13px;
  transition: background 0.15s;
}
.back-to-top:hover { background: #485769; }
.footer-mid { background: #232f3e; padding: 40px 0; }
.footer-cols {
  max-width: 800px; margin: 0 auto; padding: 0 16px;
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px;
  text-align: center;
}
.footer-col h3 { font-size: 15px; font-weight: 700; color: #fff; margin-bottom: 12px; }
.footer-col a { display: block; font-size: 13px; color: #ddd; line-height: 2.2; transition: color 0.15s; }
.footer-col a:hover { text-decoration: underline; color: #fff; }
.footer-bottom { background: #131921; padding: 24px; text-align: center; border-top: 1px solid #3a4553; }
.footer-bottom-inner { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.footer-logo { font-size: 20px; font-weight: 700; color: #fff; }
.footer-logo span { color: #ff9900; }
.footer-bottom p { font-size: 12px; color: #999; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1000px) {
  .deliver-to { display: none; }
}
@media (max-width: 768px) {
  .header-inner { flex-wrap: wrap; height: auto; padding: 8px 10px; gap: 6px; }
  .search-bar { order: 10; flex-basis: 100%; margin: 6px 0 0; }
  .nav-link { display: none; }
  .hero-bg { height: 260px; }
  .hero-card-main { padding: 24px 20px; }
  .hero-card-main h1 { font-size: 20px; }
  .hero-card-main p { font-size: 13px; }
  .products-section { padding: 0 10px 20px; margin-top: 14px; }
  .products-grid { grid-template-columns: repeat(2, 1fr); padding: 4px; }
  .product-card { padding: 10px; }
  .product-img { width: 120px; height: 120px; }
  .product-name { font-size: 13px; }
  .price-whole { font-size: 20px; }
  .footer-cols { grid-template-columns: 1fr; gap: 24px; }
}

/* ===== LOGIN MODAL ===== */
.login-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.6);
  z-index: 300; display: none; align-items: center; justify-content: center;
}
.login-overlay.open { display: flex; }
.login-modal {
  background: #fff; width: 380px; max-width: 90vw; border-radius: 8px;
  padding: 28px 32px; box-shadow: 0 8px 32px rgba(0,0,0,0.25);
  color: #0f1111; position: relative;
}
.login-close {
  position: absolute; top: 12px; right: 16px; font-size: 24px;
  color: #555; background: none; border: none; cursor: pointer;
}
.login-close:hover { color: #000; }
.login-logo {
  font-size: 22px; font-weight: 700; text-align: center; margin-bottom: 20px;
}
.login-logo span { color: #ff9900; }
.login-modal h3 { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.login-desc { font-size: 13px; color: #565959; margin-bottom: 18px; }
.login-field { margin-bottom: 16px; }
.login-field label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.login-phone-row {
  display: flex; align-items: stretch; border: 1px solid #888; border-radius: 4px; overflow: hidden;
}
.login-phone-row:focus-within { border-color: #e77600; box-shadow: 0 0 0 3px rgba(228,121,17,0.2); }
.login-prefix {
  padding: 9px 12px; background: #f5f5f5; font-size: 14px; font-weight: 600;
  color: #565959; border-right: 1px solid #ddd; display: flex; align-items: center;
}
.login-phone-row input {
  flex: 1; padding: 9px 12px; border: none; font-size: 15px; outline: none;
}
.login-submit { margin-top: 4px; font-size: 14px; font-weight: 600; padding: 10px; border-radius: 8px; }
.login-error { font-size: 12px; color: #cc0c39; margin-top: 8px; text-align: center; }
.login-terms { font-size: 11px; color: #565959; margin-top: 14px; text-align: center; line-height: 1.5; }
.login-terms a { color: #007185; }
.login-terms a:hover { text-decoration: underline; color: #c7511f; }

/* Account Dropdown */
.nav-link { position: relative; }
.account-dropdown {
  position: absolute; top: 100%; right: 0; width: 260px;
  background: #fff; border-radius: 4px; box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  z-index: 150; display: none; color: #0f1111; padding: 12px 0;
  border: 1px solid #d5d9d9;
}
.account-dropdown.open { display: block; }
.account-dd-header {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 18px 12px;
}
.account-dd-photo { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.account-dd-name { font-size: 14px; font-weight: 700; }
.account-dd-email { font-size: 12px; color: #565959; }
.account-dd-divider { height: 1px; background: #e7e7e7; margin: 4px 0; }
.account-dd-item {
  display: block; width: 100%; padding: 9px 18px; font-size: 13px;
  color: #0f1111; text-align: left; background: none; border: none;
  cursor: pointer; transition: background 0.12s;
}
.account-dd-item:hover { background: #f0f0f0; }
.account-dd-signout { color: #cc0c39; font-weight: 600; }
.account-dd-signout:hover { background: #fff5f5; }

/* Google Sign-In Button */
.btn-google-signin {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 11px 16px; background: #fff; border: 1px solid #dadce0;
  border-radius: 8px; font-size: 15px; font-weight: 500; color: #3c4043;
  cursor: pointer; transition: background 0.15s, box-shadow 0.15s;
}
.btn-google-signin:hover { background: #f7f8f8; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.btn-google-signin svg { flex-shrink: 0; }

/* Welcome line after Google sign-in */
.login-welcome {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; background: #f0f8ff; border-radius: 6px;
  margin-bottom: 16px; font-size: 13px; color: #0f1111;
}
.login-welcome img {
  width: 32px; height: 32px; border-radius: 50%; object-fit: cover;
}
