/* ===== CSS Variables ===== */
:root {
    --cyan-primary: #00BCD4;
    --cyan-light: #E0F7FA;
    --cyan-dark: #00838F;
    --gray-bg: #F5F7FA;
    --shadow: 0 4px 20px rgba(0,0,0,0.08);
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --sidebar-width: 260px;
}

/* ===== Base Styles ===== */
* {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
    background: var(--gray-bg);
    margin: 0;
    min-height: 100vh;
}

/* ===== Sidebar Navigation ===== */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: white;
    box-shadow: var(--shadow);
    z-index: 100;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 24px;
    border-bottom: 1px solid #eee;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-logo .icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--cyan-primary), var(--cyan-dark));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
}

.sidebar-logo h1 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
    color: #333;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 12px;
}

.nav-section {
    margin-bottom: 24px;
}

.nav-section-title {
    font-size: 0.7rem;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 12px;
    margin-bottom: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 10px;
    color: #666;
    text-decoration: none;
    font-size: 0.9rem;
    margin-bottom: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.nav-link:hover {
    background: var(--cyan-light);
    color: var(--cyan-dark);
}

.nav-link.active {
    background: var(--cyan-primary);
    color: white;
}

/* Nav link group (Find Trade + status section as single clickable area) */
.nav-link-group {
    display: block;
    text-decoration: none;
    border-radius: 10px;
    margin-bottom: 4px;
    padding-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.nav-link-group:hover {
    background: var(--cyan-light);
}

.nav-link-group:hover .nav-link-content {
    color: var(--cyan-dark);
}

.nav-link-group:hover .nav-sub-status {
    background: transparent;
}

.nav-link-group.active {
    background: var(--cyan-primary);
}

.nav-link-group.active .nav-link-content {
    color: white;
}

.nav-link-group.active .nav-sub-status {
    background: rgba(255,255,255,0.15);
}

.nav-link-group.active .status-label,
.nav-link-group.active .status-row i {
    color: rgba(255,255,255,0.8);
}

.nav-link-group.active .status-value {
    color: white;
}

.nav-link-group.active .status-value.status-on {
    color: white;
}

.nav-link-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #666;
    font-size: 0.9rem;
}

.nav-link-content i {
    font-size: 1.1rem;
}

.nav-link i {
    font-size: 1.1rem;
}

.nav-link .badge {
    margin-left: auto;
    background: var(--cyan-light);
    color: var(--cyan-dark);
    font-size: 0.7rem;
    padding: 4px 8px;
    border-radius: 10px;
}

.nav-link.active .badge {
    background: rgba(255,255,255,0.3);
    color: white;
}

.nav-link.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.nav-link.disabled:hover {
    background: transparent;
    color: #666;
}

.sidebar-user {
    padding: 16px;
    border-top: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-user.sidebar-user-top {
    border-top: none;
    border-bottom: 1px solid #eee;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--cyan-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan-primary);
}

.user-info {
    flex: 1;
}

.user-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: #333;
}

.user-status {
    font-size: 0.75rem;
    color: #4CAF50;
}

/* ===== Sidebar Status Section (below Search Cards) ===== */
.nav-sub-status {
    background: #f5f5f5;
    border-radius: 8px;
    padding: 6px 12px;
    margin: 0 12px;
    transition: background-color 0.15s ease;
}

.status-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 5px 0;
    font-size: 0.8rem;
    color: inherit;
}

.status-row i {
    color: #888;
    width: 18px;
    font-size: 0.9rem;
    text-align: center;
}

.status-row i.status-icon-active {
    color: var(--cyan-primary);
}

.status-row i.status-icon-paused {
    color: #999;
}

.status-label {
    color: #666;
    flex: 1;
}

.status-value {
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    min-width: 32px;
    text-align: right;
}

.status-value.status-on {
    color: var(--cyan-primary);
}

.status-value.status-off {
    color: #999;
}

.status-value.status-warning {
    color: #f0ad4e;
}

.status-value.status-paused {
    color: #999;
}

.status-value .autoaccept-paused-icon {
    font-size: 0.85rem;
}

.status-value .new-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    padding: 0;
    background: #ff5252;
    border-radius: 50%;
    animation: sidebar-pulse 1.5s ease-in-out infinite;
}

@keyframes sidebar-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.15); }
}

