/* ============================================================
   UpSnap — Main Stylesheet
   ============================================================ */

/* ---- CSS Variables ---- */
:root {
    --bg:          #080e17;
    --card:        #111c2a;
    --card-hover:  #162233;
    --border:      #1e3047;
    --accent:      #5b8fff;
    --accent-2:    #a78bfa;
    --accent-dark: #4070ee;
    --accent-glow: rgba(91,143,255,0.15);
    --grad:        linear-gradient(135deg, #5b8fff 0%, #a78bfa 100%);
    --text:        #dde6f5;
    --text-muted:  #6a85a6;
    --text-dim:    #3d5878;
    --success:     #22c55e;
    --error:       #ef4444;
    --warning:     #f59e0b;
    --radius:      10px;
    --radius-lg:   16px;
    --shadow:      0 4px 24px rgba(0,0,0,0.4);
    --shadow-lg:   0 8px 48px rgba(0,0,0,0.6);
    --transition:  0.2s ease;
}

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; display: block; }

input, textarea, select, button { font-family: inherit; }

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

.main-content {
    flex: 1;
    padding-bottom: 3rem;
}

/* ---- Navbar ---- */
.navbar {
    background: rgba(26,38,52,0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.25rem;
    height: 60px;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 800;
    font-size: 1.2rem;
    text-decoration: none;
    letter-spacing: -0.03em;
    flex-shrink: 0;
}
.nav-logo svg { color: var(--accent); }
.nav-logo:hover { text-decoration: none; }
.logo-text {
    background: var(--grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    list-style: none;
    margin-left: auto;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.75rem;
    border-radius: var(--radius);
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: color var(--transition), background var(--transition);
    background: none;
    border: none;
    cursor: pointer;
    white-space: nowrap;
}
.nav-link:hover { color: var(--text); background: rgba(255,255,255,0.05); text-decoration: none; }

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
    margin-left: auto;
}
.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

/* Dropdown */
.nav-dropdown { position: relative; }
.nav-user-btn { cursor: pointer; }

.nav-dropdown-menu {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    min-width: 160px;
    box-shadow: var(--shadow);
    overflow: hidden;
}
.nav-dropdown-menu.open { display: block; }
.nav-dropdown-menu a {
    display: block;
    padding: 0.6rem 1rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: background var(--transition), color var(--transition);
}
.nav-dropdown-menu a:hover {
    background: var(--card-hover);
    color: var(--text);
    text-decoration: none;
}

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.25rem;
    background: var(--grad);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity var(--transition), transform var(--transition), box-shadow var(--transition);
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 2px 12px rgba(91,143,255,0.3);
}
.btn:hover { opacity: 0.9; text-decoration: none; color: #fff; transform: translateY(-1px); box-shadow: 0 4px 20px rgba(91,143,255,0.4); }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn-sm { padding: 0.35rem 0.85rem; font-size: 0.85rem; }
.btn-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
}
.btn-outline:hover { background: var(--card); color: var(--text); border-color: var(--accent); }
.btn-danger { background: var(--error); }
.btn-danger:hover { background: #dc2626; }
.btn-ghost {
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
    border: none;
}
.btn-ghost:hover { background: rgba(255,255,255,0.1); color: var(--text); }

/* ---- Alerts ---- */
.alert {
    border-radius: var(--radius);
    padding: 0.9rem 1.1rem;
    margin: 1rem 0;
    font-size: 0.9rem;
    line-height: 1.5;
}
.alert-success {
    background: rgba(34,197,94,0.12);
    border: 1px solid rgba(34,197,94,0.25);
    color: #86efac;
}
.alert-error {
    background: rgba(239,68,68,0.12);
    border: 1px solid rgba(239,68,68,0.25);
    color: #fca5a5;
}
.alert-info {
    background: rgba(79,142,247,0.1);
    border: 1px solid rgba(79,142,247,0.25);
    color: #93c5fd;
}
.alert-warning {
    background: rgba(245,158,11,0.1);
    border: 1px solid rgba(245,158,11,0.25);
    color: #fde68a;
}

/* ---- Cards ---- */
.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* ---- Upload Zone ---- */
.upload-section {
    padding: 3rem 0 2rem;
    text-align: center;
}

.upload-section h1 {
    font-size: clamp(1.8rem, 4vw, 3rem);
    font-weight: 900;
    letter-spacing: -0.04em;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #fff 0%, var(--accent) 50%, var(--accent-2) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.upload-section .subtitle {
    color: var(--text-muted);
    font-size: 1.05rem;
    margin-bottom: 2rem;
}

.upload-zone {
    border: 2px dashed var(--border);
    border-radius: var(--radius-lg);
    padding: 3.5rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: border-color var(--transition), background var(--transition), transform var(--transition), box-shadow var(--transition);
    background: rgba(255,255,255,0.015);
    position: relative;
    max-width: 680px;
    margin: 0 auto;
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--accent);
    background: var(--accent-glow);
    transform: translateY(-2px);
    box-shadow: 0 0 0 4px rgba(91,143,255,0.08), 0 8px 32px rgba(0,0,0,0.3);
}

