/*=====================================
  Theme 2 UX polish layer
  Keep content editable in admin/page builder; this file only improves shared presentation.
======================================*/

:root {
    --theme2-ink: #101820;
    --theme2-muted: #5d6673;
    --theme2-surface: #ffffff;
    --theme2-soft: #f4f6f8;
    --theme2-line: rgba(16, 24, 32, 0.1);
    --theme2-shadow: 0 18px 45px rgba(16, 24, 32, 0.12);
    --theme2-radius: 22px;
}

html {
    overflow-x: hidden;
}

body.theme2-body {
    color: var(--theme2-ink);
    background:
        radial-gradient(circle at top left, rgba(220, 53, 69, 0.08), transparent 34rem),
        linear-gradient(180deg, #fff 0%, #f7f8fa 100%);
    overflow-x: hidden;
}

.container,
.container-fluid {
    width: min(100% - 32px, 1240px);
    max-width: 1240px;
    padding-left: 0;
    padding-right: 0;
}

.theme2-section,
.theme2-section-simple,
.theme2-listings-page-modern,
.theme2-listing-detail-modern {
    padding: clamp(48px, 7vw, 96px) 0 !important;
}

.theme2-section-padding {
    padding: clamp(42px, 6vw, 84px) 0 !important;
}

.theme2-section-header-simple,
.theme2-section-header-modern,
.theme2-featured-header {
    margin-bottom: clamp(28px, 4vw, 52px) !important;
}

.theme2-title-simple,
.theme2-section-title-modern,
.theme2-featured-header h2,
.theme2-listing-description-modern h2,
.theme2-specifications-modern h2 {
    color: var(--theme2-ink) !important;
    font-size: clamp(2rem, 5vw, 3.3rem) !important;
    line-height: 0.95 !important;
    font-weight: 800 !important;
}

.theme2-subtitle-simple,
.theme2-section-description,
.theme2-featured-header p,
.theme2-about-content-simple p,
.theme2-description-content,
.theme2-page-content p {
    color: var(--theme2-muted) !important;
}

.theme2-btn,
.theme2-btn-simple,
.theme2-btn-primary,
.theme2-hero-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 14px 22px !important;
    border-radius: 999px !important;
    border: 1px solid color-mix(in srgb, var(--primary-color) 86%, #000 14%);
    background: var(--primary-color) !important;
    color: #fff !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    text-decoration: none !important;
    box-shadow: 0 14px 28px color-mix(in srgb, var(--primary-color) 26%, transparent);
    transform: none !important;
}

.theme2-btn:hover,
.theme2-btn-simple:hover,
.theme2-btn-primary:hover,
.theme2-hero-btn:hover {
    background: color-mix(in srgb, var(--primary-color) 86%, #000 14%) !important;
    color: #fff !important;
    transform: translateY(-2px) !important;
}

/* Modern editable homepage hero */
.theme2-hero-carousel {
    background: #07111c;
}

.theme2-hero-slide {
    min-height: clamp(520px, 72vh, 760px);
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    position: relative;
}

.theme2-hero-content {
    max-width: 760px;
    padding: clamp(72px, 12vw, 140px) 0;
    color: #fff;
}

.theme2-hero-content h1 {
    margin: 0 0 22px;
    color: #fff;
    font-size: clamp(3rem, 8vw, 6.8rem);
    line-height: 0.88;
    font-weight: 800;
    text-transform: uppercase;
    text-shadow: 0 14px 36px rgba(0, 0, 0, 0.42);
}

.theme2-hero-content p {
    max-width: 680px;
    margin: 0 0 28px;
    color: rgba(255, 255, 255, 0.92);
    font-size: clamp(1.05rem, 2vw, 1.35rem);
    line-height: 1.55;
    font-weight: 700;
}

.theme2-hero-carousel .carousel-control-prev,
.theme2-hero-carousel .carousel-control-next {
    width: 64px;
}

/* Cards and content blocks */
.theme2-listings-grid-simple {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 360px)) !important;
    justify-content: center !important;
    gap: 28px !important;
}

.theme2-listing-card-simple,
.theme2-featured-card,
.theme2-spec-item-modern,
.theme2-about-image-simple,
.theme2-main-gallery-image,
.theme2-video-modern {
    border: 1px solid var(--theme2-line) !important;
    border-radius: var(--theme2-radius) !important;
    box-shadow: 0 12px 34px rgba(16, 24, 32, 0.08) !important;
}

.theme2-listing-card-simple,
.theme2-featured-card {
    overflow: hidden;
    background: #fff;
}

.theme2-listing-image-simple,
.theme2-featured-image {
    height: auto !important;
    aspect-ratio: 4 / 3;
}

