/* BBB Payouts Frontend Styles */

/* Global Styles */
.bbb-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.bbb-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    margin-bottom: 24px;
}

/* Button Styles */
.bbb-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.bbb-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
    color: white;
    text-decoration: none;
}

.bbb-btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bbb-btn-secondary {
    background: #6c757d;
}

.bbb-btn-danger {
    background: #dc3545;
}

.bbb-btn-success {
    background: #28a745;
}

/* Dashboard Page Layout */
.bbb-dashboard-page {
    background: #f8f9fa;
    min-height: 100vh;
}

.bbb-dashboard-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 0;
    margin-bottom: 0;
}

.bbb-header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.bbb-header-left h1 {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    white-space: nowrap;
}

.bbb-header-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.bbb-nav {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.bbb-nav-link {
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-weight: 500;
    white-space: nowrap;
}

.bbb-nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    text-decoration: none;
}

.bbb-header-btn {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    padding: 10px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
    font-size: 14px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.bbb-header-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
}

.bbb-logout {
    background: rgba(220, 53, 69, 0.8) !important;
    border-color: rgba(220, 53, 69, 0.8) !important;
}

.bbb-logout:hover {
    background: rgba(220, 53, 69, 1) !important;
    border-color: rgba(220, 53, 69, 1) !important;
}

/* Dashboard Content */
.bbb-dashboard-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.bbb-welcome-section {
    margin-bottom: 40px;
}

.bbb-welcome-section h2 {
    font-size: 32px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.bbb-welcome-section p {
    font-size: 18px;
    color: #666;
    margin: 0;
}

/* Opportunities Section */
.bbb-opportunities-section {
    margin-bottom: 50px;
}

.bbb-opportunities-section h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 30px;
}

.bbb-opportunities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.bbb-opportunity-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 30px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.bbb-opportunity-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bbb-opportunity-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
    border-color: #667eea;
}

.bbb-opportunity-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    color: white;
    margin-bottom: 20px;
}

.bbb-opportunity-content h4 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #333;
}

.bbb-opportunity-content p {
    color: #666;
    font-size: 15px;
    margin-bottom: 20px;
    line-height: 1.6;
}

.bbb-opportunity-details {
    margin-bottom: 25px;
}

.bbb-potential {
    margin-bottom: 8px;
}

.bbb-potential strong {
    color: #28a745;
    font-size: 16px;
}

.bbb-processing-time {
    color: #666;
    font-size: 14px;
}

.bbb-start-application {
    width: 100%;
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 600;
}

/* Application Queue Section */
.bbb-queue-section {
    margin-bottom: 50px;
}

.bbb-queue-section h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

.bbb-no-applications {
    background: white;
    border-radius: 16px;
    padding: 60px 40px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.bbb-no-applications p {
    font-size: 18px;
    color: #666;
    margin-bottom: 30px;
}

.bbb-applications-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
}

.bbb-application-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 25px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.bbb-application-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    border-color: #667eea;
}

.bbb-app-header {
    margin-bottom: 20px;
}

.bbb-app-id {
    font-size: 14px;
    font-weight: 600;
    color: #667eea;
    margin-bottom: 5px;
}

.bbb-app-name {
    font-size: 18px;
    font-weight: 700;
    color: #333;
}

.bbb-app-progress {
    margin-bottom: 20px;
}

.bbb-progress-bar {
    width: 100%;
    height: 10px;
    background: #e9ecef;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 8px;
}

.bbb-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 5px;
    transition: width 0.3s ease;
}

