/* Dashboard Redesign v2 - Ultra Manga Aesthetic */
.dashboard-v2-container {
    padding: 30px 15px;
    max-width: 1200px;
    margin: 0 auto;
    background-image: radial-gradient(var(--border-color) 1px, transparent 1px);
    background-size: 20px 20px;
}

/* Manga Panel Effect */
.manga-panel {
    background: white;
    border: 4px solid var(--ink-black);
    position: relative;
    box-shadow: 12px 12px 0 var(--ink-black);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.manga-panel:hover {
    transform: translate(-4px, -4px);
    box-shadow: 16px 16px 0 var(--pop-cyan);
}

/* Profile Banner */
.dashboard-banner {
    background: var(--ink-black);
    color: white;
    padding: 40px;
    border-radius: 0; /* Manga style uses sharp or very specific corners */
    position: relative;
    overflow: hidden;
    margin-bottom: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 6px solid var(--ink-black);
    box-shadow: 15px 15px 0 var(--pop-cyan);
    clip-path: polygon(0 0, 100% 0, 98% 100%, 2% 100%);
}

.dashboard-banner::after {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: linear-gradient(45deg, rgba(255,255,255,0.1) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.1) 75%, transparent 75%, transparent);
    background-size: 100px 100px;
    pointer-events: none;
}

.dashboard-banner::before {
    content: "DASHBOARD";
    position: absolute;
    top: -20px;
    right: -20px;
    font-size: 8rem;
    font-weight: 900;
    opacity: 0.1;
    font-family: var(--font-display);
    transform: rotate(-5deg);
}

.banner-profile {
    display: flex;
    align-items: center;
    gap: 25px;
    position: relative;
    z-index: 2;
}

.banner-avatar-wrapper {
    width: 100px;
    height: 100px;
    border-radius: 20px;
    border: 4px solid white;
    background: var(--pop-cyan);
    overflow: hidden;
    transform: rotate(-3deg);
    box-shadow: 5px 5px 0 var(--pop-cyan);
}

.banner-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-info h1 {
    font-size: 2.5rem;
    margin: 0;
    text-transform: uppercase;
    line-height: 1;
}

.banner-info p {
    margin: 5px 0 0;
    opacity: 0.8;
    font-weight: bold;
}

/* Stats Cards */
.banner-stats {
    display: flex;
    gap: 20px;
    position: relative;
    z-index: 2;
}

.stat-card-v2 {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(5px);
    padding: 15px 25px;
    border-radius: 15px;
    text-align: center;
    border: 2px solid rgba(255,255,255,0.2);
    min-width: 120px;
}

.stat-card-v2 .value {
    display: block;
    font-size: 2rem;
    font-weight: 900;
    color: var(--pop-cyan);
}

.stat-card-v2 .label {
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
}

/* Grid Layout */
.dashboard-grid-v2 {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
}

/* Dashboard Quick Actions */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin: 16px 0 22px;
}
.qa-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px;
    background: #fff;
    color: var(--ink-black);
    text-decoration: none;
    font-weight: 900;
    border: 3px solid var(--ink-black);
    border-radius: 12px;
    box-shadow: 6px 6px 0 var(--ink-black);
}
.qa-btn.primary { background: var(--pop-cyan); }
.qa-btn .pill {
    margin-left: 6px;
    background: var(--action-red);
    color: #fff;
    border: 2px solid var(--ink-black);
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 0.7rem;
}

