/* ==========================================================================
   Sea of Thieves Australia (SOTAU) - The Pirate Database Stylesheet
   ========================================================================== */

/* Page Header & Hero */
.db-hero-section {
    padding-top: 140px;
    padding-bottom: 30px;
    position: relative;
    z-index: 1;
}

.db-hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
    margin-top: 30px;
    margin-bottom: 25px;
}

.db-stat-box {
    background: rgba(13, 20, 29, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    backdrop-filter: blur(8px);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.db-stat-box:hover {
    transform: translateY(-2px);
    border-color: rgba(245, 190, 24, 0.35);
}

.db-stat-box.stat-highlight {
    border-color: rgba(245, 190, 24, 0.3);
    background: linear-gradient(135deg, rgba(245, 190, 24, 0.08), rgba(13, 20, 29, 0.9));
}

.db-stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: rgba(245, 190, 24, 0.12);
    border: 1px solid rgba(245, 190, 24, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-gold);
    flex-shrink: 0;
}

.db-stat-icon.icon-teal {
    background: rgba(77, 208, 225, 0.12);
    border-color: rgba(77, 208, 225, 0.25);
    color: var(--accent-teal);
}

.db-stat-info {
    display: flex;
    flex-direction: column;
}

.db-stat-num {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
    color: #fff;
    line-height: 1.2;
}

.db-stat-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    font-weight: 600;
    margin-top: 2px;
}

/* Tab Navigation Pills */
.db-tabs-nav {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    background: rgba(10, 14, 22, 0.95);
    padding: 8px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 30px;
}

.db-tab-btn {
    flex: 1 1 auto;
    min-width: 170px;
    padding: 12px 18px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.2s ease;
}

.db-tab-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.04);
}

