/* ==========================================================================
   TABS & ACCOUNT MODULE CSS
   Moved from trangchu.css to prevent conflicts & improve maintainability.
   Contains styles for: Tabs, Account Cards, Rental Cards, and Rental Modal.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. TABS STYLES (Glassmorphism & Backgrounds)
   -------------------------------------------------------------------------- */
.tabs {
    display: flex;
    justify-content: flex-start;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    padding: 10px;
    /* Add padding for shadow visibility */
}

/* Define Tab Colors via Attributes */
.tab-btn[data-tab-name="Mới nhất"] {
    --tab-color: #06b6d4;
    --tab-bg-custom: var(--tab-bg-mới-nhất);
}

.tab-btn[data-tab-name="Account"] {
    --tab-color: #f97316;
    --tab-bg-custom: var(--tab-bg-account);
}

.tab-btn[data-tab-name="Thuê Acc"] {
    --tab-color: #d946ef;
    --tab-bg-custom: var(--tab-bg-thuê-acc);
}

.tab-btn[data-tab-name="Nạp Game"] {
    --tab-color: #3b82f6;
    --tab-bg-custom: var(--tab-bg-nạp-game);
}

.tab-btn[data-tab-name="Bán Lại"] {
    --tab-color: #10b981;
    --tab-bg-custom: var(--tab-bg-bán-lại);
}

.tab-btn[data-tab-name="Treo Bán"] {
    --tab-color: #8b5cf6;
}

.tab-btn[data-tab-name="Item"] {
    --tab-color: #f43f5e;
}

.tab-btn[data-tab-name="Robux"] {
    --tab-color: #0ea5e9;
}

.tab-btn[data-tab-name="Random"] {
    --tab-color: #eab308;
}

.tab-btn {
    --tab-color: #64748b;
    /* Fallback */
    position: relative;
    padding: 10px 20px;
    border-radius: 12px;

    /* Glass Effect (Inactive State) */
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);

    font-weight: 700;
    color: #ffffff;
    /* Default text white for contrast on glass/bg */
    text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000;

    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    min-width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 10;
}

/* Background Image Layer */
.tab-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: var(--tab-bg-custom);
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    opacity: 0.8;
    /* Slightly see-through default */
    transition: all 0.3s ease;
    border-radius: 12px;
}

.tab-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.tab-btn.active {
    background: rgba(255, 255, 255, 0.4);
    color: var(--tab-color);
    border-color: var(--tab-color);
    box-shadow: 0 0 15px var(--tab-color);
    text-shadow: none;
    /* Active gets clean text */
}

/* Ensure background is fully visible on active if needed, or customize */
.tab-btn.active::before {
    opacity: 1;
}

/* Hide Text Class */
.tab-btn.hide-text {
    color: transparent !important;
    text-shadow: none !important;
}

/* Trigger Light Sweep on Active Button */
.tab-btn.active::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.8) 50%,
            rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
    z-index: 10;
    /* Ensure visible but NOT clickable */
    pointer-events: none !important;
    animation: lightSweep 3s infinite ease-in-out;
}

@keyframes lightSweep {
    0% {
        left: -100%;
        opacity: 0;
    }

    5% {
        opacity: 1;
    }

    40% {
        left: 200%;
        opacity: 0;
    }

    100% {
        left: 200%;
        opacity: 0;
    }
}

.tab-content {
    display: none;
    animation: fadeIn 0.4s ease;
}

.tab-content.active {
    display: block;
}

/* --------------------------------------------------------------------------
   2. ACCOUNT CARD STYLES (Sales)
   -------------------------------------------------------------------------- */
.product-grid {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 20px !important;
    padding: 16px;
    width: 100% !important;
}

/* --------------------------------------------------------------------------
   SKY BLOCK MARKETPLACE (Horizontal Item List)
   -------------------------------------------------------------------------- */

