/* Roof Drainage Calculator - Exaktes WUS Design */

.roof-drainage-calculator {
    max-width: 100%;
    margin: 0;
    padding: 0;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: #333;
}

.rdc-container {
    background: #ffffff;
    padding: 0;
}

/* Header - NUR Text blau, KEIN Hintergrund */
.rdc-header {
    padding: 30px 0 20px;
}

.rdc-header h2 {
    margin: 0 !important;
    font-size: 40px !important;
    font-weight: bold !important;
    color: #000 !important;
    line-height: 1.25 !important;
}

/* Intro Text */
.rdc-intro {
    padding: 0 0 20px;
}

.rdc-intro ul {
    margin: 0 0 15px 0;
    padding-left: 20px;
    list-style-type: none;
}

.rdc-intro ul li {
    margin-bottom: 8px;
    font-size: 16px;
    line-height: 1.5;
    position: relative;
    padding-left: 15px;
}

.rdc-intro ul li:before {
    content: "»";
    position: absolute;
    left: 0;
    font-weight: bold;
}

.rdc-intro p {
    margin: 0 0 10px 0;
    font-size: 16px;
    line-height: 1.6;
}

.rdc-hint {
    color: #000;
    font-size: 16px;
}

.rdc-info-link {
    color: #d9534f;
    text-decoration: none;
}

.rdc-info-link:hover {
    text-decoration: underline;
}

/* Form Container */
.rdc-form {
    padding: 0 0 20px;
}

.rdc-form-grid {
    display: flex;
    gap: 40px;
    margin-bottom: 20px;
}

.rdc-form-left {
    flex: 1;
    max-width: 500px;
}

.rdc-form-right {
    width: 500px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 20px;
}

.rdc-form-right img {
    max-width: 100%;
    height: auto;
}

