/* ===================================
   Combined Styles - Music Queue Website
   =================================== */

@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Playfair+Display:wght@700&display=swap");

:root {
    --primary: #5aa59c;
    --primary-dark: #00635d;
    --accent: #7b5597;
    --light: #f8f8f8;
    --white: #ffffff;
    --text: #222;
    --muted: #777;
    --dark: #171717;
    --radius: 18px;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    --transition: 0.35s ease;
}

/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Poppins", sans-serif;
    color: var(--text);
    background: var(--light);
    line-height: 1.7;
    min-height: 100vh;
    position: relative;
}

#random-images-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

.random-bg-img {
    position: absolute;
    opacity: 0.5;
    transform-origin: center;
}

img {
    width: 100%;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Container */
.container {
    width: min(1180px, 90%);
    margin: auto;
    padding: 2rem;
}

/* Navigation */
nav {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #eee;
}

nav ul {
    display: flex;
    justify-content: center;
    align-items: center;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

nav a {
    color: var(--dark);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

nav a:hover {
    color: var(--primary);
    background: rgba(247, 100, 69, 0.1);
}

/* Main Navigation - works for both desktop and mobile */
.main-nav {
    padding: 0.5rem;
    display: flex;
    justify-content: space-around;
    align-items: center;
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #eee;
    z-index: 100;
    min-height: 60px;
}

.main-nav .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 1rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--muted);
    transition: all 0.2s ease;
    border-radius: 8px;
    text-decoration: none;
}

.main-nav .nav-item:hover {
    color: var(--primary);
    background: rgba(247, 100, 69, 0.1);
}

.main-nav .nav-item.active {
    color: var(--primary);
    font-weight: 600;
}

.main-nav .nav-icon {
    font-size: 1.5rem;
    line-height: 1;
    width: 24px;
    height: 24px;
    display: block;
    color: inherit;
}

.main-nav .nav-text {
    font-size: 0.7rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Language Selector in Navigation */
.lang-selector-container {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    padding: 0.5rem 1rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--muted);
    transition: all 0.2s ease;
    border-radius: 8px;
    position: relative;
    visibility: visible !important;
    opacity: 1 !important;
}

.lang-selector-container:hover {
    color: var(--primary);
    background: rgba(247, 100, 69, 0.1);
}

.lang-display {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    min-height: 32px;
    background: var(--light);
    border-radius: 50%;
    border: 1px solid #eee;
}

.lang-abbr {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text);
}

.lang-dropdown {
    display: none;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border: 1px solid #eee;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 0.5rem;
    min-width: 80px;
    z-index: 1001;
}

/* Position dropdown below the language selector (always) */
.main-nav .lang-dropdown {
    bottom: auto;
    top: 100%;
    margin-top: 0.5rem;
    margin-bottom: 0;
}