.sidebar-login-link {
    color: var(--cyan-primary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s;
}

.sidebar-login-link:hover {
    color: var(--cyan-dark);
}

.sidebar-login-link i {
    font-size: 0.8rem;
    transition: transform 0.2s;
}

.sidebar-login-link:hover i {
    transform: translateX(2px);
}

/* ===== Main Content ===== */
.main-content {
    margin-left: var(--sidebar-width);
    padding: 24px;
    min-height: 100vh;
}

/* ===== Hero Search Section ===== */
.hero-search {
    background: linear-gradient(145deg, #005662 0%, #00BCD4 100%);
    border-radius: 20px;
    padding: 48px;
    text-align: center;
    color: white;
    margin-bottom: 32px;
    position: relative;
    overflow: hidden;
}

.hero-search::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 10% 90%, rgba(0, 188, 212, 0.3) 0%, transparent 35%),
        radial-gradient(circle at 90% 10%, rgba(0, 188, 212, 0.25) 0%, transparent 30%);
    pointer-events: none;
}

.hero-search::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.hero-search > * {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.hero-subtitle {
    opacity: 0.9;
    margin-bottom: 24px;
}

.search-box-hero {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0,0,0,0.3);
}

.search-box-hero input {
    flex: 1;
    border: none;
    padding: 18px 24px;
    font-size: 1rem;
    outline: none;
}

.search-box-hero button {
    background: var(--cyan-primary);
    border: none;
    color: white;
    padding: 18px 32px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.search-box-hero button:hover {
    background: var(--cyan-dark);
}

/* ===== Content Layout ===== */
.content-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 24px;
}

.content-main {
    min-width: 0;
}

.content-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ===== Panels ===== */
.panel {
    background: white;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.panel-header {
    padding: 20px 24px;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.panel-title {
    font-weight: 600;
    font-size: 1.1rem;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.panel-title .count {
    background: var(--cyan-light);
    color: var(--cyan-dark);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
}

.panel-body {
    padding: 20px 24px;
}

.panel-footer {
    padding: 12px 16px;
    border-top: 1px solid #eee;
    background: #fafafa;
}

.panel-notify-bar {
    padding: 12px 16px;
    border-bottom: 1px solid #eee;
    background: #fafafa;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.notify-toggle-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.notify-toggle-row .notify-toggle-label {
    flex: 1;
}

.notify-toggle-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    color: #666;
    user-select: none;
}

.notify-toggle-label.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.notify-toggle-label input[type="checkbox"] {
    display: none;
}

.notify-toggle-label i {
    font-size: 1.1rem;
    color: #aaa;
    transition: all 0.2s;
}

.notify-toggle-label input[type="checkbox"]:checked + i {
    color: var(--cyan-primary);
}

.notify-toggle-label:hover:not(.disabled) {
    color: #333;
}

.notify-toggle-label:hover:not(.disabled) i:not(.auto-accept-info) {
    transform: scale(1.1);
}

.auto-accept-info {
    font-size: 0.9rem;
    color: #bbb;
    cursor: pointer;
    outline: none;
}

.auto-accept-info:hover,
.auto-accept-info:focus {
    color: var(--cyan-primary);
}

.auto-accept-config-btn {
    background: none;
    border: none;
    color: #bbb;
    cursor: pointer;
    padding: 4px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    margin-left: auto;
}

.auto-accept-config-btn:hover:not(.disabled) {
    color: var(--cyan-primary);
}

.auto-accept-config-btn.disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.auto-accept-paused-badge {
    color: #999;
    font-size: 0.85rem;
    margin-left: auto;
    display: inline-flex;
    align-items: center;
}

/* Monitor Settings Cards */
.monitor-settings-cards {
    display: flex;
    gap: 8px;
    padding: 12px;
    border-bottom: 1px solid #eee;
    background: #fafafa;
}

.monitor-settings-card {
    flex: 1;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.2s;
}

.monitor-settings-card:hover:not(.disabled) {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.monitor-settings-card.disabled {
    opacity: 0.5;
}

.settings-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    background: var(--gray-bg);
    font-size: 0.75rem;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.settings-card-icon {
    font-size: 0.9rem;
    color: #999;
    transition: color 0.2s;
}

.settings-card-icon.active {
    color: var(--cyan-primary);
}

.settings-card-info {
    margin-left: auto;
    font-size: 0.8rem;
    color: #bbb;
    cursor: pointer;
    text-transform: none;
}

.settings-card-info:hover,
.settings-card-info:focus {
    color: var(--cyan-primary);
}

.settings-card-body {
    display: flex;
    flex-direction: column;
}

.settings-card-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    cursor: pointer;
    transition: background 0.15s;
    border-top: 1px solid #f0f0f0;
    min-height: 44px;
}

.settings-card-row:first-child {
    border-top: none;
}

.settings-card-row:hover:not(.disabled) {
    background: var(--cyan-light);
}

.settings-card-row:active:not(.disabled) {
    background: #b2ebf2;
}

.settings-card-row.disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.settings-row-label {
    flex: 1;
    font-size: 0.85rem;
    color: #333;
}

.settings-row-toggle {
    width: 32px;
    height: 18px;
    background: #ccc;
    border-radius: 18px;
    position: relative;
    transition: background 0.2s;
    flex-shrink: 0;
}

.settings-row-toggle::after {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    background: white;
    border-radius: 50%;
    top: 2px;
    left: 2px;
    transition: transform 0.2s;
}

.settings-row-toggle.active {
    background: var(--cyan-primary);
}

.settings-row-toggle.active::after {
    transform: translateX(14px);
}

.settings-card-row.disabled .settings-row-toggle {
    opacity: 0.5;
}

.settings-row-value {
    font-size: 0.8rem;
    color: #666;
}

.settings-row-arrow {
    font-size: 0.75rem;
    color: #bbb;
}

.hidden-checkbox {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

/* Work Hours Modal */
.work-hours-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.work-hours-inputs {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 20px;
}

.work-hours-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.work-hours-field label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.work-hours-field select {
    padding: 10px 16px;
    border: 2px solid #eee;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
    min-width: 100px;
}

.work-hours-field select:focus {
    outline: none;
    border-color: var(--cyan-primary);
}

.work-hours-separator {
    font-size: 1rem;
    color: #666;
    margin-top: 20px;
}

.work-hours-current-status {
    text-align: center;
    font-size: 0.85rem;
    color: #666;
    padding: 10px;
    background: #f5f5f5;
    border-radius: 8px;
    margin: 0;
}

.work-hours-current-status i {
    margin-right: 6px;
}

.work-hours-current-status i.bi-pause-circle {
    color: #ffc107;
}

.work-hours-current-status i.bi-check-circle {
    color: #28a745;
}

/* Simple Modal (used for work hours, etc.) */
.simple-modal {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s;
}

.modal-overlay.active .simple-modal {
    transform: scale(1);
}

.simple-modal .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #eee;
}

.simple-modal .modal-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
}

.simple-modal .modal-body {
    padding: 24px;
}

.simple-modal .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid #eee;
    background: #fafafa;
    border-radius: 0 0 16px 16px;
}