/* Inventory Cards */
.inventory-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}
.inventory-card {
    background: #fff;
    border: 4px solid var(--ink-black);
    box-shadow: 8px 8px 0 var(--ink-black);
    display: flex;
    flex-direction: column;
}
.inv-thumb {
    position: relative;
    aspect-ratio: 4/3;
    background: #f3f4f6;
    border-bottom: 3px solid var(--ink-black);
    display: grid;
    place-items: center;
}
.inv-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.inv-thumb-ph { color: #9ca3af; font-size: 2rem; }
.inv-status {
    position: absolute;
    right: 10px;
    bottom: 10px;
    background: #fff;
    border: 3px solid var(--ink-black);
    padding: 4px 8px;
    font-weight: 900;
    border-radius: 8px;
}
.inv-status.status-active { background: #dcfce7; }
.inv-status.status-sold { background: #fee2e2; }
.inv-status.status-inactive { background: #e5e7eb; }
.inv-body { padding: 12px; display: grid; gap: 8px; }
.inv-title { margin: 0; font-size: 1rem; font-weight: 900; }
.inv-meta { display: flex; justify-content: space-between; font-weight: 800; }
.inv-anime { color: var(--pop-cyan); text-transform: uppercase; font-size: 0.75rem; }
.inv-price { font-family: var(--font-display); }
.inv-actions { display: flex; gap: 8px; }
.btn-ghost {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 8px 10px; border: 3px solid var(--ink-black); background: #fff;
    text-decoration: none; color: var(--ink-black); font-weight: 900; border-radius: 8px;
}

/* Listing list */
.listing-list{ display:flex; flex-direction:column; gap:12px;}
.listing-row{
  display:grid;
  grid-template-columns: 120px 1fr auto;
  gap:16px;
  align-items:center;
  background:#fff;
  border:4px solid var(--ink-black);
  box-shadow:8px 8px 0 var(--ink-black);
  padding:10px;
}
.row-thumb{ aspect-ratio:4/3; background:#f3f4f6; border:3px solid var(--ink-black); display:grid; place-items:center; overflow:hidden;}
.row-thumb img{ width:100%; height:100%; object-fit:cover;}
.thumb-ph{ color:#cbd5e1; font-size:1.6rem;}
.row-main{ display:grid; gap:6px;}
.row-title a{ font-weight:900; color:var(--ink-black); text-decoration:none;}
.row-meta{ display:flex; flex-wrap:wrap; gap:8px; align-items:center; font-weight:800;}
.row-meta .anime{ color:var(--pop-cyan); text-transform:uppercase; font-size:.75rem;}
.row-meta .price{ font-family:var(--font-display); font-size:1.1rem;}
.chip{ border:3px solid var(--ink-black); border-radius:10px; padding:3px 8px;}
.chip-active{ background:#dcfce7;}
.chip-sold{ background:#fee2e2;}
.chip-inactive{ background:#e5e7eb;}
.row-actions{ display:flex; gap:8px; align-items:center;}
.row-actions form{ display:inline;}
.btn-danger{ display:inline-flex; align-items:center; gap:6px; padding:8px 10px; background:#fee2e2; border:3px solid var(--ink-black); border-radius:8px; color:#b91c1c; font-weight:900;}
.btn-danger i,.btn-secondary i,.btn-ghost i{ margin-right:6px;}
.btn-sm{ font-size:.85rem; padding:7px 9px;}

/* Modern Tab Navigation */
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.nav-link-v2 {
    background: white;
    border: 4px solid var(--ink-black);
    padding: 15px 20px;
    border-radius: 0;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--ink-black);
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    position: relative;
    box-shadow: 6px 6px 0 var(--ink-black);
}

.nav-link-v2:hover {
    transform: translate(-2px, -2px);
    box-shadow: 8px 8px 0 var(--pop-cyan);
    background: white;
}

.nav-link-v2.active {
    background: var(--pop-cyan);
    box-shadow: 8px 8px 0 var(--ink-black);
    transform: translate(-2px, -2px);
}

.nav-link-v2 i {
    font-size: 1.2rem;
    width: 25px;
}

.nav-link-v2 .badge {
    position: absolute;
    right: -10px;
    top: -10px;
    background: var(--action-red);
    color: white;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 0.7rem;
    border: 2px solid var(--ink-black);
}

/* Content Panels */
.dashboard-card-v2 {
    background: white;
    border: 4px solid var(--ink-black);
    border-radius: 0;
    padding: 30px;
    box-shadow: 10px 10px 0 var(--ink-black);
    min-height: 500px;
    position: relative;
}

.dashboard-card-v2::before {
    content: "";
    position: absolute;
    top: -10px;
    left: 20px;
    width: 40px;
    height: 20px;
    background: var(--pop-cyan);
    border: 3px solid var(--ink-black);
    z-index: 1;
}

.card-v2-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 6px solid var(--ink-black);
    position: relative;
}

.card-v2-header::after {
    content: var(--section-tag, "SECTION");
    position: absolute;
    bottom: -15px;
    right: 0;
    background: var(--ink-black);
    color: white;
    font-size: 0.6rem;
    padding: 2px 8px;
    font-weight: 900;
}

.card-v2-title {
    font-size: 1.8rem;
    font-weight: 900;
    text-transform: uppercase;
    margin: 0;
}

.nav-link-v2.cta-mobile {
    background: var(--ink-black);
    color: white;
    border-color: var(--ink-black);
    box-shadow: 4px 4px 0 var(--pop-cyan);
}

.nav-link-v2.cta-mobile:hover {
    background: #333;
    transform: translate(-2px, -2px);
    box-shadow: 6px 6px 0 var(--pop-cyan);
}

/* Mobile Adjustments */
@media (max-width: 992px) {
    .nav-link-v2.cta-mobile {
        margin-top: 0 !important; /* Remove the top margin on mobile scroll */
        background: var(--ink-black);
        color: white;
        box-shadow: 3px 3px 0 var(--pop-cyan);
    }
}
    .dashboard-v2-container {
        padding: 15px 10px;
    }

    .dashboard-grid-v2 {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .quick-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .inventory-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .listing-row{ grid-template-columns: 90px 1fr; }
    .row-actions{ grid-column: 1 / -1; justify-content:flex-end; }


    .dashboard-nav-v2 {
        flex-direction: row;
        overflow-x: auto;
        padding: 5px 0 15px;
        margin-bottom: 10px;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        gap: 10px;
    }

    .dashboard-nav-v2::-webkit-scrollbar {
        display: none;
    }

    .nav-link-v2 {
        white-space: nowrap;
        padding: 10px 15px;
        transform: none !important;
        font-size: 0.8rem;
        flex-shrink: 0;
    }

    .nav-link-v2.active {
        box-shadow: 4px 4px 0 var(--ink-black);
    }

    .dashboard-banner {
        flex-direction: column;
        text-align: center;
        padding: 25px 15px;
        margin-bottom: 20px;
        border-radius: 15px;
        box-shadow: 6px 6px 0 var(--pop-cyan);
    }

    .banner-profile {
        flex-direction: column;
        gap: 15px;
        margin-bottom: 20px;
    }

    .banner-avatar-wrapper {
        width: 80px;
        height: 80px;
        margin: 0 auto;
    }

    .banner-info h1 {
        font-size: 1.8rem;
    }

    .banner-stats {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .stat-card-v2 {
        min-width: 0;
        padding: 10px;
    }

    .stat-card-v2 .value {
        font-size: 1.5rem;
    }

    /* Card & Content Optimizations */
    .dashboard-card-v2 {
        padding: 20px 15px;
        border-radius: 15px;
        box-shadow: 6px 6px 0 var(--ink-black);
    }

    .card-v2-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
        margin-bottom: 20px;
    }

    .card-v2-title {
        font-size: 1.4rem;
    }

    /* Mobile Table to Cards */
    .manga-table, .manga-table thead, .manga-table tbody, .manga-table th, .manga-table td, .manga-table tr {
        display: block;
    }

    .manga-table thead {
        display: none; /* Hide headers on mobile */
    }

    .manga-table-row {
        border: 3px solid var(--ink-black);
        border-radius: 12px;
        margin-bottom: 20px;
        padding: 10px;
        background: #fff;
        box-shadow: 4px 4px 0 #eee;
        position: relative;
    }

    .manga-table-row td {
        border: none;
        padding: 8px 5px;
        text-align: right;
        display: flex;
        justify-content: space-between;
        align-items: center;
        border-bottom: 1px dashed #eee;
    }

    .manga-table-row td:last-child {
        border-bottom: none;
        justify-content: center;
        padding-top: 15px;
    }

    .manga-table-row td::before {
        content: attr(data-label);
        font-weight: 900;
        text-transform: uppercase;
        font-size: 0.7rem;
        color: #999;
        text-align: left;
    }

    .manga-table-row td[data-label="Product"] {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }

    .manga-table-row td[data-label="Product"]::before {
        margin-bottom: 5px;
    }

    .btn-sm {
        width: 100%;
        text-align: center;
        padding: 12px !important;
    }
}
