/* =======================
   GENERAL BODY STYLING
   ======================= */
html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: 'Noto Sans JP', sans-serif;
    background: linear-gradient(45deg, #fabcdb 0%, #8d5f76 25%, #4ca59c);
    background-size: 400% 400%;
    animation: diagonalShift 15s ease infinite;
    display: flex;
    flex-direction: column;
    overflow-x: hidden; /* prevent horizontal scrollbar */
    
}

.navbar-right .login-btn {
    text-decoration: none;
    padding: 8px 16px;
    background-color: rgba(255, 255, 255, 0.2);
    color: #fff;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 10px; /* space between balance and username */
}

.balance-boxnav {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.3);
    padding: 4px 20px;
    border-radius: 10px;
    margin-right: 10px;
}

.balance-boxnav .top-up {
    margin-left: 6px;
    font-weight: bold;
    text-decoration: none;
    margin-right: -20px;
}

/* =======================
   LOGIN PAGE
   ======================= */
body.login-page .page-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    max-width: 100%;
    z-index: 10;
    text-align: center;
}


body.login-page .login-container {
    max-width: 400px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    text-align: center;
    justify-content: center;
    margin: auto;
}

body.login-page .login-container h2 {
    font-size: 1.8rem;
    margin-bottom: 30px;
    color: #333;
}

body.login-page .google-btn,
body.login-page .twitter-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 80%;
    margin: 12px auto;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: bold;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
}

body.login-page .google-btn .button-content,
body.login-page .twitter-btn .button-content {
    display: flex;
    align-items: center;
    gap: 8px;
}

body.login-page .social-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