.upload-zone.dragover {
    border-style: solid;
    border-color: var(--accent-2);
    box-shadow: 0 0 0 4px rgba(167,139,250,0.1), 0 8px 32px rgba(0,0,0,0.4);
}

.upload-zone input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
}

.upload-icon {
    color: var(--accent);
    margin-bottom: 1rem;
    opacity: 0.8;
}

.upload-zone h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
    color: var(--text);
}

.upload-zone p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.upload-zone .upload-hint {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
    font-size: 0.82rem;
    color: var(--text-dim);
}
.upload-zone .upload-hint span {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0.1rem 0.4rem;
    font-family: monospace;
    color: var(--text-muted);
}

/* Album selector */
.album-selector {
    max-width: 680px;
    margin: 1rem auto 0;
    text-align: left;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}
.album-selector label { color: var(--text-muted); font-size: 0.9rem; flex-shrink: 0; }
.album-selector select {
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.45rem 0.75rem;
    border-radius: var(--radius);
    font-size: 0.9rem;
    flex: 1;
    min-width: 180px;
    cursor: pointer;
    outline: none;
    transition: border-color var(--transition);
}
.album-selector select:focus { border-color: var(--accent); }

/* ---- Progress Bar ---- */
.progress-wrap {
    max-width: 680px;
    margin: 1.25rem auto 0;
    display: none;
}
.progress-wrap.visible { display: block; }
.progress-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}
.progress-bar-track {
    height: 6px;
    background: var(--border);
    border-radius: 99px;
    overflow: hidden;
}
.progress-bar-fill {
    height: 100%;
    background: var(--grad);
    border-radius: 99px;
    width: 0%;
    transition: width 0.15s ease;
    box-shadow: 0 0 8px rgba(91,143,255,0.5);
}

/* ---- Upload Result ---- */
.upload-result {
    max-width: 680px;
    margin: 1.5rem auto 0;
    display: none;
}
.upload-result.visible { display: block; }

.result-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.result-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    border-bottom: 1px solid var(--border);
}

.result-thumb {
    width: 72px;
    height: 72px;
    border-radius: var(--radius);
    object-fit: cover;
    flex-shrink: 0;
    background: var(--bg);
}

.result-meta h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
    color: var(--text);
    word-break: break-all;
}
.result-meta p { font-size: 0.82rem; color: var(--text-muted); }

.result-links {
    padding: 1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.copy-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.copy-label {
    width: 90px;
    flex-shrink: 0;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-dim);
}
.copy-input {
    flex: 1;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 0.45rem 0.7rem;
    border-radius: var(--radius);
    font-size: 0.82rem;
    font-family: monospace;
    outline: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: text;
    min-width: 0;
}
.copy-input:focus { border-color: var(--accent); }

