/* Base Dark Theme */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #121212;
    color: #e0e0e0;
    -webkit-font-smoothing: antialiased;
}

.main-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 30px 20px;
}

/* Header & Navigation Styling */
.element-header {
    background-color: #1a1a1a;
    color: #ffffff;
    padding: 12px 24px;
    border-bottom: 2px solid #ff9800;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    gap: 20px;
}

.banner-img {
    max-height: 55px;
    width: auto;
    object-fit: contain;
}

.header-nav {
    display: flex;
    gap: 15px;
    align-items: center;
}

.header-nav a {
    color: #cfd8dc;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    padding: 6px 12px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.header-nav a:hover {
    background-color: #2c2c2c;
    color: #ff9800;
}

.header-auth {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #cfd8dc;
    font-size: 14px;
}

.auth-btn {
    background-color: #ff9800;
    color: #121212;
    border: none;
    padding: 6px 14px;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    font-size: 13px;
}

.auth-btn:hover {
    background-color: #f57c00;
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    padding: 5px;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #ff9800;
    border-radius: 2px;
    transition: 0.3s;
}

/* Typography & Links */
h1, h2, h3, h4 {
    color: #ffffff;
    margin-top: 0;
}

a {
    color: #ffb74d;
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: #ffa726;
}

/* Inventory Sections & Groups */
.inventory-section {
    margin-bottom: 45px;
}

.inventory-section > h2 {
    font-size: 24px;
    border-bottom: 2px solid #333;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.spool-group {
    background-color: #18181b;
    border: 1px solid #27272a;
    border-radius: 10px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.color-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #27272a;
    padding-bottom: 12px;
    margin-bottom: 20px;
    padding-left: 12px;
    border-left: 5px solid var(--accent-color, #ff9800);
}

.color-header h3 {
    margin: 0;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.hex-badge {
    font-size: 13px;
    color: #a1a1aa;
    font-weight: normal;
}

.spool-count {
    background-color: #27272a;
    color: #ff9800;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

/* Spool Cards Grid */
.spool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 18px;
}

.spool-card {
    background-color: #202024;
    border: 1px solid #2e2e32;
    border-radius: 8px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.spool-card:hover {
    transform: translateY(-2px);
    border-color: #ff9800;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.spool-id-title {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
}

.brand-badge {
    font-size: 11px;
    color: #d4d4d8;
    background-color: #27272a;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-body {
    margin-bottom: 16px;
}

.price-tag {
    font-size: 15px;
    color: #4ade80;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.weight-info {
    font-size: 14px;
    color: #d4d4d8;
    margin: 0 0 10px 0;
    display: flex;
    justify-content: space-between;
}

/* Progress Bar */
.progress-bar-bg {
    background-color: #27272a;
    border-radius: 4px;
    height: 8px;
    width: 100%;
    overflow: hidden;
}

.progress-bar-fill {
    background-color: #ff9800;
    height: 100%;
    width: var(--bar-width, 0%);
    border-radius: 4px;
    transition: width 0.4s ease;
}

/* Card Footer Actions */
.card-footer {
    display: flex;
    justify-content: flex-end;
    border-top: 1px solid #2e2e32;
    padding-top: 12px;
}

.action-btn {
    background-color: transparent;
    color: #ff9800;
    border: 1px solid #ff9800;
    padding: 5px 12px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s, color 0.2s;
}

.action-btn:hover {
    background-color: #ff9800;
    color: #121212;
}

/* Responsive Breakpoints for Mobile Menu */
@media (max-width: 900px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .header-container {
        flex-wrap: wrap;
    }

    .header-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        background-color: #1a1a1a;
        padding: 15px 0;
        border-top: 1px solid #333;
        margin-top: 10px;
        gap: 10px;
        text-align: center;
    }

    .header-nav.active {
        display: flex;
    }

    .header-nav a {
        padding: 10px;
        width: 100%;
        box-sizing: border-box;
    }

    .header-auth {
        margin-left: auto;
    }
}
/* Financial Dashboard Styles */
.finances-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}
.finances-year-form {
    display: flex;
    align-items: center;
    gap: 10px;
}
.finances-year-select {
    background-color: #18181b;
    color: #fff;
    border: 1px solid #27272a;
    padding: 8px 12px;
    border-radius: 6px;
    font-weight: bold;
}
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 35px;
}
.metric-card-label {
    color: #a1a1aa;
    font-size: 13px;
    text-transform: uppercase;
    font-weight: 600;
}
.metric-card-value-green {
    font-size: 26px;
    font-weight: 700;
    color: #4ade80;
    margin-top: 8px;
}
.metric-card-value-red {
    font-size: 26px;
    font-weight: 700;
    color: #ef4444;
    margin-top: 8px;
}
.metric-card-value-orange {
    font-size: 26px;
    font-weight: 700;
    color: #ff9800;
    margin-top: 8px;
}
.monthly-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(85px, 1fr));
    gap: 12px;
}
.month-box {
    background-color: #202024;
    border: 1px solid #2e2e32;
    border-radius: 6px;
    padding: 12px;
    text-align: center;
}
.finances-split-layout {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 24px;
    align-items: start;
}
.transaction-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.form-group-label {
    display: block;
    font-size: 13px;
    color: #a1a1aa;
    margin-bottom: 5px;
}
.form-control-input {
    width: 100%;
    background-color: #202024;
    color: #fff;
    border: 1px solid #2e2e32;
    padding: 10px;
    border-radius: 6px;
    box-sizing: border-box;
}
.tax-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}
.tax-modal-card {
    background-color: #18181b;
    border: 1px solid #27272a;
    border-radius: 12px;
    padding: 30px;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}
.amount-positive {
    font-size: 14px;
    font-weight: 700;
    color: #4ade80;
}
.amount-neutral {
    font-size: 14px;
    font-weight: 700;
    color: #d4d4d8;
}
.tax-modal-overlay {
    display: none !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background-color: rgba(0, 0, 0, 0.85) !important;
    z-index: 9999 !important;
    justify-content: center !important;
    align-items: center !important;
}
.tax-modal-card {
    background-color: #18181b !important;
    color: #fff !important;
    border: 1px solid #27272a !important;
    border-radius: 12px !important;
    padding: 30px !important;
    width: 100% !important;
    max-width: 450px !important;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
}