.product-grid.skyblock-mode {
    display: block !important;
    grid-template-columns: none !important;
    gap: 0 !important;
    padding: 0 !important;
}

/* Host for top coin panel (inserted below .tabs when Sky Block active) */
#skyblock-top-coin-panel {
    padding: 0 6px;
    margin: 0 0 10px 0;
}

#skyblock-top-coin-panel .sky-coin-panel {
    margin: 0;
}

.main-area .tabs {
    margin-bottom: 10px;
}

.main-area #skyblock-top-coin-panel {
    margin-top: 0;
}

.skyblock-market {
    width: 100%;
}

.skyblock-controls {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    padding: 8px 6px 6px;
}

.skyblock-search {
    flex: 1;
}

.skyblock-search input {
    width: 100%;
    height: 44px;
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: #ffffff;
    padding: 0 14px;
    font-weight: 700;
    outline: none;
}

.skyblock-sort-select {
    height: 44px;
    border-radius: 14px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: #ffffff;
    padding: 0 12px;
    font-weight: 800;
    outline: none;
}

.skyblock-chips {
    display: flex;
    gap: 10px;
    padding: 4px 6px 6px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.sky-chip {
    flex: 0 0 auto;
    height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: rgba(255, 255, 255, 0.9);
    font-weight: 900;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
}

.sky-chip.active {
    background: rgb(130 255 225 / 57%);
    border-color: rgb(27 192 153 / 85%);
}

.skyblock-list {
    display: grid;
    gap: 14px;
    padding: 8px 6px 14px;
}

.sky-empty {
    text-align: center;
    padding: 30px 10px;
    color: #64748b;
    font-weight: 800;
}

.sky-item-card {
    display: grid;
    grid-template-columns: 92px 1fr 260px;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 23, 42, 0.10);
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
}

.sky-item-media {
    width: 92px;
    height: 92px;
    border-radius: 14px;
    overflow: hidden;
    border: 0;
    padding: 0;
    background: #f1f5f9;
    cursor: pointer;
}

.sky-item-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.sky-item-title {
    font-size: 18px;
    font-weight: 950;
    color: #0f172a;
    line-height: 1.1;
}

.sky-item-sub {
    margin-top: 8px;
    font-size: 13px;
    font-weight: 950;
    color: #F44336;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.sky-item-dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: #ff6800;
    display: inline-block;
}

.sky-item-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.sky-item-cta {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
}

.sky-item-price {
    margin-top: 7px;
    font-size: 22px;
    font-weight: 950;
    color: #ff4b00;
    letter-spacing: -0.2px;
}

.sky-item-buy {
    height: 42px;
    min-width: 170px;
    padding: 0 55px 0 26px;

    /* 👉 cho nút tụt xuống so với tiêu đề, canh với giá */
    margin-top: 48px;

    border: none;
    border-radius: 10px;
    background: linear-gradient(90deg, #62ffd8 0%, #1dbbf0 100%);
    color: #ffffff;

    font-size: 15px;
    font-weight: 800;
    cursor: pointer;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    position: relative;
    overflow: visible;

    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.12);
    transition: all 0.2s ease;
}

/* Phần đuôi vát chéo bên phải */
.sky-item-buy::after {
    content: "";
    position: absolute;
    right: -22px;
    top: 0;

    width: 26px;
    height: 100%;

    background: linear-gradient(90deg, #1dbbf0 0%, #1dbbf0 100%);
    transform: skewX(-20deg);

    border-radius: 0 8px 8px 0;
}

/* Chữ trong nút */
.sky-item-buy-text {
     letter-spacing: 0.4px;
    position: relative;
    z-index: 2;

    font-weight: 800;       /* giữ độ đậm */
    font-style: normal;    /* không dùng italic thật */
    display: inline-block;

    transform: skewX(-8deg); /* nghiêng nhưng KHÔNG mỏng chữ */
}

/* Hover */
.sky-item-buy:hover {
    filter: brightness(1.05);
}

/* Click */
.sky-item-buy:active {
    transform: translateY(1px);
}
/* Coin panel */
.sky-coin-panel {
    margin: 10px 6px 6px;
    padding: 35px 24px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.14) 0%, rgba(59, 130, 246, 0.12) 100%);
    border: 1px solid rgba(15, 23, 42, 0.10);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.sky-coin-title {
    font-weight: 950;
    color: #0f172a;
    letter-spacing: 0.4px;
}

