/* ==========================================================================
   Lift U Up — Responsive Breakpoints
   ==========================================================================
   Breakpoints:
     1200px  — large tablets / small desktops
      992px  — tablets (nav collapse)
      768px  — small tablets / large phones
      480px  — phones
   ========================================================================== */

/* ==========================================================================
   1200px — Large Tablets / Small Desktops
   ========================================================================== */
@media (max-width: 1200px) {

  /* ---- Container ---- */
  .container {
    max-width: 960px;
    padding-left: 40px;
    padding-right: 40px;
  }

  /* ---- Section Headers ---- */
  .section-header h2,
  .section-title {
    font-size: 2.4rem;
  }

  .section-header p,
  .section-subtitle {
    font-size: 1.05rem;
  }

  /* ---- Hero ---- */
  .hero-title {
    font-size: 60px;
  }

  .hero-subtitle {
    font-size: 1.15rem;
  }

  /* ---- Categories Grid ---- */
  .cat-grid {
    gap: 20px;
  }

  /* ---- Product Grid ---- */
  .product-grid {
    gap: 24px;
  }

  /* ---- Region Grid ---- */
  .region-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  /* ---- Testimonials ---- */
  .testi-grid {
    gap: 24px;
  }

  /* ---- Footer ---- */
  .footer-grid {
    gap: 32px;
  }

  /* ---- WooCommerce Shop ---- */
  .woocommerce ul.products {
    gap: 24px;
  }

  /* ---- Story Section ---- */
  .story-grid,
  .story-section .grid {
    gap: 40px;
  }
}


/* ==========================================================================
   992px — Tablets (Navigation Collapse)
   ========================================================================== */