body.login-page .google-btn { background-color: #DB4437; }
body.login-page .google-btn:hover { background-color: #c33d2f; }
body.login-page .twitter-btn { background-color: #1DA1F2; }
body.login-page .twitter-btn:hover { background-color: #1991DA; }

/* =======================
   PROFILE PAGE
   ======================= */
body.profile-page .page-container {
    position: relative;
    margin-top: 80px;
    width: 90%;
    max-width: 1000px;
    text-align: center;
}

body.profile-page .page-content {
    display: none;
    opacity: 0;
    text-align: center;
    transition: opacity 0.5s ease-in-out;
}

body.profile-page .page-content.active {
    display: block;
    opacity: 1;
}

h1{
    color: white;
}

/* Tabs styling */
body.profile-page .profile-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

body.profile-page .tab-btn {
    padding: 10px 20px;
    border: none;
    background-color: rgba(255,255,255,0.2);
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    color: #fff;
    transition: all 0.3s ease;
}

body.profile-page .tab-btn:hover {
    background-color: rgba(255,255,255,0.3);
    transform: scale(1.05);
}

body.profile-page .tab-btn.active {
    background-color: #fabcdb;
    color: #333;
}


/* =======================
   NAVBAR STYLING
   ======================= */
/* =======================
   GENERAL BODY STYLING
   ======================= */
body {
    background: linear-gradient(45deg, #fabcdb 0%, #8d5f76 25%, #4ca59c);
    background-size: 400% 400%;
    animation: diagonalShift 15s ease infinite;
    min-height: 100vh;
    margin: 0;
    font-family: 'Noto Sans JP', sans-serif;
    display: flex;
    flex-direction: column;
}

main {
    margin-left: 20px;
    margin-right: 20px;
}

.content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

h1 {
    text-align: center;
}

/* =======================
   NAVBAR STYLING
   ======================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
    width: 100%;
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 20px;
    margin: 0 auto;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(6px);
}

.navbar-left {
    display: flex;
    align-items: center;
}

.navbar-left ul {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
}

.navbar-right .login-btn {
    text-decoration: none;
    padding: 8px 16px;
    background-color: rgba(255, 255, 255, 0.2);
    color: #fff;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.navbar .logo img {
    height: 50px;
    width: auto;
    display: block;
}

.navbar li {
    margin-left: 20px;
    position: relative;
}

.navbar li:not(:last-child)::after {
    content: "";
    position: absolute;
    right: -10px;
    top: 25%;
    height: 50%;
    width: 1px;
    background-color: rgba(255, 255, 255, 0.2);
}

.navbar .logo {
    color: white;
    font-weight: bold;
    font-size: 1.5rem;
    margin-right: 20px;
    margin-left: 10px;
}

.navbar ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
}

.navbar-left ul li a,
.username-link,
.login-btn {
    color: white;
    font-family: 'Noto Sans JP', sans-serif;
    text-decoration: none;
    padding: 10px 15px;
}

.navbar-left ul li a:hover,
.username-link:hover,
.login-btn:hover,
.logout-btn:hover {
    text-decoration: none;
    color: #fabcdb;
    transform: scale(1.05);
}

.navbar .dropdown {
    position: relative;
}

.navbar .dropdown-content {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.7);
    min-width: 150px;
    border-radius: 6px;
    overflow: hidden;
    z-index: 1001;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.4s ease, opacity 0.4s ease;
    display: flex;
}

.navbar .dropdown-content .long-item {
    width: auto;
    word-break: break-word;
}

.navbar .dropdown-content a {
    display: block;
    text-align: center;
    padding: 10px;
    margin-right: 20px;
    color: #ffffff;
    text-decoration: none;
}

.navbar .dropdown-content a:hover {
    background-color: rgba(255, 255, 255, 0.2);
    color: #fabcdb;
    transform: scale(1.05);
}

.navbar .dropdown:hover .dropdown-content {
    max-height: 500px;
    opacity: 1;
}

.navbar a {
    color: #ffffff;
    text-decoration: none;
    padding: 15px 20px;
    display: block;
    text-align: center;
    transition: all 0.3s ease;
}

.navbar a:hover {
    background-color: rgba(255, 255, 255, 0.2);
    color: #fabcdb;
    transform: scale(1.05);
}

.navbar .dropdown-content li:not(:last-child)::after {
    content: "";
    position: absolute;
    right: 0;
    top: 10%;
    height: 80%;
    width: 1px;
    background-color: rgba(255, 255, 255, 0.2);
}

/* =======================
   FOOTER STYLING
   ======================= */
footer {
    background-color: #2c3e50;
    color: #ffffff;
    padding: 20px;
    text-align: center;
    font-size: 14px;
    margin-top: auto;
}

footer a {
    color: #fabcdb;
    text-decoration: none;
    margin: 0 10px;
}

footer a:hover {
    text-decoration: underline;
}

/* =========================
   Shipping Success Modal
   ========================= */
.modal-overlaySS {
    display: none; /* hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4); /* subtle overlay */
    justify-content: center;
    align-items: center;
    z-index: 2000;
    animation: fadeIn 0.3s ease;
}

.close-btn {
  margin-top: 1rem;
  padding: 0.5rem 1.2rem;
  background-color: teal;
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.close-btn:hover {
  background-color: #006666;
}

.modal-overlaySS {
    display: none; /* hidden by default */
    justify-content: center;
    align-items: center;
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 128, 128, 0.6); /* teal background */
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.modal-overlaySS.active {
    display: flex;  /* show it */
    opacity: 1;
    pointer-events: auto;
    justify-content: center;
}

#ship-success-text {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 20px;
}

#ship-success-close {
    background-color: #fff;
    color: #333;
    font-weight: bold;
    padding: 10px 25px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

#ship-success-close:hover {
    background-color: #f2f2f2;
    transform: scale(1.05);
}

/* Simple animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleUp {
    from { transform: scale(0.8); }
    to { transform: scale(1); }
}

.social-icons {
    margin-bottom: 10px;
}

.social-icons a {
    display: inline-block;
    margin: 0 10px;
    transition: transform 0.3s ease;
}

.social-icons a img {
    width: 30px;
    height: 30px;
    filter: brightness(0) invert(1);
    transition: filter 0.9s ease, transform 0.9s ease;
}

.social-icons a:hover img {
    filter: brightness(0) saturate(100%) invert(78%) sepia(15%) saturate(1223%) hue-rotate(291deg) brightness(100%) contrast(97%);
    animation: icon-bounce 0.4s ease forwards;
}

@keyframes icon-bounce {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    70% { transform: scale(1.15); }
    100% { transform: scale(1.2); }
}

@keyframes icon-bounce-out {
    0% { transform: scale(1.2); }
    50% { transform: scale(0.9); }
    70% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* =======================
   PROFILE STYLING
   ======================= */
.profile-container {
    display: flex;
    max-width: 1000px;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
}

.sidebar {
    width: 200px;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 20px;
    color: #fff;
}

.sidebar ul {
    list-style: none;
    padding: 0;
}

.balance-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    width: 200px;
    padding: 30px 25px;
    background: linear-gradient(135deg, #00bfa5, #008080);
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    color: #fff;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.balance-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

.balance-box h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.balance-box p {
    font-size: 1rem;
    opacity: 0.85;
}

/* Optional: subtle background for numbers */
.balance-box p span {
    background: rgba(255,255,255,0.2);
    padding: 2px 8px;
    border-radius: 8px;
}

/* Responsive tweak */
@media (max-width: 768px) {
    .balance-box {
        width: 90%;
        padding: 25px 20px;
    }
}

/* BALANCE CARD STYLING */
.balance-card {
    background: #f5f0ff;           /* soft pastel background */
    padding: 20px 30px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    text-align: center;
    min-width: 200px;
    max-width: 280px;
    margin-right: 40px;            /* spacing if next to history box */
    font-family: 'Segoe UI', sans-serif;
}

.balance-card h2 {
    font-size: 32px;
    margin-bottom: 15px;
    color: #6a1b9a;                /* nice purple accent */
}

.balance-details p {
    font-size: 18px;
    margin: 5px 0;
    color: #333;
}

#modalContent {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: flex-start;
    overflow-x: hidden; /* hides horizontal overflow */
}

.sidebar ul li {
    margin: 15px 0;
}

.sidebar ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
}

.sidebar ul li a:hover {
    color: #fabcdb;
}

.profile-content {
    flex: 1;
    padding: 20px;
    color: #fff;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    display: none;
}

.profile-content section {
    margin-bottom: 30px;
}

.profile-content h2 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

/* =======================
   BACKGROUND ANIMATION
   ======================= */
@keyframes diagonalShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}


/* =======================
   FOOTER
   ======================= */
footer {
    background-color: #2c3e50;
    color: #ffffff;
    padding: 20px;
    text-align: center;
    font-size: 14px;
    margin-top: auto;
}

footer a {
    color: #fabcdb;
    text-decoration: none;
    margin: 0 10px;
}

footer a:hover {
    text-decoration: underline;
}

.social-icons {
    margin-bottom: 10px;
}

.social-icons a {
    display: inline-block;
    margin: 0 10px;
    transition: transform 0.3s ease;
}

.social-icons a img {
    width: 30px;
    height: 30px;
    filter: brightness(0) invert(1);
    transition: filter 0.9s ease, transform 0.9s ease;
}

.social-icons a:hover img {
    filter: brightness(0) saturate(100%) invert(78%) sepia(15%) saturate(1223%) hue-rotate(291deg) brightness(100%) contrast(97%);
    animation: icon-bounce 0.4s ease forwards;
}

@keyframes icon-bounce {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    70% { transform: scale(1.15); }
    100% { transform: scale(1.2); }
}

@keyframes icon-bounce-out {
    0% { transform: scale(1.2); }
    50% { transform: scale(0.9); }
    70% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* =======================
   BACKGROUND ANIMATION
   ======================= */
@keyframes diagonalShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}


/* =======================
   INVENTORY
   ======================= */

.cards-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.card {
    width: 180px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.view-cards-btn,
.view-sold-cards-btn {
    padding: 8px 16px;
    background: linear-gradient(135deg, #fabcdb 0%, #8d5f76 100%);
    color: #fff;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}


.view-cards-btn:hover,
.view-sold-cards-btn:hover:hover{
    background: linear-gradient(135deg, #f78ab2 0%, #6a3c58 100%);
    transform: scale(1.05);
}

/* =========================
   Sell Success Modal Styling
   ========================= */
#sell-success-modal {
    display: none;
    position: fixed;
    top: 0; 
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7); /* semi-transparent black background */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#sell-success-modal .modal-overlaySS {
    display: none; /* default hidden */
    position: fixed;
    top:0;
    left:0;
    width:100%;
    height:100%;
    background: rgba(78, 124, 177, 0.5);
    justify-content:center;
    align-items:center;
    z-index:1000;
    opacity:0;
    transition: opacity 0.3s ease;
}

#sell-success-modal .modal-overlaySS.active {
    display: flex;
    opacity:1;
}

#sell-success-modal .close-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    background-color: #fabcdb; 
    color: #333;
    font-weight: bold;
    cursor: pointer;
    margin-top: 15px;
    transition: all 0.3s ease;
}

#sell-success-modal .close-btn:hover {
    background-color: #f7b3cd;
}

.shipping-order {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    margin-bottom: 8px;
    transition: background 0.3s ease;
}

.shipping-order:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.card img,
.empty-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-bottom: 1px solid #ccc;
}