.rdc-form-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Form Groups */
.rdc-form-group {
    display: grid;
    grid-template-columns: 230px 1fr;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.rdc-form-group.rdc-full-width {
    grid-template-columns: 1fr;
}

.rdc-label {
    font-weight: normal;
    font-size: 16px;
    color: #333;
    display: block;
    padding-top: 8px;
}

.rdc-small-text {
    font-size: 11px;
    color: #666;
    margin-top: 2px;
    display: block;
}

/* Inputs */
.rdc-input-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rdc-input,
.rdc-select {
    padding: 6px 10px;
    border: 1px solid #ccc;
    border-radius: 3px;
    font-size: 16px;
    font-family: Arial, sans-serif;
    background-color: white;
    width: 120px;
}

.rdc-select {
    width: 200px;
    cursor: pointer;
}

.rdc-input:focus,
.rdc-select:focus {
    outline: none;
    border-color: #66afe9;
}

.rdc-input[readonly] {
    background-color: #f5f5f5;
    cursor: default;
    color: #666;
}

.rdc-suffix {
    font-size: 16px;
    color: #333;
}

/* Radio Buttons */
.rdc-downpipe-group {
    margin-top: 5px;
}

.rdc-radio-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.rdc-radio-item {
    display: flex;
    align-items: center;
}

.rdc-radio-item input[type="radio"] {
    margin: 0 8px 0 0;
    cursor: pointer;
}

.rdc-radio-item label {
    cursor: pointer;
    font-size: 16px;
    font-weight: normal;
    color: #333;
}

.rdc-radio-item input[type="radio"]:disabled + label {
    color: #999;
    cursor: not-allowed;
}

/* Info Text unter Formular */
.rdc-info-text {
    font-size: 12px;
    color: #333;
    margin: 15px 0;
    line-height: 1.5;
}

/* Checkbox Bereich */
.rdc-checkbox-group {
    padding: 15px 0;
    background: transparent;
    margin: 0;
}

.rdc-checkbox-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.rdc-checkbox-item input[type="checkbox"] {
    margin-top: 2px;
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.rdc-checkbox-item label {
    cursor: pointer;
    font-size: 16px;
    line-height: 1.5;
    color: #333;
}

.rdc-checkbox-item label strong {
    font-weight: bold;
}

/* Button Container */
.rdc-button-container {
    padding: 15px 0;
}

.rdc-button {
    padding: 8px 20px;
    border: none;
    border-radius: 3px;
    font-size: 16px;
    font-weight: normal;
    cursor: pointer;
    font-family: Arial, sans-serif;
}

.rdc-button-primary {
    background-color: #DC0C15;
    color: white;
}

.rdc-button-primary:hover {
    background-color: #cc101a;
}

.rdc-button-secondary {
    background-color: #DC0C15;
    color: white;
}

.rdc-button-secondary:hover {
    background-color: #cc101a;
}

/* Results Section */
.rdc-results {
    margin: 0;
    padding: 30px 0;
    border-top: 1px solid #e0e0e0;
}

.rdc-results-container {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.rdc-results-left {
    flex: 1;
    min-width: 300px;
}

.rdc-results-right {
    flex: 1;
    min-width: 300px;
}

/* Wenn linke Seite ausgeblendet ist, Beispielrechnung auf 50% rechts */
.rdc-results-left[style*="display: none"] ~ .rdc-results-right {
    max-width: 50%;
    margin-left: auto;
}

.rdc-results h3 {
    color: #000 !important;
    font-size: 28px !important;
    margin: 0 0 15px 0 !important;
    font-weight: bold !important;
    line-height: 1.25 !important;
}

.rdc-results h2 {
    color: #000 !important;
    font-size: 32px !important;
    margin: 0 0 15px 0 !important;
    font-weight: bold !important;
    line-height: 1.25 !important;
}

/* User Data */
.rdc-user-data {
    background: transparent;
    padding: 0;
    margin-bottom: 20px;
}

.rdc-data-grid {
    display: block;
}

.rdc-data-item {
    display: flex;
    padding: 4px 0;
    background: transparent;
}

.rdc-data-item:not(:last-child) {
    margin-bottom: 8px;
}

.rdc-data-label {
    font-weight: normal;
    color: #333;
    font-size: 16px;
    min-width: 280px;
}

.rdc-data-value {
    color: #333;
    font-size: 16px;
    font-weight: normal;
}

/* Result Box - Lila wie im Original */
.rdc-result-box {
    background: #d8d7ed;
    padding: 15px 20px;
    margin: 15px 0 20px 0;
}

.rdc-result-table {
    width: 100%;
}

.rdc-result-table tr td {
    padding: 8px 5px;
    font-size: 14px;
}

.rdc-result-label {
    font-weight: bold;
    color: #333;
}

.rdc-result-value {
    font-weight: bold;
    color: #333;
    font-size: 16px;
    text-align: right;
}

/* Beispielrechnung Box */
.rdc-example-box {
    background: transparent;
    padding: 0;
    margin: 20px 0;
}

.rdc-example-title {
    font-weight: bold;
    margin-bottom: 10px;
    color: #333;
    font-size: 14px;
}

.rdc-example-content {
    margin-bottom: 15px;
}

.rdc-example-text {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 10px;
}

.rdc-example-diagram {
    text-align: center;
    margin: 15px 0;
}

.rdc-example-diagram img {
    max-width: 100%;
    height: auto;
    border: 1px solid #e0e0e0;
}

.rdc-example-note {
    font-size: 12px;
    color: #333;
    line-height: 1.5;
    margin-top: 10px;
}

/* Print Button */
.rdc-print-button {
    text-align: left;
    margin-top: 20px;
}

/* Loading */
.rdc-loading {
    text-align: center;
    padding: 40px 0;
}

.rdc-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #000;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error */
.rdc-error {
    background-color: #f8d7da;
    color: #721c24;
    padding: 12px 0;
    margin: 0;
    border-top: 1px solid #f5c6cb;
    border-bottom: 1px solid #f5c6cb;
}

.rdc-error p {
    margin: 0;
    font-size: 16px;
}

/* Input Validation */
.rdc-input.error,
.rdc-select.error {
    border-color: #d9534f;
    background-color: #fff8f8;
}

/* Print Styles - Einfache Version */
@media print {
    * {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
    
    body {
        margin: 0;
        padding: 1.5cm;
    }
    
    .rdc-header h2 {
        color: #000 !important;
        font-size: 32px !important;
    }
    
    .rdc-results h3 {
        color: #000 !important;
    }
    
    .rdc-result-box {
        background: #d8d7ed !important;
    }
    
    /* Drucken Button verstecken */
    .rdc-print-button {
        display: none !important;
    }
    
    /* Beispielrechnung verstecken */
    .rdc-results-right {
        display: none !important;
    }
    
    /* Ihre Angaben tabellarisch */
    .rdc-data-grid {
        display: table;
        width: 100%;
        border-collapse: collapse;
        margin-bottom: 25px;
    }
    
    .rdc-data-item {
        display: table-row;
    }
    
    .rdc-data-label,
    .rdc-data-value {
        display: table-cell;
        padding: 8px 10px;
        border: 1px solid #ddd;
    }
    
    .rdc-data-label {
        font-weight: normal;
        width: 60%;
        background-color: #f5f5f5;
    }
    
    .rdc-data-value {
        font-weight: normal;
        width: 40%;
    }
    
    /* Entferne Doppelpunkt bei tabellarischer Darstellung */
    .rdc-data-label::after {
        content: none;
    }
    
    @page {
        size: A4;
        margin: 1.5cm;
    }
}

/* Responsive */
@media (max-width: 1124px) {
    .rdc-header h2 {
        font-size: 32px !important;
    }
}

@media (max-width: 768px) {
    .rdc-header {
        padding: 20px 0 15px;
    }
    
    .rdc-header h2 {
        font-size: 32px !important;
    }
    
    .rdc-results h2 {
        font-size: 28px !important;
    }
    
    .rdc-results h3 {
        font-size: 24px !important;
    }
    
    .rdc-intro,
    .rdc-form,
    .rdc-results,
    .rdc-checkbox-group,
    .rdc-button-container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .rdc-form-grid {
        flex-direction: column;
        gap: 20px;
    }
    
    .rdc-form-left {
        max-width: 100%;
    }
    
    .rdc-form-right {
        width: 100%;
    }
    
    .rdc-form-group {
        grid-template-columns: 1fr;
        gap: 5px;
    }
    
    .rdc-label {
        padding-top: 0;
    }
    
    .rdc-input,
    .rdc-select {
        width: 100%;
        max-width: 200px;
    }
    
    .rdc-data-label {
        min-width: auto;
    }
    
    .rdc-result-table tr td {
        display: block;
        width: 100%;
        text-align: left !important;
    }
    
    .rdc-result-value {
        padding-top: 5px;
        font-size: 16px;
    }
    
    .rdc-results-container {
        flex-direction: column;
    }
    
    .rdc-results-left[style*="display: none"] ~ .rdc-results-right {
        max-width: 100%;
        margin-left: 0;
    }
}

@media (max-width: 480px) {
    .rdc-input,
    .rdc-select {
        max-width: 100%;
    }
    
    .rdc-button {
        width: 100%;
    }
}