/*
Theme Name: CornerTCG
Theme URI: https://example.com
Author: Local Store
Description: WooCommerce theme styled to match cornertcg.myshopify.com (CoreTCG)
Version: 2.0
Text Domain: cornertcg
*/

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

/* ==========================================================================
   Variables & Reset
   ========================================================================== */
:root {
  --color-bg: #ffffff;
  --color-text: rgba(18, 18, 18, 0.9);
  --color-muted: #6b6b6b;
  --color-border: #e5e5e5;
  --color-surface: #f7f7f5;
  --color-accent: #00ac67;
  --color-accent-dark: #00944f;
  --max-width: 1200px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.5;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }

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

/* ==========================================================================
   Announcement bar
   ========================================================================== */
.announcement-bar {
  background: var(--color-accent);
  color: #fff;
  text-align: center;
  font-size: 13px;
  letter-spacing: 0.03em;
  padding: 10px 12px;
  font-weight: 600;
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  border-bottom: 1px solid var(--color-border);
  padding: 18px 0;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.site-logo {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--color-text);
}

.site-logo img { max-height: 42px; }

.main-nav ul { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  display: inline-block;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: 4px;
}
.main-nav a:hover { color: var(--color-accent); }
.main-nav .current-menu-item > a,
.main-nav .current_page_item > a,
.main-nav a.is-active {
  background: var(--color-accent);
  color: #fff;
  font-weight: 700;
}