@media (max-width: 992px) {

  /* ================================================================
     Mobile Navigation
     ================================================================ */

  /* Show hamburger button */
  .menu-toggle {
    display: flex;
  }

  /* Hide search & account icons from the top bar; keep cart visible */
  .nav-icons .search-toggle,
  .nav-icons > .nav-icon-btn:not(.cart-badge) {
    display: none;
  }

  /* Reduce nav horizontal padding */
  .nav {
    padding-left: 24px;
    padding-right: 24px;
  }
  .nav.scrolled {
    padding-left: 24px;
    padding-right: 24px;
  }

  /* Slide-in panel */
  .nav-links {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 300px;
    background: var(--ivory);
    flex-direction: column;
    align-items: stretch;
    padding: 100px 32px 40px;
    gap: 0;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    box-shadow: -8px 0 32px rgba(27, 23, 68, 0.1);
    z-index: 99;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  body.menu-open .nav-links {
    transform: translateX(0);
  }

  /* Prevent body scrolling when panel is open */
  body.menu-open {
    overflow: hidden;
  }

  /* Vertical nav link styling */
  .nav-links a,
  .nav-links .menu-item a {
    display: block;
    font-size: 15px;
    padding: 16px 0;
    border-bottom: 1px solid var(--jali);
    letter-spacing: 1.5px;
    color: var(--deep-indigo);
  }

  .nav-links a:hover,
  .nav-links .menu-item a:hover {
    color: var(--saffron);
  }

  /* Remove the desktop underline hover effect inside the panel */
  .nav-links a::after,
  .nav-links .menu-item a::after {
    display: none;
  }

  /* Hamburger to X animation */
  .hamburger-line {
    transition: transform 0.3s ease, opacity 0.3s ease;
  }

  body.menu-open .menu-toggle .hamburger-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  body.menu-open .menu-toggle .hamburger-line:nth-child(2) {
    opacity: 0;
  }

  body.menu-open .menu-toggle .hamburger-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  /* ---- Container ---- */
  .container {
    max-width: 100%;
    padding-left: 36px;
    padding-right: 36px;
  }

  /* ---- Site Main (nav offset) ---- */
  .site-main {
    padding-top: 160px;
  }

  .hero {
    padding-top: 160px;
    padding-bottom: 48px;
  }

  /* ---- Section Headers ---- */
  .section-header h2,
  .section-title {
    font-size: 1.85rem;
  }

  .section-header p,
  .section-subtitle {
    font-size: 1rem;
    max-width: 100%;
  }

  .section-header {
    margin-bottom: 32px;
  }

  /* ================================================================
     Hero — Single Column
     ================================================================ */
  .hero,
  .hero-grid,
  .hero .grid,
  .hero-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .hero-left {
    order: 1;
    text-align: center;
  }

  .hero-right {
    order: 2;
  }

  .hero-title {
    font-size: 48px;
    line-height: 1.1;
  }

  .hero-subtitle {
    font-size: 1.05rem;
    max-width: 100%;
  }

  .hero-cta,
  .hero-buttons {
    justify-content: center;
  }

  /* Float card repositioning */
  .hero-float-card,
  .float-card {
    position: relative;
    bottom: -10px;
    left: 0;
    right: auto;
    margin: 0 auto;
    max-width: 280px;
  }

  .hero {
    padding-top: 160px;
    padding-bottom: 48px;
  }

  /* ================================================================
     Trust Bar — 2x2 Grid
     ================================================================ */
  .trust-bar,
  .trust-bar-grid,
  .trust-items {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .trust-item {
    padding: 16px;
    text-align: center;
  }

  /* ================================================================
     Categories — 2 Columns
     ================================================================ */
  .cat-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  /* ================================================================
     Product Grid — 2 Columns
     ================================================================ */
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .product-card {
    padding: 12px;
  }

  .product-card .product-title {
    font-size: 1rem;
  }

  .product-card .product-price {
    font-size: 0.95rem;
  }

  /* ================================================================
     Story Section — Stacked (image first)
     ================================================================ */
  .story-grid,
  .story-section .grid,
  .story-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .story-image,
  .story-section .image-col {
    order: -1;
  }

  .story-image img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 12px;
  }

  .story-text,
  .story-section .text-col {
    order: 1;
    text-align: center;
  }

  /* ================================================================
     Region Grid — 3 Columns
     ================================================================ */
  .region-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }

  .region-card {
    padding: 16px;
  }

  /* ================================================================
     Testimonials — Single Column
     ================================================================ */
  .testimonials {
    padding: 64px 20px;
  }
  .testi-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .testi-card {
    padding: 28px;
  }

  /* ================================================================
     Newsletter
     ================================================================ */
  .newsletter-form {
    flex-direction: row;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
  }

  .newsletter-section {
    text-align: center;
  }

  .newsletter-section h2 {
    font-size: 1.75rem;
  }

  /* ================================================================
     Footer — 2x2 Grid
     ================================================================ */
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: center;
    gap: 12px;
    text-align: center;
  }

  .footer-bottom-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
  }

  /* ================================================================
     WooCommerce — Shop Grid 2 Columns
     ================================================================ */
  .woocommerce ul.products {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  /* WooCommerce — Single Product Stacked */
  .woocommerce div.product .woocommerce-product-gallery,
  .woocommerce div.product .summary,
  .single-product .product-grid,
  .single-product .product-layout {
    grid-template-columns: 1fr;
  }

  .woocommerce div.product .woocommerce-product-gallery {
    max-width: 100%;
    margin-bottom: 24px;
  }

  .woocommerce div.product .summary {
    max-width: 100%;
  }

  .woocommerce div.product .product_title {
    font-size: 1.75rem;
  }

  /* WooCommerce — Cart Table */
  .woocommerce-cart table.cart,
  .woocommerce table.shop_table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
  }

  .woocommerce-cart table.cart td,
  .woocommerce table.shop_table td {
    min-width: 100px;
  }

  .woocommerce-cart table.cart img {
    max-width: 60px;
    height: auto;
  }

  /* WooCommerce — Checkout Stacked */
  .woocommerce-checkout .col2-set,
  .woocommerce-checkout .checkout-columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .woocommerce-checkout .col2-set .col-1,
  .woocommerce-checkout .col2-set .col-2 {
    width: 100%;
    max-width: 100%;
    float: none;
  }

  .woocommerce-checkout #order_review_heading,
  .woocommerce-checkout #order_review {
    width: 100%;
    float: none;
  }
}


/* ==========================================================================
   480px — Phones
   ========================================================================== */
