/* =========================================
   EPIC Properties — Brand CSS
   Overrides Bootstrap 5 with brand identity
   Matched 1:1 to original static styles.css
   ========================================= */

/* --- Brand Fonts --- */
@font-face {
    font-family: 'Acid Grotesk';
    src: url('../fonts/FFF-AcidGrotesk-Regular.woff2') format('woff2'),
         url('../fonts/FFF-AcidGrotesk-Regular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Acid Grotesk';
    src: url('../fonts/FFF-AcidGrotesk-Bold.woff2') format('woff2'),
         url('../fonts/FFF-AcidGrotesk-Bold.woff') format('woff');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* --- CSS Variables --- */
:root {
    --jet:      #03282b;
    --sand:     #edccb0;
    --blue:     #4094d3;
    --seashell: #fbf3ed;
    --grey:     #646c7c;
    --white:    #ffffff;
}

/* --- Global --- */
body {
    font-family: 'Acid Grotesk', 'Trebuchet MS', sans-serif;
    font-weight: 400;
    color: var(--jet);
    background-color: var(--seashell);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6,
.display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
    font-family: 'Acid Grotesk', sans-serif;
    font-weight: 700;
    line-height: 1.15;
}

/* --- Utility Classes --- */
.text-jet      { color: var(--jet) !important; }
.text-sand     { color: var(--sand) !important; }
.text-blue     { color: var(--blue) !important; }
.text-seashell { color: var(--seashell) !important; }
.text-grey     { color: var(--grey) !important; }

.bg-jet      { background-color: var(--jet) !important; }
.bg-sand     { background-color: var(--sand) !important; }
.bg-blue     { background-color: var(--blue) !important; }
.bg-seashell { background-color: var(--seashell) !important; }

/* --- Section Tags (plain text, not badges) --- */
.section-tag {
    display: inline-block;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--blue);
    margin-bottom: 12px;
    background: none !important;
    padding: 0 !important;
    border-radius: 0 !important;
}

/* --- Navbar --- */
.epic-nav {
    background-color: var(--jet);
    padding: 0.75rem 0;
}

.epic-nav .navbar-brand {
    font-size: 1.25rem;
    letter-spacing: 0.04em;
}

.epic-nav .nav-link {
    color: rgba(255,255,255,0.8);
    font-weight: 700;
    font-size: .875rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    transition: color 0.2s;
}

.epic-nav .nav-link:hover {
    color: var(--sand);
}

/* Nav Call Us button */
.nav-cta {
    padding: 8px 16px;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .03em;
}

.nav-cta svg {
    flex-shrink: 0;
}

/* --- Buttons (sharp corners, no radius) --- */
.btn {
    display:inline-flex;
    align-items:center;
    justify-content:center;
    padding:.75rem 1rem;
    border:0;
    border-radius: 0 !important;
    font-family: 'Acid Grotesk', sans-serif;
    font-weight: 700;
    letter-spacing: .03em;
    transition: background .2s, transform .2s;
    text-decoration:none;
    cursor:pointer;
}

.btn-sand {
    background-color: var(--sand);
    color: var(--jet);
    border: none;
}

.btn-sand:hover {
    background-color: var(--white);
    color: var(--jet);
    /* no shift */
}

.btn-jet {
    background-color: var(--jet);
    color: var(--white);
    border: none;
}

.btn-jet:hover {
    background-color: var(--blue);
    color: var(--white);
    /* no shift */
}

.btn-outline-light {
    border: 2px solid rgba(255,255,255,0.5);
    color: var(--white);
    border-radius: 0 !important;
}

.btn-outline-light:hover {
    background-color: rgba(255,255,255,0.15);
    border-color: var(--white);
    color: var(--white);
    /* no shift */
}

/* Minimal utilities kept after removing Bootstrap from the public bundle. */
.bg-white { background:#fff !important; }
.p-4 { padding:1.5rem !important; }
.mb-0 { margin-bottom:0 !important; }
.mb-2 { margin-bottom:.5rem !important; }
.mb-3 { margin-bottom:1rem !important; }
.mt-3 { margin-top:1rem !important; }
.me-1 { margin-right:.25rem !important; }
.w-100 { width:100% !important; }
.small { font-size:.875em; }
.fw-bold { font-weight:700 !important; }
.text-center { text-align:center !important; }
.text-success { color:#108e67 !important; }
.alert {
    padding:.8rem 1rem;
    border:1px solid transparent;
    font-size:.9rem;
}
.alert-danger {
    color:#842029;
    background:#f8d7da;
    border-color:#f5c2c7;
}
.btn-lg {
    padding:.9rem 1.25rem;
    font-size:1rem;
}
.spinner-border {
    display:inline-block;
    width:1rem;
    height:1rem;
    border:.15em solid currentColor;
    border-right-color:transparent;
    border-radius:50%;
    vertical-align:-.125em;
    animation:spin .75s linear infinite;
}
.spinner-border-sm { width:.875rem; height:.875rem; border-width:.12em; }
@keyframes spin { to { transform:rotate(360deg); } }

/* --- Hero --- */
.epic-hero {
    background-size: cover;
    background-position: center;
    position: relative;
}

.epic-hero-overlay {
    background: linear-gradient(
        to top,
        rgba(3,40,43,0.85) 0%,
        rgba(3,40,43,0.4) 40%,
        rgba(3,40,43,0.1) 70%,
        transparent 100%
    );
}

.min-vh-75 {
    min-height: 100vh;
}

.epic-hero .hero-tag {
    display: inline-block;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--sand);
}

.epic-hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    color: var(--white);
}

.epic-hero .lead {
    font-size: 1.125rem;
    color: rgba(255,255,255,0.8);
    max-width: 560px;
}

.epic-hero .btn {
    padding: 16px 32px;
    font-size: .9rem;
    font-weight: 700;
    letter-spacing: .04em;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.epic-hero .btn svg {
    width: 18px;
    height: 18px;
    transition: transform .2s;
}

.epic-hero .btn-sand:hover svg {
    transform: translateX(4px);
}

/* ===== Apartments ===== */

/* Card = each apartment block */
.apartment-card {
    padding: 80px 0;
    border-top: 1px solid rgba(3,40,43,0.08);
}

.apartment-card:first-child {
    border-top: none;
}

.apartment-name {
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    font-weight: 700;
    margin-bottom: 48px;
}

/* Description + specs side by side */
.apartment-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.apartment-description {
    font-size: .95rem;
    color: var(--grey);
    line-height: 1.8;
}

/* Specs grid — 2 columns, gap creates lines */
.apartment-specs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: rgba(3,40,43,0.06);
    border: 1px solid rgba(3,40,43,0.06);
}

.spec {
    background: var(--white);
    padding: 20px;
}

/* Last spec spans full width when odd count */
.spec:last-child:nth-child(odd) {
    grid-column: 1 / -1;
}

.spec-value {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--jet);
    margin-bottom: 4px;
}

