/* Responsive Styles for About, Packages, and Blog Pages */

:root {
    --primary: #1a5f7a;
    --accent: #d4a574;
    --dark: #1a1a1a;
    --light: #f9f9f9;
}

/* Page Hero Section - Responsive */
.page-hero {
    background-size: cover !important;
    background-position: center !important;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px !important;
}

.page-hero h1 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 15px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.page-hero p {
    font-size: clamp(1rem, 2vw, 1.2rem);
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

/* General Sections */
.about-section,
.package-detail,
.blog-post {
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Images */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Cards - Responsive */
.about-section > div > div,
.package-detail,
.blog-post {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-section > div > div:hover,
.package-detail:hover,
.blog-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15) !important;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .page-hero {
        min-height: 250px;
        padding: 40px 15px !important;
    }

    .page-hero h1 {
        font-size: 1.8rem;
    }

    .page-hero p {
        font-size: 1rem;
    }

    /* Two-column layouts to single column */
    div[style*="grid-template-columns: 1fr 1fr"],
    div[style*="grid-template-columns: repeat(auto-fit"] {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }

    /* Package and blog content padding */
    .package-detail,
    .blog-post {
        padding: 20px !important;
        margin-bottom: 30px !important;
    }

    /* Image heights on mobile */
    img[style*="height: 400px"] {
        height: 250px !important;
    }

    /* Button sizing */
    .btn, button, a[class*="btn"] {
        padding: 10px 20px !important;
        font-size: 0.9em !important;
        white-space: nowrap;
    }

    /* Search section mobile optimization */
    div[style*="flex-wrap: wrap"] {
        gap: 8px !important;
    }

    /* Navigation improvements */
    .nav-links {
        flex-direction: column;
        gap: 10px;
        padding: 20px;
    }

    /* Container padding */
    .container {
        padding: 0 15px !important;
    }
}

/* Very small mobile screens */
@media (max-width: 480px) {
    /* Make inputs and buttons stack vertically */
    input[type="text"],
    button {
        width: 100% !important;
        min-width: 100% !important;
    }

    /* Smaller translate button on tiny screens */
    .translate-icon button {
        width: 50px !important;
        height: 36px !important;
        font-size: 0.8em !important;
    }

    /* Adjust heading sizes */
    h1 { font-size: 1.6rem !important; }
    h2 { font-size: 1.3rem !important; }
    h3 { font-size: 1.1rem !important; }

    /* Reduce padding everywhere */
    section, div[style*="padding"] {
        padding: 30px 10px !important;
    }
}
    .about-section,
    .package-detail,
    .blog-post {
        padding: 30px 20px !important;
        margin-bottom: 30px !important;
    }

    /* Heading sizes for mobile */
    h2 {
        font-size: 1.5rem !important;
    }

    h3 {
        font-size: 1.1rem !important;
    }

    /* Text sizing for mobile */
    p {
        font-size: 0.95rem !important;
    }

    /* Button sizing */
    .btn {
        padding: 12px 30px !important;
        font-size: 0.95rem !important;
        width: 100%;
        text-align: center;
        margin-top: 15px !important;
    }

    .btn-large {
        padding: 14px 30px !important;
    }

    /* Grid layouts for cards */
    div[style*="grid-template-columns: repeat"] {
        grid-template-columns: 1fr !important;
    }

    /* Contact info box */
    div[style*="background: #f0f4f8"] {
        margin: 20px 0 !important;
        padding: 20px !important;
    }


@media (max-width: 480px) {
    .page-hero {
        padding: 40px 0 !important;
    }

    .page-hero h1 {
        font-size: 1.5rem;
    }

    .page-hero p {
        font-size: 0.9rem;
    }

    h2 {
        font-size: 1.3rem !important;
    }

    h3 {
        font-size: 1rem !important;
    }

    /* Spacing adjustments */
    section {
        padding: 40px 0 !important;
    }

    .container {
        padding: 0 15px !important;
    }

    /* Full width buttons */
    .btn {
        width: 100% !important;
        display: block !important;
        margin-bottom: 10px !important;
    }
}

/* Translate icon styling */
.translate-icon button {
    transition: all 0.3s ease;
}

.translate-icon button:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(26, 95, 122, 0.2);
}

