@import url("../libs/toastr/toastr.min.css");
@import url("../libs/fastadmin-layer/dist/theme/default/layer.css");

/* ===== 全域 ===== */
:root {
    --main-color: #800020;
    --accent-color: #b3003c;
}

body {
    background: #0e0e0e;
    color: #f8f9fa;
    font-family: "Noto Sans TC";
    font-optical-sizing: auto;
}

.header-spacer {
    height: 60px;
}

/* ===== Profile Header ===== */
.profile-header {
    background: #000;
}

.profile-cover {
    width: 100%;
    height: 220px;
    background-size: cover;
    background-position: center;
    filter: brightness(.9);
}

@media (min-width:768px) {
    .profile-cover {
        height: 480px;
    }
}

/* ===== Stack（頭像半蓋 Banner） ===== */
.profile-stack {
    max-width: 820px;
    margin: 0 auto;
    position: relative;
    margin-top: -60px;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid #0e0e0e;
    box-shadow: 0 0 0 2px var(--accent-color);
    background: #111;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-name {
    color: #fff;
    font-size: 1.6rem;
}

.profile-id {
    font-size: .95rem;
}

.profile-bio {
    color: #ddd;
    line-height: 1.6;
    max-width: 680px;
    margin: 0 auto;
}

/* ===== 社群列 ===== */
.profile-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid #333;
    border-radius: 50%;
    margin: 0 .25rem;
    color: #ccc;
    text-decoration: none;
    font-size: 1rem;
}

.profile-social a:hover {
    color: #fff;
    border-color: var(--accent-color);
}

.profile-social .x-icon svg {
    width: 18px;
    height: 18px;
    fill: #ccc;
    display: block;
}

.profile-social .x-icon:hover svg {
    fill: #fff;
}

/* ===== Tabs：底線式、手機三等分／桌機靠左 ===== */
.profile-tabs {
    background: transparent;
    border-bottom: 1px solid #2a2a2a;
}

.profile-pillbar {
    display: flex;
    gap: 0;
    padding: 0;
    border-bottom: 1px solid #2a2a2a;
}

.profile-pillbar .nav-link {
    position: relative;
    background: transparent;
    color: #ddd;
    border: none;
    border-radius: 0;
    font-weight: 600;
}

.profile-pillbar .nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 3px;
    background: transparent;
    transition: background .2s ease;
}

.profile-pillbar .nav-link.active,
.profile-pillbar .nav-link:hover {
    color: #fff;
}

.profile-pillbar .nav-link.active::after,
.profile-pillbar .nav-link:hover::after {
    background: var(--accent-color);
}

/* 移除選中藍底，只保留底線與白字 */
.profile-pillbar .nav-link.active,
.profile-pillbar .nav-link:focus {
    background: transparent !important;
    color: #fff !important;
    box-shadow: none !important;
}

/* 分頁顯示控制（缺這兩行會看起來沒切換） */
.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* 手機：平均三等分置中 */
@media (max-width: 767.98px) {
    #profileTabs {
        width: 100%;
        justify-content: center;
    }

    .profile-pillbar .nav-item {
        flex: 1 1 0;
    }

    .profile-pillbar .nav-link {
        width: 100%;
        text-align: center;
        padding: .65rem 0;
    }
}

/* 桌機：靠左 */
@media (min-width: 768px) {
    .profile-pillbar {
        justify-content: flex-start;
    }

    .profile-pillbar .nav-item {
        flex: 0 0 auto;
    }

    .profile-pillbar .nav-link {
        padding: .7rem 1.1rem;
        text-align: left;
    }
}

/* ===== 卡片（影片／商品共用，上圖下文） ===== */
.video-card {
    background: #111;
    border: 1px solid #333;
    border-radius: 0;
    overflow: hidden;
    position: relative;
}

.video-img-top {
    width: 100%;
    aspect-ratio: 16/9;
    height: auto;
    object-fit: cover;
    display: block;
}

.video-meta {
    background: #1a1a1a;
    padding: 6px 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-height: 96px;
}

