/* Unilevel Provisionsrechner Styling */
/* Verspieltes, interaktives Design mit Animationen */

#unilevel-calculator {
    --primary-color: #0CC0DF;
    --secondary-color: #001373;
    --accent-color: #CADCEC;
    --success-color: #00BF9A;
    --warning-color: #FFBC42;
    --error-color: #FF5252;
    --text-color: #333;
    --light-text: #666;
    --border-radius: 10px;
    --box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    
    margin: 3rem 0;
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--text-color);
    background-color: #f8fafc;
    border-radius: 16px;
    padding: 0 0 25px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.calculator-wrapper {
    background: linear-gradient(145deg, #ffffff, #f5f7fa);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    position: relative;
    transition: var(--transition);
    padding: 0;
    border: 1px solid #e8e8e8;
}

.calculator-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 6px;
    background: linear-gradient(90deg, #004e92, #003366);
    z-index: 2;
}

.calculator-header {
    background: linear-gradient(135deg, #002850 0%, #004e92 100%);
    color: white;
    padding: 2.5rem 1.5rem;
    position: relative;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    box-shadow: inset 0 -10px 20px rgba(0, 0, 0, 0.1);
}

.calculator-header h3 {
    margin: 0;
    font-size: 2.4rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 0.8s ease-out;
    position: relative;
    display: inline-block;
    color: #ffffff;
}

.calculator-header h3::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.3));
    border-radius: 3px;
}

.calculator-header h3 .highlight {
    color: #4FC3F7;
    position: relative;
    text-shadow: 0 0 10px rgba(79, 195, 247, 0.3);
}

.calculator-header p {
    margin: 1.5rem 0 0;
    font-size: 1.15rem;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 0.8s ease-out 0.2s both;
    line-height: 1.6;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.calculator-emoji {
    display: none !important;
}

.calculator-body {
    padding: 2rem;
    background-color: white;
}

.calculator-settings {
    margin-bottom: 2rem;
    background-color: #ffffff;
    padding: 1.8rem;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #f0f0f0;
    margin-top: 25px;
    position: relative;
}

.calculator-settings:before {
    content: "Einstellungen";
    position: absolute;
    top: -12px;
    left: 25px;
    background: linear-gradient(90deg, #003366, #001373);
    color: white;
    padding: 4px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 3px 8px rgba(0, 19, 115, 0.2);
}

.setting-group {
    margin-bottom: 1.5rem;
}

.setting-group:last-child {
    margin-bottom: 0;
}

.setting-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 0.95rem;
}

.input-slider-group {
    display: flex;
    align-items: center;
    gap: 15px;
    width: 100%;
}

.number-input {
    width: 80px;
    height: 32px;
    border: 1px solid #d0d0d0;
    border-radius: var(--border-radius);
    text-align: center;
    font-weight: 600;
    color: var(--secondary-color);
    padding: 0 8px;
    font-size: 0.9rem;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: border-color 0.2s ease;
}

.number-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(12, 192, 223, 0.2);
}

