/* ============================================
   Responsive Breakpoints
   Mobile-first approach
   ============================================ */

/* ---- Max 1200px ---- */
@media (max-width: 1200px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }

    .hero-slide-content h1 {
        font-size: 3.2rem;
    }

    .countdown-value {
        font-size: 3.5rem;
    }
}

/* ---- Max 1024px (Tablet Landscape) ---- */
@media (max-width: 1024px) {
    .main-nav {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .header-container {
        height: 140px;
    }

    .site-logo img {
        height: 120px;
    }

    .site-header.scrolled .site-logo img {
        height: 96px;
    }

    .site-logo-name {
        display: block;
        font-size: 1.15rem;
        letter-spacing: 1.5px;
    }

    .lang-switcher {
        display: none;
    }

    .hero-section {
        margin-top: 140px;
        height: 520px;
    }

    .hero-slide-content {
        padding: 0 40px;
    }

    .hero-slide-content h1 {
        font-size: 2.8rem;
    }

    .section {
        padding: 80px 0;
    }

    .section-header h2 {
        font-size: 2.2rem;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .archive-timeline::before {
        left: 20px;
    }

    .archive-item:nth-child(odd),
    .archive-item:nth-child(even) {
        padding-left: 60px;
        padding-right: 0;
        justify-content: flex-start;
    }

    .archive-item-dot {
        left: 20px;
    }
}

/* ---- Max 768px (Tablet Portrait) ---- */
@media (max-width: 768px) {
    .hero-section {
        min-height: 500px;
        height: 80vh;
    }

    .hero-slide-content {
        padding: 0 24px;
        bottom: auto;
        top: 18%;
    }

    .hero-slide-content h1 {
        font-size: 2.2rem;
    }

    .hero-slide-content p {
        font-size: 1rem;
    }

    .hero-arrow {
        width: 40px;
        height: 40px;
        font-size: 0.9rem;
    }

    .hero-arrow.prev { left: 15px; }
    .hero-arrow.next { right: 15px; }

    .section {
        padding: 60px 0;
    }

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

    .section-header h2 {
        font-size: 1.9rem;
    }

    .countdown-grid {
        gap: 20px;
    }

    .countdown-value {
        font-size: 2.8rem;
    }

    .countdown-label {
        font-size: 0.75rem;
        letter-spacing: 2px;
    }

    .countdown-separator {
        font-size: 2.2rem;
    }

    .race-cards {
        grid-template-columns: 1fr;
        max-width: 450px;
        margin: 0 auto;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .footer-col h4::after {
        left: 50%;
        transform: translateX(-50%);
    }

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

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

    .footer-links a {
        justify-content: center;
    }

    .footer-contact-list a,
    .footer-address {
        justify-content: center;
    }

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

    .page-title-section {
        padding: 60px 0 40px;
        margin-top: 80px;
    }

    .page-title-section h1 {
        font-size: 2rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    #route-map,
    .route-map {
        height: 350px;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    }

    .story-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .story-image img,
    .story-image-placeholder {
        height: 300px;
    }

    .story-content {
        text-align: center;
    }

    .route-switcher {
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 8px;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
    }

    .route-switch-btn {
        flex-shrink: 0;
        font-size: 0.82rem;
        padding: 8px 16px;
    }

    .video-placeholder {
        padding: 50px 20px;
    }

    .hero-floating-elements {
        display: none;
    }
}

/* ---- Max 480px (Mobile) ---- */
@media (max-width: 480px) {
    html {
        font-size: 15px;
    }

    .header-container {
        padding: 0 16px;
        height: 70px;
    }

    .site-logo img {
        height: 55px;
    }

    .site-header.scrolled .site-logo img {
        height: 45px;
    }

    .hero-section {
        margin-top: 70px;
        min-height: 450px;
        height: 70vh;
    }

    .page-title-section {
        padding: 50px 0 30px;
        margin-top: 70px;
    }

    .hero-slide-content {
        bottom: auto;
        top: 12%;
        padding: 0 20px;
    }

    .hero-slide-content h1 {
        font-size: 1.7rem;
    }

    .hero-slide-content p {
        font-size: 0.9rem;
        margin-bottom: 20px;
    }

    .hero-slide-btns {
        flex-direction: column;
        gap: 10px;
    }

    .hero-slide-btns .btn {
        width: 100%;
        justify-content: center;
    }

    .hero-dots {
        bottom: 20px;
    }

    .hero-dot {
        width: 8px;
        height: 8px;
    }

    .hero-dot.active {
        width: 24px;
    }

    .countdown-section {
        padding: 50px 0;
    }

    .countdown-grid {
        gap: 14px;
    }

    .countdown-item {
        min-width: 70px;
    }

    .countdown-value {
        font-size: 2rem;
    }

    .countdown-separator {
        font-size: 1.5rem;
        padding-top: 4px;
    }

    .section {
        padding: 50px 0;
    }

    .section-header h2 {
        font-size: 1.6rem;
    }

    .story-section {
        padding: 50px 0;
    }

    .story-grid {
        gap: 24px;
    }

    .story-image img,
    .story-image-placeholder {
        height: 240px;
    }

    .story-content h2 {
        font-size: 1.5rem;
    }

    .story-content p {
        font-size: 0.9rem;
    }

    .story-btn {
        width: 100%;
        justify-content: center;
    }

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

    .btn {
        padding: 11px 22px;
        font-size: 0.85rem;
    }

    .btn-lg {
        padding: 13px 28px;
        font-size: 0.9rem;
    }

    .btn-register {
        display: none;
    }

    .lang-btn span {
        display: none;
    }

    .contact-form {
        padding: 24px;
    }

    .security-question-wrap {
        flex-direction: column;
    }

    .security-question-box {
        justify-content: center;
        min-width: auto;
        padding: 10px 16px;
    }

    .security-answer-input {
        padding: 12px !important;
        text-align: center;
    }

    #route-map,
    .route-map {
        height: 300px;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .race-card-image {
        height: 180px;
    }

    .race-card-body {
        padding: 20px;
    }

    .race-card-actions {
        flex-direction: column;
    }

    .back-to-top {
        bottom: 16px;
        right: 16px;
        width: 42px;
        height: 42px;
    }

    .mobile-nav {
        width: 100%;
    }
}

/* ---- Print ---- */
@media print {
    .site-header,
    .site-footer,
    .back-to-top,
    #preloader,
    .mobile-nav,
    .mobile-nav-overlay {
        display: none !important;
    }

    main {
        padding-top: 0 !important;
    }

    .section {
        padding: 20px 0;
    }
}

/* ============================================================
   RESPONSIVE — Sponsors
   ============================================================ */
@media (max-width: 768px) {
    .sponsor-grid {
        gap: 12px;
    }

    .sponsor-item {
        padding: 10px 14px;
        width: 130px;
        height: 90px;
        justify-content: center;
    }

    .sponsor-item img {
        height: 65px;
        max-width: 105px;
    }

    .sponsor-name {
        display: none;
    }

    .sponsor-tier[data-tier="platinum"] .sponsor-item img,
    .sponsor-tier[data-tier="gold"] .sponsor-item img,
    .sponsor-tier[data-tier="silver"] .sponsor-item img,
    .sponsor-tier[data-tier="bronze"] .sponsor-item img { height: 65px; max-width: 105px; }
}

@media (max-width: 480px) {
    .sponsor-item {
        padding: 8px 12px;
        width: 110px;
        height: 78px;
    }

    .sponsor-item img {
        height: 55px;
        max-width: 88px;
    }

    .sponsor-name {
        display: none;
    }

    .sponsor-tier[data-tier="platinum"] .sponsor-item img,
    .sponsor-tier[data-tier="gold"] .sponsor-item img,
    .sponsor-tier[data-tier="silver"] .sponsor-item img,
    .sponsor-tier[data-tier="bronze"] .sponsor-item img { height: 55px; max-width: 88px; }
}

/* ============================================================
   RESPONSIVE — Ticker Band
   ============================================================ */
@media (max-width: 768px) {
    .ticker-outer {
        height: 80px;
        margin-top: -40px;
    }

    .ticker-band {
        padding: 10px 0;
        left: -12%;
        width: 124%;
    }

    .ticker-band-yellow {
        top: -25px;
    }

    .ticker-band-white {
        top: 25px;
    }

    .ticker-item {
        font-size: 0.75rem;
        padding: 0 18px;
    }
}

@media (max-width: 480px) {
    .ticker-outer {
        height: 70px;
        margin-top: -30px;
    }

    .ticker-band-yellow {
        top: -14px;
    }

    .ticker-band-white {
        top: 14px;
    }

    .ticker-item {
        font-size: 0.68rem;
        padding: 0 14px;
    }
}

/* ============================================================
   RESPONSIVE — Countdown v2
   ============================================================ */
@media (max-width: 1024px) {
    .cd2-info-bar {
        gap: 6px;
    }

    .cd2-info-item {
        padding: 0 12px;
        font-size: 0.82rem;
    }
}

@media (max-width: 768px) {
    .countdown-section-v2 {
        padding-bottom: 48px;
    }

    .cd2-info-bar {
        padding: 16px 12px;
        margin-bottom: 36px;
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px 0;
    }

    .cd2-info-item {
        font-size: 0.78rem;
        padding: 4px 10px;
        white-space: nowrap;
    }

    .cd2-info-divider {
        display: none;
    }

    .cd2-grid {
        gap: 12px 24px;
    }

    .cd2-item {
        min-width: 80px;
    }

    .cd2-value {
        font-size: clamp(56px, 18vw, 90px);
        -webkit-text-stroke-width: 2px;
    }

    .cd2-label {
        font-size: 0.65rem;
        letter-spacing: 0.15em;
        margin-top: 8px;
    }

    .cd2-sep {
        font-size: clamp(44px, 14vw, 72px);
        -webkit-text-stroke-width: 2px;
    }
}

@media (max-width: 480px) {
    .cd2-info-bar {
        padding: 12px 8px;
        gap: 4px 0;
    }

    .cd2-info-item {
        font-size: 0.72rem;
        padding: 3px 8px;
        gap: 5px;
    }

    .cd2-info-item i {
        font-size: 0.75rem;
    }
}

@media (max-width: 400px) {
    .cd2-grid {
        gap: 8px 16px;
    }

    .cd2-value {
        font-size: clamp(48px, 20vw, 72px);
        -webkit-text-stroke-width: 1.5px;
    }

    .cd2-sep {
        font-size: clamp(36px, 16vw, 56px);
        -webkit-text-stroke-width: 1.5px;
    }
}

/* ============================================================
   RESPONSIVE — Route Modern Section
   ============================================================ */
@media (max-width: 1024px) {
    .route-modern-inner {
        grid-template-columns: 300px 1fr;
    }

    .route-modern-left {
        padding: 36px 24px;
    }

    .route-modern-header h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .route-modern-inner {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto;
    }

    .route-modern-left {
        padding: 32px 20px 24px;
        order: 2;
    }

    .route-modern-left::after {
        display: none;
    }

    .route-modern-right {
        order: 1;
        min-height: 260px;
    }

    .route-carousel {
        min-height: 260px;
    }

    .route-modern-nav {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 8px;
    }

    .route-modern-btn {
        border: 1px solid rgba(255,255,255,0.12);
        border-bottom: 1px solid rgba(255,255,255,0.12) !important;
        border-top: none !important;
        border-radius: 8px;
        padding: 12px 14px;
        background: rgba(255,255,255,0.04);
    }

    .route-modern-btn:hover {
        padding-left: 14px;
    }

    .route-modern-btn.active {
        background: rgba(244,162,97,0.1);
        border-color: rgba(244,162,97,0.3) !important;
    }

    .rmb-num {
        font-size: 0.9rem;
    }

    .rmb-name {
        font-size: 0.82rem;
    }

    .rmb-arrow {
        display: none;
    }

    .route-modern-arrows {
        display: none;
    }

    .route-detail-btn {
        font-size: 0.75rem;
        padding: 8px 16px;
        top: 14px;
        left: 14px;
    }
}

@media (max-width: 480px) {
    .route-modern-nav {
        grid-template-columns: 1fr 1fr;
    }

    .rmb-name {
        font-size: 0.75rem;
        letter-spacing: 0.03em;
    }
}