.empty-image {
    background-color: #f2f2f2;
}

#modalContent::-webkit-scrollbar {
    width: 6px;
}

#modalContent::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 3px;
}

#closeModal {
    background-color: #fff;
    color: #333;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

#closeModal:hover {
    background-color: #fabcdb;
    color: #fff;
    transform: scale(1.05);
}

#modalContent {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    max-height: 400px;
    overflow-y: auto;
    margin-bottom: 15px;
}

#modalContent div {
    width: 100px;
    text-align: center;
}

#modalContent img {
    width: 80px;
    height: auto;
    border-radius: 8px;
    border: 2px solid #fff;
    transition: transform 0.2s;
}

#modalContent img:hover {
    transform: scale(1.1);
}

#modalContent p {
    margin-top: 5px;
    font-size: 14px;
    color: #fff;
}

#shippingModal .modal-content {
    background: rgba(216, 157, 221, 0.8); /* translucent white */
    padding: 20px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
}

#shippingModal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5); /* semi-transparent overlay */
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#shippingModal .modal-content-wrapper {
    background: linear-gradient(45deg, #fabcdb, #8d5f76) !important;
    padding: 20px;
    border-radius: 16px;
    max-width: 700px;
    width: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 8px 20px rgba(33, 236, 243, 0.3);
    color: #fff;
}

