﻿/* /wwwroot/css/site.css (fix gọn dropdown + navbar sticky, bỏ rule sai gây phóng to/cắt) */

/* ===== Bootstrap default ===== */
html {
    font-size: 14px;
}

@media (min-width:768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 .1rem #fff,0 0 0 .25rem #258cfb;
}

html {
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 60px;
}

/* ===== Theme ===== */
:root {
    --bg: #0b1220;
    --panel: rgba(255,255,255,.06);
    --panel2: rgba(255,255,255,.08);
    --border: rgba(255,255,255,.12);
    --text: rgba(255,255,255,.92);
    --muted: rgba(255,255,255,.68);
    --shadow: 0 16px 40px rgba(0,0,0,.35);
    --shadow2: 0 10px 28px rgba(0,0,0,.30);
    --radius: 18px;
    --ring: 0 0 0 .25rem rgba(13,110,253,.25);
    --accent: #6ea8fe;
    --accent2: #a78bfa;
}

.site-body {
    font-family: Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
    color: var(--text);
    background: radial-gradient(1200px 600px at 15% 10%, rgba(110,168,254,.22), transparent 60%), radial-gradient(900px 520px at 85% 20%, rgba(167,139,250,.18), transparent 55%), radial-gradient(780px 520px at 50% 95%, rgba(34,211,238,.10), transparent 55%), linear-gradient(180deg, #070b14 0%, #0b1220 45%, #070b14 100%);
    overflow-x: hidden;
}

/* ===== Header/Navbar luôn hiện khi scroll ===== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 5000;
    border-bottom: 1px solid rgba(255,255,255,.08);
}

/* Navbar glass */
.navbar {
    background: rgba(11,18,32,.55);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(255,255,255,.08);
    overflow: visible; /* quan trọng: không cắt dropdown */
}

/* Đẩy nội dung xuống dưới navbar sticky (tự điều chỉnh nếu navbar cao hơn/thấp hơn) */
.site-main {
    min-height: 50vh;
    padding-top: 76px;
}

/* ===== Nav link ===== */
.navbar .nav-link {
    color: rgba(255,255,255,.78);
    border-radius: 12px;
    padding: .5rem .75rem;
}

    .navbar .nav-link:hover {
        color: #fff;
        background: rgba(255,255,255,.06);
    }

/* ===== Brand ===== */
/* CSS Logo Thương Hiệu HUY TICKET */
.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #003399 0%, #0056b3 100%); /* Màu xanh gradient sang trọng */
    color: white;
    border-radius: 8px; /* Bo góc mềm mại hơn */
    /* Căn chữ H vào giữa */
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 22px;
    font-family: sans-serif;
    /* Hiệu ứng bóng đổ nhẹ tạo chiều sâu 3D */
    box-shadow: 0 4px 6px rgba(0,0,0,0.2);
    /* Tạo hình vé rách 2 bên (Ticket stub effect) */
    /* Đây là kỹ thuật dùng mask để đục lỗ 2 bên */
    -webkit-mask: radial-gradient(circle at left center, transparent 4px, black 4.5px), radial-gradient(circle at right center, transparent 4px, black 4.5px);
    mask: radial-gradient(circle at left center, transparent 4px, black 4.5px), radial-gradient(circle at right center, transparent 4px, black 4.5px);
    /* Gộp mask lại để hiển thị phần còn lại */
    -webkit-mask-composite: source-over;
    mask-composite: add;
}

/* Hiệu ứng hover (rê chuột vào) cho logo thêm xịn */
.navbar-brand:hover .brand-icon {
    transform: translateY(-2px); /* Nhảy nhẹ lên */
    transition: all 0.3s ease;
    box-shadow: 0 6px 12px rgba(0, 51, 153, 0.4); /* Bóng xanh phát sáng */
}

/* ===== Input/Buttons ===== */
.input-glass {
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
}

    .input-glass .form-control {
        color: var(--text);
    }

        .input-glass .form-control::placeholder {
            color: rgba(255,255,255,.50);
        }

        .input-glass .form-control:focus {
            box-shadow: var(--ring);
        }

.btn-glass {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.14);
    color: var(--text);
    border-radius: 14px;
}

    .btn-glass:hover {
        background: rgba(255,255,255,.09);
        border-color: rgba(255,255,255,.22);
        color: #fff;
    }

