:root {
    --primary-color: #004a80; /* Trustindo Dark Blue */
    --text-dark-blue: #004a80;
    --accent-orange: #f26522; /* Trustindo Orange */
    --accent-green: #28a745;
    
    /* Legacy/Fallback variables */
    --primary-blue: #004a80;
    --dark-blue: #003359;
    --sky-blue-light: #f0f7ff;
    --sky-blue-bg: #f0f7ff;
    --text-dark: #333333;
    --text-light: #666666;
    --white: #ffffff;
    --gray-bg: #f8f9fa;
    --transition: all 0.3s ease;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 15px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
}

body {
    margin: 0;
    font-family: 'Poppins', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--gray-bg);
    color: var(--text-dark);
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

/* Header */
.header {
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--dark-blue);
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-nav {
    display: flex;
    gap: 25px;
    align-items: center;
}

.header-nav a {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 14px;
    text-transform: uppercase; /* UPPERCASE MENU */
    letter-spacing: 0.5px;
}

.header-nav a:hover {
    color: var(--primary-color);
}

.btn-login {
    background: var(--primary-blue); /* Keep blue for contrast or change to teal? Let's keep blue for now as primary action */
    color: var(--white) !important;
    padding: 8px 25px;
    border-radius: 4px; /* More square like Morza usually */
    font-weight: 700;
}

.btn-login:hover {
    background: var(--dark-blue);
    transform: translateY(-2px);
}

/* Package Grid & Cards (Morza Style) */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.packages-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Force 3 columns */
    gap: 30px;
    padding: 20px 0;
}

/* Hamburger Menu Base Styles */
.hamburger-menu {
    display: none; /* Hidden on desktop by default */
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1100; /* Higher than header sticky */
}

.hamburger-menu span {
    width: 100%;
    height: 3px;
    background-color: var(--dark-blue); /* Ensure this contrasts with white header */
    border-radius: 10px;
    transition: all 0.3s linear;
    position: relative;
    transform-origin: 1px;
}

/* Hamburger Animation */
.hamburger-menu.active span:first-child {
    transform: rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
    width: 0;
}
.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg);
}

@media (max-width: 992px) {
    .packages-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .packages-grid {
        grid-template-columns: 1fr;
    }
    
    .header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 15px 20px;
        position: sticky;
        top: 0;
        z-index: 1000;
    }

    .hamburger-menu {
        display: flex;
        opacity: 1;
        visibility: visible;
    }
    
    .header-nav {
        display: none;
        flex-direction: column;
        width: 100vw;
        position: absolute;
        top: 100%;
        left: -20px; /* Offset parent padding */
        right: 0;
        background-color: var(--white);
        box-shadow: 0 10px 30px rgba(0,0,0,0.15);
        padding: 10px 0;
        border-top: 1px solid #eee;
        max-height: 80vh; /* Prevent overflowing screen height */
        overflow-y: auto; /* Scrollable */
    }

    .header-nav.active {
        display: flex;
        animation: mobileMenuSlide 0.3s ease forwards;
    }

    .header-nav a {
        padding: 16px 30px;
        border-bottom: 1px solid #f0f0f0;
        width: 100%;
        text-align: center;
        box-sizing: border-box;
        font-weight: 500;
        color: #444;
        transition: all 0.2s ease;
    }
    
    .header-nav a:hover {
        background-color: #f8fbff;
        color: var(--primary-color);
        /* padding-left removed for centered layout */
        transform: scale(1.02); /* Subtle scale instead of slide */
    }
    
    /* Special styling for Login button in mobile menu */
    .header-nav .btn-login {
        margin: 20px;
        width: calc(100% - 40px); /* Full width minus margins */
        text-align: center;
        background: var(--primary-blue);
        color: white !important;
        border-radius: 8px;
        padding: 12px;
        font-weight: 600;
        border: none;
        box-shadow: 0 4px 10px rgba(52, 85, 165, 0.2);
    }
    
    .header-nav .btn-login:hover {
        background: var(--dark-blue);
        padding-left: 12px; /* Reset padding slide */
        transform: translateY(-2px);
        box-shadow: 0 6px 15px rgba(52, 85, 165, 0.3);
    }
    
    .header-nav a:last-child {
        border-bottom: none;
    }
    
    .header-title img {
        height: 40px !important;
    }
    
    .header-title span {
        font-size: 1.1rem !important;
    }
}