/* Burger menu (mobile) — hidden on desktop */
.nav-toggle { display: none; cursor: pointer; color: var(--color-text); }
.nav-toggle svg { width: 26px; height: 24px; display: block; }
.nav-toggle-cb { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

@media (max-width: 768px) {
  .site-header .container { flex-wrap: wrap; gap: 14px; }
  .nav-toggle { display: inline-flex; align-items: center; order: 1; }
  .site-logo { order: 2; font-size: 22px; }
  .header-icons { order: 3; margin-left: auto; }
  .main-nav { order: 4; flex-basis: 100%; display: none; }
  .nav-toggle-cb:checked ~ .main-nav { display: block; }
  .main-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
  .main-nav a {
    display: block;
    padding: 14px 6px;
    border-bottom: 1px solid var(--color-border);
    border-radius: 0;
    font-size: 16px;
  }
  .main-nav .current-menu-item > a,
  .main-nav .current_page_item > a,
  .main-nav a.is-active { border-radius: 4px; }
}

.header-icons { display: flex; align-items: center; gap: 20px; }
.header-icons a { position: relative; display: inline-flex; align-items: center; color: var(--color-text); }
.header-icons a:hover { color: var(--color-accent); }
.header-icons .icon-account { width: 21px; height: 22px; }
.header-icons .icon-cart { width: 20px; height: 25px; }
.header-icons .cart-count {
  position: absolute;
  top: -8px;
  right: -10px;
  background: var(--color-accent);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-nav-toggle { display: none; background: none; border: none; font-size: 22px; cursor: pointer; }

@media (max-width: 780px) {
  .main-nav { display: none; }
  .mobile-nav-toggle { display: block; }
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  background: var(--color-surface);
  text-align: center;
  padding: 0;
  overflow: hidden;
}

.hero-link { display: block; }
.hero img.hero-bg {
  width: 100%;
  height: auto;
  display: block;
}

.hero-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.hero h1 {
  font-size: 42px;
  font-weight: 800;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.5);
}

.hero p {
  color: #fff;
  text-shadow: 0 1px 8px rgba(0,0,0,0.5);
  font-size: 17px;
  margin-bottom: 28px;
}

.btn {
  display: inline-block;
  background: var(--color-accent);
  color: #fff;
  padding: 14px 30px;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.03em;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn:hover { background: var(--color-accent-dark); color: #fff; }

/* ==========================================================================
   Sections
   ========================================================================== */
.section { padding: 64px 0; }
.section-title {
  text-align: center;
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 32px;
  letter-spacing: -0.01em;
}
.section-subtitle {
  text-align: center;
  color: var(--color-muted);
  margin-bottom: 40px;
}

/* Product grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

@media (max-width: 980px) { .product-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .product-grid { grid-template-columns: 1fr; } }

.product-card {
  border: 1px solid var(--color-border);
  border-radius: 8px;
  overflow: hidden;
  text-align: center;
  transition: box-shadow 0.15s ease;
  position: relative;
  background: #fff;
  display: flex;
  flex-direction: column;
}
.product-card:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.08); }

.product-card .product-thumb {
  aspect-ratio: 3 / 4;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.product-card .product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.45s ease;
}
.product-card:hover .product-thumb img { transform: scale(1.08); }

.badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--color-text);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 4px;
  z-index: 2;
}
.badge.soldout { background: #444; }
.badge.sale { background: var(--color-accent); }

.product-card .product-info { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.product-card .product-title {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 8px;
  min-height: 2.6em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-card .price-label { font-size: 11px; color: var(--color-muted); margin-bottom: 2px; }
.product-card .price { font-weight: 700; color: var(--color-text); margin-bottom: 14px; }
.product-card .price del { color: var(--color-muted); font-weight: 400; margin-right: 6px; }
.product-card .btn { margin-top: auto; width: 100%; padding: 12px 20px; font-size: 14px; }
.product-card .btn.disabled { background: #ccc; cursor: not-allowed; pointer-events: none; }

/* Reviews (Trustpilot-style individual cards) */
.review-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 780px) { .review-grid { grid-template-columns: 1fr; } }

.review-card {
  background: var(--color-surface);
  border-radius: 8px;
  padding: 24px;
}
.review-card .tp-badge {
  display: inline-flex;
  background: var(--color-accent);
  color: #fff;
  padding: 4px 8px;
  border-radius: 3px;
  font-size: 14px;
  letter-spacing: 3px;
  margin-bottom: 14px;
}
.review-card .stars-label { font-weight: 700; margin-bottom: 12px; }
.review-card p { font-size: 14px; color: var(--color-text); margin: 0 0 14px; }
.review-card .reviewer {
  font-size: 14px;
  font-weight: 700;
  font-style: italic;
  border-top: 1px solid var(--color-border);
  padding-top: 12px;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--color-accent);
  color: rgba(255,255,255,0.9);
  padding: 32px 0;
  margin-top: 40px;
}

.footer-bottom {
  text-align: center;
  font-size: 13px;
}

.footer-payment { margin-bottom: 14px; display: flex; justify-content: center; }
.footer-payment .paypal-icon {
  background: #fff;
  border-radius: 4px;
  padding: 4px 10px;
  display: inline-block;
}

.footer-links a { opacity: 0.9; }
.footer-links a:hover { opacity: 1; text-decoration: underline; }
.footer-links .sep { margin: 0 6px; opacity: 0.6; }

/* ==========================================================================
   WooCommerce overrides
   ========================================================================== */
.woocommerce ul.products { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; list-style: none; margin: 0; padding: 0; }
/* WooCommerce adds clearfix ::before/::after which become phantom grid cells
   (they were pushing the first product into column 2). Remove them. */
.woocommerce ul.products::before, .woocommerce ul.products::after { content: none !important; display: none !important; }
@media (max-width: 980px) { .woocommerce ul.products { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .woocommerce ul.products { grid-template-columns: 1fr; } }
.woocommerce ul.products li.product {
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 0;
  overflow: hidden;
  text-align: center;
  width: auto !important;
  float: none !important;
  margin: 0 !important;
  position: relative;
  background: #fff;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.woocommerce ul.products li.product:hover {
  box-shadow: 0 10px 28px rgba(0,0,0,0.12);
  transform: translateY(-3px);
}
.woocommerce ul.products li.product > a.woocommerce-LoopProduct-link {
  display: flex;
  flex-direction: column;
}
/* Media box: show the full portrait card (uncropped, like Shopify) and zoom on hover. */
.woocommerce ul.products li.product .loop-thumb {
  aspect-ratio: 3 / 4;
  background: #fff;
  overflow: hidden;
  display: block;
}
.woocommerce ul.products li.product .loop-thumb img {
  width: 100% !important;
  height: 100% !important;
  aspect-ratio: auto !important;
  object-fit: contain !important;
  border-radius: 0 !important;
  margin: 0 !important;
  display: block;
  transition: transform 0.45s ease;
}
.woocommerce ul.products li.product:hover .loop-thumb img { transform: scale(1.08); }
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-size: 14px;
  font-weight: 600;
  padding: 14px 14px 4px;
}
.woocommerce ul.products li.product .price { font-weight: 700; display: block; padding: 0 14px 4px; }
.woocommerce ul.products li.product .button,
.woocommerce ul.products li.product .added_to_cart { margin: 10px 14px 16px; }
.woocommerce a.button, .woocommerce button.button, .woocommerce #respond input#submit, .woocommerce input.button {
  background: var(--color-accent) !important;
  color: #fff !important;
  border-radius: 8px !important;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 0.7em 1.5em !important;
}
.woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce input.button:hover {
  background: var(--color-accent-dark) !important;
}
.woocommerce span.onsale {
  background: var(--color-accent);
  border-radius: 4px;
  font-size: 11px;
  text-transform: uppercase;
  min-height: auto;
  min-width: auto;
  line-height: 1;
  padding: 6px 8px;
}
.woocommerce div.product p.price, .woocommerce div.product span.price {
  color: var(--color-text);
  font-size: 32px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 22px;
}
.woocommerce div.product p.price ins, .woocommerce div.product span.price ins { color: var(--color-accent); text-decoration: none; }

