/* ==========================================================================
   Bridges Explorer Stylesheets - Incredible India Explorer
   ========================================================================== */

:root {
    --bridges-accent: var(--saffron);
    --bridges-cyan: #00b4d8;
    --bridges-gold: var(--gold);
    --bridges-bg: var(--bg-dark);
    --bridges-surface: rgba(255, 255, 255, 0.06);
    --bridges-surface-hover: rgba(255, 255, 255, 0.12);
    --bridges-border: rgba(255, 255, 255, 0.12);
    --bridges-text: #f0f4f8;
    --bridges-muted: #94a3b8;
    --bridges-card-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

.light-theme {
    --bridges-bg: #f8fafc;
    --bridges-surface: rgba(255, 255, 255, 0.9);
    --bridges-surface-hover: #ffffff;
    --bridges-border: rgba(0, 0, 0, 0.12);
    --bridges-text: #0f172a;
    --bridges-muted: #475569;
    --bridges-card-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.bridges-page {
    min-height: 100vh;
    background-color: var(--bridges-bg);
    color: var(--bridges-text);
}

/* --- Hero Section --- */
.bridges-hero {
    position: relative;
    isolation: isolate;
    min-height: 65vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 20px 60px;
    background: 
        linear-gradient(135deg, rgba(10, 17, 24, 0.92), rgba(12, 45, 60, 0.85)),
        url("assets/river1.png") center/cover no-repeat;
    overflow: hidden;
}

.bridges-hero::before {
    content: "";
    position: absolute;
    top: -120px;
    left: 50%;
    transform: translateX(-50%);
    width: 650px;
    height: 420px;
    background: radial-gradient(circle, rgba(0, 180, 216, 0.22), transparent 70%);
    z-index: -1;
    pointer-events: none;
}

.hero-content {
    max-width: 880px;
    margin: 0 auto;
}

.hero-kicker {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    background: rgba(0, 180, 216, 0.15);
    border: 1px solid rgba(0, 180, 216, 0.35);
    color: var(--bridges-cyan);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.bridges-hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.4rem, 5vw, 3.8rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}

.bridges-hero h1 span {
    background: linear-gradient(120deg, var(--bridges-cyan), var(--bridges-gold));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.bridges-hero p {
    font-size: 1.15rem;
    color: var(--bridges-muted);
    line-height: 1.6;
    margin-bottom: 36px;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-bottom: 36px;
    flex-wrap: wrap;
}

.stat-box {
    background: var(--bridges-surface);
    border: 1px solid var(--bridges-border);
    padding: 16px 24px;
    border-radius: 14px;
    backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 140px;
}

.stat-box strong {
    font-size: 1.6rem;
    color: var(--bridges-gold);
    font-weight: 800;
}

.stat-box span {
    font-size: 0.85rem;
    color: var(--bridges-muted);
}

.hero-cta {
    display: inline-block;
    padding: 14px 32px;
    border-radius: 30px;
    background: linear-gradient(135deg, var(--bridges-cyan), #0077b6);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 6px 20px rgba(0, 180, 216, 0.35);
}

.hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 180, 216, 0.5);
}

/* --- Explorer Section --- */
.bridges-section {
    padding: 60px 20px 80px;
    max-width: 1320px;
    margin: 0 auto;
}

.section-heading {
    text-align: center;
    margin-bottom: 40px;
}

.section-badge {
    color: var(--bridges-cyan);
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.section-heading h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    margin: 8px 0 12px;
}

.section-heading p {
    color: var(--bridges-muted);
    font-size: 1.05rem;
}

/* --- Controls Toolbar --- */
.explorer-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    background: var(--bridges-surface);
    border: 1px solid var(--bridges-border);
    padding: 24px;
    border-radius: 16px;
    backdrop-filter: blur(12px);
    margin-bottom: 24px;
}

.control-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.control-field.search-field {
    grid-column: 1 / -1;
}

@media (min-width: 992px) {
    .control-field.search-field {
        grid-column: span 2;
    }
}

.control-field label {
    font-size: 0.82rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--bridges-muted);
}

.control-field input,
.control-field select {
    padding: 12px 16px;
    border-radius: 10px;
    border: 1px solid var(--bridges-border);
    background: rgba(0, 0, 0, 0.25);
    color: var(--bridges-text);
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s ease;
}

.light-theme .control-field input,
.light-theme .control-field select {
    background: #ffffff;
}

.control-field input:focus,
.control-field select:focus {
    border-color: var(--bridges-cyan);
    box-shadow: 0 0 0 3px rgba(0, 180, 216, 0.2);
}

/* Results Toolbar */
.results-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 0 4px;
}

#result-status {
    font-size: 0.95rem;
    color: var(--bridges-muted);
    font-weight: 500;
}

.btn-clear, .btn-reset {
    background: transparent;
    border: 1px solid var(--bridges-border);
    color: var(--bridges-cyan);
    padding: 8px 18px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.88rem;
    transition: all 0.2s ease;
}