@media (max-width: 480px) {

  /* ---- Container ---- */
  .container {
    padding-left: 20px;
    padding-right: 20px;
  }

  /* ---- Site Main (nav offset) ---- */
  .site-main {
    padding-top: 120px;
  }

  .page-content {
    padding-left: 16px;
    padding-right: 16px;
  }

  /* ---- Section Padding ---- */
  section,
  .section {
    padding-top: 36px;
    padding-bottom: 36px;
  }
  .hero {
    padding-top: 120px;
    padding-bottom: 36px;
  }

  /* ---- Section Headers ---- */
  .section-header h2,
  .section-title {
    font-size: 1.5rem;
  }

  .section-header p,
  .section-subtitle {
    font-size: 0.95rem;
  }

  .section-header {
    margin-bottom: 24px;
  }

  /* ================================================================
     Hero — Phone Sizing
     ================================================================ */
  .hero-title {
    font-size: 36px;
    line-height: 1.15;
  }

  .hero-subtitle {
    font-size: 0.95rem;
    line-height: 1.6;
  }

  .hero-cta .btn,
  .hero-buttons .btn {
    width: 100%;
    text-align: center;
    padding: 14px 24px;
  }

  .hero-cta,
  .hero-buttons {
    flex-direction: column;
    gap: 12px;
  }

  .hero-float-card,
  .float-card {
    max-width: 100%;
    padding: 16px;
  }

  /* ================================================================
     Trust Bar — Single Column
     ================================================================ */
  .trust-bar,
  .trust-bar-grid,
  .trust-items {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .trust-item {
    padding: 14px 16px;
    flex-direction: row;
    text-align: left;
    gap: 12px;
  }

  /* ================================================================
     Categories — Single Column
     ================================================================ */
  .cat-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* ================================================================
     Product Grid — Single Column
     ================================================================ */
  .product-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .product-card {
    max-width: 100%;
  }

  /* ================================================================
     Region Grid — 2 Columns
     ================================================================ */
  .region-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .region-card {
    padding: 12px;
  }

  .region-card h3,
  .region-name {
    font-size: 0.9rem;
  }

  /* ================================================================
     Testimonials — Single Column (tighter)
     ================================================================ */
  .testi-grid {
    gap: 16px;
    max-width: 100%;
  }

  .testimonials {
    padding: 48px 16px;
  }

  .testi-card {
    padding: 20px;
  }

  .testi-quote {
    font-size: 0.95rem;
  }

  /* ================================================================
     Newsletter — Stacked Form
     ================================================================ */
  .newsletter-form {
    flex-direction: column;
    gap: 12px;
    max-width: 100%;
  }

  .newsletter-form input[type="email"],
  .newsletter-form .newsletter-input {
    width: 100%;
    min-width: 0;
    padding: 14px 16px;
    font-size: 1rem;
  }

  .newsletter-form button,
  .newsletter-form .newsletter-btn,
  .newsletter-form input[type="submit"] {
    width: 100%;
    padding: 14px 24px;
    font-size: 1rem;
    text-align: center;
  }

  .newsletter-section h2 {
    font-size: 1.5rem;
  }

  .newsletter-section p {
    font-size: 0.95rem;
  }

  /* ================================================================
     Footer — Single Column
     ================================================================ */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
    text-align: center;
  }

  .footer-col {
    text-align: center;
  }

  .footer-col ul {
    align-items: center;
  }

  .footer-social {
    justify-content: center;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 10px;
    text-align: center;
    padding-top: 20px;
  }

  .footer-bottom-links {
    flex-direction: column;
    gap: 8px;
  }

  /* ================================================================
     WooCommerce — Shop Grid Single Column
     ================================================================ */
  .woocommerce ul.products {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .woocommerce ul.products li.product {
    max-width: 100%;
  }

  /* WooCommerce — Cart Card Layout */
  .woocommerce-cart table.cart,
  .woocommerce table.shop_table {
    white-space: normal;
  }

  .woocommerce-cart table.cart thead {
    display: none;
  }

  .woocommerce-cart table.cart tr {
    display: flex;
    flex-direction: column;
    padding: 16px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 8px;
    margin-bottom: 12px;
    background: var(--warm-cream, #faf8f5);
  }

  .woocommerce-cart table.cart td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border: none;
    min-width: 0;
    white-space: normal;
  }

  .woocommerce-cart table.cart td::before {
    content: attr(data-title);
    font-weight: 600;
    font-family: var(--font-body, 'DM Sans', sans-serif);
    font-size: 0.85rem;
    color: var(--ink, #1a1a2e);
    margin-right: 12px;
    flex-shrink: 0;
  }

  .woocommerce-cart table.cart td.product-thumbnail {
    justify-content: center;
  }

  .woocommerce-cart table.cart img {
    max-width: 80px;
  }

  .woocommerce-cart table.cart td.actions {
    flex-direction: column;
    gap: 12px;
  }

  .woocommerce-cart table.cart td.actions .coupon {
    flex-direction: column;
    width: 100%;
  }

  .woocommerce-cart table.cart td.actions .coupon input {
    width: 100%;
  }

  .woocommerce-cart table.cart td.actions .coupon button,
  .woocommerce-cart table.cart td.actions > button {
    width: 100%;
  }

  /* WooCommerce — Product title & price on phones */
  .woocommerce div.product .product_title {
    font-size: 1.5rem;
  }

  .woocommerce div.product p.price {
    font-size: 1.25rem;
  }

  .woocommerce div.product .quantity .qty {
    width: 60px;
    padding: 10px 8px;
  }

  .woocommerce div.product .single_add_to_cart_button {
    width: 100%;
    text-align: center;
    padding: 14px 20px;
  }

  /* WooCommerce — Tabs on phones */
  .woocommerce div.product .woocommerce-tabs ul.tabs {
    flex-direction: column;
    gap: 0;
  }

  .woocommerce div.product .woocommerce-tabs ul.tabs li {
    width: 100%;
    text-align: center;
  }

  .woocommerce div.product .woocommerce-tabs ul.tabs li a {
    display: block;
    padding: 12px 16px;
  }

  /* WooCommerce — Checkout tighter spacing */
  .woocommerce-checkout .woocommerce-billing-fields__field-wrapper,
  .woocommerce-checkout .woocommerce-shipping-fields__field-wrapper {
    gap: 12px;
  }

  .woocommerce-checkout .form-row {
    width: 100% !important;
    float: none !important;
  }

  .woocommerce-checkout #payment .place-order .button {
    width: 100%;
    padding: 16px;
    font-size: 1rem;
  }

  /* ================================================================
     General — Buttons Full-Width on Phones
     ================================================================ */
  .btn-full-mobile,
  .cta-section .btn {
    width: 100%;
    text-align: center;
  }

  /* ================================================================
     Navigation Panel — Full Width on Phones
     ================================================================ */
  .nav-links {
    width: 100%;
    max-width: 100%;
    padding: 72px 24px 24px;
  }

  /* ================================================================
     General Typography Adjustments
     ================================================================ */
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.2rem; }
  h4 { font-size: 1.05rem; }

  /* Tighter line heights for headings on small screens */
  h1, h2, h3 {
    line-height: 1.2;
  }
}