/* Hide the "Category:" line from the product page (UI only — category still set in the DB). */
.woocommerce div.product .product_meta .posted_in { display: none; }

.page-content, .entry-content { max-width: 780px; margin: 0 auto; padding: 60px 20px; }
.page-content h1, .entry-content h1 { font-size: 32px; margin-bottom: 24px; font-weight: 700; }

.wrap-simple { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

/* ==========================================================================
   Pagination — minimal, matching the Shopify store (plain numbers, active
   underlined, chevron for next; no boxes/borders)
   ========================================================================== */
.woocommerce nav.woocommerce-pagination { margin: 44px 0 8px; text-align: center; }
.woocommerce nav.woocommerce-pagination ul,
.woocommerce nav.woocommerce-pagination ul li {
  border: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  display: inline-block;
}
.woocommerce nav.woocommerce-pagination ul { display: inline-flex; align-items: center; gap: 26px; }
.woocommerce nav.woocommerce-pagination ul li a.page-numbers,
.woocommerce nav.woocommerce-pagination ul li span.page-numbers {
  background: none !important;
  border: 0 !important;
  padding: 2px 0 !important;
  min-width: 0 !important;
  line-height: 1.4;
  font-size: 15px;
  font-weight: 400;
  color: var(--color-text);
}
.woocommerce nav.woocommerce-pagination ul li span.current {
  font-weight: 500;
  border-bottom: 1.5px solid var(--color-text) !important;
  padding-bottom: 3px !important;
}
.woocommerce nav.woocommerce-pagination ul li a.page-numbers:hover { color: var(--color-accent); }
.woocommerce nav.woocommerce-pagination ul li a.next,
.woocommerce nav.woocommerce-pagination ul li a.prev { font-size: 18px; }

/* ==========================================================================
   Newsletter — "Subscribe to our emails" (Shopify Dawn style)
   ========================================================================== */
.newsletter {
  background: #fff;
  border-top: 1px solid var(--color-border);
  padding: 60px 20px;
  text-align: center;
}
.newsletter__inner { max-width: 520px; margin: 0 auto; padding: 0; }
.newsletter__title { font-size: 28px; font-weight: 700; margin: 0 0 10px; }
.newsletter__subtitle { color: var(--color-muted); font-size: 15px; margin: 0 0 26px; }
.newsletter__field {
  display: flex;
  align-items: stretch;
  max-width: 400px;
  margin: 0 auto;
  border: 1px solid #121212;
  border-radius: 6px;
  overflow: hidden;
}
.newsletter__field input[type="email"] {
  flex: 1;
  border: 0;
  background: transparent;
  padding: 14px 16px;
  font-size: 15px;
  font-family: inherit;
  color: var(--color-text);
  outline: none;
}
.newsletter__field button {
  border: 0;
  background: none;
  padding: 0 18px;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  color: #121212;
}
.newsletter__field button:hover { color: var(--color-accent); }
.newsletter__hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.newsletter__success { color: var(--color-accent); font-weight: 600; font-size: 16px; margin: 0; }

/* ==========================================================================
   Contact form
   ========================================================================== */
.contact-form { max-width: 640px; margin: 24px 0 0; }
.contact-form__row { display: flex; gap: 16px; }
.contact-form__row > input { flex: 1; }
.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--color-border);
  border-radius: 6px;
  padding: 13px 15px;
  font-size: 15px;
  font-family: inherit;
  color: var(--color-text);
  background: #fff;
  margin-bottom: 16px;
  outline: none;
}
.contact-form input:focus,
.contact-form textarea:focus { border-color: var(--color-accent); }
.contact-form textarea { resize: vertical; }
.contact-form .btn { border: 0; cursor: pointer; }
.contact-success {
  background: rgba(0,172,103,0.1);
  border: 1px solid var(--color-accent);
  color: var(--color-accent-dark);
  padding: 14px 18px;
  border-radius: 6px;
  font-weight: 600;
  margin-bottom: 20px;
}
