/* ============================================
   Roam Anguilla · style.css
   Color scheme: Blue (#1E6F9F), Orange (#FF8C42), White, Light tones
   ============================================ */

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

body {
    background-color: #f5f5f5;
    font-family: 'Inter', sans-serif;
    display: flex;
    justify-content: center;
    padding: 2rem 1rem;
}

/* Main app container — white body */
.app {
    max-width: 1400px;
    width: 100%;
    background: white;
    border-radius: 2rem;
    box-shadow: 0 25px 45px -12px rgba(0, 0, 0, 0.12);
    padding: 2rem 2.2rem;
}

/* CSS Variables (consistent palette) */
:root {
    --blue: #1E6F9F;
    --orange: #FF8C42;
    --light-orange: #fff0e5;
    --light-blue: #eef5fa;
}

/* ---- Header + Logo ---- */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--light-orange);
}

.logo h1 {
    font-size: 2.6rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, var(--blue) 0%, var(--orange) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

.logo h1 span {
    font-weight: 700;
    background: none;
    color: var(--blue);
    -webkit-text-fill-color: initial;
}

/* Header navigation links */
.header-nav {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    flex-wrap: wrap;
}

.nav-link {
    color: var(--blue);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.45rem 1rem;
    border-radius: 30px;
    transition: all 0.2s ease;
}

.nav-link:hover {
    background: var(--light-blue);
}

.nav-link.active {
    background: var(--blue);
    color: white;
}

/* Get App Button */
.get-app-link {
    background: var(--blue);
    color: white;
    padding: 0.7rem 1.8rem;
    border-radius: 60px;
    font-weight: 600;
    font-size: 1rem;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
}

.get-app-link:hover {
    background: #0f537c;
    transform: translateY(-2px);
}

/* ---- Section Titles ---- */
.section-title {
    font-size: 1.9rem;
    font-weight: 700;
    margin: 2rem 0 1.2rem 0;
    color: #1a2c3e;
    display: flex;
    align-items: center;
    gap: 0.7rem;
}

.section-title i {
    color: var(--orange);
    font-size: 1.8rem;
}

/* ---- Horizontal scroll containers (stories & events) ---- */
.horizontal-scroll {
    display: flex;
    overflow-x: auto;
    gap: 1.5rem;
    padding: 0.5rem 0.2rem 1.8rem 0.2rem;
    scrollbar-width: thin;
    scrollbar-color: var(--orange) #e2e8f0;
}

.horizontal-scroll::-webkit-scrollbar {
    height: 6px;
}

.horizontal-scroll::-webkit-scrollbar-thumb {
    background: var(--orange);
    border-radius: 12px;
}

/* ---- Story Card (Latest in Anguilla) ---- */
.story-card {
    flex: 0 0 300px;
    background: #ffffff;
    border-radius: 28px;
    padding: 1.4rem;
    box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(30, 111, 159, 0.15);
    transition: all 0.2s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.story-card:hover {
    transform: translateY(-4px);
    border-color: var(--orange);
    box-shadow: 0 22px 30px -12px rgba(30, 111, 159, 0.15);
}

.story-image {
    width: 100%;
    height: 150px;
    background-size: cover;
    background-position: center;
    border-radius: 20px;
    margin-bottom: 1rem;
    background-color: var(--light-blue);
    overflow: hidden;
}

.story-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.story-tag {
    display: inline-block;
    background: var(--light-orange);
    color: var(--orange);
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.2rem 0.7rem;
    border-radius: 999px;
    margin-bottom: 0.4rem;
}

.story-featured {
    display: inline-block;
    background: #fbbf24;
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.2rem 0.7rem;
    border-radius: 999px;
    margin-bottom: 0.4rem;
    margin-right: 0.3rem;
}

.story-date {
    font-size: 0.75rem;
    color: var(--blue);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.story-title {
    font-size: 1.3rem;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 0.5rem;
    color: #1a2c3e;
}

.story-excerpt {
    font-size: 0.85rem;
    color: #4a5568;
    flex: 1;
    line-height: 1.5;
}

.story-read-link {
    margin-top: 1rem;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--blue);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.story-read-link:hover {
    color: var(--orange);
}

/* ---- View All link ---- */
.view-all-link {
    display: inline-block;
    margin: -0.5rem 0 1.5rem;
    float: right;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--blue);
    text-decoration: none;
    transition: color 0.2s;
}

.view-all-link:hover { color: var(--orange); }

/* ---- Event Card ---- */
.event-card {
    flex: 0 0 300px;
    background: #ffffff;
    border-radius: 28px;
    padding: 1.4rem;
    box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(255, 140, 66, 0.2);
    transition: all 0.2s ease;
    cursor: pointer;
}

.event-card:hover {
    transform: translateY(-4px);
    border-color: var(--orange);
}

.event-day-badge {
    background: var(--blue);
    color: white;
    padding: 0.2rem 1rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1rem;
}

.event-name {
    font-size: 1.35rem;
    font-weight: 800;
}

.event-place {
    color: var(--blue);
    font-weight: 500;
    margin: 0.5rem 0 0.8rem;
    font-size: 0.9rem;
}

.event-time {
    background: var(--light-orange);
    padding: 0.3rem 1rem;
    border-radius: 30px;
    display: inline-block;
    font-weight: 600;
    font-size: 0.85rem;
}

.event-status {
    font-size: 0.8rem;
    margin-top: 0.8rem;
    background: var(--light-blue);
    padding: 0.3rem 0.8rem;
    border-radius: 30px;
    display: inline-block;
}

/* ---- Places scroll container (vertical scroll inside page) ---- */
.places-scroll-container {
    max-height: 550px;
    overflow-y: auto;
    margin: 1.5rem 0 2rem 0;
    padding-right: 0.5rem;
    border-radius: 28px;
}

.places-scroll-container::-webkit-scrollbar {
    width: 6px;
}

.places-scroll-container::-webkit-scrollbar-track {
    background: #f0f0f0;
    border-radius: 10px;
}

.places-scroll-container::-webkit-scrollbar-thumb {
    background: var(--orange);
    border-radius: 10px;
}

/* ---- Places Grid ---- */
.places-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem 1.6rem;
    margin: 1rem 0 2rem;
}

.place-card {
    background: white;
    border-radius: 28px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.04);
    border: 1px solid #f0ede8;
    transition: all 0.25s;
    cursor: pointer;
    overflow: hidden;
    border-bottom: 4px solid var(--orange);
}