.panel-refresh-btn {
    background: var(--cyan-light);
    border: none;
    color: var(--cyan-primary);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.panel-refresh-btn:hover:not(:disabled) {
    background: var(--cyan-primary);
    color: white;
}

.panel-refresh-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.panel-refresh-btn i.spin {
    animation: spin 1s linear infinite;
}

/* ===== Pokemon Cards Grid ===== */
.pokemon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 16px;
}

/* Search results: single row with horizontal scroll */
#search-results-grid {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 12px;
}

#search-results-grid::-webkit-scrollbar {
    height: 8px;
}

#search-results-grid::-webkit-scrollbar-track {
    background: var(--gray-bg);
    border-radius: 4px;
}

#search-results-grid::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

#search-results-grid::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}

#search-results-grid .pokemon-card {
    flex: 0 0 120px;
}

#search-results-grid .empty-state {
    flex: 1;
}

.pokemon-card {
    position: relative;
    background: var(--gray-bg);
    border-radius: 16px;
    padding: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    border: 3px solid transparent;
}

.pokemon-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
    background: white;
}

.pokemon-card.selected {
    border-color: var(--cyan-primary);
    background: white;
}

.pokemon-card.new-card {
    border-color: #ff5252;
}

.pokemon-card.unavailable {
    opacity: 0.5;
    cursor: not-allowed;
}

.pokemon-card.unavailable:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.pokemon-card img {
    width: 100%;
    border-radius: 10px;
}

.pokemon-card .name {
    font-weight: 600;
    font-size: 0.8rem;
    margin-top: 8px;
    color: #333;
}

.pokemon-card .meta {
    font-size: 0.7rem;
    color: #999;
}

.pokemon-card .rarity {
    display: flex;
    justify-content: center;
    gap: 2px;
    margin-top: 4px;
}

.pokemon-card .rarity i {
    font-size: 0.55rem;
    color: gold;
}

.pokemon-card .offer-count {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--cyan-primary);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 12px;
    min-width: 20px;
    text-align: center;
}

.pokemon-card .lang-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #333;
    color: white;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 6px;
    text-transform: uppercase;
}

/* ===== Feature Cards ===== */
.feature-card {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 16px;
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--cyan-light);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan-primary);
    font-size: 1.25rem;
}

.feature-content {
    flex: 1;
}

.feature-title {
    font-weight: 600;
    color: #333;
}

.feature-desc {
    font-size: 0.8rem;
    color: #999;
}

.form-check-input:checked {
    background-color: var(--cyan-primary);
    border-color: var(--cyan-primary);
}

.btn-cyan {
    background-color: var(--cyan-primary);
    border-color: var(--cyan-primary);
    color: white;
}

.btn-cyan:hover {
    background-color: var(--cyan-dark);
    border-color: var(--cyan-dark);
    color: white;
}

.btn-cyan:disabled {
    background-color: var(--cyan-primary);
    border-color: var(--cyan-primary);
    opacity: 0.65;
}

