/* MARKETPRIME: UTILITIES CSS - Based on Market Prime Design System */

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    min-height: 100vh;
}

/* Header - matching audit tool header style */
.landing-header {
    text-align: center;
    margin-bottom: 5px;
    padding-bottom: 20px;
    border-bottom: 3px solid #dc3545;
}

.landing-header h1 {
    font-size: 2rem;
    color: #000;
    margin-bottom: 10px;
    font-weight: 700;
}

.landing-header .subtitle {
    color: #666;
    font-size: 1rem;
    margin-bottom: 0;
}

/* Section styling - matching audit tool sections */
.landing-section {
    margin-bottom: 50px;
    padding-top: 40px;
    border-top: 2px solid #e9ecef;
}

.landing-section:first-of-type {
    border-top: none;
    padding-top: 0;
}

.landing-section h2 {
    text-align: center;
    font-size: 2rem;
    color: #000;
    margin-bottom: 30px;
    font-weight: 600;
}

/* About grid - two column layout like upload section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 30px;
}

.about-visual {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.about-content h3 {
    color: #000;
    font-size: 1.4rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.about-content p {
    color: #666;
    margin-bottom: 20px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.about-content h4 {
    color: #000;
    font-size: 1.1rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.about-content ul {
    margin: 15px 0;
    padding-left: 20px;
}

.about-content li {
    margin-bottom: 5px;
    font-size: 0.9rem;
}

/* File upload area */
.file-upload-area {
    border: 2px dashed #dc3545;
    border-radius: 8px;
    padding: 30px;
    text-align: center;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
}

.file-upload-area:hover {
    background: #fff5f5;
    border-color: #c82333;
}

.file-upload-area.dragover {
    background: #fff0f0;
    border-color: #c82333;
}

.file-input {
    display: none;
}

.upload-icon {
    font-size: 2.5rem;
    color: #dc3545;
    margin-bottom: 15px;
}

.upload-text {
    color: #333;
    font-size: 1rem;
    margin-bottom: 10px;
    font-weight: 500;
}

.upload-hint {
    color: #666;
    font-size: 0.85rem;
}

/* Portfolio selection */
.portfolio-selection {
    display: none;
    margin-top: 20px;
}

.portfolio-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    background: white;
    margin-bottom: 20px;
}

