/* Import a modern font */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/* Main Container */
.gsc-container {
    font-family: 'Poppins', sans-serif;
    display: flex;
    gap: 30px;
    background-color: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
    margin: 20px auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.07);
    color: #343a40;
}

/* Titles used inside the calculator */
.gsc-title-sub {
    font-size: 22px;
    font-weight: 600;
    color: #212529;
    margin-bottom: 5px;
    text-align: center;
}
.gsc-subtitle {
    font-size: 14px;
    color: #6c757d;
    text-align: center;
    margin-bottom: 25px;
}

/* --- Left Column: Inputs --- */
.gsc-inputs-column {
    flex: 1;
    min-width: 0; /* Prevents flexbox overflow */
}

/* Scenario Buttons */
.gsc-scenario-buttons {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}
.gsc-scenario-btn {
    flex: 1;
    padding: 10px 15px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    border: 1px solid;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: #fff;
}
.gsc-scenario-btn svg {
    width: 20px;
    height: 20px;
}
.gsc-scenario-btn-essentials {
    background-color: #e6f4ea;
    border-color: #b7e0c1;
    color: #155724;
}
.gsc-scenario-btn-essentials:hover {
    background-color: #d4edda;
    border-color: #a3d5b0;
}
.gsc-scenario-btn-full {
    background-color: #e7f5ff;
    border-color: #b3d7f7;
    color: #0c5460;
}
.gsc-scenario-btn-full:hover {
    background-color: #d0ebff;
    border-color: #9acffa;
}

/* Search Bar */
.gsc-search-bar-container {
    position: relative;
    margin-bottom: 20px;
}
.gsc-search-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: #adb5bd;
}
.gsc-search-input {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    font-size: 15px;
    background-color: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}
.gsc-search-input:focus {
    outline: none;
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Categories & Accordion */
.gsc-appliance-categories {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.gsc-category-header {
    display: flex;
    align-items: center;
    background-color: #ffffff;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    border: 1px solid #dee2e6;
}
.gsc-category-header:hover {
    background-color: #f1f3f5;
}
.gsc-category-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
    flex-grow: 1;
}
.gsc-icon {
    margin-right: 12px;
    display: inline-flex;
    align-items: center;
    color: #0d6efd;
}
.gsc-icon svg { width: 24px; height: 24px; }
.gsc-toggle-icon {
    font-size: 24px;
    font-weight: 500;
    color: #6c757d;
    transition: transform 0.3s ease;
}
.gsc-category.active .gsc-toggle-icon { transform: rotate(45deg); }
.gsc-appliance-list {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: #ffffff;
    border-radius: 0 0 8px 8px;
    border: 1px solid #dee2e6;
    border-top: none;
    margin-top: -8px;
    padding: 0 15px;
}
.gsc-category.active .gsc-appliance-list {
    max-height: 4000px; /* Increased for longer lists */
    padding: 10px 15px;
}
.gsc-sub-category-title {
    font-size: 13px;
    font-weight: 600;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 20px 0 10px 0;
    padding-bottom: 5px;
    border-bottom: 1px solid #e9ecef;
}
.gsc-sub-category-title:first-child {
    margin-top: 5px;
}
.gsc-appliance-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    font-size: 15px;
    border-bottom: 1px solid #f1f3f5;
}
.gsc-appliance-item:last-child {
    border-bottom: none;
}
.gsc-quantity-control {
    display: flex;
    align-items: center;
    gap: 10px;
}
.gsc-quantity-control span {
    font-weight: 600;
    min-width: 20px;
    text-align: center;
    color: #0d6efd;
}
.gsc-btn-minus, .gsc-btn-plus {
    width: 28px; height: 28px;
    border-radius: 50%;
    border: 1px solid #ced4da;
    background-color: #f8f9fa;
    color: #495057;
    font-size: 18px; font-weight: bold;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.2s ease;
}
.gsc-btn-plus:hover { background-color: #d1e7dd; border-color: #a3cfbb; }
.gsc-btn-minus:hover { background-color: #f8d7da; border-color: #f1b0b7; }
.gsc-btn-plus:active, .gsc-btn-minus:active { transform: scale(0.95); }

/* Custom Item Adder */
.gsc-custom-item-adder {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 2px dashed #dee2e6;
}
.gsc-custom-title {
    font-size: 16px;
    font-weight: 600;
    color: #495057;
    text-align: center;
    margin: 0 0 15px 0;
}
.gsc-custom-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.gsc-custom-form input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    box-sizing: border-box;
}
.gsc-custom-form input:focus {
    outline: none;
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.2);
}
#gsc-custom-name {
    grid-column: 1 / -1;
}
#gsc-add-custom-btn {
    grid-column: 1 / -1;
    background-color: #28a745;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}
#gsc-add-custom-btn:hover {
    background-color: #218838;
}
#gsc-custom-items-list .gsc-appliance-item {
    background-color: #fffbeB;
    border-radius: 6px;
    padding: 10px;
    margin-top: 10px;
    border-bottom: none;
}
.gsc-custom-item-remove-btn {
    background-color: transparent;
    border: none;
    color: #dc3545;
    cursor: pointer;
    font-size: 20px;
    padding: 0 5px;
    font-weight: bold;
}