/* ===== New Indicator ===== */
.new-indicator {
    background: #ff5252;
    color: white;
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 6px;
    margin-left: 6px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

/* ===== Orders Page Layout ===== */
.orders-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 24px;
    height: calc(100vh - 48px);
}

/* Orders Sidebar */
.orders-sidebar {
    background: white;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.orders-sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.orders-sidebar-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: #333;
}

.orders-sidebar-header p {
    font-size: 0.85rem;
    color: #999;
    margin: 0;
}

.orders-tabs {
    display: flex;
    padding: 12px 20px;
    gap: 8px;
    border-bottom: 1px solid #eee;
}

.orders-tab {
    flex: 1;
    padding: 10px;
    border: none;
    background: var(--gray-bg);
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}

.orders-tab.active {
    background: var(--cyan-primary);
    color: white;
}

.orders-list {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
}

.order-list-item {
    padding: 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 8px;
    border: 2px solid transparent;
}

.order-list-item:hover {
    background: var(--gray-bg);
}

.order-list-item.active {
    background: var(--cyan-light);
    border-color: var(--cyan-primary);
}

.order-list-item-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.order-list-avatar {
    width: 40px;
    height: 40px;
    background: var(--cyan-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan-primary);
}

.order-list-item.active .order-list-avatar {
    background: var(--cyan-primary);
    color: white;
}

.order-list-hawker {
    flex: 1;
}

.order-list-hawker-name {
    font-weight: 600;
    color: #333;
}

.order-list-hawker-meta {
    font-size: 0.75rem;
    color: #999;
}

.order-list-status {
    font-size: 0.7rem;
    padding: 4px 10px;
    border-radius: 12px;
    background: var(--cyan-light);
    color: var(--cyan-dark);
}

.order-list-status.pending {
    background: #FFF3E0;
    color: #FF9800;
}