.portfolio-item {
    display: flex;
    align-items: center;
    padding: 12px;
    margin-bottom: 8px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

.portfolio-item:hover {
    background: #e9ecef;
}

.portfolio-item:last-child {
    margin-bottom: 0;
}

.portfolio-checkbox {
    margin-right: 12px;
    width: 16px;
    height: 16px;
    accent-color: #dc3545;
}

.portfolio-item label {
    flex: 1;
    cursor: pointer;
    font-size: 1rem;
    color: #333;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    background-color: #dc3545;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn:hover {
    background-color: #c82333;
    transform: translateY(-1px);
    color: white;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn:disabled:hover {
    background-color: #dc3545;
}

.download-btn {
    width: 100%;
    padding: 16px;
    font-size: 1.1rem;
    margin-top: 20px;
}

/* Loading state */
.loading {
    display: none;
    text-align: center;
    padding: 40px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #dc3545;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.loading p {
    color: #666;
    font-size: 1rem;
}

/* Alerts */
.alert {
    padding: 16px 20px;
    margin-bottom: 20px;
    border-radius: 6px;
    font-weight: 500;
    border-left: 4px solid;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border-left-color: #28a745;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border-left-color: #dc3545;
}

/* Results section */
.results {
    display: none;
    margin-top: 30px;
    padding: 30px;
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.results h3 {
    color: #000;
    margin-bottom: 20px;
    font-size: 1.3rem;
    font-weight: 600;
}

.results p {
    color: #666;
    margin-bottom: 10px;
    font-size: 1rem;
}

.results strong {
    color: #000;
}

.campaign-list {
    list-style: none;
    padding: 0;
    margin-top: 20px;
    max-height: 200px;
    overflow-y: auto;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 15px;
}

.campaign-list li {
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    color: #333;
    font-size: 0.9rem;
}

.campaign-list li:last-child {
    border-bottom: none;
}

/* Achievements - using feature grid style */
.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
}

.achievement-card {
    text-align: center;
    padding: 25px;
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: transform 0.2s ease;
}

.achievement-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.achievement-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.achievement-card h4 {
    color: #000;
    font-size: 1.1rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.achievement-card p {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Responsive design */
@media (max-width: 1024px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .landing-header {
        margin-bottom: 5px;
    }
    
    .landing-header h1 {
        font-size: 1.8rem;
    }
    
    .landing-section h2 {
        font-size: 1.5rem;
    }
    
    .about-content h3 {
        font-size: 1.2rem;
    }
    
    .about-content p {
        font-size: 0.85rem;
    }
    
    .about-content h4 {
        font-size: 1rem;
    }
    
    .about-content li {
        font-size: 0.8rem;
    }
    
    .file-upload-area {
        padding: 25px 15px;
    }
    
    .upload-icon {
        font-size: 2rem;
    }
    
    .upload-text {
        font-size: 0.9rem;
    }
    
    .upload-hint {
        font-size: 0.75rem;
    }
    
    .portfolio-list {
        max-height: 250px;
    }
    
    .portfolio-item {
        padding: 10px;
    }
    
    .portfolio-item label {
        font-size: 0.9rem;
    }
    
    .btn {
        font-size: 0.9rem;
        padding: 10px 20px;
    }
    
    .download-btn {
        font-size: 1rem;
        padding: 14px;
    }
    
    .results {
        padding: 20px;
    }
    
    .results h3 {
        font-size: 1.1rem;
    }
    
    .results p {
        font-size: 0.9rem;
    }
    
    .campaign-list {
        max-height: 150px;
    }
    
    .campaign-list li {
        font-size: 0.8rem;
    }
    
    .achievements-grid {
        grid-template-columns: 1fr;
    }
    
    .achievement-card h4 {
        font-size: 1rem;
    }
    
    .achievement-card p {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .landing-header h1 {
        font-size: 1.5rem;
    }
    
    .container {
        padding: 15px 10px;
    }
    
    .about-visual {
        padding: 20px;
    }
    
    .file-upload-area {
        padding: 20px 15px;
    }
    
    .upload-icon {
        font-size: 1.8rem;
    }
}


.portfolio-item label {
    flex: 1;
    cursor: pointer;
    font-size: 1rem;
    color: #333;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    background-color: #dc3545;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn:hover {
    background-color: #c82333;
    transform: translateY(-1px);
    color: white;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn:disabled:hover {
    background-color: #dc3545;
}

.download-btn {
    width: 100%;
    padding: 16px;
    font-size: 1.1rem;
    margin-top: 20px;
}

/* Loading state */
.loading {
    display: none;
    text-align: center;
    padding: 40px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #dc3545;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.loading p {
    color: #666;
    font-size: 1rem;
}

/* Alerts */
.alert {
    padding: 16px 20px;
    margin-bottom: 20px;
    border-radius: 6px;
    font-weight: 500;
    border-left: 4px solid;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border-left-color: #28a745;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border-left-color: #dc3545;
}

/* Results section */
.results {
    display: none;
    margin-top: 30px;
    padding: 30px;
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.results h3 {
    color: #000;
    margin-bottom: 20px;
    font-size: 1.3rem;
    font-weight: 600;
}

.results p {
    color: #666;
    margin-bottom: 10px;
    font-size: 1rem;
}

.results strong {
    color: #000;
}

.campaign-list {
    list-style: none;
    padding: 0;
    margin-top: 20px;
    max-height: 200px;
    overflow-y: auto;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 15px;
}

.campaign-list li {
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    color: #333;
    font-size: 0.9rem;
}

.campaign-list li:last-child {
    border-bottom: none;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 20px 15px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .step {
        padding: 20px;
        margin-bottom: 30px;
    }
    
    .step-title {
        font-size: 1.1rem;
    }
    
    .step-number {
        width: 28px;
        height: 28px;
        font-size: 0.9rem;
    }
    
    .step p {
        font-size: 0.9rem;
    }
    
    .file-upload-area {
        padding: 30px 20px;
    }
    
    .upload-icon {
        font-size: 2.5rem;
    }
    
    .upload-text {
        font-size: 1rem;
    }
    
    .upload-hint {
        font-size: 0.8rem;
    }
    
    .portfolio-list {
        max-height: 250px;
    }
    
    .portfolio-item {
        padding: 10px;
    }
    
    .portfolio-item label {
        font-size: 0.9rem;
    }
    
    .btn {
        font-size: 0.9rem;
        padding: 10px 20px;
    }
    
    .download-btn {
        font-size: 1rem;
        padding: 14px;
    }
    
    .results {
        padding: 20px;
    }
    
    .results h3 {
        font-size: 1.1rem;
    }
    
    .results p {
        font-size: 0.9rem;
    }
    
    .campaign-list {
        max-height: 150px;
    }
    
    .campaign-list li {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.8rem;
    }
    
    .container {
        padding: 15px 10px;
    }
    
    .step {
        padding: 15px;
    }
    
    .file-upload-area {
        padding: 25px 15px;
    }
    
    .upload-icon {
        font-size: 2rem;
    }
}