.lang-dropdown .lang-option {
    display: block;
    padding: 0.5rem 1rem;
    color: var(--text);
    text-decoration: none;
    text-align: center;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.lang-dropdown .lang-option:hover {
    background: rgba(247, 100, 69, 0.1);
    color: var(--primary);
}

/* Hero Section */
.hero {
    background-image: var(--hero-bg, url("../images/pavillion.png"));
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    width: 100%;
    max-height: 30vh;
    min-height: 25vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 3rem 0;
    color: var(--white);
}

.hero-content h1 {
    font-family: "Playfair Display", serif;
    font-size: 3rem;
    color: var(--white);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-content .subtitle {
    font-size: 1.2rem;
    color: var(--white);
    margin-bottom: 2rem;
    font-weight: 400;
    opacity: 0.9;
}

/* Header */
header {
    text-align: center;
    padding: 0.1rem 0;
}

header h1 {
    font-family: "Playfair Display", serif;
    font-size: 3rem;
    color: var(--dark);
    margin-bottom: 1rem;
    line-height: 1.2;
}

header .subtitle {
    font-size: 1.2rem;
    color: var(--muted);
    margin-bottom: 1rem;
    font-weight: 400;
}

/* Content Section */
.content {
    text-align: left;
    padding: 2rem 0;
}

.content p {
    color: var(--muted);
    line-height: 1.8;
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
    margin-top: 20px;
}

/* Address/Compact text style for content */
.content .remark {
    text-align: left;
    line-height: 1.3;
    font-size: 1rem;
    margin: 0 auto;
    max-width: 700px;
}

/* Address/Compact text style for content */
.content .list {
    text-align: left;
    line-height: 1.3;
    font-size: 1.1rem;
    margin: 0 auto;
    max-width: 700px;
    margin-top: 5px;
}

/* Address/Compact text style for content */
.content .address {
    text-align: center;
    line-height: 1.3;
    font-size: 0.9rem;
    margin: 0 auto;
    max-width: 700px;
    margin-top: 20px;
}

/* Cards */
.card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: var(--radius);
    padding: 2rem;
    text-align: center;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.card h2 {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
    font-weight: 600;
}

.card p {
    color: var(--muted);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    color: var(--muted);
    border-top: 1px solid #eee;
    margin-top: 2rem;
}

footer p {
    font-size: 0.6rem;
}

/* Buttons */
button {
    padding: 0.75rem 1.5rem;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 30px;
    font-size: 0.95rem;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

button:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

button:active {
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 1024px) {
    .container {
        padding: 1.5rem;
    }

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

@media (max-width: 480px) {
    .container {
        padding: 1rem;
        padding-bottom: 1rem !important;
    }

    #main-content {
        padding-bottom: 1rem !important;
    }

    .main-nav {
        gap: 0.25rem;
    }

    .main-nav .nav-item {
        padding: 0.25rem 0.125rem;
        min-width: 35px;
    }

    .lang-selector-container {
        padding: 0.25rem 0.125rem;
        min-width: 35px;
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .main-nav .nav-icon {
        font-size: 0.9rem;
        width: 16px;
        height: 16px;
    }

    .main-nav .nav-text {
        font-size: 0.45rem;
    }

    .lang-display {
        min-width: 20px;
        min-height: 20px;
    }

    .lang-abbr {
        font-size: 0.5rem;
    }

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

/* Main content transitions */
#main-content {
    transition: opacity 0.2s ease;
}

/* Section-specific paragraph spacing */
.menu-section p,
.route-section p,
.route-section .list p {
    margin-top: 1em;
    margin-bottom: 1em;
    line-height: 1.3;
}

/* Schedule section pipe alignment */
.schedule-section p {
    display: flex;
    align-items: baseline;
    margin: 0.5em 0;
    line-height: 1.6;
}

/* For schedule items with time|text structure */
.time {
    color: var(--primary);
    font-weight: 600;
    white-space: nowrap;
    min-width: 50px; /* Provides space for variable length times */
    text-align: right;
}

.pipe {
    color: var(--primary);
    font-weight: 600;
    margin: 0 1em;
}

.text {
    flex: 1;
}

/* Make strong elements primary color */
strong {
    color: var(--primary);
}

/* Mobile (< 768px) - Keep navigation at top */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2rem;
    }

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

    .main-nav {
        height: auto;
        justify-content: space-between;
        padding: 0.25rem;
    }

    .main-nav .nav-item {
        padding: 0.25rem 0.25rem;
        gap: 0.0625rem;
        min-width: 40px;
        flex-shrink: 0;
    }

    .lang-selector-container {
        padding: 0.25rem 0.25rem;
        flex-shrink: 0;
        min-width: 40px;
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .main-nav .nav-icon {
        font-size: 1rem;
        width: 18px;
        height: 18px;
    }

    .main-nav .nav-text {
        font-size: 0.5rem;
    }

    .lang-display {
        min-width: 24px;
        min-height: 24px;
    }

    .lang-abbr {
        font-size: 0.6rem;
    }

    .container {
        padding-bottom: 1rem !important;
    }

    #main-content {
        padding-bottom: 1rem !important;
    }
}

/* ============================================
   Shared Image Styles
   ============================================ */

/* Fixed size images (maintains aspect ratio) */
.styled-image {
    /* width: 300px;
       height: 200px; */
    width: 100%;
    height: auto;
    object-fit: cover; /* Crop to fill */
    display: block;
    margin: 1rem auto;
    border-radius: 8px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.styled-image:hover {
    transform: scale(1.02);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.5);
}

/* Responsive images with max dimensions */
.styled-image-responsive {
    max-width: 400px;
    max-height: 300px;
    width: auto;
    height: auto;
    object-fit: contain; /* Fit within bounds */
    display: block;
    margin: 1rem auto;
}

/* Square thumbnails */
.styled-image-square {
    width: 150px;
    height: 150px;
    object-fit: cover;
    display: block;
    margin: 0.5rem;
    border-radius: 8px;
}

/* Image gallery (flexbox) */
.image-gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.image-gallery .styled-image {
    width: 250px;
    height: 200px;
}