.slider {
    -webkit-appearance: none;
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(90deg, #d4e3fa, var(--primary-color));
    outline: none;
    transition: var(--transition);
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.slider::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.slider::-moz-range-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* Toggle Switch Styling */
.toggle-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 180px;
    height: 34px;
}

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

.toggle-label {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #003366;
    border-radius: 34px;
    transition: var(--transition);
    overflow: hidden;
    display: flex;
    align-items: center;
}

.toggle-label:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    top: 50%;
    transform: translateY(-50%);
    background-color: white;
    border-radius: 50%;
    transition: var(--transition);
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.toggle-inner {
    display: flex;
    width: 200%;
    height: 100%;
    transition: var(--transition);
    position: relative;
    left: 0;
}

.toggle-on, .toggle-off {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    transition: var(--transition);
    height: 100%;
    min-width: 90px;
    color: white;
    z-index: 1;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
}

.toggle-on {
    padding-right: 15px;
}

.toggle-off {
    padding-left: 15px;
}

.toggle-input:checked + .toggle-label .toggle-inner {
    transform: translateX(-50%);
}

.toggle-input:checked + .toggle-label:before {
    transform: translate(146px, -50%);
}

/* Ebenen-Struktur */
.commission-structure {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 1.8rem 1.5rem 1.5rem;
    border: 1px solid #f0f0f0;
    margin-top: 25px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    position: relative;
}

.commission-structure:before {
    content: "Provisionseinstellungen";
    position: absolute;
    top: -12px;
    left: 25px;
    background: linear-gradient(90deg, #003366, #001373);
    color: white;
    padding: 4px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 3px 8px rgba(0, 19, 115, 0.2);
}

.commission-structure h4 {
    margin: 0 0 1.2rem;
    font-size: 1.15rem;
    color: var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.level-row {
    display: flex;
    align-items: center;
    padding: 0.8rem 0;
    border-bottom: 1px dashed #eaeaea;
    opacity: 0;
    transform: translateY(20px);
}

.level-row.animated {
    animation: fadeInUp 0.5s forwards;
}

.level-label {
    flex: 0 0 80px;
    font-weight: 600;
    color: var(--secondary-color);
}

.level-input-group {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
}

.commission-input {
    width: 70px;
    text-align: right;
    padding: 0.4rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.9rem;
}

.input-unit {
    color: var(--light-text);
    font-size: 0.85rem;
    margin-right: 5px;
}

.slider-container {
    flex: 1;
}

.commission-slider {
    width: 100%;
    margin-top: 5px;
    height: 6px;
    background: linear-gradient(90deg, #eaeaea, var(--primary-color));
}

.commission-slider::-webkit-slider-thumb {
    width: 18px;
    height: 18px;
}

.commission-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
}

/* Ergebnisbereich */
.results-container {
    background-color: transparent;
    border-radius: var(--border-radius);
    margin-top: 25px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.results-container.show-results {
    opacity: 1;
    transform: translateY(0);
}

.results-header {
    background: linear-gradient(135deg, #001735 0%, #001F40 100%);
    color: white;
    padding: 1.2rem;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    text-align: center;
}

.results-header h4 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    color: #ffffff;
}

.results-body {
    background-color: white;
    padding: 1.8rem;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #f0f0f0;
    border-top: none;
}

.result-chart-container {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #f0f0f0;
    margin-bottom: 2rem;
    position: relative;
    height: 400px;  /* Feste Höhe statt auto */
    width: 100%;
    overflow: hidden;
}

/* Wichtig für das korrekte Rendering des Charts */
.result-chart-container canvas {
    width: 100% !important;
    height: 100% !important;
}

.results-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
    background-color: #f9f9f9;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px dashed var(--accent-color);
}

.result-item {
    background-color: white;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    border: 1px solid #eaeaea;
    transition: var(--transition);
}

.result-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.total-commission {
    border-left: 4px solid var(--success-color);
}

.commission-percentage {
    border-left: 4px solid var(--warning-color);
}

.total-partners {
    border-left: 4px solid var(--primary-color);
}

.total-sales {
    border-left: 4px solid var(--secondary-color);
}

.result-label {
    font-size: 0.85rem;
    color: var(--light-text);
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary-color);
}

/* Button-Styling */
.calculator-footer {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 0.5rem 0 1rem;
    background-color: white;
    border-top: 1px solid #f5f5f5;
}

.calculate-button, .reset-button {
    padding: 0.7rem 1.8rem;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.calculate-button {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 4px 10px rgba(12, 192, 223, 0.3);
}

.reset-button {
    background-color: #f1f1f1;
    color: var(--text-color);
    border: 1px solid #ddd;
}

.calculate-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(12, 192, 223, 0.4);
}

.reset-button:hover {
    background-color: #e9e9e9;
    transform: translateY(-2px);
}

.calculate-button:active, .reset-button:active {
    transform: translateY(1px);
}

.button-pulse {
    animation: pulse 0.7s;
}

.button-shake {
    animation: shake 0.5s;
}

/* Animationen */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 4px 10px rgba(12, 192, 223, 0.3);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 8px 15px rgba(12, 192, 223, 0.4);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 4px 10px rgba(12, 192, 223, 0.3);
    }
}

@keyframes shake {
    0% { transform: translateX(0); }
    20% { transform: translateX(-5px); }
    40% { transform: translateX(5px); }
    60% { transform: translateX(-3px); }
    80% { transform: translateX(3px); }
    100% { transform: translateX(0); }
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .calculator-header {
        padding: 1.5rem 1rem;
    }
    
    .calculator-body {
        padding: 1.5rem 1rem;
    }
    
    .results-summary {
        grid-template-columns: 1fr;
    }
    
    .calculator-footer {
        flex-direction: column;
        padding: 1.5rem 1rem;
    }
    
    .calculate-button, .reset-button {
        width: 100%;
    }
    
    .toggle-switch {
        width: 160px;
    }
    
    .toggle-input:checked + .toggle-label:before {
        transform: translate(126px, -50%);
    }
}

