/* ============================================
   CEDAR & STITCH — Luxury E-Commerce
   LV-Inspired Minimal Design System
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&display=swap');

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 300;
  color: #1A1A1A;
  background: #FFFFFF;
  line-height: 1.7;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}

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

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

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 400;
  letter-spacing: 0.02em;
}

h1 { font-size: 3rem; line-height: 1.2; }
h2 { font-size: 2rem; line-height: 1.3; }
h3 { font-size: 1.4rem; line-height: 1.4; }
h4 { font-size: 1.1rem; }

/* --- Layout --- */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

/* ============================================
   HEADER / NAVIGATION
   ============================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: #FFFFFF;
  border-bottom: 1px solid #E8E8E8;
  transition: box-shadow 0.3s ease;
}

.header.scrolled {
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}

.logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #1A1A1A;
}

.logo span {
  color: #B8860B;
}

.nav {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav a {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #555;
  transition: color 0.3s ease;
  position: relative;
}

.nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: #B8860B;
  transition: width 0.3s ease;
}

.nav a:hover,
.nav a.active {
  color: #1A1A1A;
}

.nav a:hover::after,
.nav a.active::after {
  width: 100%;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.bag-icon {
  color: #555;
  transition: color 0.3s ease;
  display: flex;
  align-items: center;
}

.bag-icon:hover {
  color: #B8860B;
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
}

.menu-toggle span {
  width: 24px;
  height: 1.5px;
  background: #1A1A1A;
  transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  margin-top: 80px;
  padding: 50px 0;
  text-align: center;
  background: linear-gradient(180deg, #FAFAFA 0%, #FFFFFF 100%);
  border-bottom: 1px solid #F0F0F0;
}

.hero h1 {
  font-size: 2.4rem;
  margin-bottom: 14px;
  letter-spacing: 0.04em;
}

.hero p {
  font-size: 0.95rem;
  color: #777;
  max-width: 550px;
  margin: 0 auto 25px;
  font-weight: 300;
}

.btn {
  display: inline-block;
  padding: 12px 35px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: 1.5px solid #1A1A1A;
  color: #1A1A1A;
  background: transparent;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn:hover {
  background: #1A1A1A;
  color: #FFFFFF;
}

.btn-gold {
  border-color: #B8860B;
  color: #B8860B;
}

.btn-gold:hover {
  background: #B8860B;
  color: #FFFFFF;
}

.btn-filled {
  background: #1A1A1A;
  color: #FFFFFF;
  border-color: #1A1A1A;
}

.btn-filled:hover {
  background: #333;
  border-color: #333;
}

/* ============================================
   CATEGORY FILTERS
   ============================================ */
.filters {
  padding: 30px 0 20px;
  text-align: center;
}

.filters h2 {
  margin-bottom: 18px;
  font-size: 1.4rem;
}

.filter-bar {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 10px 28px;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border: 1px solid #DDD;
  background: transparent;
  color: #777;
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-btn:hover,
.filter-btn.active {
  border-color: #1A1A1A;
  color: #1A1A1A;
}

/* ============================================
   PRODUCT GRID
   ============================================ */
.products {
  padding: 30px 0 80px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px 30px;
}

.product-card {
  cursor: pointer;
  transition: opacity 0.4s ease;
}

.product-card.hidden {
  display: none;
}

.product-image {
  position: relative;
  overflow: hidden;
  background: #F7F7F7;
  aspect-ratio: 1;
  margin-bottom: 18px;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.05);
}

.product-image .quick-view {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 14px;
  background: rgba(255,255,255,0.95);
  text-align: center;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #1A1A1A;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.product-card:hover .quick-view {
  transform: translateY(0);
}

.product-info {
  text-align: center;
}

.product-name {
  font-family: 'Playfair Display', serif;
  font-size: 0.95rem;
  font-weight: 400;
  margin-bottom: 6px;
  letter-spacing: 0.02em;
}

.product-category-label {
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #B8860B;
  margin-bottom: 6px;
}

.product-price {
  font-size: 0.85rem;
  color: #555;
  font-weight: 400;
}

/* ============================================
   SERVICES PAGE
   ============================================ */
.page-header {
  margin-top: 80px;
  padding: 80px 0 60px;
  text-align: center;
  background: #FAFAFA;
  border-bottom: 1px solid #F0F0F0;
}

.page-header h1 {
  margin-bottom: 15px;
}

.page-header p {
  color: #777;
  max-width: 600px;
  margin: 0 auto;
  font-weight: 300;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  padding: 80px 0;
}

.service-card {
  text-align: center;
  padding: 50px 30px;
  border: 1px solid #EDEDED;
  transition: border-color 0.3s ease;
}

.service-card:hover {
  border-color: #B8860B;
}

.service-icon {
  font-size: 2.5rem;
  margin-bottom: 25px;
  color: #B8860B;
}

.service-card h3 {
  margin-bottom: 15px;
}

.service-card p {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 25px;
}

/* Process steps */
.process {
  padding: 80px 0;
  background: #FAFAFA;
}