@keyframes mobileMenuSlide {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* End of Hamburger Base Styles - Moved above media queries */

/* Morza Card Styles */
.morza-card {
    border: 1px solid #d1d9e6; /* Frame Grid Color */
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #fff;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    padding: 10px; /* Creates the frame effect */
}

.morza-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}

.package-image-container {
    width: 100%;
    height: auto;
    position: relative;
    overflow: hidden;
    background-color: #eee;
    border-radius: 8px; /* Inner radius */
}

.package-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    transition: transform 0.5s ease;
}

.morza-card:hover .package-img {
    transform: scale(1.05);
}

.package-badge-top {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #B22222;
    color: #fff;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    z-index: 2;
}

.morza-details {
    padding: 15px 5px 5px 5px;
    background: #fff;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.package-title {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-dark-blue);
    margin: 0 0 5px 0;
    line-height: 1.4;
    text-transform: uppercase;
}

.package-route-text {
    font-size: 0.75rem;
    color: #777;
    text-transform: uppercase;
    margin-bottom: 15px;
    letter-spacing: 0.5px;
}

.promo-tag-morza {
    background-color: #ef4444;
    color: white;
    padding: 3px 8px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 10px;
    border-radius: 2px;
    align-self: flex-start;
}

.price-section-morza {
    margin-top: auto;
    margin-bottom: 15px;
    padding-top: 15px;
    border-top: 1px dashed #eee;
}

.price-normal-text {
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 2px;
}

.strikethrough {
    text-decoration: line-through;
}

.highlight-price {
    font-size: 1.3rem;
    color: #b91c1c;
    font-weight: 800;
}

.btn-itinerary-morza {
    display: block;
    width: 100%;
    background-color: var(--primary-color); /* Teal */
    color: white;
    padding: 10px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    text-align: center;
    border: none;
    transition: all 0.2s;
}

.btn-itinerary-morza:hover {
    background-color: #008c7d; /* Darker Teal */
}

/* Footer */
.footer {
    background-color: #1a1a1a;
    color: var(--white);
    padding: 60px 20px;
    margin-top: 60px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.footer-column h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-column p, .footer-column a {
    color: #aaa;
    font-size: 0.9rem;
    margin-bottom: 10px;
    display: block;
}

.footer-column a:hover {
    color: var(--white);
}

.footer-bottom {
    max-width: 1200px;
    margin: 40px auto 0;
    padding-top: 20px;
    border-top: 1px solid #333;
    text-align: center;
    color: #666;
    font-size: 0.8rem;
}

/* =========================================
   TERMS & CONDITIONS / DYNAMIC CONTENT FIXES
   ========================================= */
.terms-content {
    font-size: 1rem;
    line-height: 1.6;
    color: #333;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

/* Force Reset for MS Word Paste Artifacts */
.terms-content p, 
.terms-content div, 
.terms-content span,
.terms-content table,
.terms-content td,
.terms-content th {
    max-width: 100% !important;
    box-sizing: border-box !important;
    font-family: inherit !important; /* Overwrite specific fonts */
}

/* Reset fixed widths that break mobile */
.terms-content p, 
.terms-content div,
.terms-content table {
    width: auto !important;
    height: auto !important;
}

/* Fix Lists - Word often messes these up with spans */
.terms-content ul, 
.terms-content ol {
    padding-left: 20px !important;
    margin-left: 0 !important;
    margin-bottom: 1em;
}

.terms-content li {
    margin-bottom: 0.5em;
    text-indent: 0 !important; /* Fix weird Word indentation */
}

/* Fix Tables - Make them scrollable */
.terms-content table {
    display: block;
    width: 100% !important;
    overflow-x: auto;
    border-collapse: collapse;
    margin-bottom: 15px;
}

.terms-content td, 
.terms-content th {
    padding: 8px;
    border: 1px solid #ddd;
}

/* Fix Headings */
.terms-content h1, .terms-content h2, .terms-content h3, 
.terms-content h4, .terms-content h5, .terms-content h6 {
    margin-top: 1.5em;
    margin-bottom: 0.5em;
    color: var(--primary-color);
    font-weight: 700;
}

/* Fix Images */
.terms-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
    margin: 10px 0;
}
