/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-blue: #4A90E2;
    --primary-green: #50C878;
    --accent-orange: #f59e0b;
    --accent-purple: #8b5cf6;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --background: #f9fafb;
    --white: #ffffff;
    --error: #ef4444;
    --success: #50C878;
    --border: #e5e7eb;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Loading Overlay */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--white);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.spinner-small {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--white);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-green) 100%);
    color: var(--white);
    padding: 20px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 28px;
    font-weight: 700;
}

.trust-badge {
    background-color: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-green) 100%);
    padding: 60px 0;
    color: var(--white);
}

.product-info {
    max-width: 900px;
    margin: 0 auto;
}

.general-info {
    text-align: center;
}

.general-info h1 {
    font-size: 42px;
    margin-bottom: 20px;
    font-weight: 700;
}

.general-info p {
    font-size: 18px;
    opacity: 0.9;
}

.product-card {
    background-color: var(--white);
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    color: var(--text-primary);
}

.product-header {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 20px;
}

.product-image {
    width: 120px;
    height: 80px;
    object-fit: contain;
    border-radius: 8px;
}

.product-details h1 {
    font-size: 32px;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.product-description {
    color: var(--text-secondary);
    font-size: 16px;
}

.product-highlight {
    margin-bottom: 20px;
}

.highlight-badge {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    color: var(--white);
}

.product-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.feature-icon {
    color: var(--primary-green);
    font-size: 20px;
    font-weight: bold;
}

/* Application Section */
.application-section {
    padding: 60px 0;
}

.application-section .container {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
    align-items: start;
}

/* Form Container */
.form-container {
    background-color: var(--white);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.form-header {
    margin-bottom: 30px;
}

.form-header h2 {
    font-size: 32px;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.form-header p {
    color: var(--text-secondary);
    font-size: 16px;
}

/* Form Sections */
.form-section {
    margin-bottom: 35px;
}

.form-section h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: var(--primary-blue);
    border-bottom: 2px solid var(--primary-blue);
    padding-bottom: 10px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 14px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s ease;
    background-color: var(--white);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #9ca3af;
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 15px;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    cursor: pointer;
}

.checkbox-group label {
    font-size: 14px;
    color: var(--text-secondary);
    cursor: pointer;
    line-height: 1.5;
}

/* Submit Button */
.submit-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, #3b82f6 100%);
    color: var(--white);
    border: none;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(30, 58, 138, 0.3);
}

.submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Sidebar */
.sidebar {
    position: sticky;
    top: 20px;
}

.benefit-card {
    background-color: var(--white);
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 20px;
}

.benefit-card h3 {
    font-size: 22px;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.benefits-list {
    list-style: none;
}

.benefits-list li {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.benefits-list .icon {
    font-size: 24px;
    flex-shrink: 0;
}

.benefits-list strong {
    display: block;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.benefits-list p {
    color: var(--text-secondary);
    font-size: 14px;
}

.trust-indicators {
    background-color: var(--white);
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.trust-indicators h4 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.partner-logos {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.partner-logo {
    background-color: var(--background);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 14px;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-content {
    background-color: var(--white);
    border-radius: 16px;
    padding: 40px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.success-icon {
    width: 80px;
    height: 80px;
    background-color: var(--success);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    margin: 0 auto 20px;
}

.error-icon {
    width: 80px;
    height: 80px;
    background-color: var(--error);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    margin: 0 auto 20px;
}

.modal-content h2 {
    font-size: 28px;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.modal-content p {
    color: var(--text-secondary);
    margin-bottom: 10px;
    font-size: 16px;
}

.btn-primary {
    padding: 12px 30px;
    background: linear-gradient(135deg, var(--primary-blue) 0%, #3b82f6 100%);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(30, 58, 138, 0.3);
}

/* Footer */
.footer {
    background-color: var(--text-primary);
    color: var(--white);
    padding: 30px 0;
    margin-top: 60px;
    text-align: center;
}

.footer-links {
    margin-top: 15px;
    display: flex;
    justify-content: center;
    gap: 30px;
}

.footer-links a {
    color: var(--white);
    text-decoration: none;
    font-size: 14px;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 968px) {
    .application-section .container {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
    }
    
    .product-header {
        flex-direction: column;
    }
    
    .form-container {
        padding: 30px 20px;
    }
}

@media (max-width: 640px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .general-info h1 {
        font-size: 32px;
    }
    
    .product-details h1 {
        font-size: 24px;
    }
    
    .header-content {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .trust-badge {
        font-size: 12px;
        padding: 6px 12px;
    }
}

/* New Styles for Simplified Layout */
.agent-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 12px;
}

.agent-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.agent-name {
    font-size: 16px;
    font-weight: 600;
}

.product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.product-image-section {
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-product-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    border-radius: 8px;
}

.placeholder-image {
    width: 100%;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 80px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
}

.benefits-section {
    padding: 20px;
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.benefits-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--border);
}

.tab-btn {
    padding: 10px 20px;
    border: none;
    background: none;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: var(--primary-blue);
    border-bottom-color: var(--primary-blue);
}

.benefits-content {
    padding: 20px 0;
}

.benefit-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
    font-size: 15px;
    line-height: 1.6;
}

.benefit-icon {
    color: var(--success);
    font-weight: bold;
    font-size: 18px;
    flex-shrink: 0;
    min-width: 20px;
}

.benefit-text {
    flex: 1;
    color: var(--text-primary);
    word-wrap: break-word;
}

/* Simplified Form Styles */
.form-container {
    max-width: 600px;
    margin: 0 auto;
}

.application-form .form-group input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
}

.application-form .form-group input:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 20px;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    flex-shrink: 0;
}

.checkbox-group label {
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-secondary);
}

#termsLabel a {
    color: var(--primary-blue);
    text-decoration: underline;
}

@media (max-width: 968px) {
    .product-layout {
        grid-template-columns: 1fr;
    }
}