.sky-coin-sub {
    margin-top: 4px;
    color: #64748b;
    font-weight: 800;
    font-size: 13px;
}

.sky-coin-rates {
    margin-top: 8px;
    display: grid;
    gap: 4px;
    color: #0f172a;
    font-weight: 800;
    font-size: 13px;
}

.sky-coin-cta {
    height: 44px;
    padding: 0 16px;
    border: 0;
    border-radius: 14px;
    font-weight: 950;
    color: #ffffff;
    cursor: pointer;
    background: linear-gradient(135deg, #22c55e 0%, #3b82f6 100%);
}

/* Media modal */
.sb-media-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
}

.sb-media-modal.open {
    display: block;
}

.sb-media-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.55);
}

.sb-media-dialog {
    position: relative;
    width: min(520px, calc(100vw - 24px));
    margin: 70px auto 0;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(15, 23, 42, 0.10);
    box-shadow: 0 30px 70px rgba(2, 6, 23, 0.35);
    padding: 14px;
}

.sb-media-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    border: 0;
    background: rgba(15, 23, 42, 0.08);
    cursor: pointer;
    font-size: 20px;
    font-weight: 900;
}

.sb-media-title {
    padding: 6px 44px 10px 6px;
    font-weight: 950;
    color: #0f172a;
}

.sb-media-body {
    padding: 4px 6px 8px;
}

.sb-layer-wrap {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 16px;
    overflow: hidden;
    background: #f1f5f9;
    position: relative;
}

.sb-layer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.sb-model-viewer {
    width: 100%;
    height: 420px;
    background: #f1f5f9;
    border-radius: 16px;
}

@media (max-width: 640px) {
    .sky-item-card {
        grid-template-columns: 92px 1fr;
    }

    .sky-item-right {
        grid-column: 1 / -1;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .sky-item-title {
        font-size: 16px;
    }

    .sky-item-price {
        font-size: 18px;
    }

    .sky-item-cta {
        justify-content: space-between;
        width: 100%;
    }
}

@media (max-width: 1200px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 1fr !important;
    }
}

.product-card {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    max-width: 100%;
    /* Forced Width/Margin for Grid Fix */
    width: auto !important;
    margin: 0 !important;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    border-color: #cbd5e1;
}

/* Image Area - Match Rental Tab */
.product-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: #f1f5f9;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
    z-index: 1;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

@media (min-width: 1024px) {
    .product-image-wrapper {
        width: 100%;
        aspect-ratio: 16 / 9;
    }

    .product-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

/* Info Area - Match Rental Tab */
.product-info {
    padding: 14px;
    /* Matched Rental */
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 6px;
}

@media (min-width: 1024px) {
    .product-card {
        max-height: 410px;
        overflow: hidden;
    }

    .product-info {
        padding: 12px;
        gap: 6px;
    }
}

/* Meta Row */
.product-meta-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: #5d2400;
    font-weight: 600;
}

.product-tag {
    background: rgb(227 210 238 / 25%);
    padding: 3px 8px;
    border-radius: 6px;
    color: #6d008a;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.product-game-name {
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Price Row */
.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-bottom: 8px;
    min-height: auto;
}

.product-price-current {
    font-size: 1.3rem;
    font-weight: 800;
    color: #fe3e2b;
    line-height: 1;
}

.product-price-old {
    font-size: 0.85rem;
    text-decoration: line-through;
    color: #94a3b8;
    font-weight: 600;
}