.btn-gradient {
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(110,168,254,.95), rgba(167,139,250,.85));
}

    .btn-gradient:hover {
        filter: brightness(1.05);
    }

/* ===== Dropdown: KHUNG NHỎ, KHÔNG PHÓNG TO, KHÔNG CHÌM/CẮT ===== */
/* 1) Chỉ cần dropdown-menu absolute (mặc định bootstrap) + z-index cao */
.navbar .dropdown {
    position: relative;
}
/* anchor */
.navbar .dropdown-menu {
    position: absolute; /* giữ đúng */
    z-index: 6000;
    min-width: 220px;
    width: max-content; /* không full-width */
    max-width: 280px; /* tránh quá rộng */
    padding: 8px;
    border-radius: 14px;
    margin-top: 10px;
}

/* 2) BỎ rule SAI: .navbar .dropdown-menu { position: absolute !important; } vẫn ok, nhưng KHÔNG được set .dropdown-menu relative */
/* 3) BỎ rule SAI trước đó: .navbar .dropdown, .navbar .dropdown-menu { position: relative; } -> sẽ làm menu nằm trong flow */

/* 4) Style dropdown glass */
.dropdown-glass {
    background: rgba(11,18,32,.92);
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 16px 40px rgba(0,0,0,.35);
}

    .dropdown-glass .dropdown-item {
        color: rgba(255,255,255,.88);
        border-radius: 10px;
    }

        .dropdown-glass .dropdown-item:hover {
            background: rgba(255,255,255,.08);
            color: #fff;
        }

    .dropdown-glass .dropdown-divider {
        border-top-color: rgba(255,255,255,.10);
    }

/* ===== Hero ===== */
.hero {
    position: relative;
    padding: 36px 0 30px;
}

    .hero::before {
        content: "";
        position: absolute;
        inset: 0;
        background: radial-gradient(800px 280px at 50% 0%, rgba(110,168,254,.16), transparent 60%);
        pointer-events: none;
    }

    .hero .container {
        position: relative;
        z-index: 1;
    }

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: 10px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.85);
    font-size: 13px;
    box-shadow: var(--shadow2);
}

.hero-title {
    margin: 14px 0 10px;
    font-size: clamp(30px, 3.2vw, 44px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: .2px;
}

.hero-accent {
    background: linear-gradient(135deg, rgba(110,168,254,.95), rgba(167,139,250,.90));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-sub {
    color: var(--muted);
    max-width: 54ch;
    font-size: 15px;
    margin: 0 0 16px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.hero-stats {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.stat {
    min-width: 110px;
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.10);
}

.stat-k {
    font-weight: 800;
    font-size: 16px;
}

.stat-v {
    color: var(--muted);
    font-size: 13px;
}

.hero-card {
    border-radius: 22px;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    overflow: visible;
}

.hero-card-head {
    display: flex;
    gap: 10px;
    padding: 14px 14px 0;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: 8px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.10);
    color: rgba(255,255,255,.85);
    font-size: 12px;
}

.hero-card-body {
    padding: 14px;
}

.mini {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px;
    border-radius: 16px;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.10);
    margin-bottom: 10px;
}

.mini-icon {
    width: 38px;
    height: 38px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, rgba(110,168,254,.35), rgba(167,139,250,.22));
    border: 1px solid rgba(255,255,255,.10);
}

.mini-title {
    font-weight: 700;
}

.mini-sub {
    color: var(--muted);
    font-size: 13px;
    margin-top: 2px;
}

.divider {
    height: 1px;
    background: rgba(255,255,255,.10);
    margin: 12px 0;
}

/* ===== Footer ===== */
.site-footer {
    padding: 18px 0;
    background: rgba(11,18,32,.55);
    border-top: 1px solid rgba(255,255,255,.08);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

/* mobile */
@media (max-width:992px) {
    .hero {
        padding-top: 24px;
    }

    .site-main {
        padding-top: 70px;
    }
    /* navbar thường thấp hơn trên mobile */
}


/* ===== Movie Details polish  */
.movie-details .card-title-strong {
    font-weight: 800;
    letter-spacing: .2px
}

.movie-details .meta-line {
    color: rgba(255,255,255,.78);
    font-size: 14px
}

.movie-details .meta-chip {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: 8px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.88);
}