/* Tablet-spezifische Anpassungen (iPad) */
@media (min-width: 577px) and (max-width: 1024px) {
    /* Überschriften und Texte */
    .calculator-header h3 {
        font-size: 2.4rem !important;
        padding: 25px 60px !important;
    }
    
    .calculator-header p {
        font-size: 1.4rem !important;
        padding: 20px 40px !important;
    }
    
    /* Einstellungen */
    .setting-group label {
        font-size: 1.3rem;
        margin-bottom: 0.8rem;
    }
    
    .number-input {
        font-size: 1.3rem;
        width: 120px;
        height: 45px;
    }

    .mode-info {
        font-size: 1.2rem;
    }

    .toggle-on, .toggle-off {
        font-size: 1.2rem;
    }
    
    /* Provisionseinstellungen */
    .commission-structure:before {
        font-size: 1.2rem;
        padding: 6px 20px;
    }

    .commission-structure h4 {
        font-size: 1.4rem;
        margin-bottom: 1.5rem;
    }

    .level-label {
        font-size: 1.3rem;
    }

    .commission-input {
        font-size: 1.3rem;
        width: 100px;
        height: 45px;
    }

    .input-unit {
        font-size: 1.2rem;
    }
    
    /* Ergebnistabelle */
    .results-table {
        font-size: var(--base-font-size);
    }
    
    .results-table th,
    .results-table td {
        padding: 15px 25px;
    }
    
    /* Ergebniskarten */
    .result-item {
        padding: 1.5rem;
    }
    
    .result-label {
        font-size: 1.2rem;
        margin-bottom: 0.8rem;
    }
    
    .result-value {
        font-size: 2.2rem;
    }
    
    /* Gesamtprovision Info */
    .total-commission-label {
        font-size: 1.3rem;
    }
    
    .total-commission-value {
        font-size: 1.6rem;
        padding: 8px 20px;
    }
    
    /* Buttons */
    .calculate-button, 
    .reset-button {
        font-size: 1.4rem;
        padding: 1rem 2.5rem;
    }

    /* Slider Anpassungen */
    .slider {
        height: 10px;
    }

    .slider::-webkit-slider-thumb {
        width: 28px;
        height: 28px;
    }

    .slider::-moz-range-thumb {
        width: 28px;
        height: 28px;
    }

    /* Zusätzliche Abstände */
    .setting-group {
        margin-bottom: 2rem;
    }

    .calculator-body {
        padding: 2.5rem;
    }

    .results-body {
        padding: 2.5rem;
    }
}

.toggle-setting-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mode-description {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mode-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 0.85rem;
    color: var(--light-text);
    padding: 0 0 5px 0;
}

.mode-info-item {
    transition: opacity 0.3s ease;
}

#percent-info {
    opacity: 1;
}

#fixed-info {
    opacity: 0.5;
}

.toggle-input:checked ~ .mode-info #percent-info {
    opacity: 0.5;
}

.toggle-input:checked ~ .mode-info #fixed-info {
    opacity: 1;
}

.total-commission-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: #f0f8ff;
    border: 1px solid var(--accent-color);
    border-radius: var(--border-radius);
    padding: 12px 16px;
    margin-top: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.total-commission-label {
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 0.95rem;
}

.total-commission-value {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.2rem;
    background-color: white;
    padding: 4px 12px;
    border-radius: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Ergebnistabelle - Optimierte Version */
.results-table-container {
    width: 100%;
    overflow-x: auto;
    margin: 20px 0 30px;
    padding: 0 0 1rem 0;
    border-bottom: 1px dashed #e5e5e5;
}

.results-table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--base-font-size);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: var(--border-radius);
    overflow: hidden;
    background-color: #fff;
}

.results-table thead {
    background: linear-gradient(135deg, #002850 0%, #003366 100%);
    color: white;
}

.results-table th {
    padding: 12px 15px;
    text-align: left;
    font-weight: 700;
    border: none;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
}

.results-table td {
    padding: 10px 15px;
    border-bottom: 1px solid #eaeaea;
}

.results-table tbody tr {
    background-color: white;
    transition: background-color 0.2s ease;
}

.results-table tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}

.results-table tbody tr:hover {
    background-color: #f0f8ff;
}

.results-table-total {
    background-color: #f0f8ff;
    font-weight: 700;
    color: var(--secondary-color);
    border-top: 2px solid var(--primary-color);
}

.results-table-total td {
    padding: 12px 15px;
}

/* Chart Container */
.result-chart-container {
    width: 100%;
    margin: 1rem 0;
    padding: 1.5rem;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #f0f0f0;
    position: relative;
    height: 400px;
    overflow: hidden;
}

.result-chart-container canvas {
    width: 100% !important;
    height: 100% !important;
}

/* Responsive Anpassungen */
@media (min-width: 577px) and (max-width: 1024px) {
    .results-table th,
    .results-table td {
        padding: 15px 25px;
        font-size: var(--base-font-size);
    }

    .result-chart-container {
        padding: 0.75rem;
    }

    canvas {
        max-height: 400px;
    }
}

@media (max-width: 576px) {
    .results-table-container {
        margin: 0.5rem 0;
    }

    .results-table th,
    .results-table td {
        padding: 5px 8px;
        font-size: 14px;
    }

    .result-chart-container {
        padding: 0.5rem;
        height: 300px;
    }

    canvas {
        max-height: 300px;
    }
}