.theme2-listing-content-simple,
.theme2-featured-content {
    padding: clamp(20px, 3vw, 28px) !important;
}

.theme2-listing-title-simple {
    font-size: 1.45rem !important;
    line-height: 1.05 !important;
    font-weight: 800 !important;
}

.theme2-price-badge-simple,
.theme2-featured-badge {
    border-radius: 999px !important;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

/* Page headers */
.theme2-page-header,
.theme2-page-header-simple,
.theme2-page-header-modern,
.theme2-listing-hero {
    min-height: clamp(280px, 42vw, 520px);
    display: flex;
    align-items: center;
    padding: clamp(72px, 11vw, 140px) 0 !important;
    background-position: center !important;
}

.theme2-page-header-simple {
    background:
        linear-gradient(135deg, rgba(220, 53, 69, 0.12), rgba(6, 19, 31, 0.04)),
        #f7f8fa !important;
}

.theme2-page-header-content,
.theme2-page-header-content-modern,
.theme2-listing-hero-content {
    text-align: left !important;
}

.theme2-page-header-content h1,
.theme2-page-header-content-modern h1,
.theme2-listing-hero-content h1 {
    font-size: clamp(3rem, 8vw, 6rem) !important;
    line-height: 0.9 !important;
    margin-bottom: 16px !important;
}

.theme2-breadcrumb-simple,
.theme2-breadcrumb-modern {
    justify-content: flex-start !important;
}

.theme2-breadcrumb-simple ol,
.theme2-breadcrumb-modern ol {
    flex-direction: row !important;
    flex-wrap: wrap;
    justify-content: flex-start !important;
}

/* Page builder blocks */
.theme2-page-builder-flow > .page-builder-section:first-child {
    margin-top: 0;
}

.page-builder-section {
    overflow: hidden;
}

.page-builder-section > .container,
.page-builder-section > .container-fluid {
    width: min(100% - 32px, 1240px);
}

.page-builder-section > .container-fluid.p-0 {
    width: 100%;
    max-width: none;
}

.text-block,
.theme2-text-image-section,
.theme2-featured-categories,
.theme2-bg-light {
    border-radius: 0;
}

.text-block .prose,
.theme2-text-image-content,
.theme2-page-content {
    font-size: clamp(1rem, 1.4vw, 1.1rem);
    line-height: 1.8;
}

/* Forms */
.theme2-section input,
.theme2-section textarea,
.theme2-section select,
.theme2-main input,
.theme2-main textarea,
.theme2-main select {
    border-radius: 14px !important;
    border: 1px solid rgba(16, 24, 32, 0.14) !important;
    min-height: 48px;
}

/* Footer */
.theme2-footer-simple {
    background: #06131f !important;
}

.theme2-footer-main-simple {
    padding: clamp(42px, 7vw, 76px) 0 28px !important;
}

.theme2-footer-logo-simple img {
    max-height: 70px !important;
}

@media (max-width: 991px) {
    .container,
    .container-fluid {
        width: min(100% - 24px, 1240px);
    }

    .theme2-hero-slide {
        min-height: 430px;
        align-items: flex-end;
        background-position: center;
    }

    .theme2-hero-content {
        padding: 72px 0 54px;
    }

    .theme2-hero-content h1 {
        font-size: clamp(2.65rem, 13vw, 4.2rem);
    }

    .theme2-hero-content p {
        font-size: 1rem;
        line-height: 1.45;
    }

    .theme2-page-header,
    .theme2-page-header-simple,
    .theme2-page-header-modern,
    .theme2-listing-hero {
        min-height: 240px;
        padding: 62px 0 !important;
    }

    .theme2-page-header-content h1,
    .theme2-page-header-content-modern h1,
    .theme2-listing-hero-content h1 {
        font-size: clamp(2.5rem, 13vw, 4rem) !important;
    }

    .theme2-listing-info-modern {
        padding-left: 0 !important;
    }

    .theme2-gallery-thumbs-modern {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

@media (max-width: 575px) {
    .container,
    .container-fluid,
    .page-builder-section > .container {
        width: min(100% - 20px, 1240px);
    }

    .theme2-hero-slide {
        min-height: 390px;
    }

    .theme2-hero-content {
        padding-bottom: 42px;
    }

    .theme2-hero-carousel .carousel-control-prev,
    .theme2-hero-carousel .carousel-control-next {
        display: none;
    }

    .theme2-listings-grid-simple {
        grid-template-columns: 1fr !important;
        justify-content: stretch !important;
        gap: 20px !important;
    }

    .theme2-listing-image-simple,
    .theme2-featured-image {
        aspect-ratio: 16 / 11;
    }

    .theme2-footer-main-simple .row > [class*="col-"] {
        margin-bottom: 28px;
    }
}