.order-list-cards {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.order-list-cards img {
    width: 48px;
    border-radius: 6px;
    box-shadow: var(--shadow-sm);
}

.order-list-cards .arrow {
    color: var(--cyan-primary);
    font-size: 1rem;
}

/* Orders Main Content */
.orders-main {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Order Detail Header */
.order-detail-header {
    background: linear-gradient(135deg, var(--cyan-primary), var(--cyan-dark));
    border-radius: 20px;
    padding: 24px;
    color: white;
    display: flex;
    align-items: center;
    gap: 20px;
}

.order-detail-avatar {
    width: 64px;
    height: 64px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.order-detail-info h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 4px 0;
}

.order-detail-info p {
    margin: 0;
    opacity: 0.9;
    font-size: 0.9rem;
}

.order-detail-timer {
    margin-left: auto;
    text-align: right;
}

.order-detail-timer .time {
    font-size: 1.5rem;
    font-weight: 700;
}

.order-detail-timer .label {
    font-size: 0.8rem;
    opacity: 0.9;
}

/* Trade Cards Display */
.trade-display {
    background: white;
    border-radius: 20px;
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.trade-display-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
}

.trade-cards-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 32px;
}

.trade-card-box {
    text-align: center;
}

.trade-card-box img {
    width: 120px;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.trade-card-box .card-name {
    font-weight: 600;
    margin-top: 12px;
    color: #333;
}

.trade-card-box .card-lang {
    font-size: 0.8rem;
    color: #999;
}

.trade-card-box .direction {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 8px;
}

.trade-card-box .direction.receiving {
    background: #E8F5E9;
    color: #4CAF50;
}

.trade-card-box .direction.sending {
    background: #FFF3E0;
    color: #FF9800;
}

.trade-arrow-big {
    font-size: 2.5rem;
    color: var(--cyan-primary);
}

/* Order Actions */
.order-actions-bar {
    display: flex;
    gap: 12px;
}

.order-action-btn {
    flex: 1;
    padding: 16px 24px;
    border-radius: 14px;
    border: none;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
}

.order-action-btn.primary {
    background: var(--cyan-primary);
    color: white;
}

.order-action-btn.primary:hover {
    background: var(--cyan-dark);
}

.order-action-btn.secondary {
    background: white;
    color: #333;
    box-shadow: var(--shadow-sm);
}

.order-action-btn.secondary:hover {
    background: var(--gray-bg);
}

.order-action-btn.danger {
    background: #ffebee;
    color: #ff5252;
}

.order-action-btn.danger:hover {
    background: #ffcdd2;
}

/* Chat Panel */
.chat-panel {
    background: white;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 300px;
}

.chat-header {
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-header-avatar {
    width: 40px;
    height: 40px;
    background: var(--cyan-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan-primary);
}

.chat-header-info {
    flex: 1;
}

.chat-header-name {
    font-weight: 600;
    color: #333;
}

.chat-header-status {
    font-size: 0.8rem;
    color: #4CAF50;
}

.chat-block-btn {
    background: none;
    border: 2px solid #ff5252;
    color: #ff5252;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
}

.chat-block-btn:hover {
    background: #ffebee;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background: #fafafa;
}

.chat-bubble {
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 18px;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.chat-bubble.received {
    background: white;
    margin-right: auto;
    border-bottom-left-radius: 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.chat-bubble.sent {
    background: var(--cyan-primary);
    color: white;
    margin-left: auto;
    border-bottom-right-radius: 4px;
}

.chat-input-area {
    padding: 16px 20px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 12px;
}

.chat-input-area input {
    flex: 1;
    border: 2px solid #eee;
    border-radius: 24px;
    padding: 12px 20px;
    outline: none;
    font-size: 0.9rem;
}

.chat-input-area input:focus {
    border-color: var(--cyan-primary);
}

.chat-input-area button {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    background: var(--cyan-primary);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-input-area button:hover {
    background: var(--cyan-dark);
}

.chat-input-area button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* ===== Profile Page ===== */
.profile-banner {
    background: linear-gradient(135deg, var(--cyan-primary), var(--cyan-dark));
    border-radius: 24px;
    padding: 48px;
    color: white;
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 24px;
}

.profile-avatar-lg {
    width: 100px;
    height: 100px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-avatar-lg i {
    font-size: 3rem;
    color: var(--cyan-primary);
}

.profile-name-lg {
    font-size: 1.75rem;
    font-weight: 700;
}

.profile-email-lg {
    opacity: 0.9;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
}

.settings-card {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.settings-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.settings-card-danger {
    border: 2px solid #ffebee;
}

.settings-icon {
    width: 48px;
    height: 48px;
    background: var(--cyan-light);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan-primary);
    font-size: 1.25rem;
}

.settings-icon-danger {
    background: #ffebee;
    color: #ff5252;
}

.settings-card .title {
    font-weight: 600;
    color: #333;
}

.settings-card .desc {
    font-size: 0.8rem;
    color: #999;
}

.settings-card .value {
    margin-left: auto;
    color: #adb5bd;
    font-size: 0.85rem;
}

/* ===== Blocked Users Page ===== */
.blocked-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 16px;
}

.blocked-card {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 16px;
}

.blocked-avatar {
    width: 48px;
    height: 48px;
    background: var(--gray-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
}

.blocked-info {
    flex: 1;
}

.blocked-name {
    font-weight: 600;
    color: #333;
}

.blocked-date {
    font-size: 0.8rem;
    color: #999;
}

.unblock-btn {
    background: none;
    border: 2px solid #ff5252;
    color: #ff5252;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
}

.unblock-btn:hover {
    background: #ffebee;
}

/* ===== Empty State ===== */
.empty-state,
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #999;
    text-align: center;
    padding: 48px;
    grid-column: 1 / -1;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 16px;
    color: #ddd;
}

.empty-state h3 {
    color: #666;
    margin-bottom: 8px;
}

/* ===== Exchange Modal ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.exchange-modal {
    background: white;
    border-radius: 24px;
    width: 90%;
    max-width: 600px;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: scale(0.9);
    transition: transform 0.3s;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.modal-overlay.active .exchange-modal {
    transform: scale(1);
}

.exchange-modal-header {
    background: linear-gradient(135deg, var(--cyan-primary), var(--cyan-dark));
    color: white;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.modal-close-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.modal-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.exchange-modal-header h2 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
    flex: 1;
}

.exchange-refresh-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.exchange-refresh-btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.3);
}

.exchange-refresh-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.exchange-trade-preview {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    padding: 24px;
    background: var(--gray-bg);
    border-bottom: 1px solid #eee;
}

.exchange-card-box {
    text-align: center;
    flex: 1;
    max-width: 140px;
}

.exchange-card-label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 12px;
    border-radius: 12px;
    margin-bottom: 12px;
    display: inline-block;
}

.exchange-card-label.receiving {
    background: #E8F5E9;
    color: #4CAF50;
}

.exchange-card-label.sending {
    background: #FFF3E0;
    color: #FF9800;
}

.exchange-card-box img {
    width: 100%;
    max-width: 100px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.exchange-card-name {
    font-weight: 600;
    font-size: 0.85rem;
    margin-top: 10px;
    color: #333;
}

.exchange-card-meta {
    font-size: 0.75rem;
    color: #999;
}

.exchange-arrow {
    color: var(--cyan-primary);
    font-size: 1.5rem;
}

.exchange-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
}

.exchange-hint {
    color: #666;
    font-size: 0.85rem;
    margin-bottom: 16px;
}

.exchange-offers-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Offer Item in Modal */
.exchange-offer-item {
    background: var(--gray-bg);
    border-radius: 16px;
    padding: 16px;
}

.exchange-offer-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.exchange-offer-avatar {
    width: 44px;
    height: 44px;
    background: var(--cyan-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cyan-primary);
    font-size: 1.1rem;
}

.exchange-offer-info {
    flex: 1;
}

.exchange-offer-name {
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
}

.exchange-offer-meta {
    font-size: 0.8rem;
    color: #666;
}

.offer-lang-badge {
    background: #333;
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    text-transform: uppercase;
}

.exchange-offer-trade-btn {
    background: var(--cyan-primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.2s;
}

.exchange-offer-trade-btn:hover:not(:disabled) {
    background: var(--cyan-dark);
}

.exchange-offer-trade-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    opacity: 0.7;
}

.exchange-offer-seeking {
    color: var(--cyan-primary);
    font-weight: 500;
    font-size: 0.8rem;
    margin-bottom: 10px;
}

.exchange-offer-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
    max-width: 100%;
}

.exchange-offer-card {
    text-align: center;
}

.exchange-offer-card.selectable {
    cursor: pointer;
    padding: 6px;
    border-radius: 10px;
    border: 2px solid transparent;
    transition: all 0.2s;
}

.exchange-offer-card.selectable:hover {
    background: white;
    border-color: #ddd;
}

.exchange-offer-card.selectable.selected {
    background: white;
    border-color: var(--cyan-primary);
    box-shadow: 0 0 0 3px rgba(0, 188, 212, 0.2);
}

.exchange-offer-card img {
    width: 100%;
    max-width: 80px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.exchange-offer-card .lang-badge {
    display: inline-block;
    background: #333;
    color: white;
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 4px;
    margin-top: 6px;
}

.exchange-offer-card .card-name {
    font-size: 0.7rem;
    font-weight: 500;
    margin-top: 4px;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.exchange-offer-card .rarity {
    font-size: 0.55rem;
    color: #999;
}

.exchange-offer-card .rarity i {
    font-size: 0.5rem;
    color: gold;
}

/* Loading state for modal */
.exchange-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: #999;
}

.exchange-loading i {
    font-size: 2rem;
    margin-bottom: 12px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Empty state for modal */
.exchange-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: #999;
    text-align: center;
}

.exchange-empty i {
    font-size: 3rem;
    margin-bottom: 12px;
    color: #ddd;
}

/* ===== Live Monitor Styles ===== */

/* Panel Actions Container */
.panel-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.panel-action-btn {
    background: var(--cyan-light);
    border: none;
    color: var(--cyan-primary);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.panel-action-btn:hover:not(:disabled) {
    background: var(--cyan-primary);
    color: white;
}

.panel-action-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.panel-action-btn i.spin {
    animation: spin 1s linear infinite;
}

/* Monitor Toggle Button */
.monitor-toggle-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    border: 2px solid #ddd;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
    font-size: 0.85rem;
    color: #666;
}

.monitor-toggle-btn:hover {
    border-color: var(--cyan-primary);
    color: var(--cyan-primary);
}

.monitor-toggle-btn.active {
    background: var(--cyan-primary);
    border-color: var(--cyan-primary);
    color: white;
}

.monitor-toggle-btn.active i {
    animation: pulse-icon 1.5s infinite;
}

.monitor-toggle-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: #ccc;
    color: #999;
}

.monitor-toggle-btn.disabled:hover {
    border-color: #ccc;
    color: #999;
}

@keyframes pulse-icon {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Monitoring Status Panel */
#monitor-status-panel .panel-title .monitor-icon {
    color: #999;
    margin-right: 4px;
}

#monitor-status-panel.has-active .panel-title .monitor-icon {
    color: var(--cyan-primary);
    animation: pulse-icon 1.5s infinite;
}

.monitor-empty-state {
    text-align: center;
    padding: 24px 16px;
    color: #999;
}

.monitor-empty-state i {
    font-size: 2.5rem;
    margin-bottom: 12px;
    color: #ddd;
}

.monitor-empty-state p {
    margin: 0 0 4px 0;
    font-weight: 500;
    color: #666;
}

.monitor-empty-state span {
    font-size: 0.8rem;
}

.monitored-cards-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Monitored Card Item */
.monitored-card-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--gray-bg);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.monitored-card-item:hover {
    background: white;
    box-shadow: var(--shadow-sm);
}

.monitored-card-item.current {
    border-color: var(--cyan-primary);
    background: white;
}

.monitored-card-item.paused {
    opacity: 0.6;
}

.monitored-card-item.paused .monitor-pulse {
    background: #999;
    animation: none;
}

.monitored-card-item img {
    width: 48px;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.monitored-card-info {
    flex: 1;
    min-width: 0;
}

.monitored-card-name {
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.monitored-card-meta {
    font-size: 0.75rem;
    color: #999;
    display: flex;
    align-items: center;
    gap: 6px;
}

.monitor-pulse {
    width: 8px;
    height: 8px;
    background: #4CAF50;
    border-radius: 50%;
    animation: pulse-dot 1.5s infinite;
    flex-shrink: 0;
}

@keyframes pulse-dot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(0.8); opacity: 0.6; }
}

.monitored-card-new {
    background: #ff5252;
    color: white;
    font-size: 0.65rem;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
    animation: badge-pulse 1.5s infinite;
}

@keyframes badge-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.monitored-card-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Mini toggle switch */
.mini-toggle {
    position: relative;
    width: 32px;
    height: 18px;
    flex-shrink: 0;
}

.mini-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.mini-toggle .slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.2s;
    border-radius: 18px;
}

.mini-toggle .slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: 0.2s;
    border-radius: 50%;
}

.mini-toggle input:checked + .slider {
    background-color: var(--cyan-primary);
}

.mini-toggle input:checked + .slider:before {
    transform: translateX(14px);
}

.monitored-card-btn {
    background: none;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    color: #999;
    font-size: 0.85rem;
}

.monitored-card-btn:hover {
    background: white;
}

.monitored-card-btn.reset-btn:hover {
    color: var(--cyan-primary);
}

.monitored-card-btn.stop-btn:hover {
    color: #ff5252;
}

/* New card highlight in customer goods */
.pokemon-card.new-card {
    border-color: #ff5252;
    position: relative;
}

.pokemon-card.new-card::before {
    content: 'NEW';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: #ff5252;
    color: white;
    font-size: 0.55rem;
    padding: 2px 6px;
    border-radius: 6px;
    font-weight: 600;
    z-index: 1;
}


/* ===== Inventory Page ===== */
.inventory-search-row {
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: 500px;
}

.search-clear-btn {
    background: var(--gray-bg);
    border: none;
    color: #999;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.2s;
    flex-shrink: 0;
}

.search-clear-btn:hover {
    background: #ffebee;
    color: #ff5252;
}

.search-box-inventory {
    display: flex;
    background: var(--gray-bg);
    border-radius: 12px;
    overflow: hidden;
    flex: 1;
}

.search-box-inventory input {
    flex: 1;
    border: none;
    padding: 12px 16px;
    font-size: 0.9rem;
    outline: none;
    background: transparent;
}

.search-box-inventory button {
    background: var(--cyan-primary);
    border: none;
    color: white;
    padding: 12px 20px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s;
}

.search-box-inventory button:hover {
    background: var(--cyan-dark);
}

.search-box-inventory button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.add-inventory-btn {
    width: 100%;
    margin-top: 16px;
    background: var(--cyan-primary);
    border: none;
    color: white;
    padding: 14px 20px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.add-inventory-btn:hover {
    background: var(--cyan-dark);
}

.inventory-search-results-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.inventory-search-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
    max-height: 300px;
    overflow-y: auto;
}

/* Horizontal scrolling search grid for inventory */
.inventory-search-grid-horizontal {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 12px;
    scroll-snap-type: x mandatory;
}

.inventory-search-grid-horizontal::-webkit-scrollbar {
    height: 8px;
}

.inventory-search-grid-horizontal::-webkit-scrollbar-track {
    background: var(--gray-bg);
    border-radius: 4px;
}

.inventory-search-grid-horizontal::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.inventory-search-grid-horizontal::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}

