/* ATlas Shared Styles */
* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --text-primary: #171717;
    --text-secondary: #525252;
    --text-tertiary: #737373;
    --bg-green: #e0f2e9;
    --surface: rgba(255, 255, 255, 0.85);
    --border: #e5e5e5;
    --btn-primary: #171717;
    --btn-primary-hover: #404040;
}

body {
    font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
    background:
        repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.03) 2px, rgba(0, 0, 0, 0.03) 4px),
        radial-gradient(ellipse 800px 400px at 20% 25%, rgba(255, 255, 255, 0.4) 0%, transparent 50%),
        radial-gradient(ellipse 600px 300px at 80% 60%, rgba(255, 255, 255, 0.35) 0%, transparent 50%),
        radial-gradient(ellipse at 15% 30%, rgba(34, 139, 58, 0.15) 0%, transparent 60%),
        radial-gradient(ellipse at 85% 70%, rgba(22, 163, 74, 0.12) 0%, transparent 60%),
        linear-gradient(135deg, #e0f2e9 0%, #c8f0d8 25%, #a8e6c8 50%, #88d9b8 75%, #6bcfa8 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
}

/* Layout */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}

.container-narrow {
    max-width: 600px;
    margin: 0 auto;
    padding: 2rem;
}

/* Cards */
.card {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1rem;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

/* Typography */
h1 { margin-bottom: 0.5rem; }
h2 { margin-bottom: 0.75rem; }
.subtitle { color: var(--text-tertiary); margin-bottom: 1.5rem; font-size: 0.9rem; }

/* Buttons */
.btn {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 8px;
    font-size: 0.875rem;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.15s;
}

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

.btn-secondary {
    background: #f5f5f5;
    color: var(--text-primary);
    border: 1px solid var(--border);
}
.btn-secondary:hover { background: #e5e5e5; }

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.8125rem;
}

.btn-danger { background: #dc2626; color: white; }
.btn-danger:hover { background: #b91c1c; }

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Forms */
input[type="text"], input[type="password"], input[type="email"], input[type="url"], input[type="number"],
select, textarea {
    padding: 0.5rem 0.75rem;
    border: 1px solid #d4d4d4;
    border-radius: 6px;
    font-size: 0.875rem;
    font-family: inherit;
    width: 100%;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--btn-primary);
    box-shadow: 0 0 0 2px rgba(23, 23, 23, 0.1);
}

textarea { resize: vertical; }

label {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 0.25rem;
}

/* Status messages */
.status-success { color: #16a34a; }
.status-error { color: #dc2626; }
.status-info { color: #2563eb; }

/* Auth section (shared across manage, feed-settings, etc) */
.auth-section {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1rem;
    backdrop-filter: blur(4px);
}

/* Toggle switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 28px;
    flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 28px;
}
.toggle-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}
input:checked + .toggle-slider { background-color: #171717; }
input:checked + .toggle-slider:before { transform: translateX(20px); }

/* Responsive */
@media (max-width: 768px) {
    .container, .container-narrow { padding: 1rem; }
    body { font-size: 0.9375rem; }
}
