/* Enhanced Region Group Styles */
.region-group {
    margin-bottom: 8px;
    background: linear-gradient(0.07deg, rgba(0, 85, 255, 0.15) 0%, rgba(97, 97, 97, 0.09) 100%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
}

#earning-result ul li {
    list-style: disc !important;
}

.region-group:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

/* Collapsible Region Title */
.collapsible-region {
    padding: 15px 20px;
    cursor: pointer;
    user-select: none;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background-color 0.3s ease;
}

.collapsible-region:hover {
    background: rgba(255, 255, 255, 0.05);
}

.collapsible-region.active {
    background: rgba(0, 85, 255, 0.2);
}

.region-text {
    display: flex;
    align-items: center;
    gap: 10px;
}

.region-arrow {
    font-size: 14px;
    transition: transform 0.3s ease;
    color: #0055FE;
    font-weight: bold;
}

.collapsible-region.active .region-arrow {
    transform: rotate(90deg);
}

.region-count {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9em;
    margin-left: 5px;
}

/* Region Countries Container */
.region-countries {
    padding: 0 20px 20px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.1);
}

/* Country Radio Group Grid */
.country-radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

/* Other Country Input Styles */
.custom-input-radio {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
}

.custom-input-radio .radio-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.other-country-input {
    width: 100%;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    transition: all 0.3s ease;
    margin-top: 8px;
}

.other-country-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.other-country-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.15);
    border-color: #0055FE;
    box-shadow: 0 0 0 2px rgba(0, 85, 255, 0.3);
}

.other-country-input:disabled {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.1);
}

.plan-sec {
    background: rgb(8, 8, 8);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
    color: #fff;
    backdrop-filter: blur(2px);
}

.plan-sec h3 {
    color: var(--text-white);
    margin-bottom: 20px;
    font-size: 1.5rem;
    font-weight: 500;
}

.current-earning-highlight {
    background: linear-gradient(0.07deg, rgba(0, 85, 255, 0.15) 0%, rgba(97, 97, 97, 0.09) 100%);
    border: 1px solid rgba(0, 85, 255, 0.2);
    color: white;
}

.earning-showcase {
    text-align: center;
}

.primary-earning {
    margin-bottom: 20px;
}

.monthly-salary {
    font-size: 2.8rem;
    font-weight: 700;
    display: block;
    line-height: 1;
    color: #fff;
}

.salary-label {
    font-size: 1.1rem;
    opacity: 0.8;
    margin-top: 5px;
    display: block;
    color: var(--muted-white);
}

.earning-details {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.earning-metric {
    text-align: center;
}

.earning-metric label {
    display: block;
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 4px;
    color: var(--muted-white);
}

.earning-metric span {
    font-weight: 600;
    font-size: 1.1rem;
    color: #fff;
}

.confidence-badge {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.confidence-high {
    background: rgba(16, 185, 129, 0.25);
    color: #10b981;
}

.confidence-medium {
    background: rgba(245, 158, 11, 0.25);
    color: #fbbf24;
}

.confidence-low {
    background: rgba(239, 68, 68, 0.25);
    color: #f87171;
}

.market-grid {
    display: grid;
    gap: 15px;
}

.market-item {
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border-left: 4px solid #0055fe;
    color: var(--text-white);
}

.market-item strong {
    color: #0055fe;
}

.timeline-wrapper {
    position: relative;
}

.timeline-phase {
    margin-bottom: 25px;
    border-left: 3px solid rgba(255, 255, 255, 0.2);
    padding-left: 20px;
    position: relative;
}

.timeline-phase:before {
    content: '';
    position: absolute;
    left: -8px;
    top: 20px;
    width: 12px;
    height: 12px;
    background: #0055fe;
    border-radius: 50%;
}

/* .timeline-phase:after {
    content: "";
    position: absolute;
    height: 25px;
    width: 3px;
    background: #3d3d3d;
    left: -3px;
} */

.phase-header {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.phase-icon {
    font-size: 2rem;
    margin-right: 15px;
}

.phase-info h4 {
    margin: 0 0 5px 0;
    color: var(--text-white);
    font-size: 1.25rem;
}

.phase-salary {
    background: #0055fe;
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
}

.phase-details {
    color: var(--muted-white);
    line-height: 1.6;
}

.phase-details p {
    margin-bottom: 12px;
}

.phase-details strong {
    color: var(--text-white);
}

.phase-details ul {
    margin: 8px 0;
    padding-left: 20px;
}

.phase-details li {
    margin-bottom: 4px;
    color: var(--muted-white);
}

.benefits-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.benefit-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: 10px;
    border-left: 4px solid #0055fe;
    color: var(--text-white);
}

.benefit-card h5 {
    color: var(--text-white);
    margin-bottom: 8px;
    font-size: 1.1rem;
    font-weight: 500;
}

.benefit-card p {
    color: var(--muted-white);
    line-height: 1.5;
}

.benefit-value {
    color: #0055fe;
    font-weight: 600;
    font-size: 0.9rem;
    display: block;
    margin-top: 8px;
}

.total-comp-highlight {
    grid-column: 1 / -1;
    background: rgba(0, 85, 255, 0.15);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    color: #0055fe;
    font-size: 1.2rem;
    margin-top: 15px;
    font-weight: 600;
}

.rec-category,
.reality-category {
    margin-bottom: 20px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    color: var(--text-white);
}

.rec-category h4,
.reality-category h4 {
    color: var(--text-white);
    margin-bottom: 8px;
    font-size: 1.1rem;
    font-weight: 500;
}

.rec-category p,
.reality-category p {
    color: var(--muted-white);
    line-height: 1.6;
}

.rec-category ul,
.reality-category ul {
    margin: 8px 0;
    padding-left: 20px;
}

.rec-category li,
.reality-category li {
    margin-bottom: 6px;
    color: var(--muted-white);
}

.reality-check {
    border-left: 4px solid #f59e0b;
}

.success-prob {
    background: rgba(245, 158, 11, 0.15) !important;
    color: #fbbf24;
    font-weight: 600;
}

.error-section {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
    text-align: center;
}

.error-section h3 {
    color: #f87171;
}

.error-actions {
    margin-top: 16px;
}

.reload-page-button {
    background: #0055fe;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s ease;
}

.reload-page-button:hover {
    background: #0044cc;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .country-radio-group {
        grid-template-columns: 1fr;
    }

    .earning-details {
        flex-direction: column;
    }

    .benefits-container {
        grid-template-columns: 1fr;
    }

    .monthly-salary {
        font-size: 2.2rem;
    }

    .plan-sec {
        padding: 18px;
    }

    .phase-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}