.btn-clear:hover, .btn-reset:hover {
    background: rgba(0, 180, 216, 0.15);
    border-color: var(--bridges-cyan);
}

/* --- Cards Grid --- */
.bridges-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
    gap: 28px;
}

/* Bridge Card */
.bridge-card {
    background: var(--bridges-surface);
    border: 1px solid var(--bridges-border);
    border-radius: 18px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
}

.bridge-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--bridges-card-shadow);
    border-color: rgba(0, 180, 216, 0.5);
    background: var(--bridges-surface-hover);
}

.card-image-wrap {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.card-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.bridge-card:hover .card-image-wrap img {
    transform: scale(1.06);
}

.card-badge {
    position: absolute;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(8px);
}

.state-badge {
    top: 12px;
    left: 12px;
    background: rgba(10, 17, 24, 0.85);
    color: var(--bridges-gold);
    border: 1px solid rgba(246, 196, 83, 0.4);
}

.type-badge {
    top: 12px;
    right: 12px;
    background: rgba(0, 180, 216, 0.9);
    color: #fff;
}

.card-body {
    padding: 22px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-location {
    font-size: 0.82rem;
    color: var(--bridges-cyan);
    font-weight: 600;
    margin-bottom: 6px;
}

.card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 14px;
    color: var(--bridges-text);
}

.card-specs {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 0.86rem;
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 14px;
    border: 1px solid var(--bridges-border);
}

.light-theme .card-specs {
    background: rgba(0, 0, 0, 0.04);
}

.card-specs div strong {
    color: var(--bridges-gold);
}

.card-highlights {
    font-size: 0.9rem;
    color: var(--bridges-muted);
    line-height: 1.5;
    margin-bottom: 18px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.btn-view-details {
    width: 100%;
    padding: 10px 16px;
    border-radius: 10px;
    background: transparent;
    border: 1px solid var(--bridges-cyan);
    color: var(--bridges-cyan);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    margin-top: auto;
}

.btn-view-details:hover {
    background: var(--bridges-cyan);
    color: #fff;
}

/* --- Empty State --- */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--bridges-surface);
    border: 1px dashed var(--bridges-border);
    border-radius: 18px;
    margin-top: 20px;
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.empty-state h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
}

.empty-state p {
    color: var(--bridges-muted);
    max-width: 460px;
    margin: 0 auto 20px;
}

/* --- Modal --- */
.bridge-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
}

.bridge-modal-overlay[hidden] {
    display: none !important;
}

.bridge-modal-content {
    background: var(--bridges-bg);
    border: 1px solid var(--bridges-border);
    width: min(780px, 100%);
    max-height: 90vh;
    border-radius: 20px;
    padding: 32px;
    position: relative;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
}

.modal-close-btn {
    position: absolute;
    top: 18px;
    right: 22px;
    background: transparent;
    border: none;
    color: var(--bridges-muted);
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s ease;
}

.modal-close-btn:hover {
    color: var(--bridges-cyan);
}

.modal-header {
    margin-bottom: 20px;
    padding-right: 40px;
}

.modal-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.modal-tag {
    font-size: 0.78rem;
    padding: 4px 10px;
    border-radius: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.state-tag { background: rgba(246, 196, 83, 0.15); color: var(--bridges-gold); border: 1px solid rgba(246, 196, 83, 0.3); }
.type-tag { background: rgba(0, 180, 216, 0.15); color: var(--bridges-cyan); border: 1px solid rgba(0, 180, 216, 0.3); }

.modal-bridge-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    line-height: 1.3;
}

.modal-subtitle {
    font-size: 0.95rem;
    color: var(--bridges-muted);
    margin-top: 4px;
}

.modal-hero-img-wrap {
    width: 100%;
    height: 250px;
    border-radius: 14px;
    overflow: hidden;
    margin-bottom: 24px;
}

.modal-hero-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-specs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}

.spec-card {
    background: var(--bridges-surface);
    border: 1px solid var(--bridges-border);
    padding: 14px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
}

.spec-label {
    font-size: 0.78rem;
    color: var(--bridges-muted);
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 4px;
}

.spec-value {
    font-size: 1.05rem;
    color: var(--bridges-gold);
}

.modal-section {
    margin-bottom: 20px;
}

.modal-section h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    margin-bottom: 8px;
    color: var(--bridges-cyan);
}

.modal-text {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--bridges-text);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: 24px;
    padding-top: 18px;
    border-top: 1px solid var(--bridges-border);
}

.btn-modal-action {
    padding: 10px 20px;
    border-radius: 20px;
    background: var(--bridges-surface);
    border: 1px solid var(--bridges-border);
    color: var(--bridges-text);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-modal-action:hover {
    background: var(--bridges-cyan);
    color: #fff;
    border-color: var(--bridges-cyan);
}

.modal-nav-btns {
    display: flex;
    gap: 10px;
}

body.modal-open {
    overflow: hidden;
}
