/* ============================================================
   Responsiveness.css
   Responsive / mobile styles for New Wine — index.html
   ============================================================ */

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  overflow-x: clip;
}

img {
  max-width: 100%;
}

/* ============================================================
   HAMBURGER BUTTON
   Hidden on desktop, shown on mobile/tablet
   ============================================================ */

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 10px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  z-index: 30;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2.5px;
  border-radius: 2px;
  background: var(--wine);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.hamburger:hover {
  background: var(--wine-tint);
}

/* Animate hamburger into an "X" */
.hamburger.open span:nth-child(1) {
  transform: translateY(7.5px) rotate(45deg);
}
.hamburger.open span:nth-child(2) {
  opacity: 0;
}
.hamburger.open span:nth-child(3) {
  transform: translateY(-7.5px) rotate(-45deg);
}

/* ------------------------------------------------------------
   ≤ 1024px — small laptops / large tablets
   ------------------------------------------------------------ */
@media (max-width: 1024px) {
  nav {
    padding: 16px 26px;
  }
  .hero {
    padding: 66px 28px 52px;
  }
  .hero h1 {
    font-size: 36px;
  }
  .devoted {
    padding: 40px 32px;
    gap: 30px;
  }
  .newsletter,
  .event {
    padding: 34px 30px;
  }
}

/* ------------------------------------------------------------
   ≤ 860px — tablet / mobile (hamburger menu activates)
   ------------------------------------------------------------ */
@media (max-width: 860px) {
  nav {
    flex-wrap: wrap;
    gap: 12px 16px;
    padding: 14px 22px;
  }

  .logo-mark img {
    width: 38px;
    height: 38px;
  }
  .logo-mark span {
    font-size: 17px;
  }

  /* Show the hamburger */
  .hamburger {
    display: flex !important;
    margin-left: auto;
  }

  /* Hide desktop CTA */
  .nav-cta {
    display: none !important;
  }

  /* Mobile CTA shown in dropdown */
  .nav-cta-mobile {
    display: inline-block !important;
    margin-top: 10px;
    padding: 11px 40px;
    font-size: 14px;
  }

  /* Navlinks: hidden by default, shown when menu is open */
  .navlinks {
    display: none !important;
    flex-direction: column !important;
    align-items: center;
    gap: 6px !important;
    padding: 18px 0 10px;
    margin-top: 4px;
    border-top: 1px solid rgba(86, 23, 68, 0.10);
    font-size: 14px;
    width: 100%;
    order: 3;
  }

  /* When menu is open - JS adds 'open' class to navlinks */
  .navlinks.open {
    display: flex !important;
  }

  .navlinks a {
    padding: 6px 10px;
    border-radius: 6px;
  }

  .navlinks a:hover,
  .navlinks a.active {
    background: var(--wine-tint);
  }
}

/* ------------------------------------------------------------
   ≤ 768px — tablets portrait
   ------------------------------------------------------------ */
@media (max-width: 768px) {
  .hero {
    padding: 54px 22px 44px;
  }
  .hero img.mark {
    width: 84px;
    height: 84px;
  }
  .hero h1 {
    font-size: clamp(28px, 7vw, 36px);
  }
  .hero p.sub {
    font-size: 15.5px;
  }
  section {
    padding: 52px 22px;
  }
  .section-head {
    margin-bottom: 32px;
  }
  .section-head h2 {
    font-size: 24px;
  }
}

/* ------------------------------------------------------------
   ≤ 640px — large phones
   ------------------------------------------------------------ */
@media (max-width: 640px) {
  nav {
    padding: 12px 18px;
  }

  .hero {
    padding: 46px 18px 38px;
  }
  .hero img.mark {
    width: 76px;
    height: 76px;
    margin-bottom: 18px;
  }
  .hero h1 {
    font-size: clamp(26px, 8vw, 32px);
  }
  .hero p.tagline {
    font-size: 14.5px;
    margin-bottom: 16px;
  }
  .hero p.sub {
    font-size: 15px;
    margin-bottom: 24px;
  }
  .hero-ctas {
    gap: 10px;
  }

  section {
    padding: 44px 18px;
  }
  .section-head h2 {
    font-size: 22px;
  }

  .devoted {
    flex-direction: column;
    text-align: center;
    gap: 24px;
    padding: 30px 22px;
  }
  .devoted .cover {
    width: 132px;
    height: 176px;
  }
  .devoted .content {
    min-width: 0;
  }
  .devoted .content > div {
    justify-content: center;
  }
  .devoted p {
    font-size: 15px;
  }

  .cards {
    gap: 14px;
  }

  .feed {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .feed-item {
    aspect-ratio: 1 / 1;
  }

  .newsletter {
    flex-direction: column;
    text-align: center;
    padding: 32px 22px;
  }
  .newsletter form {
    width: 100%;
  }
  .newsletter input {
    flex: 1 1 100%;
    min-width: 0;
    width: 100%;
  }
  .newsletter .btn {
    flex: 1 1 100%;
    text-align: center;
  }

  .event {
    flex-direction: column;
    text-align: center;
    padding: 30px 22px;
  }
  .event .info {
    min-width: 0;
  }

  .foot-grid {
    gap: 26px;
  }
}

/* ------------------------------------------------------------
   ≤ 480px — phones
   ------------------------------------------------------------ */
@media (max-width: 480px) {
  body {
    font-size: 15px;
  }

  .btn {
    padding: 12px 26px;
    font-size: 14px;
  }

  .eyebrow {
    font-size: 12px;
    letter-spacing: 1.6px;
  }

  .navlinks {
    gap: 8px 14px;
    font-size: 13px;
  }
  .navlinks a {
    padding: 2px 0;
  }

  .hero h1 {
    font-size: clamp(24px, 8.5vw, 30px);
  }

  section {
    padding: 40px 16px;
  }

  .card {
    padding: 24px 20px;
  }
  .card h3 {
    font-size: 17px;
  }

  .foot-grid {
    grid-template-columns: 1fr;
    gap: 22px;
    text-align: center;
  }
  .foot-grid h4 {
    margin-bottom: 10px;
  }
  .foot-bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
  }
}

/* ------------------------------------------------------------
   ≤ 360px — very small phones
   ------------------------------------------------------------ */
@media (max-width: 360px) {
  .hero h1 {
    font-size: 24px;
  }
  .navlinks {
    gap: 8px 10px;
  }
  .feed {
    grid-template-columns: 1fr;
  }
  .devoted .cover {
    width: 120px;
    height: 160px;
  }
}