/* ==========================================
   RESPONSIVE STYLES
   All media queries organized by breakpoint
========================================== */

/* ==========================================
   TABLET (max-width: 1024px)
========================================== */
@media (max-width: 1024px) {
  /* === PRODUCTS === */
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    padding: 30px 20px;
  }

  /* === HOME - HEADLINE === */
  .headline .top,
  .headline .bottom {
    font-size: 45px;
  }

  .headline .middle {
    font-size: 60px;
  }

  /* === HOME - SPREADSHEET BUTTON === */
  .spreadsheet-button {
    font-size: 32px;
    padding: 25px 40px;
  }

  .spreadsheet-button .sub-text {
    font-size: 18px;
  }

  .spreadsheet-button .sub-sub-text {
    font-size: 24px;
  }

  /* === HOME - JOIN === */
  .join-text {
    font-size: 36px;
  }

  .offer {
    font-size: 18px;
  }

  /* === HOME - BESTSELLER === */
  .bestseller-section h2 {
    font-size: 2.5rem;
  }

  .bestseller-img {
    height: 400px;
  }

  /* === HOME - FEEDBACK === */
  .feedback-card {
    max-width: 250px;
  }

  /* === HOME - NEWS === */
  .hipobuy-news h2 {
    font-size: 48px;
  }

  .hipobuy-news .news-items p {
    font-size: 20px;
  }

  .hipobuy-news .signup-button {
    padding: 20px 50px;
    font-size: 24px;
  }

  /* === PRODUCT DETAIL === */
  .product-card-detail {
    flex-direction: column;
    height: auto;
  }

  .product-info-left,
  .product-info-box {
    width: 100%;
  }

  .product-title {
    margin-top: 20px;
    font-size: 32px;
  }

  #productPrice {
    font-size: 36px;
  }

  .buy-button {
    width: 70%;
    font-size: 18px;
    padding: 18px 0;
    margin-top: 30px;
  }

  .product-features {
    margin-top: 30px;
  }

  .back-button {
    left: 20px;
    top: 40px;
  }

  /* === PRODUCT DETAIL - MODERN === */
  .product-detail-wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
    padding: 30px;
  }

  .product-image-wrapper {
    position: static;
    min-height: 400px;
  }

  .product-detail-title {
    font-size: 36px;
  }

  .product-detail-price {
    font-size: 40px;
  }

  .related-products-grid-modern {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  .related-card img {
    height: 220px;
  }

  /* === PRODUCTS PAGE - MODERN === */
  .products-filter-bar {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .apply-filter-button {
    grid-column: 1 / -1;
  }

  .products-grid-modern {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
  }

  /* === HOMEPAGE - MODERN === */
  .hero-title-main {
    font-size: 52px;
  }

  .bestseller-card-modern {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .join-benefits {
    grid-template-columns: 1fr;
  }

  .reviews-grid {
    grid-template-columns: 1fr;
  }

  .contact-container {
    grid-template-columns: 1fr;
  }
}

/* ==========================================
   MOBILE (max-width: 1024px)
========================================== */
@media (max-width: 1024px) {
  /* === HEADER - FOR ALL PAGES === */
  body {
    margin-top: 20px !important;
  }

  .headbar {
    padding: 10px 20px !important;
  }

  .headbar .logo {
    font-size: 20px !important;
  }

  /* === INFO BAR - FOR INDEX.HTML === */
  .headline-info-bar {
    top: 44px !important;
    font-size: 12px !important;
    padding: 8px 15px !important;
    gap: 15px !important;
    top: 80px;
    font-size: 12px;
    padding: 6px 12px;
    gap: 12px;
  }

  /* Hide center register button */
  .header-center {
    display: none;
  }

  /* === BURGER MENU === */
  .burger-menu {
    display: flex !important;
    flex-direction: column;
    cursor: pointer;
    z-index: 1001;
    gap: 4px;
  }

  .burger-menu span {
    width: 25px;
    height: 3px;
    background: white;
    transition: 0.3s;
    border-radius: 2px;
    display: block;
  }

  .burger-menu.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
  }

  .burger-menu.active span:nth-child(2) {
    opacity: 0;
  }

  .burger-menu.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
  }

  /* === MOBILE NAVIGATION === */
  .nav-links {
    position: fixed;
    top: 60px;
    right: -100%;
    width: 70%;
    max-width: 300px;
    height: calc(100vh - 60px);
    background: #D22B2B;
    flex-direction: column;
    padding: 30px 20px;
    gap: 0;
    transition: right 0.3s ease;
    box-shadow: -2px 0 10px rgba(0,0,0,0.3);
    overflow-y: auto;
    z-index: 1000;
  }

  .nav-links.active {
    right: 0;
  }

  .nav-links a {
    font-size: 18px;
    padding: 15px;
    margin-left: 0;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    border-radius: 0;
  }

  .nav-links a:hover,
  .nav-links a.active {
    background-color: rgba(255,255,255,0.1);
    transform: none;
  }

  .feature-info {
    display: none;
  }

  /* === HEADLINE === */
  .headline {
    margin-top: 80px;
  }

  .headline .top,
  .headline .bottom {
    font-size: 40px;
  }

  .headline .middle {
    font-size: 52px;
  }

  /* === SPREADSHEET BUTTON === */
  .spreadsheet-button {
    font-size: 28px;
    padding: 25px 40px;
  }

  .spreadsheet-button .sub-text {
    font-size: 16px;
  }

  .spreadsheet-button .sub-sub-text {
    font-size: 22px;
  }

  /* === BESTSELLER === */
  .bestseller-section {
    margin: 50px auto;
  }

  .bestseller-section h2 {
    font-size: 2.5rem;
  }

  .bestseller-card {
    max-width: 65%;
    margin: 0 auto;
  }

  .bestseller-img {
    height: 500px;
  }

  .bestseller-info h3 {
    font-size: 1.6rem;
  }

  .bestseller-price {
    font-size: 2rem;
  }

  /* === JOIN SECTION === */
  .join-button {
    flex-direction: column;
    padding: 35px 25px;
    gap: 18px;
  }

  .join-text {
    font-size: 36px;
    margin: 0;
  }

  .offer {
    font-size: 18px;
  }

  /* === FAQ === */
  .faq-section h2 {
    font-size: 36px;
  }

  .faq-question {
    font-size: 18px;
    padding: 18px;
  }

  .faq-answer {
    font-size: 16px;
  }

  /* === NEWS === */
  .hipobuy-news h2 {
    font-size: 44px;
  }

  .hipobuy-news .news-items p {
    font-size: 20px;
  }

  .hipobuy-news .signup-button {
    padding: 20px 45px;
    font-size: 22px;
  }

  /* === FEEDBACK === */
  .feedback-section h2 {
    font-size: 36px;
  }

  .feedback-card {
    max-width: 100%;
  }

  .feedback-card p {
    font-size: 17px;
  }

  /* === CONTACT === */
  .contact-section h2 {
    font-size: 40px;
  }

  .contact-form input,
  .contact-form textarea {
    font-size: 15px;
    padding: 14px;
  }

  .contact-button {
    font-size: 19px;
    padding: 16px 32px;
  }

  .social-icons a img {
    width: 42px;
    height: 42px;
  }

  /* === PRODUCTS PAGE - OPTIMIZED === */
  .headline-products {
    font-size: 48px;
    margin-top: 30px;
  }

  .info-products {
    font-size: 18px;
    margin: 15px 20px 30px;
  }

  /* SEARCH - Compact */
  #searchContainer {
    margin: 25px auto 15px;
  }

  .search-wrapper {
    width: 90%;
    max-width: 500px;
  }

  #searchInput {
    font-size: 16px;
    padding: 12px 45px 12px 15px;
  }

  #searchButton {
    font-size: 18px;
  }

  /* FILTERS - Compact */
  .product-filters {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin: 15px auto 35px;
    flex-wrap: wrap;
    padding: 0 20px;
    max-width: 850px;
  }

  .product-filters input[type="number"],
  .product-filters select,
  .product-filters button#applyFilter {
    padding: 10px 12px;
    font-size: 14px;
    border: 2px solid #ccc;
    outline: none;
    border-radius: 8px;
    transition: all 0.3s;
  }

  .product-filters input[type="number"] {
    width: 90px;
    font-weight: 500;
  }

  .product-filters select {
    min-width: 140px;
    cursor: pointer;
    font-weight: 500;
  }

  .product-filters button#applyFilter {
    background-color: #D22B2B;
    color: white;
    font-weight: bold;
    border: 2px solid #D22B2B;
    cursor: pointer;
    padding: 10px 20px;
    min-width: 90px;
  }

  /* PRODUCT GRID - ALWAYS 2 SIDE BY SIDE */
  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
    padding: 30px 15px;
  }

  .product-card {
    padding: 18px;
  }

  .product-card img {
    height: 180px;
  }

  .product-card h3 {
    font-size: 15px;
  }

  .product-card p.price {
    font-size: 18px;
  }

  /* === PRODUCT DETAIL === */
  .product-card-detail {
    margin: 40px auto 40px;
    flex-direction: column;
  }

  .product-info-left {
    width: 100%;
    padding: 30px;
  }

  .product-info-box {
    width: 100%;
    padding: 30px 25px;
  }

  .product-title {
    font-size: 32px;
    margin-top: 30px;
  }

  #productPrice {
    font-size: 36px;
    margin: 25px 0;
  }

  .buy-button {
    width: 80%;
    padding: 18px 0;
    font-size: 19px;
    margin-top: 25px;
  }

  .product-features {
    flex-direction: row;
    gap: 15px;
    margin-top: 25px;
    flex-wrap: wrap;
    justify-content: center;
  }

  .join-button-top-right {
    position: relative;
    top: 0;
    right: 0;
    margin: 20px;
    width: calc(100% - 40px);
    font-size: 14px;
    padding: 10px 16px;
  }

  .back-button {
    left: 15px;
    top: 40px;
    padding: 8px 14px;
    font-size: 15px;
  }

  /* === RELATED PRODUCTS - 2 side by side === */
  .related-products {
    margin: 50px auto;
    padding: 15px;
  }

  .related-products h2 {
    font-size: 28px;
    margin-bottom: 25px;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }

  .related-card {
    padding: 15px;
  }

  .related-card img {
    height: 160px;
  }

  .related-card h3 {
    font-size: 15px;
  }

  .related-card p {
    font-size: 17px;
  }

  /* === PAGINATION === */
  .pagination-container {
    gap: 18px;
    margin: 40px 0;
  }

  #prevPage,
  #nextPage {
    padding: 12px 22px;
    font-size: 17px;
  }

  #backToTop {
    top: 20px;
    right: 18px;
    padding: 10px 14px;
    font-size: 15px;
  }

  /* === PRODUCT DETAIL - BRAND/CATEGORY === */
  .product-brand,
  .product-category {
    font-size: 16px;
  }
}