.video-meta .vm-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.video-title {
    font-size: .95rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-views {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    color: #bbb;
    font-size: .85rem;
}

.video-views i {
    font-size: 1rem;
    line-height: 1;
}

.video-content {
    font-size: .85rem;
    color: #aaa;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
    min-height: 36px;
}

.video-price {
    font-weight: 700;
    color: #ffc107;
}

/* ===== Footer（base_new 專用） ===== */
footer.custom-footer {
    background: #1a1a1a;
    color: #ccc;
    padding: 2rem 0;
}

footer.custom-footer a {
    color: #ccc;
    text-decoration: none;
}

footer.custom-footer a:hover {
    color: var(--accent-color);
}

footer.custom-footer .social-icons {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

footer.custom-footer .social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid #333;
    border-radius: 50%;
}

footer.custom-footer .social-icons i {
    font-size: 18px;
    line-height: 1;
}

footer.custom-footer .social-icons svg {
    width: 18px;
    height: 18px;
    display: block;
    fill: #ccc;
}

footer.custom-footer .social-icons svg:hover {
    fill: var(--accent-color);
}

.skeleton-card {
    background: #222;
    overflow: hidden;
}

.skeleton-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #333;
}

.skeleton-lines {
    padding: 0.5rem;
}

.skeleton-line {
    height: 10px;
    background: #333;
    border-radius: 4px;
    margin-bottom: 6px;
}

@keyframes shimmer {
    0% {
        background-position: -400px 0;
    }

    100% {
        background-position: 400px 0;
    }
}

.shimmer {
    background: linear-gradient(90deg, #333 25%, #444 50%, #333 75%);
    background-size: 800px 100%;
    animation: shimmer 1.2s infinite linear;
}

.navbar-brand {
    font-size: 1.3rem;
    color: #fff !important;
    letter-spacing: 0.5px;
}

@media (max-width: 768px) {
    .navbar-brand {
        font-size: 1.1rem;
    }
}

/* 半透明 header */
#mainHeader {
    background: rgba(0, 0, 0, 0.5);
    /* 純半透明黑 */
    height: 50px;
    /* 高度縮小 */
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* LOGO */
#mainHeader .navbar-brand {
    font-size: 1.1rem;
    color: #fff !important;
    padding-top: 0;
    padding-bottom: 0;
}

/* 連結 */
#mainHeader .nav-link {
    color: #fff !important;
    font-weight: 500;
    padding: 0 0.5rem;
    transition: color 0.2s;
}

#mainHeader .nav-link:hover {
    color: #ff6666 !important;
}

/* 購物車紅點 */
#cartCount {
    font-size: 0.7rem;
    min-width: 18px;
    height: 18px;
    line-height: 18px;
    text-align: center;
    padding: 0 4px;
}

/* 手機版展開時的自然半透明背景 */
@media (max-width: 991.98px) {
    #mainHeader {
        background: rgba(0, 0, 0, 0.6);
        /* 手機狀態下主 header 稍深 */
    }

    #mainHeader .navbar-collapse {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(0, 0, 0, 0.7);
        /* 半透明黑底 */
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: all 0.25s ease-in-out;
        z-index: 999;
        padding: 0.5rem 1rem;
    }

    /* 展開動畫 */
    #mainHeader .navbar-collapse.show {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    /* 調整連結風格 */
    #mainHeader .nav-link {
        display: block;
        width: 100%;
        padding: 0.6rem 0;
        text-align: center;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        color: #fff !important;
    }

    #mainHeader .nav-link:last-child {
        border-bottom: none;
    }

    /* 手機時 LOGO 與按鈕高度微調 */
    #mainHeader .navbar-brand {
        font-size: 1rem;
    }
}

#mainHeader .navbar-collapse.collapsing {
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.25s ease-in-out;
}

/* ===== 空狀態樣式 ===== */
.empty-wrapper {
    width: 100%;
    min-height: 300px;
}