.spec-label {
    font-size: .75rem;
    color: var(--grey);
    letter-spacing: .04em;
}

/* Floor plan */
.apartment-floorplan {
    background: var(--white);
    padding: 32px;
    margin-bottom: 48px;
    text-align: center;
}

.apartment-floorplan h3 {
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--grey);
    margin-bottom: 24px;
}

.apartment-floorplan img {
    max-width: 100%;
    max-height: 420px;
    margin: 0 auto;
    object-fit: contain;
    display: block;
}

/* Gallery — 3 columns, images directly in grid */
.apartment-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    overflow: hidden;
    margin-bottom: 8px;
}

.apartment-gallery img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    cursor: pointer;
    display: block;
    transition: opacity .3s ease;
}

.apartment-gallery img:hover {
    opacity: 0.85;
}

/* Apartment CTA (dark jet button with icon) */
.apartment-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 32px;
    background: var(--jet);
    color: var(--white);
    padding: 16px 32px;
    border-radius: 0;
    font-family: 'Acid Grotesk', sans-serif;
    font-weight: 700;
    font-size: .85rem;
    letter-spacing: .04em;
    transition: background .2s, transform .2s;
    text-decoration: none;
}

.apartment-cta svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.apartment-cta:hover {
    background: var(--blue);
    color: var(--white);
    /* no shift */
}

