/* Additional responsive styles for specific elements */

/* ===== PAGE LOADER ===== */
.page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-color);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.page-loader.hidden {
    opacity: 0;
    visibility: hidden;
}

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

.loader-logo {
    width: 120px;
    height: auto;
    margin-bottom: 30px;
    animation: pulse 2s infinite;
}

.loader-text {
    color: var(--white);
    font-size: 1.2rem;
    margin-bottom: 20px;
    font-family: 'Playfair Display', serif;
}

.loader-bar {
    width: 200px;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin: 0 auto;
}

.loader-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    width: 0%;
    animation: loading 2s ease-in-out infinite;
}

@keyframes pulse {
    0% { opacity: 0.6; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1); }
    100% { opacity: 0.6; transform: scale(0.95); }
}

@keyframes loading {
    0% { width: 0%; transform: translateX(-100%); }
    50% { width: 100%; transform: translateX(0%); }
    100% { width: 0%; transform: translateX(100%); }
}

/* ===== TOAST NOTIFICATIONS ===== */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9998;
    max-width: 400px;
}

.toast {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 20px;
    margin-bottom: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 15px;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    border-left: 4px solid var(--primary-color);
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    border-left-color: #34A853;
}

.toast.error {
    border-left-color: #EA4335;
}

.toast.warning {
    border-left-color: #FBBC05;
}

.toast.info {
    border-left-color: #4285F4;
}

.toast-icon {
    font-size: 1.5rem;
}

.toast.success .toast-icon {
    color: #34A853;
}

.toast.error .toast-icon {
    color: #EA4335;
}

.toast.warning .toast-icon {
    color: #FBBC05;
}

.toast.info .toast-icon {
    color: #4285F4;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--dark-color);
}

.toast-message {
    color: var(--text-light);
    font-size: 0.9rem;
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

/* ===== SKELETON LOADING ===== */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 4px;
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-card {
    height: 400px;
    border-radius: var(--border-radius);
}

.skeleton-title {
    height: 24px;
    width: 70%;
    margin-bottom: 15px;
}

.skeleton-text {
    height: 16px;
    width: 100%;
    margin-bottom: 10px;
}

.skeleton-text.short {
    width: 50%;
}

/* ===== MOBILE MENU ENHANCEMENTS ===== */
@media (max-width: 992px) {
    .main-navigation {
        padding-top: 120px;
    }
    
    .mobile-menu-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 998;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
    }
    
    .mobile-menu-overlay.active {
        opacity: 1;
        visibility: visible;
    }
    
    .nav-link {
        font-size: 16px;
    }
    
    .dropdown-content a {
        padding: 12px 20px;
        font-size: 14px;
    }
}

/* ===== TOUCH DEVICE OPTIMIZATIONS ===== */
@media (hover: none) and (pointer: coarse) {
    .btn:hover {
        transform: none;
    }
    
    .feature-card:hover {
        transform: none;
    }
    
    .package-card:hover {
        transform: none;
    }
    
    .destination-card:hover {
        transform: none;
    }
    
    .review-card:hover {
        transform: none;
    }
    
    .nav-link:hover {
        background: transparent;
    }
    
    .dropdown:hover .dropdown-content {
        opacity: 0;
        visibility: hidden;
    }
    
    .dropdown.active .dropdown-content {
        opacity: 1;
        visibility: visible;
    }
}

/* ===== PRINT STYLES ===== */
@media print {
    .top-bar,
    .mobile-menu-btn,
    .book-now-btn,
    .back-to-top,
    .footer-social-icons,
    .newsletter,
    .slider-nav,
    .packages-slider-nav {
        display: none !important;
    }
    
    .hero {
        min-height: auto;
        padding: 50px 0;
        background: none !important;
        color: var(--dark-color);
    }
    
    .hero:before {
        display: none;
    }
    
    section {
        padding: 50px 0;
        page-break-inside: avoid;
    }
    
    .btn {
        background: none !important;
        color: var(--dark-color) !important;
        border: 1px solid var(--dark-color);
        box-shadow: none !important;
    }
    
    a {
        text-decoration: underline;
        color: var(--dark-color);
    }
    
    .footer-bottom {
        border-top: 1px solid var(--dark-color);
        color: var(--dark-color);
    }
}