.process h2 {
  text-align: center;
  margin-bottom: 60px;
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  max-width: 1000px;
  margin: 0 auto;
}

.step {
  text-align: center;
  position: relative;
}

.step-number {
  font-family: 'Playfair Display', serif;
  font-size: 2.5rem;
  color: #B8860B;
  margin-bottom: 15px;
}

.step h4 {
  margin-bottom: 10px;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.step p {
  font-size: 0.85rem;
  color: #777;
}

/* ============================================
   ABOUT PAGE
   ============================================ */
.about-content {
  padding: 80px 0;
  max-width: 800px;
  margin: 0 auto;
}

.about-content p {
  margin-bottom: 25px;
  color: #555;
  font-size: 1.05rem;
  line-height: 1.9;
}

.about-content p:first-of-type::first-letter {
  font-family: 'Playfair Display', serif;
  font-size: 3.5rem;
  float: left;
  margin-right: 10px;
  line-height: 1;
  color: #B8860B;
}

.about-values {
  padding: 80px 0;
  background: #FAFAFA;
}

.about-values h2 {
  text-align: center;
  margin-bottom: 60px;
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  max-width: 1000px;
  margin: 0 auto;
}

.value-item {
  text-align: center;
}

.value-item h3 {
  margin-bottom: 12px;
  font-size: 1.2rem;
}

.value-item p {
  color: #777;
  font-size: 0.9rem;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  padding: 80px 0;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.form-group label {
  display: block;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #999;
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 0;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 300;
  border: none;
  border-bottom: 1px solid #DDD;
  background: transparent;
  color: #1A1A1A;
  outline: none;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: #B8860B;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.contact-info {
  padding-top: 20px;
}

.contact-info h3 {
  margin-bottom: 30px;
}

.contact-detail {
  margin-bottom: 30px;
}

.contact-detail h4 {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #999;
  margin-bottom: 8px;
}

.contact-detail p,
.contact-detail a {
  font-size: 1rem;
  color: #555;
}

.contact-detail a:hover {
  color: #B8860B;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: #1A1A1A;
  color: #999;
  padding: 60px 0 40px;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 50px;
}

.footer-brand .logo {
  color: #FFFFFF;
  margin-bottom: 15px;
}

.footer-brand p {
  font-size: 0.85rem;
  max-width: 300px;
  line-height: 1.7;
}

.footer-links h4 {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #FFFFFF;
  margin-bottom: 20px;
}

.footer-links a {
  display: block;
  font-size: 0.85rem;
  color: #999;
  margin-bottom: 10px;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: #B8860B;
}

.footer-bottom {
  border-top: 1px solid #333;
  padding-top: 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
}

.social-links {
  display: flex;
  gap: 20px;
}

.social-links a {
  color: #999;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: #B8860B;
}

/* ============================================
   CTA BANNER
   ============================================ */
.cta-banner {
  padding: 100px 0;
  text-align: center;
  background: #FAFAFA;
  border-top: 1px solid #F0F0F0;
}

.cta-banner h2 {
  margin-bottom: 15px;
  font-size: 2.2rem;
}

.cta-banner p {
  color: #777;
  max-width: 500px;
  margin: 0 auto 35px;
}

/* ============================================
   CART BADGE
   ============================================ */
.bag-icon {
  position: relative;
}

.cart-count {
  position: absolute;
  top: -6px;
  right: -8px;
  background: #B8860B;
  color: #FFF;
  font-size: 0.6rem;
  font-weight: 600;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.cart-count.hidden {
  display: none;
}

/* ============================================
   PRODUCT MODAL
   ============================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: #FFF;
  max-width: 900px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.modal-overlay.active .modal {
  transform: scale(1);
}

.modal-image {
  background: #F7F7F7;
  aspect-ratio: 1;
}

.modal-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-details {
  padding: 50px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #999;
  transition: color 0.3s ease;
  z-index: 2001;
}

.modal-close:hover {
  color: #1A1A1A;
}

.modal-category {
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #B8860B;
  margin-bottom: 10px;
}

.modal-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 400;
  margin-bottom: 15px;
}

.modal-price {
  font-size: 1.3rem;
  color: #1A1A1A;
  font-weight: 400;
  margin-bottom: 25px;
}

.modal-description {
  font-size: 0.9rem;
  color: #777;
  line-height: 1.8;
  margin-bottom: 30px;
}

.modal-qty {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 25px;
}

.modal-qty label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #999;
}

.qty-controls {
  display: flex;
  align-items: center;
  border: 1px solid #DDD;
}

.qty-btn {
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  font-size: 1.1rem;
  cursor: pointer;
  color: #555;
  transition: background 0.2s ease;
}

.qty-btn:hover {
  background: #F5F5F5;
}

.qty-value {
  width: 40px;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 500;
  border-left: 1px solid #DDD;
  border-right: 1px solid #DDD;
  line-height: 36px;
}

.btn-add-cart {
  width: 100%;
  padding: 16px;
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  background: #1A1A1A;
  color: #FFF;
  border: 1.5px solid #1A1A1A;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-add-cart:hover {
  background: #B8860B;
  border-color: #B8860B;
}

.added-msg {
  text-align: center;
  margin-top: 12px;
  font-size: 0.75rem;
  color: #B8860B;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.added-msg.show {
  opacity: 1;
}

/* ============================================
   CART PAGE
   ============================================ */
.cart-page {
  margin-top: 80px;
  padding: 60px 0 80px;
  min-height: 60vh;
}

.cart-empty {
  text-align: center;
  padding: 80px 0;
}

.cart-empty h2 {
  margin-bottom: 15px;
}

.cart-empty p {
  color: #777;
  margin-bottom: 30px;
}

.cart-table {
  width: 100%;
  border-collapse: collapse;
}

.cart-table th {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #999;
  text-align: left;
  padding: 15px 0;
  border-bottom: 1px solid #E8E8E8;
}

.cart-table th:last-child {
  text-align: right;
}

.cart-table td {
  padding: 25px 0;
  border-bottom: 1px solid #F0F0F0;
  vertical-align: middle;
}

.cart-item-info {
  display: flex;
  align-items: center;
  gap: 20px;
}

.cart-item-img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  background: #F7F7F7;
}

.cart-item-name {
  font-family: 'Playfair Display', serif;
  font-size: 0.95rem;
}

.cart-item-cat {
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #B8860B;
  margin-top: 4px;
}

.cart-item-price {
  font-size: 0.95rem;
}

.cart-item-remove {
  background: none;
  border: none;
  color: #CCC;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.3s ease;
}

.cart-item-remove:hover {
  color: #c0392b;
}

.cart-summary {
  display: flex;
  justify-content: flex-end;
  padding-top: 40px;
}

.cart-summary-box {
  width: 350px;
}

.cart-subtotal {
  display: flex;
  justify-content: space-between;
  padding: 15px 0;
  border-bottom: 1px solid #E8E8E8;
  font-size: 0.95rem;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  padding: 20px 0;
  font-size: 1.2rem;
  font-weight: 500;
}

.btn-checkout {
  width: 100%;
  margin-top: 20px;
  padding: 16px;
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  background: #B8860B;
  color: #FFF;
  border: none;
  cursor: pointer;
  transition: background 0.3s ease;
}

.btn-checkout:hover {
  background: #9a7209;
}

.cart-continue {
  display: block;
  text-align: center;
  margin-top: 15px;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #999;
}

.cart-continue:hover {
  color: #B8860B;
}

/* ============================================
   RESPONSIVE (consolidated)
   ============================================ */

@media (max-width: 1200px) {
  .container { padding: 0 30px; }
  .product-grid { gap: 35px 25px; }
}

@media (max-width: 1024px) {
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px 20px;
  }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .process-steps { grid-template-columns: repeat(2, 1fr); gap: 40px; }
  .hero h1 { font-size: 2.5rem; }
}

@media (max-width: 768px) {
  .container { padding: 0 24px; }
  .header .container { height: 65px; }
  .logo { font-size: 1.2rem; }

  .nav {
    position: fixed;
    top: 65px;
    left: 0;
    right: 0;
    background: #FFFFFF;
    flex-direction: column;
    padding: 40px 24px;
    gap: 25px;
    border-bottom: 1px solid #E8E8E8;
    transform: translateY(-120%);
    transition: transform 0.3s ease;
    z-index: 999;
  }
  .nav.open { transform: translateY(0); }
  .menu-toggle { display: flex; }

  .hero { margin-top: 65px; padding: 60px 0; }
  .hero h1 { font-size: 2rem; }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 25px 15px;
  }

  .modal { grid-template-columns: 1fr; max-height: 95vh; }
  .modal-image { max-height: 300px; }
  .modal-details { padding: 30px 24px; }
  .modal-name { font-size: 1.4rem; }

  .services-grid { grid-template-columns: 1fr; }
  .process-steps { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; gap: 50px; }

  .cart-table th:nth-child(2),
  .cart-table td:nth-child(2) { display: none; }
  .cart-summary { justify-content: stretch; }
  .cart-summary-box { width: 100%; }

  .footer-content { flex-direction: column; gap: 40px; }
  .footer-bottom { flex-direction: column; gap: 15px; text-align: center; }
  .values-grid { grid-template-columns: 1fr; gap: 30px; }

  .page-header { margin-top: 65px; }
  .cart-page { margin-top: 65px; }
}

@media (max-width: 480px) {
  .product-grid {
    grid-template-columns: 1fr;
    gap: 35px;
    max-width: 400px;
    margin: 0 auto;
  }
  .filter-bar { gap: 6px; }
  .filter-btn { padding: 8px 16px; font-size: 0.65rem; }
  .process-steps { grid-template-columns: 1fr; }
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.5rem; }
}

/* --- CLEAR CART --- */
.cart-actions {
  display: flex;
  justify-content: flex-end;
  margin: 15px 0;
}

.btn-clear-cart {
  padding: 10px 22px;
  font-family: 'Inter', -apple-system, sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: #FFF;
  color: #555;
  border: 1.5px solid #CCC;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-clear-cart:hover {
  color: #ef4444;
  border-color: #ef4444;
}