.inventory-search-grid-horizontal .inventory-search-card {
    flex: 0 0 120px;
    scroll-snap-align: start;
    padding: 12px;
}

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

.inventory-search-grid-horizontal .inventory-search-card .card-name {
    font-size: 0.8rem;
    margin-top: 8px;
}

.inventory-search-grid-horizontal .inventory-search-card .card-meta {
    font-size: 0.7rem;
}

.inventory-search-grid-horizontal .inventory-search-card .card-rarity i {
    font-size: 0.55rem;
}

.inventory-search-card {
    position: relative;
    background: var(--gray-bg);
    border-radius: 10px;
    padding: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.inventory-search-card:hover {
    background: white;
    box-shadow: var(--shadow-sm);
}

.inventory-search-card.selected {
    border-color: var(--cyan-primary);
    background: white;
}

.inventory-search-card.in-inventory {
    background: var(--cyan-light);
}

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

.inventory-search-card .card-name {
    font-size: 0.65rem;
    font-weight: 500;
    margin-top: 4px;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.inventory-search-card .card-meta {
    font-size: 0.55rem;
    color: #999;
}

.inventory-search-card .card-rarity {
    margin-top: 2px;
}

.inventory-search-card .card-rarity i {
    font-size: 0.45rem;
    color: gold;
}

.inventory-search-card .in-inventory-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    color: var(--cyan-primary);
    font-size: 0.8rem;
}

/* Language Selector */
.language-selector {
    margin-top: 16px;
}

.language-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.language-chip {
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    background: var(--gray-bg);
    color: #666;
    border: 2px solid transparent;
}

.language-chip:hover {
    background: var(--cyan-light);
    color: var(--cyan-dark);
}

.language-chip.selected {
    background: var(--cyan-primary);
    color: white;
    border-color: var(--cyan-primary);
}


/* ===== Login Modal ===== */
.login-modal {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    overflow: hidden;
    transform: scale(0.9);
    transition: transform 0.3s;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border-top: 4px solid var(--cyan-primary);
}

.modal-overlay.active .login-modal {
    transform: scale(1);
}

.login-modal-header {
    background: white;
    color: #222;
    padding: 18px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid #eee;
}

.login-modal-header h2 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    flex: 1;
}