.bbb-progress-text {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.bbb-app-actions {
    display: flex;
    gap: 12px;
}

.bbb-app-actions .bbb-btn {
    flex: 1;
    text-align: center;
    padding: 10px 16px;
    font-size: 14px;
}

/* Completed Applications Section */
.bbb-completed-section {
    margin-bottom: 50px;
}

.bbb-completed-section h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

.bbb-completed-applications {
    background: white;
    border-radius: 16px;
    padding: 40px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.bbb-completed-applications p {
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* Form Styles */
.bbb-form-group {
    margin-bottom: 20px;
}

.bbb-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.bbb-form-group input,
.bbb-form-group select,
.bbb-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.bbb-form-group input:focus,
.bbb-form-group select:focus,
.bbb-form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.bbb-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Document Upload */
.bbb-upload-area {
    border: 2px dashed #ccc;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.bbb-upload-area:hover,
.bbb-upload-area.dragover {
    border-color: #667eea;
    background: #f8f9ff;
}

.bbb-upload-icon {
    font-size: 48px;
    color: #ccc;
    margin-bottom: 16px;
}

.bbb-upload-text {
    font-size: 16px;
    color: #666;
    margin-bottom: 8px;
}

.bbb-upload-subtext {
    font-size: 14px;
    color: #999;
}

.bbb-file-list {
    margin-top: 20px;
}

.bbb-file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 8px;
}

.bbb-file-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.bbb-file-icon {
    width: 32px;
    height: 32px;
    background: #667eea;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
    font-weight: 600;
}

.bbb-file-details {
    flex: 1;
}

.bbb-file-name {
    font-weight: 600;
    color: #333;
    margin-bottom: 2px;
}

.bbb-file-size {
    font-size: 12px;
    color: #666;
}

.bbb-file-actions {
    display: flex;
    gap: 8px;
}

/* Notifications */
.bbb-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    padding: 16px 20px;
    max-width: 400px;
    z-index: 9999;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.bbb-notification.show {
    transform: translateX(0);
}

.bbb-notification.success {
    border-left: 4px solid #28a745;
}

.bbb-notification.error {
    border-left: 4px solid #dc3545;
}

.bbb-notification.warning {
    border-left: 4px solid #ffc107;
}

.bbb-notification.info {
    border-left: 4px solid #17a2b8;
}

/* Loading States */
.bbb-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: bbb-spin 1s linear infinite;
}

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

.bbb-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: bbb-skeleton 1.5s infinite;
}

@keyframes bbb-skeleton {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Empty States */
.bbb-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.bbb-empty-icon {
    font-size: 64px;
    color: #ccc;
    margin-bottom: 20px;
}

.bbb-empty-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 12px;
    color: #333;
}

.bbb-empty-description {
    font-size: 16px;
    margin-bottom: 24px;
    line-height: 1.5;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .bbb-header-content {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .bbb-header-right {
        justify-content: center;
        flex-wrap: wrap;
    }
}

@media (max-width: 768px) {
    .bbb-dashboard-container {
        padding: 10px;
    }
    
    .bbb-header-content {
        padding: 15px;
    }
    
    .bbb-header-btn {
        padding: 8px 16px;
        font-size: 14px;
        min-width: 120px;
    }
    
    .bbb-opportunities-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .bbb-applications-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .bbb-header-content {
        padding: 10px;
    }
    
    .bbb-header-btn {
        padding: 6px 12px;
        font-size: 12px;
        min-width: 100px;
    }
    
    .bbb-dashboard-container {
        padding: 5px;
    }
}

/* PWA Specific Styles */
@media (display-mode: standalone) {
    .bbb-dashboard-container {
        padding-top: 20px; /* Account for status bar */
    }
    
    .bbb-header-content {
        position: sticky;
        top: 0;
        z-index: 100;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }
}

/* Eligibility Check Specific Styles */
.bbb-eligibility-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.bbb-eligibility-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
}

.bbb-eligibility-header h1 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 600;
}

.bbb-eligibility-steps {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    min-width: 80px;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    background: #ccc;
    transition: all 0.3s ease;
}

.step.active .step-number {
    background: #667eea;
    transform: scale(1.1);
}

.step-label {
    font-size: 12px;
    text-align: center;
    color: #666;
    font-weight: 500;
}

.step.active .step-label {
    color: #667eea;
    font-weight: 600;
}

.bbb-score-display {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f0ff 100%);
    border: 2px solid #667eea;
    border-radius: 12px;
    padding: 20px;
    margin: 20px 0;
    text-align: center;
}

.score-circle {
    width: 120px;
    height: 120px;
    margin: 0 auto 15px;
    position: relative;
}

.score-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    font-weight: bold;
    color: #667eea;
}

.score-status {
    font-size: 18px;
    font-weight: 600;
    margin: 10px 0;
}

.score-status .eligible {
    color: #28a745;
}

.score-status .not-eligible {
    color: #dc3545;
}

.score-explanation {
    font-size: 14px;
    color: #666;
    margin: 10px 0;
}

.bbb-eligibility-content {
    margin-top: 30px;
}

