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


* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

/* Main Container */
.container {
    max-width: 1000px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Header */
header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 30px;
    text-align: center;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.95;
    font-weight: 300;
}

/* Settings Panel */
.settings-panel {
    background: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
}
.settings-panel {
    display: none;
}

.settings-toggle {
    width: 100%;
    padding: 15px 30px;
    background: #f8f9fa;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    text-align: left;
    transition: background 0.3s;
}

.settings-toggle:hover {
    background: #e9ecef;
}

.settings-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
    padding: 0 30px;
}

.settings-content.active {
    max-height: 600px;
    padding: 20px 30px 30px;
    overflow-y: auto;
}

.settings-content h3 {
    margin-bottom: 20px;
    color: #667eea;
}

/* Tabs */
.tabs {
    display: flex;
    background: #f8f9fa;
    border-bottom: 2px solid #e0e0e0;
}

.tab-btn {
    flex: 1;
    padding: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 500;
    color: #666;
    transition: all 0.3s;
    position: relative;
}

.tab-btn:hover {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
}

.tab-btn.active {
    color: #667eea;
    background: white;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

/* Tab Content */
.tab-content {
    display: none;
    padding: 40px 30px;
    animation: slideIn 0.4s ease;
}

.tab-content.active {
    display: block;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

.tab-content h2 {
    color: #667eea;
    margin-bottom: 25px;
    font-size: 1.8rem;
}

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

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

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #444;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
select,
textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s, box-shadow 0.3s;
}

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

textarea {
    resize: vertical;
    min-height: 100px;
}

small {
    display: block;
    margin-top: 5px;
    color: #888;
    font-size: 0.85rem;
}

/* Buttons */
.btn-primary,
.btn-save,
.btn-download {
    padding: 14px 30px;
    border: none;
    border-radius: 8px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    width: 100%;
    justify-content: center;
    margin-top: 10px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.btn-save {
    background: #28a745;
    color: white;
}

.btn-save:hover {
    background: #218838;
    transform: translateY(-2px);
}

.btn-download {
    background: #17a2b8;
    color: white;
    font-size: 0.95rem;
}

.btn-download:hover {
    background: #138496;
}

/* Output Box */
.output-box {
    margin-top: 30px;
    padding: 25px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 2px solid #e0e0e0;
}

.output-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.output-header h3 {
    color: #667eea;
}

.resume-content,
.analysis-content {
    background: white;
    padding: 30px;
    border-radius: 8px;
    line-height: 1.8;
    white-space: pre-wrap;
    font-size: 0.95rem;
}

/* Analysis Sections */
.analysis-section {
    margin-bottom: 25px;
    padding: 20px;
    background: white;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.analysis-section h4 {
    color: #667eea;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.analysis-section p,
.analysis-section ul {
    color: #555;
    line-height: 1.7;
}

.analysis-section ul {
    margin-left: 20px;
    margin-top: 10px;
}

.analysis-section li {
    margin-bottom: 8px;
}

/* Loading Spinner */
.spinner-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 9999;
}

.spinner-overlay.active {
    display: flex;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.spinner-overlay p {
    color: white;
    margin-top: 20px;
    font-size: 1.1rem;
}

/* Footer */
footer {
    text-align: center;
    padding: 25px;
    background: #f8f9fa;
    color: #666;
    font-size: 0.95rem;
    border-top: 1px solid #e0e0e0;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    header h1 {
        font-size: 1.8rem;
    }

    .subtitle {
        font-size: 0.95rem;
    }

    .container {
        border-radius: 15px;
    }

    .tab-content {
        padding: 25px 20px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .tabs {
        flex-direction: column;
    }

    .tab-btn {
        border-bottom: 1px solid #e0e0e0;
    }

    .output-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
}

/* Success/Error Messages */
.message {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Info Box */
.info-box {
    background: #e7f3ff;
    border: 1px solid #b3d9ff;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.info-box > strong {
    display: block;
    color: #0056b3;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.info-highlight {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 12px;
    margin: 15px 0;
    color: #856404;
    font-weight: 500;
}

.step-box {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 15px;
    margin: 15px 0;
}

.step-box strong {
    color: #667eea;
    display: block;
    margin-bottom: 10px;
    font-size: 1rem;
}

.step-box ul,
.step-box ol {
    margin: 10px 0 0 25px;
    color: #555;
}

.step-box li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.step-box p {
    margin: 5px 0;
    color: #555;
}

.step-box a {
    color: #667eea;
    text-decoration: none;
    word-break: break-all;
}

.step-box a:hover {
    text-decoration: underline;
}

.info-box code {
    background: #667eea;
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    font-weight: 600;
}

.security-note {
    margin-top: 15px;
    padding: 10px;
    background: #d4edda;
    border-radius: 6px;
    color: #155724;
    font-size: 0.9rem;
    text-align: center;
}

/* API Status Indicators */
.api-status {
    margin: 15px 0;
}

.status-indicators {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.status-item {
    padding: 10px 15px;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 500;
}

.status-item.configured {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-item.not-configured {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}