.translate-icon button:active {
    transform: scale(0.98);
}

.translate-icon button:focus { 
    outline: 2px solid #1a5f7a; 
    outline-offset: 2px; 
}

/* Popup styling */
#translatePopup {
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Better spacing for content */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Gradient backgrounds */
div[style*="background: linear-gradient"] {
    padding: 40px 20px !important;
}

/* Tables responsive */
@media (max-width: 768px) {
    table {
        font-size: 0.9rem;
    }

    table th,
    table td {
        padding: 10px 5px;
    }
}

/* Blog post images - responsive */
.blog-image {
    min-height: 250px;
}

@media (max-width: 768px) {
    .blog-image {
        min-height: 200px;
    }

    /* Blog post grid to single column */
    div[style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }
}

/* Package details responsive */
.package-detail {
    padding: 30px !important;
}

@media (max-width: 768px) {
    .package-detail {
        padding: 20px !important;
    }

    .package-detail > div {
        grid-template-columns: 1fr !important;
    }
}

/* Lists responsive */
ul, ol {
    margin-left: 20px;
    margin-right: 10px;
}

li {
    margin-bottom: 8px;
    line-height: 1.6;
}

/* Stats sections */
div[style*="text-align: center"] {
    width: 100%;
}

/* Footer responsive */
.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-section {
        text-align: center;
    }
}

/* Navigation responsive - already in main CSS but ensure mobile menu works */
@media (max-width: 768px) {
    .nav-links {
        flex-direction: column;
        gap: 10px;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links a {
        display: block;
        padding: 10px;
    }
}

/* Accessibility improvements */
button:focus,
a:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Touch-friendly buttons */
@media (max-width: 768px) {
    button,
    a.btn {
        min-height: 44px;
        min-width: 44px;
    }
}

/* Loading animations */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.loading {
    animation: shimmer 2s infinite;
    background: linear-gradient(to right, #f0f0f0 8%, #f8f8f8 18%, #f0f0f0 33%);
    background-size: 800px 104px;
}

/* Print styles */
@media print {
    .navbar,
    .footer,
    .page-hero {
        display: none;
    }

    body {
        font-size: 12pt;
        color: #000;
    }

    a {
        text-decoration: underline;
    }
}

/* Legal Pages Styling */
.legal-section {
    padding: 80px 0;
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
}

.legal-header {
    text-align: center;
    margin-bottom: 60px;
    padding: 40px 20px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.legal-header h1 {
    font-size: clamp(2em, 4vw, 3em);
    color: var(--primary);
    margin-bottom: 15px;
    font-weight: 800;
}

.legal-header .last-updated {
    color: #999;
    font-size: 0.95em;
    font-style: italic;
}

.legal-content {
    background: white;
    padding: 50px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    max-width: 900px;
    margin: 0 auto;
}

.legal-content h2 {
    color: var(--primary);
    font-size: clamp(1.5em, 3vw, 2em);
    margin-top: 40px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--accent);
}

.legal-content h2:first-child {
    margin-top: 0;
}

.legal-content h3 {
    color: var(--dark);
    font-size: clamp(1.2em, 2.5vw, 1.5em);
    margin-top: 30px;
    margin-bottom: 15px;
    font-weight: 600;
}

.legal-content p {
    line-height: 1.8;
    margin-bottom: 20px;
    color: #555;
    font-size: 1.05em;
}

.legal-content ul,
.legal-content ol {
    margin: 20px 0;
    padding-left: 30px;
}

.legal-content li {
    margin-bottom: 12px;
    line-height: 1.7;
    color: #555;
}

.legal-content strong {
    color: var(--dark);
    font-weight: 600;
}

@media (max-width: 768px) {
    .legal-content {
        padding: 30px 20px;
    }
    
    .legal-header {
        padding: 30px 15px;
    }
}