/* --- Location address link (Google Maps button) --- */
.location-address-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 24px;
    padding: 12px 20px;
    background: var(--jet);
    color: var(--white);
    border-radius: 0;
    font-family: 'Acid Grotesk', sans-serif;
    font-size: .875rem;
    font-weight: 700;
    letter-spacing: .03em;
    transition: background .2s;
    text-decoration: none;
}

.location-address-link:hover {
    background: var(--blue);
    color: var(--white);
}

.location-address-link svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* --- Location badges --- */
.badge-card {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--seashell);
    padding: 10px 18px;
    font-size: .8rem;
    font-weight: 700;
    color: var(--jet);
    letter-spacing: .02em;
    border: none !important;
    border-radius: 0 !important;
}

/* --- CTA Banner --- */
.epic-cta-banner {
    background: var(--sand);
}

.epic-cta-banner h2 {
    color: var(--jet) !important;
}

.epic-cta-banner p {
    color: var(--grey) !important;
}

/* CTA Banner buttons (custom, not Bootstrap .btn) */
.cta-banner-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: none;
    font-family: 'Acid Grotesk', sans-serif;
    cursor: pointer;
    padding: 16px 28px;
    font-weight: 700;
    font-size: .85rem;
    letter-spacing: .03em;
    transition: background .2s;
    text-decoration: none;
    border-radius: 0;
}

.cta-btn svg {
    width: 18px;
    height: 18px;
}

.cta-btn-primary {
    background: var(--jet);
    color: var(--white);
}

.cta-btn-primary:hover {
    background: #052f32;
    color: var(--white);
}

.cta-btn-secondary {
    background: var(--white);
    color: var(--jet);
}

.cta-btn-secondary:hover {
    background: var(--seashell);
    color: var(--jet);
}

/* --- Map Modal (Google Maps popup) --- */
.map-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 300;
    align-items: center;
    justify-content: center;
}

.map-modal.active {
    display: flex;
}

.map-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3,40,43,0.85);
    backdrop-filter: blur(6px);
}

.map-modal-content {
    position: relative;
    width: 90vw;
    max-width: 900px;
    aspect-ratio: 16/10;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.4);
}

.map-modal-content iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

.map-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 310;
    width: 36px;
    height: 36px;
    border: none;
    background: var(--jet);
    color: var(--white);
    font-size: 1.25rem;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.map-modal-close:hover {
    background: var(--blue);
}

/* --- Brochure Modal --- */
.brochure-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 300;
    align-items: center;
    justify-content: center;
}

.brochure-modal.active {
    display: flex;
}

.brochure-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3,40,43,0.85);
    backdrop-filter: blur(6px);
}

.brochure-form-card {
    position: relative;
    background: var(--white);
    padding: 48px 40px;
    width: 90vw;
    max-width: 480px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.3);
    z-index: 1;
}

.brochure-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: none;
    background: none;
    color: var(--grey);
    font-size: 1.25rem;
    cursor: pointer;
}

/* --- Contact Section (dark background like original) --- */
.epic-contact {
    background: var(--jet);
    padding: 80px 0;
}

.epic-contact .section-tag {
    color: var(--sand);
}

.epic-contact h2 {
    color: var(--white);
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 14px;
    color: rgba(255,255,255,0.8);
    font-size: .95rem;
    margin-bottom: 20px;
}

.contact-item svg {
    color: var(--sand);
    flex-shrink: 0;
}

.contact-item a {
    color: var(--sand);
}

.contact-item a:hover {
    color: var(--white);
}