.modal-contentSS {
    background: rgba(16, 147, 151, 0.4);
    padding: 20px 40px;
    border-radius: 12px;
    display: flex;              /* MAKE IT FLEX */
    flex-direction: column;     /* Stack items vertically */
    justify-content: center;    /* Center vertically inside modal */
    align-items: center;        /* Center horizontally */
    text-align: center;         /* Center text inside elements */
    max-width: 400px;
    width: 80%;
    color: white;
}

.modal-contentSS h3 {
    color: white;
}

#shippingModal h3 {
    margin-bottom: 15px;
    font-size: 28px;
    text-align: center;
}

.card-actions {
    margin-top: 10px;
    display: flex;
    gap: 5px;
    justify-content: center;
}

.card-actions button {
    padding: 5px 10px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}


.inventory-card img {
    width: 100%;
    border-radius: 8px;
}

/* Default card style */
.inventory-card {
    width: 180px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(5px);
    box-shadow: 2px 4px 12px rgba(0,0,0,0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border 0.3s ease;
    cursor: pointer; /* make it obvious that cards are clickable */
    transition: all 0.3s ease;
    opacity: 1;
    transform: scale(1);
}

/* Hidden cards */
.inventory-card.hidden {
    opacity: 0;
    transform: scale(0.95);
    pointer-events: none; /* prevent clicking hidden cards */
    position: absolute;   /* optional to remove from flow */
}

/* Hover effect */
.inventory-card:hover {
    transform: translateY(-3px);
    box-shadow: 4px 8px 20px rgba(0,0,0,0.25);
    transform: scale(1.03);
}

/* Selected state */
.inventory-card.selected {
    transform: rotate(1deg) scale(1.02);
    border: 3px solid #fabcdb;
    box-shadow: 4px 8px 20px rgba(250, 172, 219, 0.6);
}

.inventory-wrapper {
    display: flex;
    justify-content: center;   /* center both containers together */
    align-items: flex-end;     /* align bottoms */
    gap: 40px;                 /* space between box and buttons */
    margin: 20px auto;
}

.inventory-box {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    height: 750px;
    padding: 70px;
    border-radius: 12px;
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    overflow-y: auto;    /* scroll only inside the box */
    justify-content: center;  /* align cards top-left */
    align-items: flex-start;      /* prevent cards from stretching vertically */
    min-width: 1150px;
    max-width: 1150px;
}

/* Optional: prettier scrollbar */
.inventory-box::-webkit-scrollbar {
    width: 8px;
}

.inventory-box::-webkit-scrollbar-thumb {
    background-color: rgba(255,255,255,0.3);
    border-radius: 4px;
}

.inventory-box::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.1);
}

