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

:root {
  --red:      #c0392b;
  --red-dark: #962d22;
  --brown:    #5c2d0e;
  --cream:    #fdf6ef;
  --tan:      #f0e0cc;
  --gray:     #6b6b6b;
  --dark:     #1a1a1a;
  --white:    #ffffff;
  --radius:   12px;
  --shadow:   0 4px 24px rgba(0,0,0,.10);
  --nav-h:    64px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Georgia', serif;
  color: var(--dark);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }

.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }

/* ── Buttons ── */
.btn {
  display: inline-block;
  border-radius: 6px;
  font-family: 'Arial', sans-serif;
  font-weight: 700;
  letter-spacing: .04em;
  cursor: pointer;
  transition: background .2s, transform .15s;
  border: none;
  text-align: center;
}
.btn--primary {
  background: var(--red);
  color: var(--white);
  padding: 14px 32px;
  font-size: 1rem;
}
.btn--primary:hover { background: var(--red-dark); transform: translateY(-2px); }
.btn--lg { padding: 16px 44px; font-size: 1.1rem; }

/* ── Section titles ── */
.section-title {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  color: var(--brown);
  margin-bottom: 12px;
  text-align: center;
}
.section-sub {
  text-align: center;
  color: var(--gray);
  max-width: 560px;
  margin: 0 auto 40px;
  font-family: 'Arial', sans-serif;
  font-size: .95rem;
}

/* ── NAV ── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  background: rgba(255, 255, 255, .98);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 16px rgba(0,0,0,.08);
  border-bottom: 3px solid transparent;
  transition: border-color .3s;
}
.nav.scrolled {
  border-bottom-color: var(--red);
}
.nav__inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav__logo {
  display: flex;
  align-items: center;
  z-index: 201;
  flex-shrink: 0;
}
.nav__logo-img {
  height: 50px;
  width: auto;
  display: block;
  transition: transform .25s;
}
.nav__logo:hover .nav__logo-img { transform: scale(1.04); }

/* Hamburger — hidden on desktop */
.nav__burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 201;
  padding: 4px;
}
.nav__burger span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--dark);
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}
.nav--open .nav__burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav--open .nav__burger span:nth-child(2) { opacity: 0; }
.nav--open .nav__burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Hide mobile-only overlay elements on desktop */
.nav__mobile-logo,
.nav__mobile-tag { display: none; }

/* Nav links */
.nav__links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* All links base */
.nav__links a {
  font-family: 'Arial', sans-serif;
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--dark);
  padding: 8px 16px;
  border-radius: 6px;
  position: relative;
  transition: color .2s, background .2s;
}

/* Animated underline for Productos & Nosotros */
.nav__links li:not(:last-child) a::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 16px;
  right: 16px;
  height: 2px;
  background: var(--red);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}
.nav__links li:not(:last-child) a:hover { color: var(--red); }
.nav__links li:not(:last-child) a:hover::after { transform: scaleX(1); }

/* Contact pill button */
.nav__links li:last-child a {
  background: var(--red);
  color: var(--white);
  padding: 9px 22px;
  border-radius: 999px;
  box-shadow: 0 3px 12px rgba(192,57,43,.30);
  transition: background .2s, transform .2s, box-shadow .2s;
}
.nav__links li:last-child a:hover {
  background: var(--red-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(192,57,43,.40);
}

/* ── HERO ANIMATIONS ── */
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ── HERO ── */
.hero {
  position: relative;
  min-height: 65vh;
  display: flex;
  align-items: center;
  background:
    linear-gradient(135deg, #3b1002ee 40%, #7a230acc 100%),
    url('Sausages.png') center/cover no-repeat;
}
.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(26,10,2,.85) 50%, transparent 100%);
  animation: fadeIn .8s ease both;
}
.hero__content {
  position: relative;
  z-index: 1;
  max-width: 620px;
  padding: 48px 20px 48px 8vw;
}
.hero__eyebrow {
  font-family: 'Arial', sans-serif;
  font-size: .85rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #e8a87c;
  margin-bottom: 16px;
  opacity: 0;
  animation: fadeSlideUp .7s ease .2s forwards;
}
.hero__title {
  font-size: clamp(1.9rem, 4.5vw, 3.2rem);
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 20px;
  opacity: 0;
  animation: fadeSlideUp .7s ease .45s forwards;
}
.hero__sub {
  font-family: 'Arial', sans-serif;
  color: #d9cfc8;
  font-size: 1rem;
  max-width: 480px;
  margin-bottom: 32px;
  line-height: 1.7;
  opacity: 0;
  animation: fadeSlideUp .7s ease .65s forwards;
}
.hero .btn--primary {
  opacity: 0;
  animation: fadeSlideUp .7s ease .85s forwards;
}