.db-tab-btn.active {
    background: linear-gradient(135deg, rgba(245, 190, 24, 0.18), rgba(245, 190, 24, 0.05));
    border-color: rgba(245, 190, 24, 0.4);
    color: var(--accent-gold);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.db-tab-badge {
    font-size: 0.72rem;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(245, 190, 24, 0.2);
    color: var(--accent-gold);
    font-weight: 800;
}

/* Active Tab Panels */
.db-tab-panel {
    display: none;
    animation: dbFadeIn 0.25s ease;
}

.db-tab-panel.active {
    display: block;
}

@keyframes dbFadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   MODULE 1: Universal Codex & Search
   ========================================================================== */
.db-filter-bar {
    background: rgba(13, 20, 29, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 25px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.db-search-row {
    display: flex;
    gap: 14px;
    align-items: center;
    flex-wrap: wrap;
}

.db-search-wrap {
    flex: 1 1 320px;
    position: relative;
    display: flex;
    align-items: center;
}

.db-search-icon {
    position: absolute;
    left: 15px;
    width: 18px;
    height: 18px;
    color: var(--accent-gold);
    pointer-events: none;
}

.db-search-input {
    width: 100%;
    padding: 13px 44px 13px 44px;
    background: rgba(7, 11, 17, 0.9);
    border: 1px solid rgba(245, 190, 24, 0.3);
    border-radius: 6px;
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.db-search-input:focus {
    border-color: var(--accent-gold);
    box-shadow: 0 0 12px rgba(245, 190, 24, 0.25);
}

.db-search-clear {
    position: absolute;
    right: 12px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 4px;
}

.db-search-clear:hover {
    color: #fff;
}

.db-sort-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.db-select {
    padding: 12px 14px;
    background: rgba(7, 11, 17, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.88rem;
    outline: none;
    cursor: pointer;
}

.db-select:focus {
    border-color: var(--accent-gold);
}

/* Category Pills */
.db-category-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 14px;
}

.db-cat-pill {
    padding: 7px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 20px;
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    transition: all 0.15s ease;
}

.db-cat-pill:hover {
    border-color: rgba(245, 190, 24, 0.3);
    color: #fff;
}

.db-cat-pill.active {
    background: rgba(245, 190, 24, 0.15);
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

/* Secondary Filter Row */
.db-secondary-filters {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 14px;
}

.db-filter-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.db-filter-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Results Count & Reset */
.db-meta-status {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 0.88rem;
    color: var(--text-muted);
    padding: 0 4px;
}

.db-count-box {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.db-count-main {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.15rem;
    color: #ffffff;
    line-height: 1.25;
    letter-spacing: 0.02em;
}

.db-count-sub {
    font-size: 0.84rem;
    color: var(--accent-gold);
    font-weight: 600;
}

.db-reset-filters-btn {
    background: transparent;
    border: none;
    color: var(--accent-teal);
    font-size: 0.84rem;
    cursor: pointer;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: underline;
}

.db-reset-filters-btn:hover {
    color: #fff;
}

/* Grid & Items Cards */
.db-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 22px;
    margin-bottom: 50px;
}

.db-card {
    background: rgba(13, 20, 29, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
}

.db-card:hover {
    transform: translateY(-3px);
    border-color: rgba(245, 190, 24, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.db-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}

.db-badge-group {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}

/* Availability Badges */
.avail-badge {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 9px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.avail-available {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #34d399;
}

.avail-available .status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 6px #34d399;
}

.avail-limited {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.4);
    color: #fbbf24;
}

.avail-limited .status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #fbbf24;
    box-shadow: 0 0 6px #fbbf24;
}

.avail-retired {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #f87171;
}

.avail-retired .status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #f87171;
}

/* Rarity Badges */
.rarity-badge {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
}

.rarity-mythic {
    background: rgba(245, 190, 24, 0.15);
    border-color: rgba(245, 190, 24, 0.5);
    color: var(--accent-gold);
}

.rarity-legendary {
    background: rgba(168, 85, 247, 0.15);
    border-color: rgba(168, 85, 247, 0.4);
    color: #c084fc;
}

.rarity-rare {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.4);
    color: #38bdf8;
}

/* Card Media / Thumbnail Container */
.db-card-media {
    width: 100%;
    height: 125px;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.04) 0%, rgba(5, 10, 15, 0.65) 100%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    padding: 8px;
    position: relative;
    overflow: hidden;
    transition: border-color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.db-card:hover .db-card-media {
    border-color: rgba(245, 190, 24, 0.35);
    background: radial-gradient(circle at center, rgba(245, 190, 24, 0.08) 0%, rgba(5, 10, 15, 0.8) 100%);
}

.db-card-media.rarity-mythic {
    border-color: rgba(245, 190, 24, 0.3);
    box-shadow: inset 0 0 15px rgba(245, 190, 24, 0.06);
}

.db-card-media.rarity-legendary {
    border-color: rgba(168, 85, 247, 0.3);
    box-shadow: inset 0 0 15px rgba(168, 85, 247, 0.06);
}

.db-card-media.rarity-rare {
    border-color: rgba(56, 189, 248, 0.25);
    box-shadow: inset 0 0 15px rgba(56, 189, 248, 0.05);
}

.db-card-img {
    max-height: 100px;
    max-width: 100%;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.6));
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.db-card-img[src=""],
.db-card-img:not([src]) {
    display: none;
}

.db-card:hover .db-card-img {
    transform: scale(1.08);
}

/* Card Body */
.db-card-title {
    font-size: 1.22rem;
    color: #fff;
    margin: 0 0 6px 0;
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.3;
}

.db-card-sub {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.db-card-company {
    color: var(--accent-teal);
    font-weight: 600;
}

/* Pricing Tag */
.db-price-strip {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(7, 11, 17, 0.7);
    border-radius: 6px;
    padding: 8px 12px;
    margin-bottom: 14px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.db-currency-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 800;
    font-size: 0.92rem;
}

.currency-gold {
    color: #facc15;
}

.currency-doubloon {
    color: #38bdf8;
}

.currency-ancient {
    color: #f43f5e;
}

.currency-free {
    color: #34d399;
}

.db-card-snippet {
    font-size: 0.86rem;
    color: #cbd5e1;
    line-height: 1.5;
    margin-bottom: 18px;
    flex-grow: 1;
}

.db-card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding-top: 14px;
    margin-top: auto;
}

.db-view-guide-btn {
    padding: 8px 16px;
    font-size: 0.84rem;
    border-radius: 4px;
    background: transparent;
    border: 1px solid rgba(245, 190, 24, 0.35);
    color: var(--accent-gold);
    cursor: pointer;
    font-family: var(--font-body);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.db-view-guide-btn:hover {
    background: var(--accent-gold);
    color: #080d14;
    border-color: var(--accent-gold);
}

.db-action-icon-btn {
    width: 36px;
    height: 36px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
}

.db-action-icon-btn:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}

.db-action-icon-btn.active-wishlist {
    background: rgba(244, 63, 94, 0.15);
    border-color: rgba(244, 63, 94, 0.5);
    color: #f43f5e;
}

.db-action-icon-btn.active-calc {
    background: rgba(77, 208, 225, 0.15);
    border-color: rgba(77, 208, 225, 0.5);
    color: var(--accent-teal);
}

/* ==========================================================================
   MODULE 2: Loot Haul & Emissary Calculator
   ========================================================================== */
.calc-container {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 28px;
    margin-bottom: 60px;
}

@media (max-width: 1024px) {
    .calc-container {
        grid-template-columns: 1fr;
    }
}

.calc-selector-card {
    background: rgba(13, 20, 29, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 26px;
}

.calc-haul-summary-card {
    background: rgba(13, 20, 29, 0.95);
    border: 1px solid rgba(245, 190, 24, 0.25);
    border-radius: 12px;
    padding: 26px;
    position: sticky;
    top: 100px;
    height: fit-content;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Multiplier Controls */
.calc-multiplier-box {
    background: rgba(7, 11, 17, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 18px;
    margin-bottom: 22px;
}

.calc-control-label {
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--accent-gold);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.emissary-grades-row {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 6px;
}

.grade-btn {
    padding: 10px 4px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: all 0.15s ease;
}

.grade-btn:hover {
    color: #fff;
    border-color: rgba(245, 190, 24, 0.3);
}

.grade-btn.active {
    background: linear-gradient(180deg, rgba(245, 190, 24, 0.25), rgba(245, 190, 24, 0.05));
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.grade-btn-mult {
    font-size: 0.7rem;
    opacity: 0.8;
}

/* Toggle Weekend Switch */
.calc-event-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(245, 190, 24, 0.06);
    border: 1px solid rgba(245, 190, 24, 0.2);
    border-radius: 6px;
    padding: 12px 16px;
    margin-top: 14px;
}

.toggle-switch-wrap {
    position: relative;
    width: 48px;
    height: 26px;
}

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

.toggle-switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 26px;
    transition: .3s;
}

.toggle-switch-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    border-radius: 50%;
    transition: .3s;
}

.toggle-switch-input:checked + .toggle-switch-slider {
    background-color: var(--accent-gold);
}

.toggle-switch-input:checked + .toggle-switch-slider:before {
    transform: translateX(22px);
    background-color: #080d14;
}

/* Loot Picker Grid */
.calc-loot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.loot-card {
    background: rgba(7, 11, 17, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 12px;
    transition: border-color 0.2s;
}

.loot-card:hover {
    border-color: rgba(77, 208, 225, 0.35);
}

.loot-card.in-haul {
    border-color: rgba(245, 190, 24, 0.4);
    background: rgba(245, 190, 24, 0.04);
}

.loot-card-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.loot-thumb-wrap {
    width: 48px;
    height: 48px;
    min-width: 48px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.04) 0%, rgba(0, 0, 0, 0.6) 100%);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3px;
    overflow: hidden;
}

.loot-thumb-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.5));
}

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