.eligibility-intro {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.eligibility-intro h2 {
    color: #333;
    margin-bottom: 10px;
}

.eligibility-question {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.eligibility-question:hover {
    border-color: #667eea;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.1);
}

.question-header h3 {
    color: #333;
    margin-bottom: 10px;
    font-size: 18px;
}

.question-header .required {
    color: #dc3545;
    font-weight: bold;
}

.question-header .minimum-req {
    background: #dc3545;
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    margin-left: 10px;
}

.help-text {
    color: #666;
    font-size: 14px;
    font-style: italic;
    margin-bottom: 15px;
}

.question-options {
    margin-top: 15px;
}

.radio-option,
.checkbox-option {
    display: block;
    margin-bottom: 10px;
    padding: 10px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.radio-option:hover,
.checkbox-option:hover {
    background: #f8f9ff;
    border-color: #667eea;
}

.radio-option input,
.checkbox-option input {
    margin-right: 10px;
}

.text-input,
.number-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.text-input:focus,
.number-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.bbb-next-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: block;
    margin: 30px auto;
    min-width: 200px;
}

.bbb-next-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
}

.bbb-next-button:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Mobile Responsive for Eligibility */
@media (max-width: 768px) {
    .bbb-eligibility-container {
        padding: 15px;
        margin: 10px;
    }
    
    .bbb-eligibility-header {
        padding: 15px;
    }
    
    .bbb-eligibility-header h1 {
        font-size: 24px;
    }
    
    .bbb-eligibility-steps {
        gap: 10px;
    }
    
    .step {
        min-width: 60px;
    }
    
    .step-number {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .step-label {
        font-size: 10px;
    }
    
    .score-circle {
        width: 100px;
        height: 100px;
    }
    
    .score-text {
        font-size: 20px;
    }
    
    .eligibility-question {
        padding: 15px;
    }
    
    .question-header h3 {
        font-size: 16px;
    }
    
    .bbb-next-button {
        padding: 12px 30px;
        font-size: 16px;
        min-width: 150px;
    }
}

@media (max-width: 480px) {
    .bbb-eligibility-container {
        padding: 10px;
        margin: 5px;
    }
    
    .bbb-eligibility-header {
        padding: 10px;
    }
    
    .bbb-eligibility-header h1 {
        font-size: 20px;
    }
    
    .bbb-eligibility-steps {
        gap: 8px;
        flex-wrap: wrap;
    }
    
    .step {
        min-width: 50px;
    }
    
    .step-number {
        width: 30px;
        height: 30px;
        font-size: 12px;
    }
    
    .step-label {
        font-size: 9px;
    }
    
    .score-circle {
        width: 80px;
        height: 80px;
    }
    
    .score-text {
        font-size: 16px;
    }
    
    .eligibility-question {
        padding: 10px;
    }
    
    .question-header h3 {
        font-size: 14px;
    }
    
    .radio-option,
    .checkbox-option {
        padding: 8px;
        font-size: 14px;
    }
    
    .text-input,
    .number-input {
        padding: 10px;
        font-size: 14px;
    }
    
    .bbb-next-button {
        padding: 10px 25px;
        font-size: 14px;
        min-width: 120px;
    }
}

/* PWA Specific Eligibility Styles */
@media (display-mode: standalone) {
    .bbb-eligibility-container {
        margin-top: 10px;
    }
    
    .bbb-eligibility-header {
        position: sticky;
        top: 0;
        z-index: 50;
        margin-bottom: 20px;
    }
    
    .bbb-score-display {
        position: sticky;
        top: 80px;
        z-index: 40;
        margin-bottom: 20px;
    }
}

/* Print Styles */
@media print {
    .bbb-header-content {
        flex-direction: column;
        gap: 15px;
        text-align: center;
        padding: 15px 20px;
    }
    
    .bbb-header-right {
        width: 100%;
        justify-content: center;
        gap: 10px;
    }
    
    .bbb-header-btn {
        padding: 8px 12px;
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .bbb-header-content {
        padding: 15px 15px;
    }
    
    .bbb-header-left h1 {
        font-size: 24px;
    }
    
    .bbb-header-right {
        flex-direction: column;
        gap: 10px;
        width: 100%;
    }
    
    .bbb-nav {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .bbb-header-btn {
        flex: 1;
        min-width: 120px;
        text-align: center;
        padding: 10px 12px;
        font-size: 14px;
    }
    
    .bbb-dashboard-content {
        padding: 30px 15px;
    }
    
    .bbb-welcome-section h2 {
        font-size: 24px;
    }
    
    .bbb-welcome-section p {
        font-size: 16px;
    }
    
    .bbb-opportunities-grid,
    .bbb-applications-grid {
        grid-template-columns: 1fr;
    }
    
    .bbb-form-row {
        grid-template-columns: 1fr;
    }
    
    .bbb-app-actions {
        flex-direction: column;
    }
    
    .bbb-notification {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .bbb-no-applications {
        padding: 40px 20px;
    }
    
    .bbb-opportunity-card,
    .bbb-application-card {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .bbb-header-content {
        padding: 10px 15px;
    }
    
    .bbb-header-left h1 {
        font-size: 20px;
    }
    
    .bbb-header-right {
        gap: 8px;
    }
    
    .bbb-nav {
        gap: 6px;
    }
    
    .bbb-header-btn {
        padding: 8px 10px;
        font-size: 12px;
        min-width: 100px;
    }
    
    .bbb-opportunities-section h3,
    .bbb-queue-section h3,
    .bbb-completed-section h3 {
        font-size: 20px;
    }
    
    .bbb-opportunity-content h4 {
        font-size: 18px;
    }
    
    .bbb-opportunity-icon {
        width: 60px;
        height: 60px;
        font-size: 24px;
    }
    
    .bbb-dashboard-content {
        padding: 20px 10px;
    }
}

/* Print Styles */
@media print {
    .bbb-dashboard-header,
    .bbb-app-actions,
    .bbb-btn {
        display: none !important;
    }
    
    .bbb-card,
    .bbb-opportunity-card,
    .bbb-application-card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
    
    .bbb-dashboard-page {
        background: white;
    }
}