/* Lead form sits in a white card even on dark backgrounds — no overrides needed.
   The form's bg-white class ensures inputs stay visible. */

/* --- Footer --- */
.epic-footer {
    background-color: var(--jet);
    color: rgba(255,255,255,0.6);
    border-top: 1px solid rgba(255,255,255,0.08);
}

.epic-footer a {
    color: var(--sand);
}

/* --- Lead Form --- */
.lead-form-wrapper .form-control {
    display:block;
    width:100%;
    border: 1px solid #c1c4ca;
    padding: 14px 16px;
    border-radius: 0;
    font-family: 'Acid Grotesk', sans-serif;
    font-size: .9375rem;
    background-color: var(--white);
    color: var(--jet);
}

.lead-form-wrapper .form-control:focus {
    border-color: var(--blue);
    box-shadow: none;
    background-color: var(--white);
}

.lead-form-wrapper .form-control::placeholder {
    color: var(--grey);
}

/* --- Responsive --- */
@media (max-width: 960px) {
    .apartment-gallery {
        grid-template-columns: repeat(2, 1fr);
    }

    .apartment-body {
        grid-template-columns: 1fr;
    }

    .apartment-specs {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .min-vh-75 {
        min-height: 80vh;
    }

    .epic-hero h1 {
        font-size: 2rem;
    }

    .epic-hero .btn {
        padding: 14px 24px;
        font-size: .85rem;
    }

    .apartment-card {
        padding: 48px 0;
    }

    .apartment-specs {
        grid-template-columns: 1fr;
    }

    /* Floor plan mobile */
    .apartment-floorplan {
        padding: 20px 16px;
        margin-bottom: 32px;
    }

    .apartment-floorplan img {
        max-height: 280px;
    }

    /* Mobile swipe gallery */
    .apartment-gallery {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 10px;
        padding-bottom: 12px;
        scrollbar-width: none;
    }

    .apartment-gallery::-webkit-scrollbar {
        display: none;
    }

    .apartment-gallery img {
        flex: 0 0 82%;
        scroll-snap-align: center;
    }

    /* Swipe indicator dots */
    .gallery-scroll-hint {
        display: flex;
        justify-content: center;
        gap: 6px;
        margin-top: 8px;
    }

    .gallery-scroll-hint .dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: rgba(3,40,43,0.2);
        transition: background .2s;
    }

    .gallery-scroll-hint .dot.active {
        background: var(--blue);
    }
}

/* Desktop: hide scroll hints */
@media (min-width: 769px) {
    .gallery-scroll-hint {
        display: none;
    }
}

/* --- Location Slideshow v2 --- */
.location-slideshow {
    position: relative;
}

.location-slideshow-frame {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(3,40,43,0.15);
    background: var(--jet);
}

.location-slideshow-img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 2 / 1;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.location-slideshow-img.visible {
    opacity: 1;
}

.location-slideshow-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px 20px 14px;
    background: linear-gradient(transparent, rgba(3,40,43,0.7));
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.location-slideshow-caption span:first-child {
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.02em;
}

.location-slideshow-credit {
    font-size: 0.6rem;
    opacity: 0.5;
}

.location-slideshow-dots {
    position: absolute;
    bottom: 14px;
    right: 20px;
    display: flex;
    gap: 7px;
    z-index: 5;
}

.location-slideshow-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.6);
    background: transparent;
    cursor: pointer;
    padding: 0;
    transition: background 0.3s, border-color 0.3s;
}

.location-slideshow-dot:hover {
    border-color: #fff;
}

.location-slideshow-dot.active {
    background: #fff;
    border-color: #fff;
}

@media (max-width: 768px) {
    .location-slideshow-img {
        aspect-ratio: 4 / 3;
    }
    .location-slideshow-caption span:first-child {
        font-size: 0.9rem;
    }
    .location-slideshow-credit {
        display: none;
    }
    .location-slideshow-dots {
        bottom: 12px;
        right: 14px;
    }
}
