* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #482922;
}

.container {
    min-height: 100vh;
    background: linear-gradient(135deg, #fff 0%, #fff 100%);
}

/* Navigation */
.navbar {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
     z-index: 999;
  transition: top 0.3s;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.nav-content {
    margin-right: -21rem !important;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 4rem;
}

.logo {
    margin-left: -18rem !important;
    font-weight: bold;
    font-size: 1.25rem;
    color: #482922;
}

.nav-links {
    display: none;
    gap: 1.8rem;
}

.nav-links a {
    color: #482922;
    text-decoration: none;
    font-weight: normal;
     text-decoration: none;
  transition: text-decoration 0.2s ease;
}

.nav-links a:hover {
  text-decoration: underline;
}

.nav-icon-button{
    margin-right: -1rem !important;
    }

@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }
    
    .nav-container {
        padding: 0 1.5rem;
    }
}

@media (min-width: 1024px) {
    .nav-container {
        padding: 0 2rem;
    }
}

.amazon-searchbar {
  margin-right: -8rem !important;
    display: flex;
  align-items: center;
  margin: 0 1rem;
  flex: 1;
  max-width: 1000px;
}

.amazon-searchbar form {
  display: flex;
  flex: 1;
  background-color: #fff;
  border-radius: 4px;
  border: 1px solid #ccc;
  overflow: hidden;
  width: 100%;
  height: 38px;
}

.amazon-searchbar select {
  background-color: #f3f3f3;
  border: none;
  padding: 0 8px;
  font-size: 14px;
  outline: none;
}

.amazon-searchbar input {
  flex: 1;
  border: none;
  padding: 0 10px;
  font-size: 14px;
  outline: none;
}

.amazon-searchbar button {
  background-color: #febd69;
  border: none;
  padding: 0 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.amazon-searchbar button i {
  width: 16px;
  height: 16px;
}

#searchOverlay {
  position: fixed;
  top: 67px; /* altura exacta del navbar */
  left: 0;
  width: 100%;
  height: calc(100% - 67px);
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 999;
  display: none;
  pointer-events: none;
}



.carousel-section {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 600px;
  background: transparent;
}

.carousel-container {
  width: 100%;
  height: 600px;
  position: relative;
}

.carousel-slides {
  display: flex;
  width: 400%;
  height: 100%;
 animation: slideCarousel 40s infinite; /* más lento */
  transition: transform 1s ease-in-out;   /* suaviza el cambio */
}

.carousel-slide {
  flex: 1 0 100%;
  height: 100%;
  position: relative;
}

.carousel-image {
  width: 25%;
  height: auto;
  object-fit: cover;
  display: block;
}

.carousel-caption {
  position: absolute;
  bottom: 8%;
  left: 5%;
  color: white;
  max-width: 50%;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
}

.carousel-fade-section {
  position: relative;
  width: 100%;
  height: 600px;
  overflow: hidden;
}

.carousel-fade-container {
  position: relative;
  width: 100%;
  height: 100%;
}
.carousel-fade-section {
  position: relative;
  overflow: hidden;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2rem;
  font-weight: 300;
  color: white;
  background-color: transparent;
  padding: 0.5rem 1rem;
  cursor: pointer;
  z-index: 10;
  user-select: none;
  border-radius: 1px;
}

.left-arrow {
  left: 20px;
}

.right-arrow {
  right: 20px;
}

.carousel-fade-slide {
  opacity: 0;
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  transition: opacity 0.5s ease;
  z-index: 0;
}

.carousel-fade-slide.active {
  opacity: 1;
  z-index: 1;
  position: relative;
}

.carousel-fade-slide {
  position: absolute;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
  z-index: 0;
}

.carousel-fade-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-fade-slide.active {
  opacity: 1;
  z-index: 1;
}

.carousel-fade-caption {
  position: absolute;
  bottom: 10%;
  left: 5%;
  color: white;
  max-width: 50%;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
}