/* ==========================================================================
   Utility: Hide / Show at Breakpoints
   ========================================================================== */

/* Desktop only (hidden on tablet and below) */
@media (max-width: 992px) {
  .desktop-only,
  .hide-tablet {
    display: none !important;
  }
}

/* Tablet only (hidden on desktop, hidden on phone) */
@media (min-width: 993px) {
  .tablet-only,
  .mobile-only {
    display: none !important;
  }
}

@media (max-width: 480px) {
  .tablet-only {
    display: none !important;
  }
}

/* Mobile only (hidden above 768px) */
@media (min-width: 769px) {
  .mobile-only,
  .phone-only {
    display: none !important;
  }
}

/* Phone only (hidden above 480px) */
@media (min-width: 481px) {
  .phone-only {
    display: none !important;
  }
}

/* Hide on phone */
@media (max-width: 480px) {
  .hide-phone {
    display: none !important;
  }
}


/* ==========================================================================
   Accessibility: Reduced Motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  .nav-links {
    transition: none;
  }

  .nav-overlay {
    transition: none;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}


/* ==========================================================================
   Touch: Larger Tap Targets
   ========================================================================== */
@media (pointer: coarse) {
  .nav-links a,
  .nav-links li a {
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .btn,
  button,
  input[type="submit"] {
    min-height: 44px;
  }

  .product-card a,
  .category-card a,
  .region-card a {
    min-height: 44px;
  }
}


/* ==========================================================================
   Landscape Phones (short viewport)
   ========================================================================== */
@media (max-width: 768px) and (orientation: landscape) {
  .hero {
    padding-top: 120px;
    padding-bottom: 20px;
    min-height: auto;
  }

  .hero-title {
    font-size: 36px;
  }

  .hero-right img {
    max-height: 280px;
    object-fit: cover;
  }

  .nav-links {
    padding-top: 60px;
  }
}