/* ── PRODUCTS ── */
.products {
  padding: 80px 0;
  background: var(--cream);
}
.products__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.product-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 36px rgba(0,0,0,.14);
}
.product-card__img-wrap {
  width: 100%;
  height: 210px;
  overflow: hidden;
  background: var(--tan);
}
.product-card__img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform .4s;
}
.product-card:hover .product-card__img-wrap img { transform: scale(1.05); }
.product-card__body {
  padding: 20px 22px 24px;
}
.product-card__body h3 {
  font-size: 1.1rem;
  color: var(--brown);
  margin-bottom: 8px;
}
.product-card__body p {
  font-family: 'Arial', sans-serif;
  font-size: .89rem;
  color: var(--gray);
  line-height: 1.6;
}

/* ── ABOUT ── */
.about {
  padding: 80px 0;
  background: var(--white);
}
.about__inner {
  display: flex;
  align-items: center;
  gap: 64px;
}
.about__text { flex: 1; }
.about__text .section-title { text-align: left; }
.about__text p {
  font-family: 'Arial', sans-serif;
  color: var(--gray);
  margin-bottom: 16px;
  line-height: 1.75;
}
.about__features {
  list-style: none;
  margin-top: 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
}
.about__features li {
  font-family: 'Arial', sans-serif;
  font-size: .93rem;
  color: var(--dark);
  display: flex;
  align-items: center;
  gap: 8px;
}
.feature-icon {
  width: 22px;
  height: 22px;
  background: var(--red);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .7rem;
  font-weight: bold;
  flex-shrink: 0;
}
.about__badge { flex-shrink: 0; }
.badge-circle {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--red) 0%, var(--brown) 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  text-align: center;
  box-shadow: 0 8px 40px rgba(192,57,43,.35);
}
.badge-label {
  font-family: 'Arial', sans-serif;
  font-size: .75rem;
  letter-spacing: .15em;
  text-transform: uppercase;
  opacity: .85;
}
.badge-year {
  font-size: 3rem;
  font-weight: bold;
  line-height: 1;
  margin: 4px 0;
}
.badge-sub {
  font-family: 'Arial', sans-serif;
  font-size: .75rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  opacity: .75;
}

/* ── CONTACT ── */
.contact {
  padding: 80px 0;
  background: var(--cream);
}
.contact__form {
  max-width: 760px;
  margin: 0 auto;
  background: var(--white);
  border-radius: var(--radius);
  padding: 48px;
  box-shadow: var(--shadow);
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}
.form-group { display: flex; flex-direction: column; }
.form-group--full { grid-column: 1 / -1; }
.form-group--submit { align-items: center; margin-top: 8px; }

label {
  font-family: 'Arial', sans-serif;
  font-size: .83rem;
  font-weight: 600;
  color: var(--brown);
  margin-bottom: 6px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
input, select, textarea {
  border: 1.5px solid #ddd;
  border-radius: 6px;
  padding: 13px 14px;
  font-size: 1rem;
  font-family: 'Arial', sans-serif;
  color: var(--dark);
  background: var(--white);
  transition: border-color .2s;
  outline: none;
  width: 100%;
  -webkit-appearance: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--red); }
textarea { resize: vertical; }

.contact__success {
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
  padding: 48px 24px;
}
.success-icon {
  width: 64px;
  height: 64px;
  background: #27ae60;
  color: white;
  font-size: 1.8rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}
.contact__success h3 { font-size: 1.5rem; color: var(--brown); margin-bottom: 10px; }
.contact__success p { font-family: 'Arial', sans-serif; color: var(--gray); }

