:root,
::backdrop {
    --bg: #fff;
    --accent-bg: #f5f7ff;
    --text: #212121;
    --text-light: #585858;
    --border: #898ea4;
    --accent: #584ff2;
    --accent-hover: #7972f4;
    --accent-text: var(--bg);
    --code: #d81b60;
    --preformatted: #444;
    --marked: #7972f4;
    --disabled: #efefef;
}

/* Ensure light mode overrides for key elements */
body {
    color: var(--text);
    background-color: var(--bg);
}

a,
a:visited {
    color: var(--accent);
}

a:hover {
    text-decoration: none;
}

/* Other elements following the same pattern */
header {
    background-color: var(--accent-bg);
    border-bottom: 1px solid var(--border);
    color: var(--text);
}

footer {
    color: var(--text-light);
    border-top: 1px solid var(--border);
}

/* Continue overriding other elements as needed... */

/* Specific overrides for images and videos that might be impacted by dark mode settings */
img,
video {
    opacity: 1;
    /* Remove any opacity settings from dark mode */
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.company-name {
    color: white;
}

.button-red {
    --accent: #c41010;
    --accent-hover: #e42222;
    --accent-text: white;
}

/* Logo and header styles */
.logo-image {
    width: 35px;
    margin-right: 0.5em;
}

.logo-title {
    margin: 0;
    font-size: 2em;
}

.logo-clickable {
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.logo-clickable:hover {
    opacity: 0.8;
}

/* Message styles */
.message {
    padding: 10px;
    margin: 10px 0;
    border-radius: 4px;
}

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

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

.message-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* Form styles */
.code-input {
    font-size: 1.5em;
    letter-spacing: 0.2em;
    text-align: center;
    width: 200px;
    padding: 10px;
}

.help-section {
    margin-top: 2em;
    padding-top: 1em;
    border-top: 1px solid #ccc;
}

.resend-button {
    background-color: #f8f9fa;
    border: 1px solid #ccc;
    color: #666;
    cursor: pointer;
}

.resend-button:hover:not(:disabled) {
    background-color: #e9ecef;
}

.resend-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Profile page styles */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 8px;
    margin: 10px 0;
}

.info-grid p {
    margin: 5px 0;
}

/* .health-summary {
    margin: 15px 0;
}

.health-summary h3 {
    margin-top: 20px;
    margin-bottom: 10px;
    color: #333;
} */

/* Loading State Styles */
.loading-state {
    text-align: center;
    padding: 2rem;
    background-color: #f8f9fa;
    border-radius: 8px;
    margin: 20px 0;
    border: 1px solid #e9ecef;
}

.loading-state .spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--accent);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.5rem;
}

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

.loading-state p {
    color: #495057;
    margin-bottom: 0.5rem;
}

.loading-state strong {
    color: var(--accent);
    font-size: 1.1em;
}

.loading-state small {
    color: #6c757d;
    opacity: 0.9;
    line-height: 1.4;
}

.no-data {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    padding: 20px;
    margin: 20px 0;
    text-align: center;
}

/* .settings-section {
    margin: 15px 0;
}

.settings-section h3 {
    margin-top: 25px;
    margin-bottom: 10px;
    color: #333;
} */

.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    border: none;
    cursor: pointer;
}

.button:hover {
    background-color: #0056b3;
}

.button-secondary {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
}

.button-secondary:hover {
    background-color: #545b62;
}

/* Details/summary styles - keep Simple.css defaults for home page, add specific styling for profile */
/* .profile-page details {
    margin: 20px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
}

.profile-page summary {
    font-weight: bold;
    cursor: pointer;
    margin-bottom: 10px;
}

.profile-page details[open] summary {
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
} */

/* Logout form styles */
.logout-form {
    margin: 20px 0;
}

.logout-form button[type="submit"] {
    background-color: #dc3545;
    color: white;
    margin-right: 10px;
}

.logout-form button[type="submit"]:hover {
    background-color: #c82333;
}

.logout-form a {
    padding: 8px 16px;
    text-decoration: none;
    color: #6c757d;
    border: 1px solid #6c757d;
    border-radius: 4px;
    display: inline-block;
}

.logout-form a:hover {
    background-color: #f8f9fa;
}

/* Progress tracking styles */
/* .progress-steps {
    margin: 20px 0;
}

.step {
    display: flex;
    align-items: center;
    margin: 10px 0;
    padding: 8px 12px;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.step.completed {
    background-color: #d4edda;
    color: #155724;
}

.step.in-progress {
    background-color: #fff3cd;
    color: #856404;
    animation: pulse 2s ease-in-out infinite alternate;
}

.step.error {
    background-color: #f8d7da;
    color: #721c24;
}

.step-icon {
    margin-right: 12px;
    font-size: 1.2em;
    min-width: 20px;
}

.step-text {
    flex: 1;
    font-weight: 500;
}

@keyframes pulse {
    from {
        opacity: 1;
    }
    to {
        opacity: 0.6;
    }
} */

/* .progress-complete {
    text-align: center;
    padding: 20px;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    margin: 20px 0;
}

.progress-complete h3 {
    color: #155724;
    margin-bottom: 10px;
}

.progress-summary {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.progress-summary .step {
    margin: 0;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.9em;
} */

/* .progress-error {
    text-align: center;
    padding: 20px;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin: 20px 0;
}

.progress-error h3 {
    color: #721c24;
    margin-bottom: 10px;
} */

.error-details {
    background-color: #f1f3f4;
    border: 1px solid #dadce0;
    border-radius: 4px;
    padding: 10px;
    margin: 15px 0;
    text-align: left;
}

.error-details code {
    color: #d73a49;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9em;
}

.pipeline-complete {
    text-align: center;
    padding: 20px;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    margin: 20px 0;
}

.pipeline-complete h3 {
    color: #155724;
    margin-bottom: 15px;
}

/* .completion-summary {
    margin: 15px 0;
    padding: 10px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 4px;
} */

/* .summary-item {
    margin: 5px 0;
    color: #155724;
} */

.next-steps {
    margin-top: 20px;
}

.action-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
    flex-wrap: wrap;
}

.btn-primary {
    background-color: var(--accent);
    color: var(--accent-text);
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-primary:hover {
    background-color: var(--accent-hover);
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-secondary:hover {
    background-color: #545b62;
}

/* .mt-4 {
    margin-top: 1.5rem;
} */

/* Data Connection Progress Styles */
.connection-info {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
}

.connection-info h3 {
    color: var(--accent);
    margin-bottom: 15px;
}

.connection-info ul {
    list-style: none;
    padding: 0;
}

.connection-info li {
    padding: 8px 0;
    border-bottom: 1px solid #e9ecef;
}

.connection-info li:last-child {
    border-bottom: none;
}

.note {
    text-align: center;
    color: #6c757d;
    font-style: italic;
    margin-top: 30px;
}