.copy-btn {
    flex-shrink: 0;
    background: var(--accent-glow);
    border: 1px solid rgba(79,142,247,0.3);
    color: var(--accent);
    padding: 0.45rem 0.8rem;
    border-radius: var(--radius);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: background var(--transition), color var(--transition);
    white-space: nowrap;
}
.copy-btn:hover { background: var(--accent); color: #fff; }
.copy-btn.copied { background: rgba(34,197,94,0.15); border-color: rgba(34,197,94,0.3); color: var(--success); }

.result-actions {
    padding: 0.75rem 1.25rem 1.25rem;
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

/* ---- Recent Images ---- */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}
.section-header h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
}

.images-section { padding: 2rem 0; }

.images-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 0.85rem;
}

.image-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
    position: relative;
}
.image-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.image-card-thumb {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    background: var(--bg);
    display: block;
}

.image-card-info {
    padding: 0.6rem 0.75rem;
}
.image-card-info .image-name {
    font-size: 0.78rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 0.15rem;
}
.image-card-info .image-meta {
    font-size: 0.72rem;
    color: var(--text-dim);
}

.image-card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15,25,35,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity var(--transition);
}
.image-card:hover .image-card-overlay { opacity: 1; }

.image-card-overlay a,
.image-card-overlay button {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background var(--transition);
    text-decoration: none;
    font-size: 0;
}
.image-card-overlay a:hover,
.image-card-overlay button:hover { background: var(--accent); border-color: var(--accent); }
.image-card-overlay svg { width: 16px; height: 16px; }

/* ---- Dashboard ---- */
.page-header {
    padding: 2rem 0 1.5rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 2rem;
}
.page-header h1 {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: 0.25rem;
}
.page-header p { color: var(--text-muted); }

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}
.stat-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
}
.stat-card .stat-value {
    font-size: 2rem;
    font-weight: 800;
    background: var(--grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 0.25rem;
}
.stat-card .stat-label {
    font-size: 0.82rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.albums-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}
.album-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    transition: border-color var(--transition);
}
.album-card:hover { border-color: var(--accent); }
.album-card-title {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text);
    text-decoration: none;
}
.album-card-title:hover { color: var(--accent); text-decoration: none; }
.album-card-meta { font-size: 0.82rem; color: var(--text-muted); }
.album-card-actions { margin-top: auto; display: flex; gap: 0.5rem; }

/* ---- Pagination ---- */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 2rem;
}
.page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius);
    background: var(--card);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: none;
    transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.page-btn:hover, .page-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    text-decoration: none;
}

/* ---- Image Page ---- */
.image-view {
    padding: 2rem 0;
}
.image-view-wrap {
    text-align: center;
    margin-bottom: 2rem;
}
.image-view-img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: inline-block;
}
.image-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}
.info-chip {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.6rem 0.85rem;
    text-align: center;
}
.info-chip .chip-value {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text);
    display: block;
}
.info-chip .chip-label {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* ---- Gallery Page ---- */
.gallery-header {
    padding: 2rem 0 1.5rem;
}
.gallery-header h1 {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}
.gallery-header p { color: var(--text-muted); margin-top: 0.35rem; }

/* ---- Login / Register ---- */
.auth-page {
    min-height: calc(100vh - 60px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.25rem;
}
.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.auth-tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
}
.auth-tab {
    flex: 1;
    padding: 1rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    cursor: pointer;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    transition: color var(--transition), border-color var(--transition);
    margin-bottom: -1px;
}
.auth-tab.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
    background: rgba(91,143,255,0.07);
}
.auth-tab:hover:not(.active) { color: var(--text); }

.auth-form { padding: 1.75rem; display: none; }
.auth-form.active { display: block; }