.selected-total {
    font-weight: bold;
    font-size: 1.2em;
    text-align: center;   /* center horizontally */
    margin-bottom: 20px;  /* push it higher above buttons */
}

.profile-main-container {
    display: flex;
    gap: 40px;
    flex-wrap: wrap; /* stack on small screens */
    justify-content: center;
    align-items: stretch;
    flex-direction: row;
}

/* History Box */
#history-box {
    background: linear-gradient(
        135deg, 
        rgb(211, 127, 130), 
        rgba(250, 208, 196, 0.4)
    );
    border-radius: 20px;
    padding: 30px 20px;
    min-width: 500px;
    height: 600px;
    flex: 1;
    color: white;
    box-shadow: 0 15px 30px rgba(0,0,0,0.25);
    overflow: hidden;
    overflow-y: auto;
}

/* Tabs inside history box */
.history-tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.history-tab-btn {
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    background: rgba(255,255,255,0.2);
    color: white;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.history-tab-btn.active {
    background: #fabcdb;
    color: #333;
}

/* Scrollable sold orders list */
.sold-orders-list {
    max-height: 300px;      /* adjust as needed */
    overflow-y: auto;
    margin: 0;
    padding: 0;
    list-style: none;       /* removes default bullets */
    scrollbar-width: thin;        /* Firefox */
    scrollbar-color: #888 #f1f1f1;
}

/* Chrome, Edge, Safari */
.sold-orders-list::-webkit-scrollbar {
    width: 6px;
}
.sold-orders-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}
.sold-orders-list::-webkit-scrollbar-thumb {
    background-color: #888;
    border-radius: 10px;
}
.sold-orders-list::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Default: allow scrolling */
body {
    overflow-y: auto;
}

/* When balance tab is active, hide page scrollbar */
body.balance-tab-active {
    overflow-y: hidden;
}

/* ---------- Sold history scrollbar & list reset (target your exact HTML) ---------- */
#sell-history > ul {
    max-height: 520px;
    overflow-y: auto;
    overflow-x: hidden;     /* prevent horizontal scrollbar */
    margin: 0;
    padding: 0 20px 0 0;     /* add right padding so text doesn't clash with scrollbar */
    list-style: none;
    box-sizing: border-box;

    scrollbar-width: thin;
    scrollbar-color: #fabcdb rgba(0,0,0,0.06);
}

/* WebKit browsers (Chrome, Edge, Safari) */
#sell-history > ul::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
#sell-history > ul::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.06);
    border-radius: 8px;
}
#sell-history > ul::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #fabcdb, #deafe7);
    border-radius: 8px;
    border: 2px solid rgba(255,255,255,0.02);
}
#sell-history > ul::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #f48fb1, #c78aa8);
}

/* Make sure individual li still look the same but take full width */
#sell-history > ul > li.sale-order {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    background: transparent;
}

/* Tab content */
.history-content {
    display: none;
}

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

/* =======================
   INVENTORY ACTION BUTTONS
   ======================= */
/* Buttons positioned at bottom-right, inline with box */

#balance {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    background: linear-gradient(
        135deg,
        rgba(0, 191, 165, 0.2),   /* teal-ish with 30% opacity */
        rgba(0, 128, 128, 0.2)    /* darker teal with 30% opacity */
    );
    padding: 40px 30px;
    border-radius: 20px;
    margin: 40px auto;
    box-shadow: 0 15px 30px rgba(0,0,0,0.25);
    color: white;
    text-align: center;
    transition: transform 0.3s ease;
}