/* ===== DARK MODE SUPPORT ===== */
@media (prefers-color-scheme: dark) {
    body:not(.light-mode) {
        background: #1a1a1a;
        color: #e0e0e0;
    }
    
    body:not(.light-mode) .hero {
        background: linear-gradient(rgba(26, 26, 26, 0.9), rgba(26, 26, 26, 0.95));
    }
    
    body:not(.light-mode) .feature-card,
    body:not(.light-mode) .package-card,
    body:not(.light-mode) .testimonial-card,
    body:not(.light-mode) .review-card,
    body:not(.light-mode) .contact-info-card,
    body:not(.light-mode) .tour-card {
        background: #2a2a2a;
        color: #e0e0e0;
    }
    
    body:not(.light-mode) .section-title h2,
    body:not(.light-mode) .package-title h3,
    body:not(.light-mode) .testimonial-info h4,
    body:not(.light-mode) .reviewer-details h4 {
        color: #ffffff;
    }
    
    body:not(.light-mode) .section-title p,
    body:not(.light-mode) .package-features span,
    body:not(.light-mode) .testimonial-text,
    body:not(.light-mode) .review-text {
        color: #b0b0b0;
    }
}

/* ===== HIGH CONTRAST MODE ===== */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #b35900;
        --secondary-color: #ffaa00;
        --dark-color: #000000;
        --light-color: #ffffff;
        --text-color: #000000;
        --text-light: #333333;
        --white: #ffffff;
    }
    
    .btn {
        border: 2px solid var(--dark-color);
    }
    
    .nav-link {
        border: 1px solid transparent;
    }
    
    .nav-link:hover,
    .nav-link.active {
        border-color: var(--primary-color);
    }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .feature-icon,
    .package-img img,
    .destination-card img,
    .tour-card-image img {
        transition: none !important;
    }
    
    .btn:hover,
    .feature-card:hover,
    .package-card:hover,
    .destination-card:hover,
    .review-card:hover,
    .contact-info-card:hover,
    .tour-card:hover {
        transform: none !important;
    }
}

/* ===== LARGE TEXT MODE ===== */
@media (prefers-reduced-data: no-preference) {
    body {
        font-size: clamp(16px, 2vw, 18px);
    }
    
    .section-title h2 {
        font-size: clamp(2rem, 5vw, 3rem);
    }
    
    .hero h1 {
        font-size: clamp(2.5rem, 6vw, 4.5rem);
    }
}

/* ===== SMALL SCREEN OPTIMIZATIONS ===== */
@media (max-width: 375px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-btns {
        flex-direction: column;
        gap: 15px;
    }
    
    .hero-btns .btn {
        width: 100%;
        justify-content: center;
    }
    
    .package-features ul {
        grid-template-columns: 1fr;
    }
    
    .tour-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .tour-actions .btn {
        width: 100%;
        justify-content: center;
    }
    
    .contact-form-wrapper {
        padding: 20px 15px;
    }
}

/* ===== LANDSCAPE ORIENTATION ===== */
@media (orientation: landscape) and (max-height: 500px) {
    .hero {
        min-height: 120vh;
    }
    
    .mobile-menu-btn {
        width: 45px;
        height: 45px;
    }
    
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

/* ===== TABLET OPTIMIZATIONS ===== */
@media (min-width: 768px) and (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tour-packages-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .destinations-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== DESKTOP LARGE SCREENS ===== */
@media (min-width: 1600px) {
    .container {
        max-width: 1400px;
    }
    
    .hero h1 {
        font-size: 5rem;
    }
    
    .section-title h2 {
        font-size: 3.5rem;
    }
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* ===== SELECTION STYLES ===== */
::selection {
    background: var(--primary-color);
    color: var(--white);
}

::-moz-selection {
    background: var(--primary-color);
    color: var(--white);
}

/* ===== FOCUS VISIBLE ===== */
:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* ===== ACCESSIBILITY IMPROVEMENTS ===== */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: #f1f1f1;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #21759b;
    display: block;
    font-size: 14px;
    font-weight: bold;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}