.carousel-fade-caption {
  position: absolute;
  bottom: 15%;
  left: 7%;
  color: #ffffff;
  max-width: 40%;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.carousel-fade-caption h2 {
    margin-left: 5rem !important;
  font-size: 4rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  font-family: 'Poppins', sans-serif;
  line-height: 1.2;
}

.carousel-fade-caption h1 {
  font-size: 5rem;
  font-weight: 700;
  margin-top: -20rem;
  margin-left: 10rem !important;
  font-family: 'Poppins', sans-serif;
  line-height: 1.2;
}

.carousel-fade-caption h3 {
  margin-left: 12rem !important;
  font-size: 1rem;
  letter-spacing: 5px;
  white-space: nowrap;
  font-weight: 300;
  line-height: 1.6;
  margin-bottom: 2rem;
  font-family: 'Poppins', sans-serif;
  color: #f0f0f0;
}


.carousel-fade-caption p {
  margin-left: 5rem !important;
  font-size: 1.430rem;
  font-weight: 400;
  line-height: 1.6;
  margin-bottom: 2rem;
  font-family: 'Poppins', sans-serif;
  color: #f0f0f0;
}

/* Ajuste para el botón dentro del carrusel */
.carousel-fade-caption .btn {
  margin-left: 5rem !important;
  font-size: 1rem;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 1px;
}


.btn-more {
  margin-top: 0.5rem !important;
  margin-left: 25rem !important;
  background-color: transparent;
   color: #f8fafc;
    border: 1px solid #d1d5db;
        display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 1px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-more:hover {
    background-color: #f8fafc;
    color: #482922;
}

/* RESPONSIVE: Ajustes en celulares */
@media (max-width: 768px) {
  .carousel-fade-caption {
    bottom: 10%;
    left: 5%;
    max-width: 90%;
  }

  .carousel-fade-caption h2 {
    font-size: 1.75rem;
  }

  .carousel-fade-caption p {
    font-size: 0.95rem;
  }

  .carousel-fade-caption .btn {
    font-size: 0.875rem;
    padding: 0.6rem 1.2rem;
  }
}



.btn-outline {
  background-color: transparent;
  border: 2px solid #482922;
  color: #fff;
  padding: 10px 20px;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s;
}

.btn-outline:hover {
  background-color: #482922;
  color: #fff;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 1px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: transparent;
   color: #f8fafc;
    border: 1px solid #d1d5db;
}

.btn-primary:hover {
    background-color: #f8fafc;
    color: #482922;
}

.btn-send {
    background-color: transparent;
   color: #482922;
    border: 1px solid #482922;
    text-align: center;
    transition: all 0.3s ease;
}

.btn-send:hover {
    background-color: #482922;
    border: none;
    color: #fff;
}


.btn-outline {
    background-color: transparent;
    color: #f8fafc;
    border: 1px solid #d1d5db;
}

.btn-outline:hover {
    background-color: #f8fafc;
    color: #482922;
}

.btn-primero {
    background-color: #482922;
   color: #f8fafc;
}

.btn-primero:hover {
    background-color: transparent;
    color: #482922;
    border: 1px solid #482922;
}

.btn-segundo {
    background-color: transparent;
   color: #482922;
       border: 1px solid #482922;
}

.btn-segundo:hover {
    background-color: #482922;
    color: #f8fafc;
    border: 1px solid #482922;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-full {
    width: 100%;
    justify-content: center;
}

.btn i {
    width: 1rem;
    height: 1rem;
}

/* Sections */
.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 1.875rem;
    font-weight: bold;
    color: #482922;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.125rem;
    color: #482922;
    max-width: 32rem;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .section-container {
        padding: 0 1.5rem;
    }
    
    .section-title {
        font-size: 2.25rem;
    }
}

@media (min-width: 1024px) {
    .section-container {
        padding: 0 2rem;
    }
}

/* Books Section */
.books-section {
    padding: 5rem 0;
    background-color: white;
}

.books-grid {
    display: grid;
    gap: 2rem;
}

.book-card {
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: all 0.3s ease;
}

.book-card:hover {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    transform: translateY(-4px);
}

.book-header {
    padding: 1.5rem 1.5rem 0;
}

.book-cover {
    width: 100%;
    height: 16rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.book-cover i {
    width: 4rem;
    height: 4rem;
    color: white;
}

.book-cover-1 {
    background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%);
}

.book-cover-2 {
    background: linear-gradient(135deg, #3b82f6 0%, #14b8a6 100%);
}

.book-cover-3 {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.book-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.book-description {
    color: #64748b;
    margin-bottom: 1rem;
}

.book-content {
    padding: 0 1.5rem 1.5rem;
}

.book-rating {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.stars {
    display: flex;
    gap: 0.25rem;
}

.star {
    width: 1rem;
    height: 1rem;
    color: #d1d5db;
}

.star.filled {
    color: #fbbf24;
    fill: currentColor;
}

.reviews {
    margin-left: 0.5rem;
    font-size: 0.875rem;
    color: #64748b;
}

.book-excerpt {
    color: #64748b;
    margin-bottom: 1rem;
}

.book-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.book-price {
    font-size: 1.5rem;
    font-weight: bold;
    color: #1e293b;
}

@media (min-width: 768px) {
    .books-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .books-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* About Section */
.about-section {
    padding: 5rem 0;
    background-color: #482922;
}

.about-grid {
    display: grid;
    gap: 3rem;
    align-items: center;
}

.about-paragraph {
    font-size: 1.125rem;
    color: #ffff;
    margin-bottom: 1.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.stat-card {
    background: white;
    border-radius: 0.5rem;
    padding: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.stat-card i {
    width: 2rem;
    height: 2rem;
    color: #1e293b;
    margin: 0 auto 0.5rem;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: bold;
    color: #1e293b;
}

.stat-label {
    font-size: 0.875rem;
    color: #64748b;
}

/* Author Image Section */
.author-image {
    padding-left: 0;
}

.author-photo-container {
    position: relative;
    border-radius: 0.2rem;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    background: white;
}

.author-photo {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
}

.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    padding: 2rem;
}


@media (min-width: 1024px) {
    .author-image {
        padding-left: 3rem;
    }
    
    .author-photo {
        height: 500px;
    }
}

/* Hover effect for the photo */
.author-photo-container:hover .author-photo {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

.author-photo {
    transition: transform 0.3s ease;
}

@media (min-width: 1024px) {
    .about-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .testimonials {
        padding-left: 3rem;
    }
}

/* Add these styles to your existing CSS file */

/* Cart Toggle Button */
.cart-toggle {
    position: relative;
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    border-radius: 0.375rem;
    color: #482922 !important;
}

.cart-count {
    background-color: #482922;
    color: white;
    border-radius: 50%;
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
    position: absolute;
    top: -0.25rem;
    right: -0.25rem;
}

/* Cart Modal */
.cart-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    animation: fadeIn 0.3s ease;
}

.cart-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-modal-content {
    background: white;
    border-radius: 0.5rem;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    animation: slideIn 0.3s ease;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}

.cart-header h2 {
    margin: 0;
    color: #1e293b;
}

.close-cart {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.25rem;
}

.cart-body {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
}

.cart-footer {
    padding: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

/* Cart Items */
.cart-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-image {
    width: 60px;
    height: 80px;
    border-radius: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cart-item-image i {
    width: 1.5rem;
    height: 1.5rem;
    color: white;
}

.cart-item-details {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.cart-item-price {
    color: #64748b;
    font-size: 0.875rem;
}

.cart-item-controls {
  display: flex !important;
  align-items: center;
  justify-content: flex-end;
  margin-left: auto !important;
}

.quantity-selector {
  display: inline-flex;
  align-items: center;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 4px 8px;
}

.quantity-btn {
  background: none;
  border: none;
  font-size: 18px;
  width: 24px;
  height: 24px;
  cursor: pointer;
  color: #333;
}

.quantity-value {
  min-width: 20px;
  text-align: center;
  font-size: 16px;
  margin: 0 8px;
}

.cart-item.loading {
  opacity: 0.5;
  position: relative;
  pointer-events: none;
}

.cart-item .item-spinner {
  position: absolute;
  top: 70px;
  right: 250px;
  width: 25px;
  height: 25px;
  border: 2px solid #ccc;
  border-top: 2px solid #482922;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  z-index: 2;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Cart Total */
.cart-total {
    margin-bottom: 1.5rem;
}

.total-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.total-final {
    font-weight: bold;
    font-size: 1.125rem;
    color: #1e293b;
    border-top: 1px solid #e2e8f0;
    padding-top: 0.5rem;
    margin-top: 0.5rem;
}

.cart-actions {
    display: flex;
    gap: 1rem;
}

.cart-actions .btn {
    flex: 1;
}

/* Empty Cart */
.empty-cart {
    text-align: center;
    padding: 2rem;
    color: #64748b;
}

.empty-cart i {
    width: 3rem;
    height: 3rem;
    margin-bottom: 1rem;
    color: #cbd5e1;
}

/* Cart Page */
.cart-page {
    min-height: 100vh;
    background: #f8fafc;
    padding: 2rem 0;
}

.cart-page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.cart-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.cart-page-content {
    display: grid;
    gap: 2rem;
}

.cart-items-section {
    background: white;
    border-radius: 0.5rem;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.cart-summary-section {
    background: white;
    border-radius: 0.5rem;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    height: fit-content;
}

.cart-summary h3 {
    margin-bottom: 1rem;
    color: #1e293b;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.summary-row.total {
    font-weight: bold;
    font-size: 1.25rem;
    color: #1e293b;
}

.checkout-section {
    margin-top: 1.5rem;
}

.checkout-section .btn {
    margin-bottom: 0.75rem;
}

/* Cart Page Items */
.cart-page-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.cart-page-item:last-child {
    border-bottom: none;
}

.cart-page-item-image {
    width: 80px;
    height: 100px;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.cart-page-item-image i {
    width: 2rem;
    height: 2rem;
    color: white;
}

.cart-page-item-details {
    flex: 1;
}

.cart-page-item-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.cart-page-item-price {
    color: #64748b;
    margin-bottom: 1rem;
}

.cart-page-item-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 1rem;
}

/* Success Modal */
.success-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 3000;
    animation: fadeIn 0.3s ease;
}

.success-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.success-content {
    background: white;
    border-radius: 0.5rem;
    padding: 2rem;
    text-align: center;
    max-width: 400px;
    animation: slideIn 0.3s ease;
}

.success-content i {
    width: 3rem;
    height: 3rem;
    color: #10b981;
    margin-bottom: 1rem;
}

.success-content h3 {
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.success-content p {
    color: #64748b;
    margin-bottom: 1.5rem;
}

.success-actions {
    display: flex;
    gap: 1rem;
}

.success-actions .btn {
    flex: 1;
}

/* Responsive Design */
@media (min-width: 768px) {
    .cart-page-content {
        grid-template-columns: 2fr 1fr;
    }
    
    .cart-actions {
        flex-direction: row;
    }
    
    .nav-links {
        display: flex;
        align-items: center;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translateY(-20px);
    }
    to { 
        opacity: 1;
        transform: translateY(0);
    }
}

/* Book cover color classes for cart items */
.book-cover-1 {
    background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%);
}

.book-cover-2 {
    background: linear-gradient(135deg, #3b82f6 0%, #14b8a6 100%);
}

.book-cover-3 {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

/* Author Image Styles */
.author-image {
    padding-left: 0;
}

.author-photo-container {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    background: white;
}

.author-photo {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.author-photo:hover {
    transform: scale(1.02);
}

.photo-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    padding: 2rem;
}

.photo-caption h3 {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.photo-caption p {
    font-size: 1rem;
    opacity: 0.9;
}

@media (min-width: 1024px) {
    .author-image {
        padding-left: 3rem;
    }
    
    .author-photo {
        height: 500px;
    }
}

/* Contact Section */
.contact-section {
    padding: 5rem 0;
    background-color: white;
}

.contact-container {
    max-width: 64rem;
    margin: 0 auto;
    padding: 0 1rem;
}

.contact-card {
    background: white;
    border-radius: 1px;
    padding: 2rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-row {
    display: grid;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #482922;
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group textarea {
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 1px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #1e293b;
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

@media (min-width: 768px) {
    .form-row {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .contact-container {
        padding: 0 1.5rem;
    }
}

@media (min-width: 1024px) {
    .contact-container {
        padding: 0 2rem;
    }
}

/* Footer */
.footer {
    background-color: #482922;
    color: white;
    padding: 3rem 0;
}

.footers {
    background-color: #482922;
    color: white;
    padding: 3rem 0;
    margin-top: 200px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.footer-content {
    text-align: center;
}

.footer-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.footer-tagline {
    color: #94a3b8;
    margin-bottom: 1.5rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s ease;
}


.footer-copyright {
    color: #94a3b8;
    font-size: 0.875rem;
}

.icon {
  width: 20px;
  height: 20px;
  display: inline-block;
}

.icon-threads {
  margin-right: -0.3rem !important;
  width: 20px;
  height: 20px;
  display: inline-block;
}

@media (min-width: 768px) {
    .footer-container {
        padding: 0 1.5rem;
    }
}

@media (min-width: 1024px) {
    .footer-container {
        padding: 0 2rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading animation for icons */
i[data-lucide] {
    display: inline-block;
}

@media (max-width: 768px) {
  .navbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .product-card {
    width: 100%;
    margin-bottom: 1rem;
  }
}


/* Mostrar/ocultar según tamaño */
  .menu-toggle {
    font-size: 24px;
    background: none;
    border: none;
    color: #482922;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    margin-right: 1rem;
    transition: transform 0.3s ease;
    z-index: 1100;
  }

  /* Toggle Morphing Animation */
.toggle-icon {
  display: inline-block;
  width: 24px;
  height: 18px;
  position: relative;
  transition: transform 0.4s ease;
}

.bar {
  position: absolute;
  height: 3px;
  width: 100%;
  background-color: #482922;
  left: 0;
  transition: all 0.4s ease;
  border-radius: 2px;
}

.bar1 { top: 0; }
.bar2 { top: 7px; }
.bar3 { top: 14px; }

.menu-toggle.open .bar1 {
  transform: rotate(45deg);
  top: 7px;
}

.menu-toggle.open .bar2 {
  opacity: 0;
}

.menu-toggle.open .bar3 {
  transform: rotate(-45deg);
  top: 7px;
}


.desktop-only {
  display: flex;
}

.mobile-hidden {
  display: none;
  flex-direction: column;
  position: absolute;
  top: 64px; /* debajo del navbar */
  left: 0;
  width: 100%;
  background-color: white;
  padding: 1rem;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  z-index: 100;
}

.mobile-hidden a {
  margin: 0.5rem 0;
}

/* Responsive */
@media (max-width: 1024px) {
  .menu-toggle {
    display: inline-block;
  }

  .desktop-only {
    display: none !important;
  }

  .mobile-hidden.show {
    display: flex;
  }
.navbar {
  z-index: 1100;
}

  .navbar .nav-content {
    flex-wrap: wrap;
  }

  .amazon-searchbar {
    width: 100%;
    margin-top: 0.5rem;
  }
}

/* Ocultar nav-links en laptop o menores */
@media (max-width: 1024px) {
  .nav-links a:not(#accountLink):not(.nav-icon-button):not(.cart-toggle) {
    display: none !important;
  }

  .menu-toggle {
    display: inline-flex !important;
  }

  .navbar {
    padding: 0.5rem 1rem;
  }
}

/* Mostrar nav-links solo en pantallas grandes */
@media (min-width: 1025px) {
  .menu-toggle {
    display: none !important;
  }
}

/* Estilo botón toggle ≣ */

/* Overlay oscuro */
.menu-overlay {
  position: fixed;
  top: 67px;
  left: 0;
  width: 100%;
  height: calc(100% - 67px);
  background: rgba(0, 0, 0, 0.5);
  display: none;
  z-index: 999;
}


/* Menú lateral */
.mobile-menu {
  position: fixed;
  top: 67px; /* justo debajo del navbar */
  left: 0;
  width: 100%;
  height: calc(100% - 67px); /* todo el viewport menos el navbar */
  background-color: #fff;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  padding: 1.5rem;
  z-index: 1000; /* encima del contenido pero debajo del navbar */
  transition: transform 0.3s ease;
  transform: translateX(-100%);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.mobile-menu.open {
  transform: translateX(0);
}


.menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: bold;
  font-size: 18px;
  margin-bottom: 1rem;
}

.menu-header button {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
}

.menu-links {
  list-style: none;
  padding: 0;
}

.menu-links li {
  margin: 1rem 0;
}

.menu-title {
color: #482922;
    font-size: 30px;
text-decoration: none;
    font-weight: bold;
     text-decoration: none;
}

.menu-links a {
color: #482922;
    font-size: 23px;
text-decoration: none;
    font-weight: normal;
     text-decoration: none;
  transition: text-decoration 0.2s ease;
}

.menu-links a:hover {
  text-decoration: underline;
}

/* Mostrar correctamente en pantallas < 1536px (menores a 24") */
@media (max-width: 1535px) {
  .menu-toggle {
    display: inline-flex;
  }

  .nav-links a:not(#accountLink):not(.nav-icon-button):not(.cart-toggle) {
    display: none !important;
  }

  .logo {
    display: block;
    font-size: 20px;
    font-weight: bold;
    color: #482922;
  }


}

/* En pantallas >= 1536px se ve todo normalmente */
@media (min-width: 1536px) {
  .menu-toggle {
    display: none !important;
  }

  .nav-links a {
    display: inline-block !important;
  }


}

@media (min-width: 1024px) and (max-width: 1535px) {
  .nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 4rem;
    padding: 0 1rem;
    margin-right: 0 !important;
    margin-left: -2rem !important;
  }

  .logo {
    margin-left: -7rem !important;
    display: block;
    font-size: 1.25rem;
    font-weight: bold;
    color: #482922;
  }

  .amazon-searchbar {
    max-width: 600px !important;
    flex-grow: 1;
    margin: 0 1rem;
    margin-left: -7rem !important;
  }

  .nav-icon-button {
    margin: 0 !important;
        margin-left: -1rem !important;
    align-items: right;
  }

  .language-selector {
    margin: 0 !important;
        margin-left: -1rem !important;
        align-items: right;
  }

  .menu-toggle {
    display: inline-flex !important;
  }

  .cart-toggle {
align-items: right;
margin-right: -2rem !important;
}
}


/* Mostrar solo en pantallas pequeñas */
.mobile-search-button {
  display: none; /* Oculto por defecto */
}

@media screen and (max-width: 768px) {
  .mobile-search-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    padding: 6px;
    cursor: pointer;
  }

  .mobile-search-button i {
    width: 20px;
    height: 20px;
    color: #482922; /* o el color que estés usando */
  }
}

/* RESPONSIVE NAVBAR FOR CELLPHONES */
@media (max-width: 768px) {
  .menu-toggle {
    display: inline-flex;
    margin-left: -0.2rem !important;
  }

/* GLOBALS */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: #482922;
  background-color: #fff;
}

.container {
  min-height: 100vh;
  background: linear-gradient(135deg, #fff 0%, #fff 100%);
  padding: 0;
  margin: 0 auto;
  overflow-x: hidden;
}

/* NAVBAR REPAIR FOR MOBILE */
.navbar {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  width: 100%;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 4rem;
  flex-wrap: wrap;
}

.logo {
  font-weight: bold;
  font-size: 1.25rem;
  color: #482922;
  flex: 1;
}

.menu-toggle {
  display: none;
  font-size: 24px;
  background: none;
  border: none;
  color: #482922;
  cursor: pointer;
  margin-left: 1rem;
  z-index: 1001;
}

.nav-links {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.nav-links a {
  color: #482922;
  text-decoration: none;
  font-weight: 500;
}

.amazon-searchbar {
  display: flex;
  align-items: center;
  flex: 2;
  max-width: 100%;
  margin: 0 1rem;
}

.amazon-searchbar form {
  display: flex;
  width: 100%;
  border: 1px solid #ccc;
  border-radius: 4px;
  overflow: hidden;
  height: 38px;
}

.amazon-searchbar input,
.amazon-searchbar select {
  border: none;
  outline: none;
  font-size: 14px;
}

.amazon-searchbar input {
  flex: 1;
  padding: 0 10px;
}

.amazon-searchbar select {
  background-color: #f3f3f3;
  padding: 0 8px;
}

.amazon-searchbar button {
  background-color: #febd69;
  border: none;
  padding: 0 10px;
  cursor: pointer;
}

/* PREVENT HORIZONTAL SCROLL */
body {
  overflow-x: hidden;
}

html {
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

.navbar, .nav-container, .nav-content {
  width: 100%;
  overflow-x: hidden;
}

/* Fix any overly-wide elements */
img, video, canvas, iframe {
  max-width: 100%;
  height: auto;
  display: block;
}

section, div, header, footer {
  max-width: 100%;
  overflow-x: hidden;
}


  .logo {
    text-align: center;
    font-size: 20px;
    margin-left: 4rem !important;
        white-space: nowrap;
  }

  .amazon-searchbar {
    display: none !important;
  }
  .cart-toggle {
margin-right: -0.5rem !important;
align-items: right;
  }
  
}

.mobile-search-button {
background-color: transparent;
border: none;
color:#482922;
margin-right: 1rem !important;
}


.mobile-search-container {
  display: none;
  position: absolute;
  top: 60px;
  left: 0;
  width: 100%;
  background: white;
  padding: 10px 12px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  z-index: 2000;
}

.mobile-search-container form {
  display: flex;
  align-items: center;
  gap: 8px;
  background-color: #fff;
  border-radius: 4px;
  padding: 6px 8px;
  border: 1px solid #ccc;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.mobile-search-container select.search-category {
  padding: 4px 8px;
  font-size: 14px;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: #f3f3f3;
}

.mobile-search-container input[type="text"] {
  flex: 1;
  padding: 6px 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
}

.mobile-search-container button[type="submit"] {
  padding: 6px 10px;
  background-color: #482922;
  border: none;
  color: white;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-search-container button[type="submit"] i {
  width: 18px;
  height: 18px;
}

#searchOverlayMobile {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1999;
}

.mobile-language-selector {
  display: none;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}

.mobile-language-selector label {
  font-size: 0.875rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
  color: #482922;
  display: block;
}

.mobile-language-selector select {
  width: 100%;
  padding: 0.5rem;
  font-size: 0.875rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}

@media (max-width: 768px) {
  .mobile-language-selector {
    display: block;
  }

  .navbar .language-selector {
    display: none !important;
  }
}


/* Ajustes del carrusel solo en celulares */
@media (max-width: 768px) {
  .carousel-fade-section {
    width: 100%;      /* ancho máximo relativo a la pantalla */
    margin: 0 auto;      /* centrado horizontal */
    margin-bottom: -30rem !important;
  }

.carousel-fade-slide img {
  width: auto;         /* Usa el ancho real de la imagen */
  height: auto;        /* Mantiene la proporción original */
  max-width: 100%;     /* Evita que sobrepase el contenedor */
  display: block;      /* Elimina espacios blancos extra */
  margin: 0 auto;      /* Centra la imagen horizontalmente */
  object-fit: contain; /* Asegura que no se deforme */
}


}

/* Ocultar textos, botones y flechas del carrusel en móviles */
@media (max-width: 768px) {
  .carousel-fade-caption,
  .carousel-fade-caption *,
  .carousel-fade-slide .btn,
  .carousel-fade-slide .btn-primary,
  .carousel-fade-slide .btn-more,
  .carousel-arrow {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
}


/* ====== NAVBAR (deslizante) ====== */
.navbar{
  position: sticky;
  top:0; left:0; right:0;
  z-index: 1000;
  transition: top .25s ease;
  background: #fff; /* ajusta a tu diseño */
}

/* ====== BÚSQUEDA MOBILE ====== */
.mobile-search-container{
  display:none;
  position:fixed;
  top: 56px; /* debajo del navbar */
  left:0; right:0;
  z-index: 999;
  background:#fff;
  padding: .75rem;
  box-shadow: 0 6px 16px rgba(0,0,0,.08);
}
@media (max-width: 1024px){
  .amazon-searchbar{ max-width: 52vw; }
}
@media (max-width: 768px){
  .amazon-searchbar{ display:none; }     /* ocultar barra Amazon en cel */
  #mobileSearchBtn{ display:inline-flex; }
}

/* ====== LIBROS (grid) ====== */
.books-grid{
  gap: 28px !important;
}
.books-grid a img{
  width: min(42vw, 160px) !important;
  height: auto !important;
}
@media (max-width: 768px){
  .books-grid{
    display:grid !important;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px !important;
    padding: 0 14px;
  }
  .books-grid a h3{
    font-size: .95rem;
  }
}

/* ===== Distribución: versión móvil ===== */
@media (max-width: 768px) {
  #available {
    padding: 24px 0 !important;
  }

  /* Título + líneas */
  #available .section-title {
    font-size: 18px !important;
  }

  /* Grid 2 columnas, huecos iguales a la referencia */
  .distributors-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
    padding: 0 12px !important;
    justify-content: initial !important;
  }

  /* Tarjeta */
  .dist-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }
  .dist-card {
    width: 100%;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #eee;
    box-shadow: 0 2px 6px rgba(0,0,0,.06);
    padding: 16px 10px;
    min-height: 92px;           /* alto visual como la referencia */
    display: flex;
    justify-content: center;
    align-items: center;
  }

  /* Logos: forzar consistencia pese a estilos inline */
  .dist-card img {
    width: 100% !important;
    max-width: 200px !important;
    max-height: 44px !important;   /* controla la altura del logo */
    height: auto !important;
    object-fit: contain !important;
    margin: 0 !important;
  }

  /* Fecha bajo cada logo */
  .dist-date {
    font-size: 11px;
    letter-spacing: .2px;
    color: #333;
  }

  /* Badge (opcional) como en Hoopla */
  .dist-badge {
    display: inline-block;
    margin-top: 6px;
    font-size: 10px;
    line-height: 1;
    padding: 6px 8px;
    border-radius: 4px;
    background: #ffefb0;
    color: #6b4c00;
    border: 1px solid #e8d27a;
  }

  /* Oculta márgenes grandes que estaban puestos inline */
  .distributors-grid a[style], .distributors-grid img[style] {
    margin-top: 0 !important;
  }
}

/* Desktop/Tablet ≥769px: no tocar tu layout actual */


/* ====== SELECTOR DE IDIOMA (posiciones y solapamientos limpios) ====== */
.language-selector{ z-index: 1200; }

/* ====== LOADER (normalizado) ====== */
#loaderOverlay{
  position:fixed; inset:0;
  background:#fff;
  display:flex; justify-content:center; align-items:center;
  z-index: 2000;
  transition: opacity .6s ease;
}