#balance:hover {
    transform: translateY(-5px);
}

.total-balance {
    font-size: 48px;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 2px 2px 5px rgba(0,0,0,0.3);
}

.currency-boxes {
    display: flex;
    gap: 20px;
}

.currency-box {
    background: rgba(255,255,255,0.2);
    padding: 20px 25px;
    border-radius: 12px;
    min-width: 150px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.3s ease, background 0.3s ease;
}

.currency-box:hover {
    background: rgba(255,255,255,0.3);
    transform: translateY(-3px);
}

.currency-box p {
    font-size: 16px;
    margin-bottom: 8px;
}

.currency-box span {
    font-size: 24px;
    font-weight: bold;
    color: #fcd4e8;
}


.inventory-filters {
    text-align: center;
    margin-bottom: 100px !important;
    flex-direction: column;
}

.category-btn {
    display: block; /* makes each button take its own line */
    width: 100%; /* optional: stretch to container width */
    padding: 50px 100px !important; /* larger size */
    font-size: 30px; /* larger text */
    border-radius: var(--border-radius, 30px) !important; /* use your variable if you have one */
    border: 1px solid var(--border-color, #333); /* use your existing variable */
    background-color: rgba(240, 240, 240, 0.5) !important; /* 50% transparent */
    color: var(--button-text, #000); /* text color */
    margin-bottom: 10px; /* spacing between buttons */
    cursor: pointer;
    transition: background 0.2s;
}

.category-btn:hover {
    background-color: var(--button-hover-bg, #ddd);
    transform: scale(1.05);
}

.category-btn.active {
    background: linear-gradient(45deg, #fabcdb, #deafe7);
    color: #333;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.inventory-actions {
    display: flex;
    flex-direction: column;      /* total above buttons */
    align-items: flex-end;       /* stick to the right side */
    justify-content: center;     /* center vertically within their container */
    margin-right: 200px;          /* spacing from right wall */
    height: 100%;                /* allow vertical centering */
}

.inventory-actions button {
    padding: 6px 12px;   /* skinnier buttons */
    border: none;
    border-radius: 6px;
    background-color: rgba(250, 188, 219, 0.8); 
    color: #333;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.inventory-actions button:hover {
    background-color: #deafe7;
    transform: scale(1.05);
}

.quantity-controls button {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: #fff;
    font-size: 16px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quantity-controls button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.quantity-display {
    display: inline-block;
    width: 24px;
    text-align: center;
    font-weight: bold;
    margin: 0 4px;
    color: #fff;
}

/* =========================
   SHIPPING FORM STYLING
   ========================= */
.shipping-form {
    background-color: rgba(255, 255, 255, 0.05); /* very subtle, almost transparent */
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    padding: 20px;
    border-radius: 12px;
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    text-align: left;
}


.shipping-wrapper {
    display: flex;
    gap: 40px;
    flex-wrap: wrap; /* stack on small screens */
    justify-content: center;
    align-items: stretch;
    flex-direction: row;
}

#shipping-popup::-webkit-scrollbar {
    width: 8px;
}
#shipping-popup::-webkit-scrollbar-thumb {
    background: #fabcdb;
    border-radius: 4px;
}
#shipping-popup::-webkit-scrollbar-track {
    background: #eee;
}

.shipping-history-container {
    flex: 1 1 auto;             /* keep it flexible in the layout */
    min-width: 300px;
    max-width: 500px;
    max-height: 640px;
    border-radius: 12px;
    border: 1px solid #ccc;
    display: flex;
    flex-direction: column;
    overflow: hidden;           /* keeps rounded corners */
    overflow-y: auto;
}

.shipping-list {
    flex: 1 1 auto;             /* fill available height */
    overflow-y: auto;           /* enable vertical scroll */
    padding: 10px;
}

/* Custom scrollbar styling */
.shipping-history-container::-webkit-scrollbar {
    width: 10px;
}

.shipping-history-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

.shipping-history-container::-webkit-scrollbar-thumb {
    background-color: #fabcdb; /* matches site accent */
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.shipping-history-container::-webkit-scrollbar-thumb:hover {
    background-color: #f48fb1;
}

/* Optional: make the list a bit nicer */
.shipping-history-container ul {
    list-style: none;
    padding-left: 0;
    margin-top: 10px;
}

.shipping-history-container li {
    padding: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}
.shipping-history-container li:last-child {
    border-bottom: none;
}

.shipping-form .form-row {
    display: flex;
    gap: 10px;
}

.shipping-form .form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.shipping-form .form-group input {
    background-color: rgba(255, 255, 255, 0.3); /* subtle transparent */
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff; /* text visible on gradient background */
    padding: 10px;
    border-radius: 8px;
    font-size: 16px;
}

.shipping-form .form-group input:focus {
    outline: none;
    border-color: #fabcdb;
    box-shadow: 0 0 5px rgba(250, 188, 219, 0.5);
}

.shipping-form .full-width {
    flex: 1 1 100%;
}

.shipping-form .btn-save {
    padding: 12px 30px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    background-color: #fabcdb;
    color: #333;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    align-self: flex-end;
}

.shipping-form .btn-save:hover {
    background-color: #deafe7;
    transform: scale(1.05);
}

.postal-row {
    display: flex;
    gap: 10px;
    align-items: flex-end; /* ensures button aligns with input bottom */
}

.postal-row input {
    flex: 1; /* input takes remaining space */
}

.postal-row button {
    padding: 8px 16px;
    border-radius: 6px;
    border: none;
    background-color: #fabcdb;
    color: #333;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.postal-row button:hover {
    background-color: #deafe7;
    transform: scale(1.05);
}

/* =========================
   MODAL
   ========================= */

/* Modal Overlay */
.modal-overlay {
    display: flex;
    justify-content: center;
    align-items: center;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}



/* Show modal */
.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Modal Box */
.modal-content {
    background: #4ca59c; /* Teal background */
    padding: 30px;
    border-radius: 12px;
    max-width: 1200px;
    width: 90%;
    text-align: center;
    transform: translateY(-50px);
    transition: transform 0.3s ease;
    color: #fff; /* Make text readable */
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    max-height:800px;
    overflow-y: auto;
}

/* Slide down when active */
.modal-overlay.active .modal-content {
    transform: translateY(0);
}

/* Modal Text */
.modal-content h3 {
    margin-bottom: 20px;
    font-size: 18px;
    color: #fff;
}

/* Buttons */
.modal-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.modal-buttons button {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s ease;
}

/* Yes button */
#modal-yes {
    background: #fabcdb;
    color: #333;
}
#modal-yes:hover {
    background: #f99fc0;
}

/* No button */
#modal-no {
    background: rgba(241, 227, 227, 0.3);
    color: #fff;
}
#modal-no:hover {
    background: rgba(245, 241, 241, 0.5);
}