/* --- Right Column: Results --- */
.gsc-results-column {
    flex-basis: 400px;
    position: sticky;
    top: 20px;
    height: fit-content;
}
.gsc-results-content {
    background-color: #ffffff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    border: 1px solid #dee2e6;
    text-align: center;
}
.gsc-gauge-container { padding: 20px 0; }
.gsc-gauge { width: 250px; height: 125px; margin: 0 auto; position: relative; }
.gsc-gauge-body { width: 100%; height: 100%; background: #e9ecef; border-radius: 125px 125px 0 0; position: relative; overflow: hidden; }
.gsc-gauge-fill { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: conic-gradient(from -90deg at 50% 100%, #0d6efd 0%, #6ea8fe 50%, #dcf0ff 100%); transform-origin: 50% 100%; transform: rotate(0deg); transition: transform 0.8s cubic-bezier(0.68, -0.55, 0.27, 1.55); }
.gsc-gauge-cover { width: 80%; height: 160%; background: #ffffff; border-radius: 50%; position: absolute; top: 20%; left: 10%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding-bottom: 20px; box-sizing: border-box; }
.gsc-gauge-value { font-size: 36px; font-weight: 700; color: #0d6efd; line-height: 1; }
.gsc-gauge-label { font-size: 12px; color: #495057; font-weight: 500; }
.gsc-summary { margin-top: 20px; border-top: 1px solid #e9ecef; padding-top: 20px; display: flex; justify-content: space-around; gap: 15px; }
.gsc-summary-item { text-align: center; }
.gsc-summary-item label { display: block; font-size: 13px; color: #6c757d; margin-bottom: 5px; }
.gsc-summary-item span { font-size: 18px; font-weight: 600; color: #343a40; }

/* Tooltips */
.gsc-tooltip-trigger {
    position: relative;
    display: inline-block;
    cursor: help;
    color: #0d6efd;
    font-weight: bold;
}
.gsc-tooltip-text {
    visibility: hidden;
    width: 220px;
    background-color: #343a40;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 8px;
    position: absolute;
    z-index: 10;
    bottom: 125%;
    left: 50%;
    margin-left: -110px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.4;
}
.gsc-tooltip-trigger:hover .gsc-tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Recommendation Box */
.gsc-recommendation { background-color: #e7f5ff; border: 1px solid #b3d7f7; border-radius: 8px; padding: 15px; margin-top: 25px; }
.gsc-recommendation h3 { margin: 0 0 8px 0; font-size: 16px; color: #0a58ca; }
.gsc-recommendation p { margin: 0; font-size: 14px; color: #0c63e4; }

/* CTA Button in Recommendation */
.gsc-cta-button {
    display: inline-block;
    margin-top: 15px;
    background-color: #0d6efd;
    color: #fff !important;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 500;
    transition: background-color 0.2s;
}
.gsc-cta-button:hover {
    background-color: #0b5ed7;
}

/* Reset Button & Disclaimer */
.gsc-reset-button { width: 100%; background-color: #dc3545; color: #fff; border: none; padding: 12px; border-radius: 8px; font-size: 16px; font-weight: 500; cursor: pointer; transition: background-color 0.2s; margin-top: 20px; }
.gsc-reset-button:hover { background-color: #c82333; }
.gsc-disclaimer { font-size: 11px; color: #6c757d; margin-top: 15px; line-height: 1.4; }

/* Comparison Chart */
.gsc-comparison-chart-container {
    background-color: #fff;
    padding: 25px;
    border-radius: 12px;
    max-width: 1200px;
    margin: 40px auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.07);
}
.gsc-chart-row {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}
.gsc-chart-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
}
.gsc-chart-header {
    background-color: #495057;
    color: #fff;
    padding: 12px;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
}
.gsc-chart-cell {
    padding: 15px;
    font-size: 14px;
    line-height: 1.5;
    border-bottom: 1px solid #f1f3f5;
    flex-grow: 1;
}
.gsc-chart-column .gsc-chart-cell:last-of-type {
    border-bottom: none;
}
.gsc-chart-cell strong {
    color: #212529;
}
.gsc-chart-watts {
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    background-color: #f8f9fa;
    color: #0d6efd;
}

/* Utility Class */
.gsc-hidden { display: none !important; }

/* Mobile Responsiveness */
@media (max-width: 992px) {
    .gsc-container { flex-direction: column; padding: 15px; }
    .gsc-results-column { position: static; top: auto; flex-basis: auto; }
    .gsc-chart-row { flex-direction: column; }
}
@media (max-width: 480px) {
    .gsc-appliance-item { flex-direction: column; align-items: flex-start; gap: 10px; }
    .gsc-quantity-control { align-self: flex-end; }
    .gsc-gauge { width: 220px; height: 110px; }
    .gsc-gauge-value { font-size: 32px; }
    .gsc-scenario-buttons { flex-direction: column; }
    .gsc-custom-form { grid-template-columns: 1fr; }
}