.login-modal-header .modal-close-btn {
    background: #f5f5f5;
    color: #666;
}

.login-modal-header .modal-close-btn:hover {
    background: #eee;
    color: #333;
}

.login-modal-body {
    padding: 32px 24px;
}

.login-form-group {
    margin-bottom: 20px;
}

.login-form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.login-input-wrapper {
    display: flex;
    align-items: center;
    background: var(--gray-bg);
    border-radius: 12px;
    border: 2px solid transparent;
    transition: all 0.2s;
}

.login-input-wrapper:focus-within {
    border-color: var(--cyan-primary);
    background: white;
}

.login-input-wrapper i {
    padding: 0 16px;
    color: #999;
    font-size: 1rem;
}

.login-input-wrapper:focus-within i {
    color: var(--cyan-primary);
}

.login-input-wrapper input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 14px 16px 14px 0;
    font-size: 0.95rem;
    outline: none;
    color: #333;
}

.login-input-wrapper input::placeholder {
    color: #999;
}

.login-error {
    background: #ffebee;
    color: #d32f2f;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 0.85rem;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.login-error::before {
    content: "\F33A";
    font-family: "bootstrap-icons";
    font-size: 1rem;
}

.login-submit-btn {
    width: 100%;
    background: var(--cyan-primary);
    border: none;
    color: white;
    padding: 16px 24px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.login-submit-btn:hover:not(:disabled) {
    background: var(--cyan-dark);
}

.login-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.login-submit-btn .btn-loading i.spin {
    animation: spin 1s linear infinite;
}

/* ===== Password Change Modal ===== */
.password-change-notice {
    background: #fff3cd;
    color: #856404;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 0.85rem;
    margin-bottom: 20px;
    border: 1px solid #ffc107;
}

.password-change-notice i {
    color: #e0a800;
}

#password-change-success {
    background: #d4edda;
    color: #155724;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 0.85rem;
    margin-bottom: 20px;
    border: 1px solid #28a745;
}