#sell-success-modal .-modal-contentSS {
    background: rgba(0,0,0,0.8);
    padding: 20px 40px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center; /* vertically center inside modal box */
    align-items: center;    /* horizontally center */
    text-align: center;     /* for text elements inside */
    max-width: 400px;
    width: 80%;
    color: white;
}

#sell-balance-change {
    color: #ffffff; /* green */
}

#sell-success-modal {
    display: none; /* ensures it never flashes on page load */
}

/* Container spacing */
/* Container */
#history {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    height: 700px;
    overflow-y: auto;
}

/* Scrollbar track */
#history::-webkit-scrollbar {
    width: 10px;              /* Width of scrollbar */
}

/* Track background */
#history::-webkit-scrollbar-track {
    background: rgba(241, 241, 241, 0.4);       /* Light background for the track */
    border-radius: 10px;
}

/* Scrollbar thumb (the draggable part) */
#history::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #1abc9c, #16a085);  /* Teal gradient */
    border-radius: 10px;
    border: 2px solid #f1f1f1;  /* Adds spacing around thumb */
}

/* Scrollbar thumb hover */
#history::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #16a085, #1abc9c);
}

/* Optional: very subtle shadow */
#history::-webkit-scrollbar-thumb:active {
    box-shadow: inset 0 0 5px rgba(0,0,0,0.2);
}