/* Smartphone-spezifische Anpassungen */
@media (max-width: 576px) {
    .calculator-header h3 {
        font-size: 1.5rem;
        padding: 15px 25px !important;
    }
    
    .calculator-header p {
        font-size: 0.9rem;
        padding: 10px 20px !important;
    }
    
    .result-chart-container {
        padding: 1rem;
        height: 300px;  /* Kleinere Höhe auf Smartphones */
    }
    
    .calculator-settings {
        padding: 1.2rem;
    }
    
    .commission-level-row {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .commission-level-label {
        margin-bottom: 0.5rem;
        width: 100%;
    }
    
    .commission-input-group {
        width: 100%;
    }
    
    .results-table {
        font-size: var(--base-font-size);
    }
    
    .results-table th,
    .results-table td {
        padding: 5px 8px;
    }
    
    /* Horizontales Scrollen für die Tabelle auf sehr kleinen Geräten */
    .results-table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

/* Extreme Smartphone-Größen (iPhone SE, etc.) */
@media (max-width: 375px) {
    .calculator-header h3 {
        font-size: 1.3rem;
        padding: 12px 20px !important;
    }
    
    .calculator-body {
        padding: 1rem 0.7rem;
    }
    
    .result-chart-container {
        height: 250px;
    }
    
    .setting-group label {
        font-size: 0.85rem;
    }
    
    .mode-info {
        font-size: 0.8rem;
    }
    
    .toggle-switch {
        width: 140px;
    }
    
    .toggle-input:checked + .toggle-label:before {
        transform: translate(106px, -50%);
    }
}

/* Mobile-optimierte Tabelle als Card-Layout */
@media screen and (max-width: 576px) {
    .results-table {
        border: 0;
        width: 100%;
        font-size: var(--base-font-size);
    }

    .results-table thead {
        border: none;
        clip: rect(0 0 0 0);
        height: 1px;
        margin: -1px;
        overflow: hidden;
        padding: 0;
        position: absolute;
        width: 1px;
    }

    .results-table tr {
        display: block;
        margin-bottom: 1.5rem;
        border: 1px solid #e0e0e0;
        border-radius: 8px;
        background: #fff;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        position: relative;
    }

    .results-table tr::before {
        content: attr(data-level);
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        padding: 8px;
        background: linear-gradient(135deg, var(--secondary-color) 0%, var(--primary-color) 100%);
        color: white;
        font-weight: bold;
        text-align: center;
        border-top-left-radius: 8px;
        border-top-right-radius: 8px;
        font-size: 1.1rem;
    }

    .results-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-size: 0.9rem;
        padding: 12px 15px;
        position: relative;
        border: none;
        border-bottom: 1px solid #f0f0f0;
        min-height: 48px;
    }

    .results-table tr td:first-child {
        margin-top: 40px;
    }

    .results-table td:last-child {
        border-bottom: none;
        margin-bottom: 5px;
    }

    .results-table td::before {
        content: attr(data-label);
        font-weight: 600;
        text-transform: uppercase;
        font-size: 0.85rem;
        color: #666;
        flex: 1;
        padding-right: 12px;
        text-align: left;
        white-space: normal;
        hyphens: auto;
    }

    .results-table td span {
        text-align: right;
        flex: 1;
    }

    .results-table tr:nth-child(1) {
        border-left: 4px solid var(--primary-color);
    }

    .results-table tr:nth-child(2) {
        border-left: 4px solid var(--success-color);
    }

    .results-table tr:nth-child(3) {
        border-left: 4px solid var(--warning-color);
    }

    .results-table tr:nth-child(4) {
        border-left: 4px solid #9C27B0;
    }

    .results-table tr:nth-child(5) {
        border-left: 4px solid #FF5722;
    }

    .results-table tfoot tr {
        background: #f8f9fa;
        border: 2px solid var(--secondary-color);
        margin-top: 2rem;
        position: relative;
    }

    .results-table tfoot tr::before {
        content: "Gesamtergebnis";
        background: var(--secondary-color);
    }

    .results-table tfoot td {
        font-weight: bold;
        color: #333;
        background: white;
    }

    .results-table tfoot td:first-child {
        margin-top: 40px;
        font-size: 0.9rem;
        background: white;
        justify-content: flex-end;
    }

    .results-table-container {
        padding: 0 10px;
    }

    .results-table td[data-label="Verdienst"],
    .results-table td[data-label="Provision"] {
        color: var(--secondary-color);
        font-weight: 600;
    }

    .results-table td.level-indicator {
        display: none;
    }

    .results-table tr td:nth-child(2) {
        margin-top: 40px;
    }
}

.text-right {
    text-align: right !important;
} 