/* ── FOOTER ── */
.footer {
  background: var(--dark);
  padding: 28px 0;
}
.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.footer__logo { display: flex; align-items: center; }
.footer__logo-img { height: 56px; width: auto; display: block; }
.footer__copy { font-family: 'Arial', sans-serif; font-size: .83rem; color: #888; }

/* ══════════════════════════════
   RESPONSIVE — Tablet (≤ 1024px)
══════════════════════════════ */
@media (max-width: 1024px) {
  .products__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
  .about__inner { gap: 40px; }
  .badge-circle { width: 170px; height: 170px; }
  .badge-year { font-size: 2.6rem; }
}

/* ══════════════════════════════
   RESPONSIVE — Mobile (≤ 640px)
══════════════════════════════ */
@media (max-width: 640px) {

  /* Nav: show burger */
  .nav__burger { display: flex; }

  /* ── Full-screen overlay ── */
  .nav__links {
    position: fixed;
    inset: 0;
    z-index: 199;
    background: linear-gradient(150deg, #111 0%, #1a0a04 55%, #0d0d0d 100%);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    opacity: 0;
    pointer-events: none;
    transform: translateX(100%);
    transition: opacity .4s ease, transform .4s cubic-bezier(.77,0,.18,1);
    /* Inset decorative frame */
    --frame: 18px;
  }
  /* Outer frame border */
  .nav__links::before {
    content: '';
    position: absolute;
    inset: var(--frame);
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 6px;
    pointer-events: none;
  }
  /* Red top accent bar */
  .nav__links::after {
    content: '';
    position: absolute;
    top: var(--frame);
    left: var(--frame);
    right: var(--frame);
    height: 3px;
    background: linear-gradient(90deg, var(--red), #e74c3c88);
    border-radius: 6px 6px 0 0;
    pointer-events: none;
  }

  .nav--open .nav__links {
    opacity: 1;
    pointer-events: all;
    transform: translateX(0);
  }

  /* Logo inside overlay */
  .nav__mobile-logo {
    display: block;
    margin-bottom: 28px;
    width: auto !important;
  }
  .nav__mobile-logo img {
    height: 72px;
    width: auto;
    filter: brightness(0) invert(1);
    opacity: .85;
  }

  /* Divider under logo */
  .nav__mobile-logo::after {
    content: '';
    display: block;
    width: 40px;
    height: 2px;
    background: var(--red);
    margin: 20px auto 0;
    border-radius: 2px;
  }

  /* Links */
  .nav__links li { width: 100%; text-align: center; }
  .nav__links a {
    display: block;
    font-size: 1.45rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: rgba(255,255,255,.75);
    background: none !important;
    box-shadow: none !important;
    padding: 16px 40px;
    border-radius: 0 !important;
    border: none;
    position: relative;
    transition: color .25s ease, padding-left .25s ease;
  }
  /* Left red bar on hover */
  .nav__links a::before {
    content: '';
    position: absolute;
    left: calc(var(--frame) + 12px);
    top: 50%;
    transform: translateY(-50%) scaleY(0);
    width: 3px;
    height: 60%;
    background: var(--red);
    border-radius: 2px;
    transition: transform .25s ease;
  }
  .nav__links a:hover,
  .nav__links a:active {
    color: var(--white);
    padding-left: 56px;
    transform: none !important;
    background: none !important;
  }
  .nav__links a:hover::before { transform: translateY(-50%) scaleY(1); }
  .nav__links li:not(:last-child) a::after { display: none !important; }

  /* Tagline */
  .nav__mobile-tag {
    display: block;
    margin-top: 32px;
    font-family: 'Arial', sans-serif;
    font-size: .7rem;
    letter-spacing: .28em;
    text-transform: uppercase;
    color: rgba(255,255,255,.25);
  }

  /* Stagger link slide-in */
  .nav--open .nav__links li:nth-child(1) { animation: linkIn .4s ease .05s both; }
  .nav--open .nav__links li:nth-child(2) { animation: linkIn .4s ease .15s both; }
  .nav--open .nav__links li:nth-child(3) { animation: linkIn .4s ease .23s both; }
  .nav--open .nav__links li:nth-child(4) { animation: linkIn .4s ease .31s both; }
  .nav--open .nav__links li:nth-child(5) { animation: linkIn .4s ease .39s both; }

  @keyframes linkIn {
    from { opacity: 0; transform: translateX(24px); }
    to   { opacity: 1; transform: translateX(0); }
  }

  /* Hero */
  .hero {
    min-height: 70vh;
    align-items: flex-end;
    background-position: center top;
  }
  .hero__overlay {
    background: linear-gradient(to top, rgba(26,10,2,.92) 50%, rgba(26,10,2,.4) 100%);
  }
  .hero__content {
    padding: calc(var(--nav-h) + 24px) 20px 40px;
    max-width: 100%;
  }
  .hero__title { font-size: clamp(1.7rem, 7vw, 2.4rem); }
  .hero__sub { font-size: .95rem; }
  .btn--lg { padding: 14px 32px; font-size: 1rem; width: 100%; }

  /* Products */
  .products { padding: 56px 0; }
  .products__grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .product-card__img-wrap { height: 200px; }

  /* About */
  .about { padding: 56px 0; }
  .about__inner {
    flex-direction: column;
    gap: 32px;
    text-align: center;
  }
  .about__text .section-title { text-align: center; }
  .about__badge { order: -1; }
  .badge-circle { width: 150px; height: 150px; }
  .badge-year { font-size: 2.2rem; }
  .about__features {
    grid-template-columns: 1fr;
    text-align: left;
  }

  /* Contact */
  .contact { padding: 56px 0; }
  .contact__form { padding: 24px 16px; }
  .form-row { grid-template-columns: 1fr; gap: 16px; }
  .form-group--submit { align-items: stretch; }
  .form-group--submit .btn { width: 100%; }

  /* Footer */
  .footer__inner { flex-direction: column; text-align: center; }
}