/* Title styling */
#history h2 {
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.8rem;
    color: #333;
}

/* Table styling */
#history table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
}

/* Table header */
#history table th,
#history table td {
    padding: 12px 15px;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

/* Optional: add striped rows */
#history table tr:nth-child(even) {
    background-color: #f9f9f9;
}

/* Row hover effect */
#history table tr:hover {
    background-color: #f0f8ff;
}

/* Buttons */
.view-cards-btn {
    padding: 6px 12px;
    background-color: #4a90e2;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.2s, transform 0.1s;
}

.view-cards-btn:hover {
    background-color: #357ab7;
    transform: translateY(-2px);
}

/* Fallback for empty state */
#history p {
    text-align: center;
    color: #777;
    font-size: 1.1rem;
    margin-top: 20px;
}

.inventory-top-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    padding: 10px 15px;
    background: linear-gradient(90deg, #fabcdb, #8d5f76);
    border-radius: 12px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.2);
    flex-direction: column;
    margin-left: 40px;
}

.inventory-top-bar label {
    font-size: 14px;
    font-weight: bold;
    color: white;
}

.inventory-top-bar select {
    padding: 6px 10px;
    font-size: 14px;
    border: none;
    border-radius: 8px;
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: box-shadow 0.2s ease;
}

.inventory-top-bar select:focus {
    outline: none;
    box-shadow: 0 0 6px rgba(255,255,255,0.7);
}

#select-all-btn {
    padding: 6px 12px;
    font-size: 14px;
    border: none;
    border-radius: 8px;
    background: #8d5f76;
    color: white;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
}

#select-all-btn:hover {
    background: #6c475b;
    transform: translateY(-2px);
}

/* ---------- Topup History ---------- */
#topup-history {
    width: 100%;
    padding: 10px 15px;
    box-sizing: border-box;
    max-height: 520px;        /* same as sell-history */
    overflow-y: auto;
}

/* Custom scrollbar matching sell-history */
#topup-history::-webkit-scrollbar {
    width: 8px;
}

#topup-history::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.06);
    border-radius: 8px;
}

#topup-history::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #fabcdb, #deafe7);
    border-radius: 8px;
    border: 2px solid rgba(255,255,255,0.02);
}

#topup-history::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #f48fb1, #c78aa8);
}

/* Firefox */
#topup-history {
    scrollbar-width: thin;
    scrollbar-color: #fabcdb rgba(0,0,0,0.06);
}

/* History Grid & Row */
#topup-history .history-grid {
    display: flex;
    flex-direction: column;
    gap: 10px; /* space between rows */
}

#topup-history .history-row {
    display: flex;
    justify-content: space-between; /* 3 columns */
    align-items: center;
    padding: 10px 15px;
    border-radius: 8px;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    font-size: 16px;
    color: white;
}

#topup-history .history-col {
    flex: 1;
    text-align: center;
    min-width: 100px;
}

#topup-history .history-col:first-child {
    text-align: left;
}

#topup-history .history-col:nth-child(2) {
    text-align: center;
}

#topup-history .history-col:last-child {
    text-align: right;
}

/* Responsive */
@media (max-width: 1080px) {
    #topup-history .history-row {
        font-size: 14px;
        padding: 8px 10px;
    }
    #topup-history .history-col {
        min-width: 80px;
    }
}



/* =======================
   1080p
   ======================= */

/* CSS for screens 1920px wide or smaller */
@media (max-width: 1920px) {
    .inventory-filters{
        font-size: 5px;
        margin-bottom: 100px !important;
    }

    .category-btn{
        width:300px;
        font-size: 20px;
        padding: 15px 100px !important;
    }

    .inventory-box{
        min-width: 1000px;
        max-width: 1000px;
        height: 490px;

    }

    .inventory-actions{
        margin-right: 100px;
    }

    .inventory-card{
        width: 160px;
    }

    #history-box{
        height: 450px;
    }

    #history{
        height: 580px;
    }
}

   /* =======================
   1080p
   ======================= */
