/* Base styles shared across all pages */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

header {
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    padding: 0.75rem 0;
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    white-space: nowrap;
}

.logo-mark {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: linear-gradient(135deg, #3b82f6, #22d3ee);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 900;
    font-size: 0.9rem;
    flex-shrink: 0;
    line-height: 1;
}

.logo-icon {
    width: 40px;
    height: 40px;
    object-fit: contain;
    display: block;
    flex-shrink: 0;
}

.nav-links {
    display: flex;
    gap: 1rem;
    align-items: center;
}

/* Override for dashboard pages - handled in dashboard.css */
header .nav-links {
    /* Styles handled in dashboard.css */
}

.nav-links a {
    color: #333;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.nav-links a:hover {
    background-color: #f0f0f0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.form-container {
    max-width: 500px;
    margin: 2rem auto;
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.form-container h1 {
    margin-bottom: 1.5rem;
    color: #333;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #555;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: #666;
    font-size: 0.875rem;
}

/* Animated gradient background for buttons */
@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Global animated button styling */
button,
.btn,
.btn-primary,
.btn-secondary,
a.btn,
a.btn-primary,
a.btn-secondary,
input[type="submit"],
input[type="button"],
input[type="reset"] {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8, #3b82f6);
    background-size: 200% 200%;
    animation: gradient-shift 3s ease infinite;
    color: #ffffff !important;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-decoration: none;
    display: inline-block;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

button:hover,
.btn:hover,
.btn-primary:hover,
.btn-secondary:hover,
a.btn:hover,
a.btn-primary:hover,
a.btn-secondary:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

button:active,
.btn:active,
.btn-primary:active,
.btn-secondary:active,
a.btn:active,
a.btn-primary:active,
a.btn-secondary:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
    transform: translateY(0);
}

button:disabled,
.btn:disabled,
.btn-primary:disabled,
.btn-secondary:disabled,
input[type="submit"]:disabled,
input[type="button"]:disabled,
input[type="reset"]:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    animation: none;
    box-shadow: none;
    background: linear-gradient(135deg, #9ca3af, #6b7280, #9ca3af);
}

.form-links {
    text-align: center;
}

.form-links a {
    color: #007bff;
    text-decoration: none;
    display: inline-block;
}

.form-links a:hover {
    text-decoration: underline;
}

.errors {
    background-color: #f8d7da;
    color: #721c24;
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
    border: 2px solid #f5c6cb;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.error {
    margin-bottom: 0.75rem;
    padding: 0.5rem;
    background-color: rgba(255, 255, 255, 0.3);
    border-left: 4px solid #dc3545;
    padding-left: 0.75rem;
    font-weight: 500;
}

.error:last-child {
    margin-bottom: 0;
}

.error pre {
    margin-top: 0.5rem;
    padding: 0.75rem;
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow-x: auto;
    font-size: 0.85em;
    line-height: 1.4;
}

.messages {
    background-color: #d4edda;
    color: #155724;
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.message {
    margin-bottom: 0.5rem;
}

footer {
    background-color: #fff;
    border-top: 1px solid #e0e0e0;
    padding: 2rem 0;
    text-align: center;
    color: #666;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

footer p {
    margin: 0;
    font-size: 0.9rem;
}

/* Check Email Page Styles */
.check-email-container {
    text-align: center;
    max-width: 600px;
    margin: 2rem auto;
}

.check-email-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    line-height: 1;
}

.check-email-container h1 {
    margin-bottom: 1rem;
    color: #333;
}

.check-email-intro {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.check-email-instructions {
    background-color: #f8f9fa;
    border-left: 4px solid #3b82f6;
    padding: 1.5rem;
    margin-bottom: 2rem;
    text-align: left;
    border-radius: 4px;
}

.check-email-instructions h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: #333;
}

.check-email-instructions ol {
    margin: 0;
    padding-left: 1.5rem;
    color: #555;
}

.check-email-instructions li {
    margin-bottom: 0.75rem;
}

.check-email-warning {
    background-color: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 4px;
    padding: 1rem;
    margin-bottom: 2rem;
    color: #856404;
}

.check-email-actions {
    margin-top: 2rem;
}

.check-email-help-text {
    color: #666;
    margin-bottom: 1rem;
}

.check-email-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.check-email-buttons .btn-primary {
    color: #fff !important;
}

.check-email-link {
    color: #3b82f6;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.check-email-link:hover {
    background-color: #f0f0f0;
    text-decoration: none;
}

.check-email-footer {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e0e0e0;
}

.check-email-footer p {
    color: #999;
    font-size: 0.9rem;
    margin: 0;
}

/* Terms and Privacy Checkbox Styles */
.terms-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    font-weight: normal;
    margin-bottom: 0;
    padding: 0.75rem;
    background-color: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.terms-checkbox-label input[type="checkbox"] {
    margin-top: 0.25rem;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #3b82f6;
}

.terms-checkbox-label span {
    flex: 1;
    line-height: 1.5;
    color: #555;
}

.terms-checkbox-label a {
    color: #3b82f6;
    text-decoration: underline;
}

.terms-checkbox-label a:hover {
    color: #2563eb;
}

.terms-checkbox-label:hover {
    background-color: #f0f0f0;
    border-color: #3b82f6;
}

/* Privacy and Terms Page Styles */
.container h1 {
    margin-bottom: 0.5rem;
    color: #333;
}

.container h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #333;
    font-size: 1.5rem;
}

.container h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #444;
    font-size: 1.2rem;
}

.container section {
    margin-bottom: 2rem;
}

.container ul,
.container ol {
    margin: 1rem 0;
    padding-left: 2rem;
    line-height: 1.8;
}

.container li {
    margin-bottom: 0.5rem;
}

.container p {
    margin-bottom: 1rem;
    line-height: 1.7;
    color: #555;
}

.container a {
    color: #3b82f6;
    text-decoration: underline;
}

.container a:hover {
    color: #2563eb;
}