.place-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 32px -12px rgba(30, 111, 159, 0.2);
}

.place-img {
    height: 170px;
    background-size: cover;
    background-position: center;
    background-color: #eef2f5;
}

.place-info {
    padding: 1.2rem 1.2rem 1.3rem;
}

.place-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: #1a2c3e;
    line-height: 1.25;
}

.place-category {
    background: var(--orange);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    display: inline-block;
    margin: 0.6rem 0 0.9rem;
}

.place-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.3rem;
}

.place-phone a {
    text-decoration: none;
    color: var(--blue);
    font-weight: 500;
    font-size: 0.85rem;
}

.place-link {
    background: var(--blue);
    color: white;
    padding: 0.3rem 1rem;
    border-radius: 40px;
    font-size: 0.75rem;
    font-weight: 600;
    transition: 0.2s;
}

.place-link:hover {
    background: var(--orange);
}

/* ---- Modal Overlay ---- */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    max-width: 560px;
    width: 90%;
    border-radius: 42px;
    padding: 2rem 1.8rem;
    position: relative;
    max-height: 85vh;
    overflow-y: auto;
    border-top: 6px solid var(--orange);
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    cursor: pointer;
    color: #6c757d;
    background: none;
    border: none;
    line-height: 1;
    transition: color 0.2s;
}

.modal-close:hover { color: var(--orange); }

.modal h2 {
    font-size: 1.8rem;
    color: var(--blue);
    line-height: 1.2;
    padding-right: 2rem;
}

.detail-row {
    margin: 1.2rem 0;
    padding-left: 0.8rem;
    border-left: 4px solid var(--light-orange);
}

.detail-row p {
    font-size: 0.9rem;
    color: #2d3748;
    line-height: 1.6;
}

.event-list {
    list-style: none;
    padding-left: 0;
}

.event-list li {
    background: #f8f9fa;
    margin: 0.5rem 0;
    padding: 0.7rem 1rem;
    border-radius: 28px;
}

/* ---- Panel Card (used by events.js) ---- */
.panelCard {
    background: white;
    border-radius: 28px;
    padding: 1.5rem 1.8rem;
    margin: 1.5rem 0;
    box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.1);
    border: 1px solid #f0ede8;
    border-top: 4px solid var(--orange);
    position: relative;
    color: #1a2c3e;
}

.panelCard h3 { color: #1a2c3e; }
.panelCard p { color: #2d3748; font-size: 0.9rem; }
.panelCard a { color: var(--blue); }

.closeButton {
    position: absolute;
    top: 1rem;
    right: 1.2rem;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: #6c757d;
    padding: 0.2rem 0.5rem;
    border-radius: 50%;
    transition: background 0.2s;
}

.closeButton:hover { background: var(--light-orange); }

.pageButton {
    background: var(--blue);
    color: white;
    border: none;
    padding: 0.6rem 1.5rem;
    border-radius: 40px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.2s;
}

.pageButton:hover { background: var(--orange); }

/* ---- Amenities (places modal) ---- */
.amenitiesBlock {
    margin-top: 1rem;
    padding-top: 0.8rem;
    border-top: 1px solid var(--light-orange);
}

.amenitiesLabel {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--blue);
    margin-bottom: 0.5rem;
}

.amenitiesIcons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 0.4rem;
}

.amenity-icon {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: #1a2c3e;
}

.amenity-icon span {
    font-size: 0.55rem;
    line-height: 1.1;
    letter-spacing: 0.3px;
    max-width: 48px;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #4a5568;
}

/* ---- Footer ---- */
.footer {
    text-align: center;
    margin-top: 1rem;
    padding: 1.8rem 0 0.5rem;
    border-top: 2px solid var(--light-orange);
    font-weight: 500;
    color: #3b4b5e;
}

/* ---- Responsive ---- */
@media (max-width: 720px) {
    .app {
        padding: 1.2rem;
        border-radius: 1.2rem;
    }
    .logo h1 {
        font-size: 2rem;
    }
    .places-scroll-container {
        max-height: 480px;
    }
    .section-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    body {
        padding: 0.8rem 0.4rem;
    }
    .app {
        padding: 1rem;
        border-radius: 1rem;
    }
    .header {
        gap: 0.6rem;
    }
    .logo h1 {
        font-size: 1.7rem;
    }
    .header-nav {
        gap: 0.15rem;
    }
    .nav-link {
        font-size: 0.8rem;
        padding: 0.35rem 0.65rem;
    }
    .get-app-link {
        font-size: 0.85rem;
        padding: 0.55rem 1.1rem;
    }
    .story-card {
        flex: 0 0 260px;
    }
    .modal-content {
        border-radius: 28px;
        padding: 1.5rem 1.2rem;
    }
    .modal h2 {
        font-size: 1.4rem;
    }
}
