/* Construction Cost Calculator Styles */

.ccc-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    font-family: Arial, sans-serif;
}

.ccc-form {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.ccc-input-group {
    margin-bottom: 25px;
}

.ccc-input-group h3 {
    margin-bottom: 15px;
    color: #333;
    font-size: 18px;
    font-weight: 600;
}

.ccc-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.ccc-col {
    flex: 1;
    min-width: 200px;
}

.ccc-col label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #555;
}

.ccc-col input[type="number"],
.ccc-col input[type="text"],
.ccc-col select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.ccc-col input[type="number"]:focus,
.ccc-col select:focus {
    outline: none;
    border-color: #007cba;
}

.ccc-col input[readonly] {
    background-color: #f0f0f0;
    cursor: not-allowed;
}

/* Main content layout */
.ccc-main-content {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.ccc-left-section {
    flex: 1;
    min-width: 600px;
}

.ccc-right-section {
    flex: 0 0 280px;
    position: sticky;
    top: 20px;
}

/* Illustration styles */
.ccc-illustration {
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

#house-svg, #house-svg-mobile {
    max-width: 100%;
    height: auto;
}

/* Desktop/Mobile illustration visibility */
.ccc-illustration-desktop {
    display: block;
}

.ccc-illustration-mobile {
    display: none;
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
    margin-top: 30px;
}

/* Table Styles */
.ccc-calculation-table,
.ccc-price-table {
    margin: 25px 0;
    overflow-x: auto;
}

.ccc-calculation-table table,
.ccc-price-table table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.ccc-calculation-table th,
.ccc-calculation-table td,
.ccc-price-table th,
.ccc-price-table td {
    padding: 12px 15px;
    text-align: left;
    border: 1px solid #e0e0e0;
}

.ccc-calculation-table th,
.ccc-price-table th {
    background: #f5f5f5;
    font-weight: 600;
    color: #333;
}

.ccc-calculation-table td:nth-child(2),
.ccc-calculation-table td:nth-child(3),
.ccc-calculation-table td:nth-child(4),
.ccc-price-table td:nth-child(2),
.ccc-price-table td:nth-child(3),
.ccc-price-table td:nth-child(4) {
    text-align: center;
}

.ccc-calculation-table tr:nth-child(even) {
    background: #fafafa;
}

.ccc-calculation-table tr:hover {
    background: #f0f8ff;
}

/* Special row styles */
.ccc-basement-row {
    background: #e8f5e9 !important;
}

.ccc-floor-row {
    font-weight: 500;
}

.ccc-garden-row {
    background: #f1f8e9 !important;
}

.ccc-rooftop-row {
    background: #fff3cd !important;
}

.ccc-tum-row,
.ccc-terrace-row {
    background: #fffbf0 !important;
}

.ccc-tum-row td:first-child,
.ccc-terrace-row td:first-child {
    padding-left: 45px;
}

.ccc-roof-row {
    background: #e7f3ff !important;
}

.ccc-foundation-row {
    background: #f0f0f0 !important;
}

/* Area control buttons */
.ccc-area-control {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.ccc-area-adjust {
    width: 28px;
    height: 28px;
    border: 1px solid #ddd;
    background: #f8f9fa;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    padding: 0;
    transition: all 0.2s;
}

.ccc-area-adjust:hover {
    background: #007cba;
    color: white;
    border-color: #007cba;
}

.ccc-area-input {
    width: 80px;
    padding: 5px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
    font-size: 13px;
}

/* Select dropdown in table */
.ccc-calculation-table select {
    width: 100%;
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 13px;
    margin-bottom: 5px;
}

/* Garden dropdown specific */
#ccc-garden-option {
    margin-top: 5px;
}

/* Checkbox style */
.ccc-checkbox {
    display: inline-flex;
    align-items: center;
    margin-top: 8px;
    font-size: 13px;
    cursor: pointer;
}

.ccc-checkbox input[type="checkbox"] {
    margin-right: 6px;
    cursor: pointer;
}

/* Small text for notes */
.ccc-calculation-table small {
    font-size: 11px;
    color: #666;
    font-style: italic;
}

/* Total area */
.ccc-total-area {
    text-align: right;
    padding: 15px 0;
    border-top: 2px solid #007cba;
    margin-top: 15px;
    font-size: 16px;
    color: #333;
}

.ccc-total-area span {
    color: #007cba;
    font-size: 18px;
}

/* Price table specific styles */
.ccc-price-table {
    margin-top: 30px;
}

.ccc-price-table td:nth-child(4) {
    font-weight: 600;
    color: #007cba;
}

/* Notes section */
.ccc-notes {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-left: 4px solid #007cba;
    clear: both;
}

.ccc-notes p {
    margin: 0 0 10px 0;
    font-style: italic;
    color: #666;
    font-size: 14px;
}

.ccc-additional-text {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #ddd;
    color: #444;
    font-size: 14px;
    line-height: 1.6;
}

/* Responsive */
@media (max-width: 1024px) {
    .ccc-main-content {
        flex-direction: column;
    }
    
    .ccc-left-section {
        min-width: 100%;
    }
    
    .ccc-right-section {
        display: none; /* Hide desktop illustration on mobile */
    }
    
    .ccc-illustration-mobile {
        display: block; /* Show mobile illustration */
    }
}

@media (max-width: 768px) {
    .ccc-container {
        padding: 10px;
    }
    
    .ccc-form {
        padding: 15px;
    }
    
    .ccc-row {
        flex-direction: column;
    }
    
    .ccc-col {
        min-width: 100%;
    }
    
    .ccc-calculation-table,
    .ccc-price-table {
        font-size: 13px;
    }
    
    .ccc-calculation-table th,
    .ccc-calculation-table td,
    .ccc-price-table th,
    .ccc-price-table td {
        padding: 8px 10px;
    }
    
    .ccc-area-control {
        flex-wrap: wrap;
    }
    
    .ccc-area-input {
        width: 60px;
        font-size: 12px;
    }
    
    .ccc-area-adjust {
        width: 24px;
        height: 24px;
        font-size: 14px;
    }
    
    .ccc-tum-row td:first-child,
    .ccc-terrace-row td:first-child {
        padding-left: 25px;
    }
    
    #ccc-garden-option {
        font-size: 12px;
        padding: 5px 8px;
    }
}