.loot-comp-tag {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 3px;
}

.loot-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px 0;
}

.loot-range {
    font-size: 0.8rem;
    color: #facc15;
    font-weight: 700;
}

.loot-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.stepper {
    display: inline-flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 4px;
    overflow: hidden;
}

.stepper-btn {
    background: transparent;
    border: none;
    color: #fff;
    width: 32px;
    height: 32px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.stepper-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.stepper-val {
    width: 38px;
    text-align: center;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 0.92rem;
    color: var(--accent-gold);
}

/* Active Haul Summary Panel */
.haul-hero-total {
    background: linear-gradient(135deg, rgba(245, 190, 24, 0.12), rgba(13, 20, 29, 0.95));
    border: 1px solid rgba(245, 190, 24, 0.3);
    border-radius: 8px;
    padding: 18px;
    text-align: center;
    margin-bottom: 20px;
}

.haul-total-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-gold);
    font-weight: 800;
}

.haul-total-gold {
    font-size: 2rem;
    font-weight: 900;
    font-family: var(--font-heading);
    color: #fff;
    margin: 4px 0;
    text-shadow: 0 0 15px rgba(245, 190, 24, 0.3);
}

.haul-range-sub {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.haul-metrics-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.haul-metric-box {
    background: rgba(7, 11, 17, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    padding: 10px 12px;
    text-align: center;
}

.haul-metric-val {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--accent-teal);
    display: block;
}

.haul-metric-lbl {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
}

/* Haul Item Rows */
.haul-items-list {
    max-height: 240px;
    overflow-y: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 10px 0;
    margin-bottom: 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.haul-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    padding: 4px 6px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 4px;
}

.haul-row-name {
    color: #fff;
    font-weight: 600;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.haul-row-qty {
    color: var(--accent-gold);
    font-weight: 800;
}

.haul-row-remove {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    padding: 0 4px;
}

.haul-row-remove:hover {
    color: #ef4444;
}

/* Sovereign vs Outpost Notice */
.haul-turnin-tip {
    background: rgba(77, 208, 225, 0.08);
    border-left: 3px solid var(--accent-teal);
    padding: 12px;
    border-radius: 0 6px 6px 0;
    font-size: 0.8rem;
    line-height: 1.5;
    color: #cbd5e1;
    margin-bottom: 20px;
}

/* ==========================================================================
   MODULE 3: Personal Wishlist & Set Tracker
   ========================================================================== */
.wishlist-summary-hero {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
}

.wish-total-box {
    background: rgba(13, 20, 29, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 18px;
    text-align: center;
}

.wish-total-num {
    font-size: 1.6rem;
    font-weight: 900;
    font-family: var(--font-heading);
    margin: 4px 0;
}

/* Set Completion Cards */
.set-trackers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.set-tracker-card {
    background: rgba(13, 20, 29, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 20px;
}

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

.set-progress-bar-bg {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.set-progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-gold), var(--accent-teal));
    border-radius: 4px;
    transition: width 0.4s ease;
}

/* Wishlist Item Table / Grid */
.wishlist-items-container {
    background: rgba(13, 20, 29, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 24px;
    margin-bottom: 60px;
}

.wishlist-empty-state {
    text-align: center;
    padding: 50px 20px;
}

.wishlist-empty-icon {
    width: 56px;
    height: 56px;
    color: var(--text-muted);
    opacity: 0.5;
    margin-bottom: 15px;
}

/* ==========================================================================
   MODULE 4: Unlock Advisor Wizard
   ========================================================================== */
.advisor-card {
    background: rgba(13, 20, 29, 0.92);
    border: 1px solid rgba(245, 190, 24, 0.25);
    border-radius: 12px;
    padding: 35px;
    max-width: 880px;
    margin: 0 auto 60px auto;
}

.advisor-progress {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    position: relative;
}

.advisor-step-pill {
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 700;
}

.advisor-step-pill.active {
    background: rgba(245, 190, 24, 0.15);
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

.advisor-question-title {
    font-size: 1.4rem;
    color: #fff;
    margin-bottom: 20px;
    font-family: var(--font-heading);
}

.advisor-options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
}

.advisor-option-card {
    background: rgba(7, 11, 17, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 20px;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.advisor-option-card:hover {
    border-color: rgba(245, 190, 24, 0.4);
    transform: translateY(-2px);
}

.advisor-option-card.selected {
    background: linear-gradient(135deg, rgba(245, 190, 24, 0.15), rgba(7, 11, 17, 0.9));
    border-color: var(--accent-gold);
    box-shadow: 0 0 15px rgba(245, 190, 24, 0.2);
}

.advisor-opt-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.advisor-opt-desc {
    font-size: 0.84rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Advisor Results */
.advisor-results-box {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.recommendation-card {
    background: rgba(7, 11, 17, 0.9);
    border: 1px solid rgba(245, 190, 24, 0.35);
    border-radius: 8px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.rec-rank-tag {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--accent-gold);
    background: rgba(245, 190, 24, 0.12);
    padding: 4px 10px;
    border-radius: 4px;
    width: fit-content;
}

/* ==========================================================================
   ITEM DETAIL MODAL DRAWER
   ========================================================================== */
.sotau-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.sotau-modal.active {
    display: flex;
}

.sotau-modal .modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 8, 12, 0.85);
    backdrop-filter: blur(8px);
}

.sotau-modal .modal-dialog {
    position: relative;
    background: #0d141d;
    border: 1px solid rgba(245, 190, 24, 0.3);
    border-radius: 12px;
    width: 100%;
    max-width: 680px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7);
    z-index: 1001;
    animation: modalScaleUp 0.2s ease;
}

@keyframes modalScaleUp {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

.sotau-modal .modal-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: background 0.15s;
}

.sotau-modal .modal-close-btn:hover {
    background: rgba(239, 68, 68, 0.8);
}

.modal-body-content {
    padding: 30px;
}

/* Modal Hero Presentation */
.modal-header-hero {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 20px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.modal-hero-icon-wrap {
    width: 76px;
    height: 76px;
    min-width: 76px;
    background: radial-gradient(circle, rgba(245, 190, 24, 0.1) 0%, rgba(10, 18, 26, 0.9) 100%);
    border: 1px solid rgba(245, 190, 24, 0.35);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.6);
}

.modal-hero-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.7));
}

@media (max-width: 600px) {
    .modal-header-hero {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}

.modal-steps-list {
    padding-left: 20px;
    margin: 15px 0 25px 0;
    color: #cbd5e1;
    font-size: 0.92rem;
    line-height: 1.7;
}

.modal-tip-box {
    background: rgba(245, 190, 24, 0.08);
    border-left: 4px solid var(--accent-gold);
    padding: 14px 18px;
    border-radius: 0 6px 6px 0;
    margin: 20px 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #fef08a;
}

.modal-stat-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    background: rgba(0, 0, 0, 0.35);
    padding: 14px;
    border-radius: 6px;
    margin-bottom: 25px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.modal-strip-item {
    display: flex;
    flex-direction: column;
}

.modal-strip-lbl {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    font-weight: 700;
}

.modal-strip-val {
    font-size: 0.95rem;
    color: #fff;
    font-weight: 700;
    margin-top: 2px;
}

/* Mobile Responsiveness & Filter Drawer */
.db-mobile-filter-toggle {
    display: none;
    padding: 10px 16px;
    background: rgba(245, 190, 24, 0.1);
    border: 1px solid rgba(245, 190, 24, 0.3);
    border-radius: 6px;
    color: var(--accent-gold);
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    align-items: center;
    gap: 8px;
    width: 100%;
    justify-content: center;
}

@media (max-width: 767px) {
    .db-hero-section {
        padding-top: 75px;
        padding-bottom: 20px;
    }

    .db-hero-stats {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        margin-top: 15px;
        margin-bottom: 15px;
    }

    .db-stat-box {
        padding: 10px 12px;
        gap: 10px;
    }

    .db-stat-icon {
        width: 36px;
        height: 36px;
        border-radius: 6px;
    }

    .db-stat-icon svg {
        width: 18px;
        height: 18px;
    }

    .db-stat-num {
        font-size: 1.15rem;
    }

    .db-stat-label {
        font-size: 0.68rem;
        letter-spacing: 0.5px;
        line-height: 1.1;
    }

    .db-tabs-nav {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 6px;
        padding: 6px;
        margin-bottom: 18px;
    }

    .db-tab-btn {
        width: 100%;
        min-width: 0;
        padding: 10px 8px;
        font-size: 0.82rem;
        gap: 6px;
        justify-content: center;
    }

    .db-tab-btn span {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .db-filter-bar {
        padding: 14px;
        gap: 12px;
        margin-bottom: 18px;
    }

    .db-search-row {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .db-search-wrap {
        width: 100%;
        flex: 1 1 100%;
    }

    .db-sort-wrap {
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .db-sort-wrap .db-select {
        width: 100%;
    }

    .db-category-pills {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        gap: 6px;
        padding-bottom: 6px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .db-category-pills::-webkit-scrollbar {
        display: none;
    }

    .db-cat-pill {
        flex-shrink: 0;
        padding: 6px 12px;
        font-size: 0.78rem;
        white-space: nowrap;
    }

    .db-mobile-filter-toggle {
        display: flex;
        margin-top: 4px;
    }

    .db-secondary-filters {
        display: none;
        flex-direction: column;
        align-items: stretch;
        background: rgba(7, 11, 17, 0.95);
        border: 1px solid rgba(245, 190, 24, 0.2);
        border-radius: 8px;
        padding: 14px;
        margin-top: 10px;
        gap: 12px;
    }

    .db-secondary-filters.active {
        display: flex;
    }

    .db-filter-item {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 4px;
    }

    .db-filter-item .db-select {
        width: 100%;
    }

    .db-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .db-card {
        padding: 14px 16px;
    }

    .db-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .emissary-grades-row {
        grid-template-columns: repeat(3, 1fr);
        gap: 6px;
    }

    .grade-btn {
        padding: 8px 4px;
        font-size: 0.78rem;
    }

    .grade-btn-mult {
        font-size: 0.7rem;
    }

    .calc-container {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .calc-selector-card,
    .calc-haul-summary-card {
        padding: 16px 14px;
    }

    .haul-metrics-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .haul-metric-box {
        padding: 10px 8px;
    }

    .haul-metric-val {
        font-size: 1.05rem;
    }

    .haul-metric-lbl {
        font-size: 0.7rem;
    }

    .wishlist-summary-hero {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .wish-total-box {
        padding: 14px 16px;
    }

    .advisor-card {
        padding: 20px 14px;
    }

    .advisor-progress {
        flex-direction: column;
        gap: 6px;
    }

    .advisor-step-pill {
        width: 100%;
        text-align: center;
    }

    .modal-body-content {
        padding: 16px;
    }

    /* Mobile Sticky Tab Navigation (2x2 Control Panel) */
    .db-tabs-nav {
        position: sticky;
        top: 60px;
        z-index: 90;
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px !important;
        padding: 8px !important;
        background: rgba(7, 11, 17, 0.98) !important;
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border: 1px solid rgba(245, 190, 24, 0.3) !important;
        border-radius: 12px !important;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
        margin-bottom: 24px !important;
    }

    .db-tab-btn {
        padding: 10px 8px !important;
        font-size: 0.84rem !important;
        font-weight: 700 !important;
        flex-direction: row !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 6px !important;
        min-height: 44px !important;
        min-width: 0 !important;
        border-radius: 8px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .db-tab-btn span {
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .db-tab-btn svg {
        width: 15px !important;
        height: 15px !important;
        flex-shrink: 0 !important;
    }

    /* Compact Codex Cards on Mobile */
    .db-card-media {
        height: 85px !important;
    }

    .db-card-img {
        max-height: 70px !important;
    }

    .db-card-title {
        font-size: 1.05rem !important;
    }

    .db-card-snippet {
        display: none !important; /* Progressive disclosure: hide description on initial mobile card */
    }

    /* Sticky Calculator Payout Bar for Mobile */
    .calc-payout-sticky-bar {
        position: sticky;
        top: 118px;
        z-index: 85;
        background: linear-gradient(135deg, rgba(245, 190, 24, 0.95), rgba(13, 20, 29, 0.98));
        border: 1px solid rgba(245, 190, 24, 0.5);
        border-radius: 8px;
        padding: 10px 16px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 14px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    }

    .calc-payout-sticky-val {
        font-family: var(--font-heading);
        font-size: 1.1rem;
        font-weight: 800;
        color: #080d14;
    }

    .calc-payout-sticky-sub {
        font-size: 0.75rem;
        color: #1e293b;
        font-weight: 700;
    }

    /* Wizard Step Navigation Buttons */
    .advisor-nav-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-top: 20px;
        gap: 12px;
    }

    .advisor-nav-row .btn-primary,
    .advisor-nav-row .btn-outline {
        min-height: 44px;
        font-size: 0.88rem;
    }
}

/* ==========================================================================
   Codex Pagination & Stepper
   ========================================================================== */
.db-pagination-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 36px;
    margin-bottom: 20px;
    text-align: center;
}

.db-load-more-btn {
    padding: 14px 34px;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: var(--font-body);
    letter-spacing: 0.05em;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.db-load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(245, 190, 24, 0.35);
}

/* Calculator Stage Accordions */
@media (min-width: 769px) {
    .calc-stage-accordion {
        background: transparent !important;
        border: none !important;
        border-radius: 0 !important;
        overflow: visible !important;
    }
    .calc-stage-accordion .accordion-header-btn {
        display: none !important;
    }
    .calc-stage-accordion .accordion-body-content {
        display: block !important;
        padding: 0 !important;
    }
    .calc-stage-title {
        display: flex !important;
    }
}

@media (max-width: 768px) {
    .calc-stage-accordion {
        margin-bottom: 14px;
        background: rgba(13, 20, 29, 0.95);
        border: 1px solid rgba(245, 190, 24, 0.25);
        border-radius: 10px;
    }
    .calc-stage-accordion .stage-num {
        background: var(--accent-gold);
        color: #080d14;
        width: 22px;
        height: 22px;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 0.8rem;
        font-weight: 800;
        margin-right: 4px;
    }
    .calc-stage-title {
        display: none !important;
    }
}