/* ==========================================
   MOBILE (max-width: 768px)
========================================== */
@media (max-width: 768px) {
  /* === NEW HEADER === */
  .headbar-new {
    padding: 10px 20px;
    grid-template-columns: auto 1fr auto;
  }

  .logo-new {
    font-size: 18px;
  }

  .sale-countdown-btn {
    padding: 4px 8px;
    gap: 6px;
    flex-direction: row;
  }

  .sale-offer {
    font-size: 10px;
  }

  .countdown-timer {
    font-size: 10px;
    letter-spacing: 0.2px;
  }

  .claim-btn-compact {
    padding: 3px 8px;
    font-size: 9px;
  }

  .burger-menu-new {
    width: 26px;
    height: 20px;
  }

  .nav-menu-new {
    width: 100%;
    top: 56px;
    border-radius: 0;
  }

  body {
    padding-top: 20px;
  }

  .headline-info-bar {
    top: 44px;
    padding: 8px 15px;
    font-size: 12px;
  }

  .viewer-info #viewer-count {
    font-size: 14px;
  }

  .hero-clean {
    padding: 70px 20px 40px;
  }

  /* === HERO - CLEAN === */
  .hero-badge {
    font-size: 13px;
    padding: 8px 20px;
    margin-bottom: 20px;
  }

  .hero-clean-title {
    font-size: 36px;
    letter-spacing: -0.3px;
  }

  .hero-clean-title::after {
    width: 80px;
    height: 4px;
    margin: 16px auto 0;
  }

  .hero-clean-subtitle {
    font-size: 17px;
  }

  .hero-clean-button {
    padding: 22px 50px;
    font-size: 19px;
  }

  /* === SECTION TITLES === */
  .section-clean-title {
    font-size: 28px;
  }

  /* === BESTSELLER === */
  .bestseller-card-modern {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 30px;
  }

  .bestseller-image img {
    height: 300px;
  }

  .bestseller-content h3 {
    font-size: 24px;
  }

  .bestseller-price {
    font-size: 28px;
  }

  .carousel-clean-nav {
    width: 40px;
    height: 40px;
  }

  /* === JOIN === */
  .join-clean-benefits {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .benefit-clean {
    padding: 24px 20px;
  }

  /* === FAQ === */
  .faq-question {
    font-size: 15px;
    padding: 16px 20px;
  }

  .faq-answer {
    font-size: 14px;
  }

  /* === PRODUCT DETAIL - MODERN === */
  .product-back-nav {
    margin-top: 20px;
  }

  .product-detail-wrapper {
    padding: 30px 20px 20px 20px;
    gap: 30px;
    border-radius: 16px;
  }

  .product-image-wrapper {
    padding: 20px;
    min-height: 300px;
  }

  .product-detail-title {
    font-size: 28px;
  }

  .product-detail-price {
    font-size: 36px;
  }

  .product-features-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .product-buy-button {
    font-size: 16px;
    padding: 16px 24px;
  }

  .product-register-button {
    font-size: 15px;
    padding: 14px 24px;
  }

  .related-products-header h2 {
    font-size: 32px;
  }

  .related-products-grid-modern {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .related-card img {
    height: 180px;
  }

  .related-card h3 {
    font-size: 15px;
    margin: 12px 12px 6px;
  }

  .related-card p {
    font-size: 18px;
    margin: 0 12px 12px;
  }

  /* === PRODUCTS PAGE - MODERN === */
  .products-hero {
    padding: 30px 20px 40px;
  }

  .products-hero-title {
    font-size: 40px;
  }

  .products-hero-subtitle {
    font-size: 16px;
  }

  .products-search-section {
    position: static;
    padding: 30px 20px;
  }

  .products-search-bar {
    flex-direction: column;
    padding: 12px;
    border-radius: 16px;
    gap: 8px;
  }

  .products-search-bar input {
    width: 100%;
    padding: 12px;
  }

  .search-button-modern {
    width: 100%;
    padding: 14px;
  }

  .products-filter-bar {
    grid-template-columns: 1fr;
  }

  .price-inputs {
    flex-direction: column;
  }

  .price-separator {
    display: none;
  }

  .products-main {
    padding: 40px 20px;
  }

  .products-grid-modern {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .products-grid-modern .product-card img {
    height: 200px;
  }

  .products-grid-modern .product-card h3 {
    font-size: 15px;
    margin: 12px 16px 6px;
  }

  .products-grid-modern .product-card .price {
    font-size: 19px;
    margin: 0 16px 16px;
  }

  .products-pagination {
    padding: 40px 20px;
  }

  .pagination-button {
    padding: 12px 20px;
    font-size: 14px;
  }

  .page-info {
    font-size: 14px;
    padding: 12px 16px;
  }

  .back-to-top-modern {
    width: 48px;
    height: 48px;
    bottom: 20px;
    right: 20px;
  }

  /* === HOMEPAGE - MODERN === */
  .hero-section {
    padding: 80px 20px 60px;
  }

  .hero-title-top,
  .hero-title-bottom {
    font-size: 20px;
  }

  .hero-title-main {
    font-size: 40px;
  }

  .hero-subtitle {
    font-size: 16px;
  }

  .hero-features {
    gap: 24px;
  }

  .bestsellers-section {
    padding: 60px 20px;
  }

  .section-title {
    font-size: 32px;
  }

  .bestseller-card-modern {
    padding: 24px;
  }

  .bestseller-image img {
    height: 300px;
  }

  .bestseller-content h3 {
    font-size: 24px;
  }

  .bestseller-price {
    font-size: 28px;
  }

  .carousel-nav {
    width: 40px;
    height: 40px;
  }

  .join-section-modern {
    padding: 60px 20px;
  }

  .join-title {
    font-size: 36px;
  }

  .benefit-item {
    padding: 24px 16px;
  }

  .faq-question {
    font-size: 16px;
    padding: 20px;
  }

  .contact-form-wrapper {
    padding: 24px;
  }

  /* === POPUP - MOBILE === */
  .welcome-popup-modal {
    padding: 30px 20px;
    max-width: 95%;
  }

  .popup-title {
    font-size: 26px;
  }

  .popup-subtitle {
    font-size: 14px;
  }

  .benefit-icon {
    font-size: 28px;
  }

  .benefit-text h3 {
    font-size: 15px;
  }

  .benefit-text p {
    font-size: 12px;
  }

  .popup-claim-btn {
    font-size: 16px;
    padding: 16px;
  }

  .popup-trust {
    gap: 10px;
  }

  .popup-trust span {
    font-size: 11px;
  }
}

/* ==========================================
   SMALL MOBILE (max-width: 480px)
========================================== */
@media (max-width: 480px) {
  /* === HEADLINE === */
  .headline .top,
  .headline .bottom {
    font-size: 22px;
  }

  .headline .middle {
    font-size: 28px;
  }

  /* === SPREADSHEET BUTTON === */
  .spreadsheet-button {
    font-size: 18px;
    padding: 18px 25px;
  }

  .spreadsheet-button .sub-text {
    font-size: 12px;
  }

  .spreadsheet-button .sub-sub-text {
    font-size: 16px;
  }

  /* === JOIN === */
  .join-text {
    font-size: 24px;
  }

  .offer {
    font-size: 14px;
  }

  /* === NEWS === */
  .hipobuy-news h2 {
    font-size: 28px;
  }

  .hipobuy-news .news-items p {
    font-size: 16px;
  }

  .hipobuy-news .signup-button {
    padding: 15px 35px;
    font-size: 18px;
  }

  /* === FAQ === */
  .faq-question {
    font-size: 14px;
    padding: 12px;
  }

  .faq-answer {
    font-size: 13px;
  }

  /* === PRODUCTS PAGE - Keep 2 columns === */
  .headline-products {
    font-size: 32px;
    margin-top: 30px;
  }

  .info-products {
    font-size: 16px;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 20px 10px;
  }

  .product-card {
    padding: 12px;
  }

  .product-card img {
    height: 140px;
  }

  .product-card h3 {
    font-size: 13px;
  }

  .product-card p.price {
    font-size: 16px;
  }

  /* === RELATED PRODUCTS - Also 2 === */
  .related-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .related-card {
    padding: 12px;
  }

  .related-card img {
    height: 140px;
  }

  .related-card h3 {
    font-size: 14px;
  }

  .related-card p {
    font-size: 16px;
  }

  /* === CONTACT === */
  .contact-section h2 {
    font-size: 28px;
  }

  /* === FEEDBACK === */
  .feedback-section h2 {
    font-size: 28px;
  }

  /* === BESTSELLER === */
  .bestseller-section h2 {
    font-size: 1.5rem;
  }

  /* === PRODUCT DETAIL - BRAND/CATEGORY === */
  .product-brand,
  .product-category {
    font-size: 15px;
  }

  /* === PRODUCT DETAIL - MODERN === */
  .product-detail-title {
    font-size: 24px;
  }

  .product-detail-price {
    font-size: 32px;
  }

  .product-buy-button,
  .product-register-button {
    font-size: 15px;
    padding: 14px 20px;
  }

  .related-products-header h2 {
    font-size: 28px;
  }

  .related-card img {
    height: 160px;
  }

  /* === PRODUCTS PAGE - MODERN === */
  .products-hero-title {
    font-size: 32px;
  }

  .products-hero-subtitle {
    font-size: 15px;
  }

  .products-grid-modern .product-card img {
    height: 160px;
  }

  .products-grid-modern .product-card h3 {
    font-size: 14px;
  }

  .products-grid-modern .product-card .price {
    font-size: 18px;
  }

  .pagination-button span {
    display: none;
  }

  /* === HOMEPAGE - MODERN === */
  .hero-title-main {
    font-size: 32px;
  }

  .hero-cta-button {
    font-size: 16px;
    padding: 14px 28px;
  }

  .bestseller-image img {
    height: 250px;
  }

  .carousel-nav.prev,
  .carousel-nav.next {
    display: none;
  }

  .join-title {
    font-size: 28px;
  }
}