.empty-state {
    background: #111;
    border: 1px solid #333;
    border-radius: 4px;
    padding: 2.5rem 1rem;
    width: 260px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.empty-state p {
    color: #aaa;
    font-size: 0.95rem;
}

.empty-state .empty-icon i {
    opacity: 0.8;
}

.martop {
    margin-top: 70px;
}

/* ===== 使用者作品訂單（video_orders） ===== */
.order-card {
    background: #111;
    border: 1px solid #333;
    border-radius: 6px;
    padding: 10px 14px;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 12px;
    transition: border-color 0.2s, background 0.2s;
}

.order-card:hover {
    border-color: var(--accent-color);
    background: #181818;
}

/* 左側封面圖 */
.order-card .video-cover {
    flex: 0 0 160px;
}

.order-card .video-cover img {
    width: 160px;
    height: 90px;
    object-fit: cover;
    border-radius: 4px;
    display: block;
}

/* 右側資料區 */
.order-card .record-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2px 0;
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.order-card .record-item:last-child {
    border-bottom: none;
}

.order-card .record-item .label {
    color: #aaa;
}

.order-card .record-item .value {
    color: #fff;
    font-weight: 500;
}

/* 手機版調整 */
@media (max-width: 767.98px) {
    .order-card {
        flex-direction: column;
        align-items: center;
        text-align: left;
    }

    .order-card .video-cover {
        flex: 0 0 auto;
        width: 100%;
    }

    .order-card .video-cover img {
        width: 100%;
        height: auto;
        aspect-ratio: 16/9;
    }
}

/* ——————————————————————————————— */
/* 商品頁：數量選擇器 */
/* ——————————————————————————————— */
.num_box {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.num_box .btn_change_num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.25rem;
    background: #1a1a1a;
    color: #f8f9fa;
    border: 1px solid #444;
    border-radius: 0.25rem;
    cursor: pointer;
    transition: 0.2s;
    text-decoration: none !important;
}

.num_box .btn_change_num:hover {
    background: var(--accent-color);
    color: #0e0e0e;
}

.num_box .num_val_share {
    width: 3rem;
    height: 2.5rem;
    text-align: center;
    background: #1a1a1a;
    color: #f8f9fa;
    border: 1px solid #444;
    border-radius: 0.25rem;
    -moz-appearance: textfield;
}

.num_box .num_val_share::-webkit-outer-spin-button,
.num_box .num_val_share::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* 缺貨徽章 */
.num_box+.badge {
    font-size: 1.25rem;
    background-color: #444 !important;
    color: #f8f9fa !important;
}

/* ——————————————————————————————— */
/* 商品頁右側商品資訊卡片（暗色） */
/* ——————————————————————————————— */
.card.bg-dark.text-white {
    background: linear-gradient(180deg, #222 0%, #000 100%);
    box-shadow: 0 0 10px rgba(255, 0, 0, 0.2);
}

/* ——————————————————————————————— */
/* 商品大圖（main-image）讓圖片維持 cover */
/* ——————————————————————————————— */
.main-image img {
    object-fit: cover;
    width: 100%;
    height: 100%;
}

/* ——————————————————————————————— */
/* 購物車頁面 Header */
/* ——————————————————————————————— */
.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    color: #f8f9fa;
}

.cart-header p {
    font-size: 1.5rem;
    margin: 0;
}

.cart-header a {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: transparent;
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
    border-radius: 0.25rem;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
}

.cart-header a:hover {
    background: var(--accent-color);
    color: #0e0e0e;
}

/* ——————————————————————————————— */
/* 購物車主容器 */
/* ——————————————————————————————— */
.cart-container {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.cart-items {
    flex: 1;
    overflow-x: auto;
}

/* 列表欄位標題 */
.cart-items-header {
    display: flex;
    background: #1a1a1a;
    padding: 0.75rem;
    border-radius: 0.25rem 0.25rem 0 0;
    color: #ccc;
}

.cart-items-header p {
    flex: 1;
    text-align: center;
    font-weight: 600;
    margin: 0;
}

.cart-items-header p:first-child {
    flex: 2;
}

/* ——————————————————————————————— */
/* 每一列商品 */
/* ——————————————————————————————— */
.cart-item {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    border-bottom: 1px solid #333;
}

.cart-item:last-child {
    border-radius: 0 0 0.25rem 0.25rem;
    border-bottom: none;
}

/* 商品資訊（圖片 + 名稱） */
.cart-item-info {
    flex: 2;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.cart-item-info img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 0.25rem;
}

.cart-item-name {
    margin: 0;
    color: #f8f9fa;
    font-size: 0.95rem;
}

/* 單價 / 小計 */
.cart-item-price,
.cart-item-subtotal {
    flex: 1;
    text-align: center;
}

.cart-item-price p,
.cart-item-subtotal p {
    margin: 0;
}

/* 數量調整區 */
.cart-item-quantity {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.cart-item-quantity .btn-change {
    background: #1a1a1a;
    color: #f8f9fa;
    border: 1px solid #444;
    border-radius: 0.25rem;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    font-size: 1.1rem;
    transition: 0.2s;
}

.cart-item-quantity .btn-change:hover {
    background: var(--accent-color);
    color: #0e0e0e;
}

.cart-item-quantity .quantity-value {
    min-width: 2rem;
    color: #f8f9fa;
    text-align: center;
}

/* 刪除按鈕 */
.cart-item-remove {
    flex: 1;
    text-align: center;
}

.cart-item-remove .btn-remove {
    color: #f00;
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
    cursor: pointer;
}

.cart-item-remove .btn-remove:hover {
    color: var(--accent-color);
}

/* 空購物車 */
.cart-empty {
    text-align: center;
    padding: 2rem;
    color: #777;
}

.cart-empty h5 {
    margin: 0;
}

/* ——————————————————————————————— */
/* 結帳 Summary */
/* ——————————————————————————————— */
.cart-summary {
    width: 300px;
    background: #1a1a1a;
    padding: 1rem;
    border-radius: 0.25rem;
    color: #f8f9fa;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cart-summary-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.1rem;
    border-bottom: 1px solid #333;
    padding-bottom: 0.5rem;
}

.total-amount {
    color: var(--accent-color);
    font-weight: 600;
}

.btn-checkout {
    width: 100%;
    background: var(--accent-color);
    border: none;
    color: #0e0e0e;
    padding: 0.75rem;
    font-size: 1rem;
    border-radius: 0.25rem;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-checkout:hover {
    background: #b3003c;
}

/* ——————————————————————————————— */
/* RWD */
/* ——————————————————————————————— */
@media (max-width: 767.98px) {
    .cart-items-header {
        display: none;
    }

    .cart-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
        padding: 1rem;
    }

    .cart-item>div {
        flex: none !important;
        width: 100%;
        text-align: left;
    }

    .cart-container {
        flex-direction: column;
    }

    .cart-summary {
        width: 100% !important;
        margin-top: 1.5rem;
    }
}

/* ——————————————————————————————— */
/* 重新設計後的卡片 (你的新版樣式) */
/* ——————————————————————————————— */
.redesigned-cart-item {
    display: flex;
    flex-wrap: wrap;
    background-color: #1a1a1a;
    border: 1px solid #333;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1rem;
    gap: 1rem;
}

/* 商品圖片與名稱 */
.cart-product {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 2;
    min-width: 200px;
}

.cart-product img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 0.25rem;
}

.cart-item-name {
    margin: 0;
    color: #f8f9fa;
    font-size: 1rem;
    word-break: break-word;
}

/* 價格資訊 */
.cart-price-group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
    min-width: 120px;
    font-size: 0.95rem;
}

.price-row {
    display: flex;
    justify-content: space-between;
    color: #f8f9fa;
}

.price-row .label {
    color: #ccc;
}

/* 數量 & 刪除 */
.cart-controls {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: space-between;
    flex: 1;
    min-width: 150px;
    gap: 0.5rem;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cart-item-quantity .quantity-value {
    color: #f8f9fa;
    min-width: 2rem;
    text-align: center;
}

.cart-item-remove .btn-remove {
    color: #f00;
    font-size: 1.5rem;
    line-height: 1;
}

.cart-item-remove .btn-remove:hover {
    color: var(--accent-color);
}

/* 手機版重新排版 */
@media (max-width: 767.98px) {
    .redesigned-cart-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .cart-controls {
        align-items: flex-start;
        width: 100%;
    }

    .cart-price-group,
    .cart-item-quantity {
        width: 100%;
    }

    .price-row {
        justify-content: space-between;
    }
}

@media (max-width: 767.98px) {
    /* cart-controls 變成水平排列 */
    .cart-controls {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100%;
    }

    /* 左邊數量區塊保持水平並對齊 */
    .cart-item-quantity {
        justify-content: flex-start;
        width: auto !important;
    }

    /* 右邊垃圾桶按鈕靠右 */
    .cart-item-remove {
        text-align: right;
        width: auto !important;
    }

    .cart-item-remove .btn-remove {
        font-size: 1.6rem;
        line-height: 1;
    }
}


/* ——————————————————————————————————————————————————————— */
/* Layer 深色主题调整 */
/* ——————————————————————————————————————————————————————— */
.layui-layer-shade {
    background-color: rgba(0, 0, 0, 0.7) !important;
}

.layui-layer {
    border-radius: 0.5rem !important;

    background: #000000;
    border: 1px solid #800020;
}

.layui-layer-title {
    background-color: var(--main-color) !important;
    color: #f8f9fa !important;
    text-align: center !important;
    padding: 0.75rem 1rem !important;
    font-size: 1.1rem !important;
    line-height: 1.5 !important;
    border-bottom: none !important;
}

.layui-layer-content {
    color: #f8f9fa !important;
    text-align: center !important;
    padding: 1.25rem 1.5rem !important;
    line-height: 1.4 !important;
    font-size: 1rem !important;
}

.layui-layer-dialog .layui-layer-content {
    background-color: #1a1a1a !important;
}

.layui-layer-btn {
    background-color: #1a1a1a !important;
    padding: 1rem !important;
    text-align: center !important;
}

.layui-layer-btn a {
    display: inline-block !important;
    margin: 0 0.5rem !important;
    min-width: 6rem !important;
    background-color: var(--accent-color) !important;
    border: 1px solid var(--accent-color) !important;
    color: #fff !important;
    border-radius: 0.25rem !important;
    text-decoration: none !important;
    transition: opacity 0.2s !important;
}

.layui-layer-btn .layui-layer-btn1 {
    background-color: #444 !important;
    border: 1px solid #444 !important;
    color: #f8f9fa !important;
}

.layui-layer-setwin .layui-layer-close {
    color: #f8f9fa !important;
    opacity: 0.8;
}

.layui-layer-setwin .layui-layer-close:hover {
    opacity: 1;
}

/* 外框保持 16:9 高度 */
.video-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: black;
    overflow: hidden;
}

/* Video.js 主層寬度 100%，高度跟著 wrapper */
.video-wrapper .video-js {
    width: 100% !important;
    height: 100% !important;
}

/* 真正的影片層（避免溢出） */
.video-js .vjs-tech {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
}


/* 深色主題用於排序下拉選單 */
.form-select {
    background-color: #1a1a1a !important;
    color: #f8f9fa !important;
    border: 1px solid #444 !important;
}

.form-select:focus {
    border-color: var(--accent-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(179, 0, 60, 0.25) !important;
}

.btn-accent {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: #fff;
}

.btn-accent:hover {
    background-color: #990033;
    border-color: #990033;
    color: #fff;
}

/* 文字輸入框改成與 select 完全相同的深色樣式 */
input[type="text"].form-control,
input[type="search"].form-control,
input[type="number"].form-control {
    background-color: #1a1a1a !important;
    color: #f8f9fa !important;
    border: 1px solid #444 !important;
    border-radius: 0.25rem !important;
    padding: 0.5rem 0.75rem !important;
}

/* placeholder 顏色 */
input.form-control::placeholder {
    color: #777 !important;
    opacity: 1;
}

/* focus 效果：與 select 相同 */
input.form-control:focus {
    border-color: var(--accent-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(179, 0, 60, 0.25) !important;
    background-color: #1a1a1a !important;
}

/* ———————————————————————————————————————————————————————————— */
/* Pagination 深色主题 */
.page .pagination {
    display: flex;
    justify-content: center;
    padding: 0.5rem 0;
    margin: 0;
    list-style: none;
}

.page .pagination li {
    margin: 0 0.25rem;
}

.page .pagination li span,
.page .pagination li a {
    display: block;
    padding: 0.5rem 0.75rem;
    background: #1a1a1a;
    color: #f8f9fa;
    border: 1px solid #444;
    border-radius: 0.25rem;
    min-width: 2.5rem;
    text-align: center;
    text-decoration: none;
}

.page .pagination li.active span {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: #fff;
}

.page .pagination li.disabled span {
    opacity: 0.5;
    cursor: default;
}

.page .pagination li a:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
    color: #fff;
}

/* 手機調整 - 兩欄滿版 */
@media (max-width: 767.98px) {
    .row.row-cols-2>.col {
        margin-top: 0;
        padding: 0;
    }
}

.row.row-cols-2.gy-4 {
    row-gap: 2px !important;
    margin-top: 0 !important;
}

/* =============================== */
/* 訂閱方案卡片 Sub Plan Cards      */
/* =============================== */
.subplan-card {
    width: 100%;
    background: #111;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 1.5rem 1.2rem;
    text-align: center;
    transition: all .25s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.subplan-card:hover {
    border-color: var(--accent-color);
    background: #181818;
    transform: translateY(-3px);
}

/* 標題 */
.subplan-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: .5rem;
}

/* 價格 */
.subplan-price {
    font-size: 1.1rem;
    color: #ffc107;
    margin-bottom: 1rem;
    font-weight: 600;
}

/* 折扣提示 */
.subplan-discount {
    display: inline-block;
    margin: 0 auto;
    margin-bottom: 1.2rem;
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    font-size: .9rem;
    font-weight: 600;
    color: #ffc107;
    border: 1px solid #ffc107;
    background: rgba(255, 193, 7, 0.1);
}

/* PC 三欄排版，RWD 自動一欄 */
#subPlanGrid .col-md-4 {
    display: flex;
}

/* ================================ */
/* 會員訂閱方案卡片 (多筆支援)       */
/* ================================ */
.subplan-user-card {
    background: #111;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 1.2rem 1rem;
    transition: .2s;
}

.subplan-user-card:hover {
    border-color: var(--accent-color);
    background: #181818;
}

/* 標題 + 按鈕 */
.subplan-user-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.subplan-name {
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
}

/* 資訊列 */
.subplan-info .info-row {
    display: flex;
    justify-content: space-between;
    padding: .4rem 0;
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.subplan-info .info-row:last-child {
    border-bottom: none;
}

.info-row .label {
    color: #bbb;
    font-size: .9rem;
}

.info-row .value {
    color: #fff;
    font-size: .95rem;
    text-align: right;
}

/* ================================ */
/* 扣款紀錄卡片                      */
/* ================================ */
.subplan-log-card {
    background: #111;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 1rem 1rem;
    transition: .2s;
}

.subplan-log-card:hover {
    border-color: var(--accent-color);
    background: #181818;
}

.subplan-log-card .log-row {
    display: flex;
    justify-content: space-between;
    padding: .35rem 0;
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.subplan-log-card .log-row:last-child {
    border-bottom: none;
}

.log-row .label {
    color: #aaa;
    font-size: .9rem;
}

.log-row .value {
    color: #fff;
    font-size: .95rem;
}

/* ================================ */
/* 手機 RWD                         */
/* ================================ */
@media (max-width: 767.98px) {

    /* 手機卡片內文字靠左排列 */
    .subplan-info .info-row,
    .subplan-log-card .log-row {
        flex-direction: column;
        align-items: flex-start;
        gap: .25rem;
    }

    .subplan-info .value,
    .subplan-log-card .value {
        text-align: left !important;
    }
}

.card-body{
    margin-bottom: 1rem;
}

.layui-layer-btn a{
    height: 34px;
}

/* ================================ */
/* 商品訂單卡片 product-order-card */
/* ================================ */
.product-order-card {
    background: #111;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 1rem 1rem;
    transition: .2s;
}

.product-order-card:hover {
    border-color: var(--accent-color);
    background: #181818;
}

.product-order-card .log-row {
    display: flex;
    justify-content: space-between;
    padding: .35rem 0;
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.product-order-card .log-row:last-child {
    border-bottom: none;
}

.product-order-card .label {
    color: #aaa;
    font-size: .9rem;
}

.product-order-card .value {
    color: #fff;
    font-size: .95rem;
}

/* 手機版：上下排列 */
@media (max-width: 767.98px) {

    .product-order-card .log-row {
        flex-direction: column;
        align-items: flex-start;
        gap: .25rem;
    }

    .product-order-card .value {
        text-align: left !important;
    }
}

/* 作品封面大小統一 */
.product-order-card .video-cover img {
    width: 240px;
    height: 140px;
    object-fit: cover;
    border-radius: 4px;
}

/* 手機版：圖片滿版 */
@media (max-width: 767.98px) {
    .product-order-card {
        flex-direction: column;
    }

    .product-order-card .video-cover img {
        width: 100%;
        height: auto;
        aspect-ratio: 16/9;
    }
}

.layui-layer-loading{
    background: transparent !important;
    border: none !important;
}

.n-msg{
    color: red;
}

/* 統一所有 form-control 的深色風格（含 password） */
.form-control {
    background-color: #1a1a1a !important;
    color: #f8f9fa !important;
    border: 1px solid #444 !important;
    border-radius: 0.25rem !important;
    padding: 0.5rem 0.75rem !important;
}

/* placeholder 顏色 */
.form-control::placeholder {
    color: #777 !important;
}

/* focus 效果 */
.form-control:focus {
    background-color: #1a1a1a !important;
    border-color: var(--accent-color) !important;
    box-shadow: 0 0 0 0.2rem rgba(179, 0, 60, 0.25) !important;
}

.navbar-toggler:focus{
    box-shadow:none;
}

.bsky-icon svg {
    width: 16px;
    height: 15px;
}