/* ---- Forms ---- */
.form-group { margin-bottom: 1.1rem; }
.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 0.4rem;
}
.form-control {
    width: 100%;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.65rem 0.85rem;
    border-radius: var(--radius);
    font-size: 0.95rem;
    outline: none;
    transition: border-color var(--transition), box-shadow var(--transition);
}
.form-control:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(79,142,247,0.12);
}
.form-control::placeholder { color: var(--text-dim); }

textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

/* ---- Modal ---- */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    z-index: 200;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
}
.modal-backdrop.open { display: flex; }

.modal {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 480px;
    box-shadow: var(--shadow-lg);
    animation: modalIn 0.2s ease;
}
@keyframes modalIn {
    from { opacity: 0; transform: scale(0.95) translateY(-10px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border);
}
.modal-header h3 { font-size: 1.05rem; font-weight: 600; }
.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: var(--radius);
    transition: color var(--transition), background var(--transition);
    display: flex;
}
.modal-close:hover { color: var(--text); background: rgba(255,255,255,0.05); }

.modal-body { padding: 1.5rem; }
.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
}

/* ---- Delete / Success pages ---- */
.center-page {
    min-height: calc(100vh - 120px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.25rem;
}
.center-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    text-align: center;
    max-width: 480px;
    width: 100%;
}
.center-card .icon-wrap {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    font-size: 0;
}
.icon-wrap.success { background: rgba(34,197,94,0.15); color: var(--success); }
.icon-wrap.error   { background: rgba(239,68,68,0.15); color: var(--error); }
.center-card h2 { font-size: 1.5rem; font-weight: 700; margin-bottom: 0.5rem; }
.center-card p { color: var(--text-muted); margin-bottom: 1.5rem; }

/* ---- Empty state ---- */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-muted);
}
.empty-state svg { color: var(--text-dim); margin: 0 auto 1rem; }
.empty-state h3 { font-size: 1.1rem; margin-bottom: 0.5rem; color: var(--text); }
.empty-state p { font-size: 0.9rem; }

/* ---- Section labels ---- */
.section-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-dim);
    margin-bottom: 1rem;
}

/* ---- Delete confirm strip ---- */
.delete-strip {
    background: rgba(239,68,68,0.08);
    border: 1px solid rgba(239,68,68,0.2);
    border-radius: var(--radius);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}
.delete-strip p { font-size: 0.88rem; color: #fca5a5; }

/* ---- Divider ---- */
.divider {
    height: 1px;
    background: var(--border);
    margin: 1.5rem 0;
}

/* ---- Footer ---- */
.site-footer {
    background: var(--card);
    border-top: 1px solid var(--border);
    padding: 1.5rem 0;
}
.footer-inner {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}
.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 700;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
}
.footer-logo:hover { color: var(--accent); text-decoration: none; }
.footer-logo svg { color: var(--accent); }
.footer-copy { color: var(--text-dim); font-size: 0.82rem; flex: 1; }
.footer-nav { display: flex; gap: 1rem; }
.footer-nav a { color: var(--text-muted); font-size: 0.85rem; }
.footer-nav a:hover { color: var(--accent); }

/* ---- Utilities ---- */
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.hidden { display: none !important; }

/* ---- Responsive ---- */
@media (max-width: 640px) {
    .nav-toggle { display: flex; }
    .nav-links {
        display: none;
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--card);
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        padding: 0.75rem;
        gap: 0.25rem;
    }
    .nav-links.open { display: flex; }
    .nav-inner { position: relative; flex-wrap: wrap; }
    .nav-dropdown-menu { position: static; box-shadow: none; border: none; background: var(--bg); border-radius: var(--radius); }

    .form-row { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .images-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
    .footer-inner { flex-direction: column; text-align: center; }
    .footer-copy { flex: none; }

    .copy-row { flex-wrap: wrap; }
    .copy-label { width: 100%; }
    .copy-input { min-width: 0; }
}

@media (max-width: 400px) {
    .stats-grid { grid-template-columns: 1fr; }
}