.product-price-sold {
    font-size: 16px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
}

/* Title */
.product-title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: auto;
    margin-bottom: 12px;
}

/* Desc */
.product-desc-wrapper {
    flex: 1;
    margin-bottom: 8px;
    display: none;
}

.product-desc {
    display: none;
}

/* Card Action Button */
.btn-card-action {
    display: block;
    width: 100%;
    text-align: center;
    padding: 10px 0;
    border: none;
    background: linear-gradient(135deg, #f8b81e 0%, #ff0000de 100%);
    color: #ffffff;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 12px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.2s;
    margin-top: auto;
    box-shadow: 0 4px 10px rgba(255, 152, 0, 0.25);
}

.btn-card-action:hover {
    background: linear-gradient(135deg, #ffcc80 0%, #fb8c00 100%);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.18);
}

.btn-card-action.disabled {
    border-color: #cbd5e1;
    color: #cbd5e1;
    background: #f8fafc;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-card-action.sold {
    background: #e2e8f0;
    color: #64748b;
    border: 1px solid #cbd5e1;
    cursor: not-allowed;
    pointer-events: none;
    box-shadow: none;
}

/* Sold Stamp Overlay */
.sold-stamp {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-15deg);
    border: 3px solid #ef4444;
    color: #ef4444;
    font-size: 20px;
    font-weight: 900;
    padding: 6px 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
    z-index: 9999;
    background: transparent;
    border-radius: 8px;
    white-space: nowrap;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    opacity: 1;
    pointer-events: none;
}

.product-card.sold-card .product-image img {
    filter: grayscale(100%);
    opacity: 0.7;
}

/* --------------------------------------------------------------------------
   3. RENTAL CARD STYLES
   -------------------------------------------------------------------------- */
.rental-grid-custom {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
    padding: 16px;
}

@media (max-width: 768px) {
    .rental-grid-custom {
        grid-template-columns: repeat(2, 1fr);
        /* Force 2 columns on mobile/tablet */
        gap: 12px;
        padding: 10px;
    }
}

.rental-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 4px 20px rgba(100, 116, 139, 0.1);
    display: flex;
    flex-direction: column;
}

.rental-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(236, 72, 153, 0.2), 0 0 15px rgba(236, 72, 153, 0.3);
    z-index: 5;
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(236, 72, 153, 0.3);
}

.rental-card.status-available {
    border: 1px solid rgba(34, 197, 94, 0.4);
}

.rental-card.status-available:hover {
    border-color: #22c55e;
    box-shadow: 0 12px 28px rgba(34, 197, 94, 0.15), 0 0 15px rgba(34, 197, 94, 0.2);
}

.rental-card.status-renting {
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.rental-card.status-renting:hover {
    border-color: #ef4444;
    box-shadow: 0 12px 28px rgba(239, 68, 68, 0.15), 0 0 15px rgba(239, 68, 68, 0.2);
}

.rental-card.status-renting {
    transform: none;
}

.rental-rented-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-12deg);
    border: 2px solid #ef4444;
    color: #ef4444;
    font-weight: 900;
    font-size: 14px;
    padding: 6px 10px;
    border-radius: 10px;
    background: rgb(252 237 231 / 84%);
    letter-spacing: 1px;
    text-transform: uppercase;
    z-index: 12;
    pointer-events: none;
}

.rental-countdown-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 10px;
    margin: 6px 0 10px;
    border-radius: 12px;
    background: #fff7ed;
    border: 1px solid rgba(251, 146, 60, 0.35);
}

.rental-countdown-label {
    font-size: 12px;
    font-weight: 800;
    color: #9a3412;
}

.rental-countdown {
    font-size: 12px;
    font-weight: 900;
    color: #dc2626;
    font-variant-numeric: tabular-nums;
}

.rental-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
    overflow: hidden;
}