.movie-details .panel {
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 22px;
    box-shadow: 0 18px 48px rgba(0,0,0,.35);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.movie-details .panel-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 10px;
}

.movie-details .desc {
    color: rgba(255,255,255,.82);
    line-height: 1.55;
    max-height: 220px;
    overflow: auto;
    padding-right: 4px;
}

    .movie-details .desc::-webkit-scrollbar {
        height: 10px;
        width: 10px
    }

    .movie-details .desc::-webkit-scrollbar-thumb {
        background: rgba(255,255,255,.12);
        border-radius: 999px
    }

.movie-details .poster-wrap {
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
    border: 1px solid rgba(255,255,255,.12);
    box-shadow: 0 18px 50px rgba(0,0,0,.40);
    overflow: hidden;
}

    .movie-details .poster-wrap img {
        width: 100%;
        aspect-ratio: 2/3;
        object-fit: cover;
        display: block;
    }

.movie-details .poster-bottom {
    padding: 12px 12px 14px;
    background: rgba(11,18,32,.55);
    border-top: 1px solid rgba(255,255,255,.10);
}

.movie-details .btn-wide {
    width: 100%
}

.movie-details .showtime-group {
    padding: 14px 14px 12px;
    border-radius: 18px;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.10);
    margin-bottom: 12px;
}

.movie-details .showtime-title {
    font-weight: 800;
    color: rgba(255,255,255,.92);
}

.movie-details .showtime-sub {
    color: rgba(255,255,255,.68);
    font-size: 13px;
    margin-top: 2px;
}

.movie-details .time-chip {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.92);
    text-decoration: none;
}

    .movie-details .time-chip:hover {
        background: rgba(255,255,255,.10);
        border-color: rgba(255,255,255,.22)
    }

    .movie-details .time-chip .t {
        font-weight: 900
    }

    .movie-details .time-chip .room {
        color: rgba(255,255,255,.70);
        font-size: 12px;
        margin-left: 4px;
    }

.movie-details .buy-cta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 10px
}

.movie-details .btn-primary-cta {
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(110,168,254,.98), rgba(167,139,250,.90));
    color: #071022;
    font-weight: 900;
}

    .movie-details .btn-primary-cta:hover {
        filter: brightness(1.06)
    }

.movie-details .btn-soft {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    color: rgba(255,255,255,.92);
    border-radius: 16px;
}

    .movie-details .btn-soft:hover {
        background: rgba(255,255,255,.10);
        border-color: rgba(255,255,255,.22)
    }
/* tăng sáng nền khu chi tiết */
.movie-details {
    position: relative;
}

    .movie-details::before {
        content: "";
        position: absolute;
        inset: -24px -12px -24px -12px;
        background: radial-gradient(900px 420px at 15% 15%, rgba(110,168,254,.18), transparent 60%), radial-gradient(900px 420px at 85% 35%, rgba(167,139,250,.16), transparent 60%);
        pointer-events: none;
        z-index: 0;
    }

    .movie-details > * {
        position: relative;
        z-index: 1;
    }


.glass-panel {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 16px 40px rgba(0,0,0,.35);
}

.screen {
    display: inline-block;
    padding: 10px 18px;
    border-radius: 999px;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.85);
    font-weight: 700;
}

.seat-map {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.seat-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.row-label {
    width: 26px;
    text-align: center;
    color: rgba(255,255,255,.75);
    font-weight: 700;
}

.row-seats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.seat {
    width: 44px;
    height: 38px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.9);
    font-weight: 700;
}

.seat-sm {
    width: 14px;
    height: 14px;
    border-radius: 6px;
    display: inline-block;
    border: 1px solid rgba(255,255,255,.18);
}

.seat.available {
    background: rgba(255,255,255,.06);
}

.seat.selected {
    background: rgba(110,168,254,.35);
    border-color: rgba(110,168,254,.55);
}

.seat.held {
    background: rgba(255,193,7,.18);
    border-color: rgba(255,193,7,.45);
    color: rgba(255,255,255,.85);
}

.seat.sold {
    background: rgba(220,53,69,.20);
    border-color: rgba(220,53,69,.45);
    color: rgba(255,255,255,.85);
}

.seat:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,.75);
}

.btn-gradient {
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(110,168,254,.95), rgba(167,139,250,.85));
    color: #081024;
    font-weight: 800;
}
