@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #3498db;
    --secondary-color: #2ecc71;
    --background-color: #f0f4f8;
    --text-color: #2c3e50;
    --border-radius: 12px;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Base Styles */
body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
}

/* Hub Container */
.hub-container {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.hub-content {
    width: 100%;
    max-width: 1200px;
    background-color: #ffffff;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    padding: 30px;
}

.hub-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Hub Layout */
.hub-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.hub-section {
    flex: 1;
    min-width: 250px;
    background-color: #ffffff;
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.hub-section:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.section-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.section-icon {
    margin-right: 10px;
}

/* Radio Group */
.radio-group {
    display: flex;
    gap: 20px;
}

.Radio {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.Radio__input {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    margin-right: 10px;
    position: relative;
    transition: all 0.3s ease;
}

.Radio__input:checked {
    background-color: var(--primary-color);
}

.Radio__input:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background-color: #ffffff;
    border-radius: 50%;
}

.Radio__label {
    font-size: 1rem;
    color: var(--text-color);
}

/* Profile Section */
.profile-section {
    background-color: #ffffff;
    border-radius: var(--border-radius);
    overflow: hidden;
    margin-bottom: 30px;
    box-shadow: var(--shadow-sm);
}

.profile-header {
    padding: 15px 20px;
    background-color: var(--primary-color);
    color: #ffffff;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.profile-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
}

.profile-icon {
    transition: transform 0.3s ease;
}

.profile-icon.rotate {
    transform: rotate(180deg);
}

.profile-content {
    overflow: hidden;
    background-color: #ffffff;
}

.profile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.profile-item {
    display: flex;
    flex-direction: column;
}

.profile-item strong {
    font-weight: 600;
    margin-bottom: 5px;
}

/* Profile Actions */
.profile-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    background-color: #f8f9fa;
}

.profile-save-section {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.profile-load-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.profile-name-input {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.profile-name-input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 2px rgba(46, 204, 113, 0.1);
}

.profile-button {
    padding: 0.75rem 1.5rem;
    background-color: var(--primary-color);
    color: #ffffff;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    min-width: 130px;
    justify-content: center;
}

.profile-button:hover {
    background-color: var(--secondary-color);
    transform: translateY(-1px);
}

.profile-button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
    transform: none;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 20px;
    margin-top: 20px;
}

.generate-csv-button {
    flex: 1;
    padding: 15px;
    font-size: 1.1rem;
    background-color: var(--secondary-color);
    color: #ffffff;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.generate-csv-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

.payment-button {
    flex: 1;
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: #ffffff;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.payment-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1);
}

.button-icon {
    margin-right: 10px;
    width: 1.2rem;
    height: 1.2rem;
}

/* React Select Styles */
/* React Select Styles */
.react-select__menu {
    z-index: 9999 !important;
    /* Ensure dropdown appears above other elements */
    background-color: white;
    border: 1px solid #e1e1e1;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-top: 4px;
}

.profile-select .react-select__menu {
    max-height: 200px;
    overflow-y: auto;
}

.profile-select .react-select__option {
    padding: 10px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.profile-select .react-select__option:hover {
    background-color: var(--background-color);
}

.profile-select .react-select__option--is-selected {
    background-color: var(--primary-color);
    color: white;
}

.profile-select .react-select__control {
    border: 2px solid var(--primary-color);
    min-height: 42px;
}

.profile-select .react-select__control:hover {
    border-color: var(--secondary-color);
}

.profile-select .react-select__control--is-focused {
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 1px var(--secondary-color);
}

/* Fix for profile section container */
.profile-section {
    position: relative;
}

.profile-actions {
    position: relative;
    z-index: 1;
}

.react-select__control {
    border-radius: var(--border-radius);
    border: 2px solid var(--primary-color) !important;
    transition: all 0.3s ease;
    min-height: 42px !important;
}

.react-select__control:hover {
    border-color: var(--secondary-color) !important;
}

.react-select__control--is-focused {
    box-shadow: 0 0 0 1px var(--secondary-color) !important;
    border-color: var(--secondary-color) !important;
}

.react-select__menu {
    border-radius: var(--border-radius);
    overflow: hidden;
    z-index: 100;
}

.react-select__option {
    cursor: pointer;
}

.react-select__option--is-focused {
    background-color: rgba(52, 152, 219, 0.1);
}

.react-select__option--is-selected {
    background-color: var(--primary-color);
}

.react-select__multi-value {
    background-color: var(--primary-color);
    border-radius: 20px;
}

.react-select__multi-value__label {
    color: #ffffff;
}

.react-select__multi-value__remove {
    color: #ffffff;
    cursor: pointer;
}

.react-select__multi-value__remove:hover {
    background-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
}

.react-select__option[aria-label="All States"],
.react-select__option[aria-label="All Secured Parties"] {
    font-weight: bold;
    background-color: #f0f4f8;
}

.react-select__option[aria-label="All States"]:hover,
.react-select__option[aria-label="All Secured Parties"]:hover {
    background-color: #e1e8ed;
}

/* Date Picker Container */
.date-picker-container {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.date-picker-container .react-datepicker-wrapper {
    flex: 1;
}

/* Media Queries */
@media (max-width: 768px) {
    .hub-layout {
        flex-direction: column;
    }

    .hub-section {
        width: 100%;
    }

    .profile-grid {
        grid-template-columns: 1fr;
    }

    .profile-actions {
        padding: 1rem;
    }

    .profile-save-section {
        flex-direction: column;
    }

    .action-buttons {
        flex-direction: column;
    }

    .profile-name-input,
    .profile-button,
    .generate-csv-button,
    .payment-button {
        width: 100%;
    }

    .date-picker-container {
        flex-direction: column;
    }
}

/* Payment and Discount Styles */
.discount-section {
    margin-bottom: 1rem;
}

.discount-input-group {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.discount-input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid var(--primary-color);
    border-radius: var(--border-radius);
}

.apply-discount-button {
    padding: 0.75rem 1.5rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
}

.apply-discount-button:disabled {
    background-color: #ccc;
}

.discount-applied {
    color: var(--secondary-color);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.payment-section {
    margin-top: 2rem;
    padding: 1rem;
    border: 1px solid #eee;
    border-radius: var(--border-radius);
}