.rental-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.rental-card:hover .rental-image-wrapper img {
    transform: scale(1.05);
}

.rental-badge-pill {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 4px;
    z-index: 10;
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.rental-badge-pill.available {
    background: rgb(173 246 176 / 95%);
    color: #166534;
    border: 1px solid #22c55e;
}

.rental-badge-pill.renting {
    background: rgb(241 161 161 / 95%);
    color: #991b1b;
    border: 1px solid #ef4444;
}

.rental-info {
    padding: 14px;
    flex: 1;
    display: flex;
    flex-direction: column;
    background: transparent;
}

.rental-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.rental-tag {
    background: rgb(157 1 196 / 9%);
    color: #45008f;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.rental-price-row {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-bottom: 8px;
}

.rental-price-value {
    font-size: 1.3rem;
    font-weight: 800;
    color: #ff401a;
    text-shadow: none;
    margin: 0;
    line-height: 1;
}

.rental-card.status-available .rental-price-value {
    color: #0ea5e9;
    text-shadow: none;
}

.rental-price-unit {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 600;
}

.rental-title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 12px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: none;
}

.btn-rental {
    width: 100%;
    padding: 10px 0;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: auto;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.btn-rental.available {
    background: linear-gradient(135deg, #38bdf8 0%, #3b82f6 100%);
    color: white;
}

.btn-rental.available:hover {
    background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 12px rgba(14, 165, 233, 0.3);
}

.btn-rental.renting {
    background: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    border: 1px solid #cbd5e1;
    box-shadow: none;
}

.btn-rental.renting:hover {
    background: #cbd5e1;
}

/* --------------------------------------------------------------------------
   4. RENTAL DETAIL MODAL V2
   -------------------------------------------------------------------------- */
.rental-detail-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.rental-detail-content {
    background: white;
    width: 900px;
    max-width: 95%;
    max-height: 90vh;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.rental-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.rental-modal-close:hover {
    background: rgba(0, 0, 0, 0.8);
}

.rental-modal-left {
    flex: 1.5;
    background: #0f172a;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    min-height: 400px;
}

.rental-modal-right {
    flex: 1;
    padding: 24px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    background: white;
}

.rental-modal-game-title {
    font-size: 13px;
    font-weight: 700;
    color: #6366f1;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.rental-modal-title {
    margin: 0 0 16px 0;
    font-size: 24px;
    color: #1e293b;
    font-weight: 800;
}

.rental-modal-price-box {
    background: #f8fafc;
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    border: 1px solid #e2e8f0;
}

.rental-modal-price-label {
    font-size: 14px;
    color: #64748b;
    margin-bottom: 4px;
}

.rental-modal-price-value {
    font-size: 28px;
    font-weight: 800;
    color: #059669;
}

.rental-modal-desc-box {
    margin-bottom: 24px;
}

.rental-modal-desc-title {
    margin: 0 0 8px 0;
    color: #334155;
    font-weight: 700;
}

.rental-modal-desc-text {
    margin: 0;
    color: #64748b;
    line-height: 1.6;
    white-space: pre-line;
    font-size: 14px;
}

.rent-input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
}

.rent-input-btn {
    width: 44px;
    height: 44px;
    font-size: 20px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: white;
    cursor: pointer;
}

.rent-days-input {
    flex: 1;
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: white;
    height: 44px;
}

.btn-rent-confirm {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.2);
    transition: transform 0.2s;
}

.btn-rent-confirm:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}

@media (max-width: 768px) {
    .rental-detail-content {
        flex-direction: column;
        height: 90vh;
        width: 90%;
    }

    .rental-modal-left {
        flex: none;
        height: 250px;
        min-height: auto;
        width: 100%;
    }

    .rental-modal-right {
        flex: 1;
        padding: 16px;
        overflow-y: auto;
    }

    .rental-modal-title {
        font-size: 20px;
    }
}