/* ===== Toggle Disabled State ===== */
.toggle-wrapper.disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* ===== Responsive Design ===== */
@media (max-width: 1200px) {
    .content-grid {
        grid-template-columns: 1fr;
    }

    .content-sidebar {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .content-sidebar .feature-card {
        flex: 1 1 300px;
    }
}

@media (max-width: 992px) {
    .orders-layout {
        grid-template-columns: 1fr;
        height: auto;
    }

    .orders-sidebar {
        max-height: 400px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .sidebar-nav {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        padding: 8px;
    }

    .nav-section {
        display: flex;
        flex-direction: column;
        gap: 8px;
        margin-bottom: 0;
        width: 100%;
    }

    .nav-section-title {
        display: none;
    }

    .main-content {
        margin-left: 0;
        padding: 16px;
    }

    .hero-search {
        padding: 24px;
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .trade-cards-row {
        flex-direction: column;
        gap: 16px;
    }

    .trade-arrow-big {
        transform: rotate(90deg);
    }

    .exchange-modal {
        width: 95%;
        max-height: 90vh;
    }

    .exchange-trade-preview {
        padding: 16px;
        gap: 16px;
    }

    .exchange-card-box img {
        max-width: 80px;
    }

    .exchange-arrow {
        font-size: 1.2rem;
    }

    .monitor-settings-cards {
        flex-direction: column;
    }

    .content-sidebar {
        flex-direction: column;
    }

    .content-sidebar > .panel {
        width: 100%;
    }

    /* Mobile nav: full width items with horizontal status */
    .nav-link-group,
    .nav-link {
        width: 100%;
    }

    .nav-sub-status {
        display: flex;
        flex-direction: row;
        gap: 16px;
        padding: 6px 12px;
        margin: 0 12px 8px;
    }

    .nav-sub-status .status-row {
        flex: 1;
        padding: 0;
        gap: 6px;
    }

    .nav-sub-status .status-row i {
        width: auto;
    }
}
