/* ============================================
   NANMOLEK TOURISM - MAIN STYLESHEET
   ============================================ */

/* Reset & Base */
* { margin: 0; padding: 0; box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    overflow-y: auto !important;
}

body {
    font-family: var(--font, 'Poppins', sans-serif);
    font-size: var(--font-size, 16px);
    color: var(--text, #2d3436);
    line-height: 1.6;
    overflow-x: hidden;
    overflow-y: auto !important;
    min-height: 100vh;
}

.container {
    max-width: var(--container, 1200px);
    margin: 0 auto;
    padding: 0 20px;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.navbar.scrolled {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: var(--container, 1200px);
    margin: 0 auto;
    padding: 0 20px;
    height: 70px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}

.logo-icon {
    width: 42px;
    height: 42px;
    background: var(--primary, #0066cc);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.logo-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--heading, #1a1a2e);
}

.logo-subtitle {
    font-size: 11px;
    color: #666;
}

.nav-menu-wrapper {
    display: flex;
    align-items: center;
}

.nav-menu {
    display: flex;
    gap: 3px;
    list-style: none;
}

.nav-link {
    padding: 10px 15px;
    color: #333;
    font-weight: 500;
    font-size: 14px;
    border-radius: 8px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    text-decoration: none;
}

.nav-link i { font-size: 12px; }

.nav-link:hover,
.nav-link.active {
    color: var(--primary, #0066cc);
    background: rgba(0,102,204,0.08);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: #333;
    transition: all 0.3s;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border: none;
    background: #f5f5f5;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #333;
    transition: all 0.2s;
}

.btn-icon:hover {
    background: var(--primary, #0066cc);
    color: white;
}

/* ============================================
   SEARCH OVERLAY
   ============================================ */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.search-overlay.active {
    display: flex;
}

.search-container {
    width: 90%;
    max-width: 600px;
    position: relative;
}

.search-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 40px;
    cursor: pointer;
    line-height: 1;
}

.search-form {
    width: 100%;
}

.search-input-group {
    display: flex;
    background: white;
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.search-icon {
    padding: 15px 20px;
    color: #999;
    font-size: 18px;
}

.search-input-group input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 18px;
    padding: 15px 0;
    font-family: inherit;
}

.search-submit {
    padding: 15px 30px;
    background: var(--primary, #0066cc);
    border: none;
    color: white;
    font-weight: 600;
    cursor: pointer;
    font-size: 16px;
    font-family: inherit;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-section {
    position: relative;
    height: 85vh;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="rgba(255,255,255,0.05)" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,112C672,96,768,96,864,112C960,128,1056,160,1152,160C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
    background-size: cover;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    padding: 20px;
    max-width: 800px;
}

.hero-content h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.3);
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.btn-explore {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 30px;
    background: white;
    color: var(--primary, #0066cc);
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-explore:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

/* ============================================
   SECTIONS
   ============================================ */
section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--heading, #1a1a2e);
    margin-bottom: 0.5rem;
}

.section-header p {
    font-size: 1.1rem;
    color: #666;
}

/* ============================================
   DESTINATIONS GRID
   ============================================ */
.destinations-section {
    background: #f9fafb;
}

.destinations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px;
}

.destination-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: all 0.3s;
    cursor: pointer;
}

.destination-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.card-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.destination-card:hover .card-image img {
    transform: scale(1.08);
}

.no-image {
    width: 100%;
    height: 100%;
    background: #e8edf2;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    color: #c0c7cf;
}

.category-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 16px;
    background: var(--primary, #0066cc);
    color: white;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    z-index: 1;
}

.card-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.destination-card:hover .card-overlay {
    opacity: 1;
}

.btn-explore-card {
    padding: 12px 25px;
    background: white;
    color: var(--primary, #0066cc);
    border-radius: 25px;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-content {
    padding: 20px;
}

.card-content h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--heading, #1a1a2e);
}

.location {
    color: #888;
    font-size: 0.9rem;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.description {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ============================================
   EVENTS SECTION
   ============================================ */
.events-section {
    background: white;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.event-card {
    background: #f9fafb;
    border-radius: 16px;
    padding: 25px;
    display: flex;
    gap: 20px;
    align-items: center;
    transition: all 0.3s;
    box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}

.event-card:hover {
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    transform: translateY(-3px);
}

.event-date-box {
    text-align: center;
    min-width: 70px;
    background: var(--primary, #0066cc);
    color: white;
    padding: 15px 10px;
    border-radius: 12px;
}

.event-date-box .date {
    font-size: 28px;
    font-weight: 700;
    display: block;
    line-height: 1;
}

.event-date-box .month {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
}

.event-info h3 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.event-info p {
    color: #888;
    font-size: 0.9rem;
}

/* ============================================
   GALLERY PREVIEW
   ============================================ */
.gallery-preview {
    background: #f9fafb;
}

.gallery-masonry {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 15px;
    grid-auto-rows: 200px;
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    opacity: 0;
    transition: opacity 0.3s;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-outline {
    display: inline-block;
    padding: 12px 30px;
    border: 2px solid var(--primary, #0066cc);
    color: var(--primary, #0066cc);
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
}

.btn-outline:hover {
    background: var(--primary, #0066cc);
    color: white;
}

.btn-primary {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary, #0066cc);
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,102,204,0.3);
}

/* ============================================
   PAGE HEADER
   ============================================ */
.page-header {
    position: relative;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.page-header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    padding: 60px 0 0;
    margin-top: 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer h4 {
    font-size: 1.1rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--primary, #0066cc);
}

.footer ul li {
    margin-bottom: 12px;
}

.footer a {
    opacity: 0.85;
    transition: all 0.2s;
}

.footer a:hover {
    opacity: 1;
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.social-links a:hover {
    background: var(--primary, #0066cc);
    transform: translateY(-3px);
}

.footer-contact ul li {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-contact ul li i {
    color: var(--primary, #0066cc);
    width: 20px;
}

.footer-bottom {
    padding: 25px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.8;
}

/* ============================================
   BACK TO TOP
   ============================================ */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    background: var(--primary, #0066cc);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: all 0.3s;
}

.back-to-top:hover {
    transform: translateY(-5px);
}

.back-to-top.visible {
    display: flex;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.contact-form-wrapper {
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.contact-form-wrapper h2 {
    margin-bottom: 10px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    transition: border 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary, #0066cc);
}

.btn-submit {
    width: 100%;
    padding: 14px;
    background: var(--primary, #0066cc);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-submit:hover {
    filter: brightness(1.1);
}

.contact-info-wrapper {
    padding: 20px;
}

.contact-info-item {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
}

.info-icon {
    width: 50px;
    height: 50px;
    background: rgba(0,102,204,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary, #0066cc);
    font-size: 20px;
    flex-shrink: 0;
}

/* ============================================
   ABOUT PAGE
   ============================================ */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.about-content .lead {
    font-size: 1.2rem;
    color: var(--primary, #0066cc);
    font-weight: 500;
    margin-bottom: 20px;
}

.mission-vision {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 30px;
}

.mv-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    text-align: center;
}

.mv-card i {
    font-size: 30px;
    color: var(--primary, #0066cc);
    margin-bottom: 15px;
}

/* ============================================
   LOADING
   ============================================ */
.loader-wrapper {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: white;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.loader-circle {
    width: 45px;
    height: 45px;
    border: 3px solid #f0f0f0;
    border-top: 3px solid var(--primary, #0066cc);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 15px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loader-text {
    font-weight: 600;
    color: var(--primary, #0066cc);
}

/* ============================================
   HERO SLIDESHOW
   ============================================ */
.hero-slideshow {
    position: relative;
    height: 85vh;
    min-height: 500px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.hero-slide {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-slide.active {
    opacity: 1;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
}

.hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    width: 50px; height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    z-index: 10;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-arrow:hover {
    background: rgba(255,255,255,0.4);
}

.hero-prev { left: 20px; }
.hero-next { right: 20px; }

.hero-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.hero-dot {
    width: 12px; height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.3s;
}

.hero-dot.active {
    background: white;
    transform: scale(1.2);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .contact-grid,
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-content h1 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }
    
    .nav-menu-wrapper {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        bottom: 0;
        background: white;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 999;
        padding: 20px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .nav-menu-wrapper.active {
        transform: translateX(0);
    }
    
    .nav-menu {
        flex-direction: column;
        width: 100%;
    }
    
    .nav-link {
        padding: 15px;
        font-size: 16px;
    }
    
    .hero-content h1 {
        font-size: 1.8rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .destinations-grid {
        grid-template-columns: 1fr;
    }
    
    .events-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .mission-vision {
        grid-template-columns: 1fr;
    }
    
    section {
        padding: 50px 0;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-section {
        height: 70vh;
        min-height: 400px;
    }
    
    .hero-content h1 {
        font-size: 1.5rem;
    }
}