/* ============================================
   DyS MUDANZAS - ADMIN PANEL STYLES
   Misma paleta de colores de la Landing
   Black & Gold con Dark/Light modes
   ============================================ */

/* ===== CSS CUSTOM PROPERTIES ===== */
:root {
    --gold: #c8a95e;
    --gold-light: #e0c97f;
    --gold-dark: #a8893e;
    --gold-gradient: linear-gradient(135deg, #c8a95e 0%, #e0c97f 50%, #c8a95e 100%);
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --transition-fast: all 0.2s ease;
    --sidebar-width: 260px;
    --header-height: 64px;
    --danger: #e74c3c;
    --success: #27ae60;
    --warning: #f39c12;
    --info: #3498db;
}

/* ── Dark Theme (Default) ──────────────────────── */
[data-theme="dark"] {
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-tertiary: #1a1a1a;
    --bg-card: #141414;
    --bg-card-hover: #1c1c1c;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-muted: #666666;
    --border-color: rgba(200, 169, 94, 0.15);
    --border-light: rgba(255, 255, 255, 0.06);
    --shadow-color: rgba(0, 0, 0, 0.4);
    --header-bg: rgba(10, 10, 10, 0.95);
    --input-bg: #1a1a1a;
    --sidebar-bg: #0d0d0d;
    --scrollbar-track: #111;
    --scrollbar-thumb: #333;
}

/* ── Light Theme ───────────────────────────────── */
[data-theme="light"] {
    --bg-primary: #faf9f6;
    --bg-secondary: #f0ede6;
    --bg-tertiary: #e8e4db;
    --bg-card: #ffffff;
    --bg-card-hover: #f8f6f0;
    --text-primary: #1a1a1a;
    --text-secondary: #555555;
    --text-muted: #888888;
    --border-color: rgba(200, 169, 94, 0.25);
    --border-light: rgba(0, 0, 0, 0.08);
    --shadow-color: rgba(0, 0, 0, 0.1);
    --header-bg: rgba(250, 249, 246, 0.95);
    --input-bg: #f0ede6;
    --sidebar-bg: #f5f3ee;
    --scrollbar-track: #e8e4db;
    --scrollbar-thumb: #c8a95e;
}

/* ===== RESET ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { font-size: 16px; scroll-behavior: smooth; scrollbar-width: thin; scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track); }
html::-webkit-scrollbar { width: 6px; }
html::-webkit-scrollbar-track { background: var(--scrollbar-track); }
html::-webkit-scrollbar-thumb { background: var(--scrollbar-thumb); border-radius: 3px; }

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }
button { cursor: pointer; font-family: inherit; }

.gold { color: var(--gold); }

/* ===== ADMIN LAYOUT ===== */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

/* ===== SIDEBAR ===== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 100;
    transition: transform 0.3s ease;
    overflow-y: auto;
}

.sidebar-header {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-light);
}

.sidebar-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

.sidebar-logo .logo-text {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 3px;
    line-height: 1;
}

.sidebar-logo .logo-sub {
    font-family: var(--font-body);
    font-size: 0.55rem;
    letter-spacing: 6px;
    color: var(--gold);
    text-transform: uppercase;
    font-weight: 500;
}

.sidebar-close {
    display: none;
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 5px;
    transition: var(--transition-fast);
}

.sidebar-close:hover { color: var(--gold); }

.sidebar-nav {
    flex: 1;
    padding: 15px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition-fast);
    position: relative;
}

.nav-item:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.nav-item.active {
    background: rgba(200, 169, 94, 0.12);
    color: var(--gold);
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    background: var(--gold);
    border-radius: 0 3px 3px 0;
}

.nav-item svg { flex-shrink: 0; }

.nav-item .badge {
    margin-left: auto;
    background: var(--danger);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

.nav-divider {
    height: 1px;
    background: var(--border-light);
    margin: 10px 0;
}

.nav-logout { color: var(--danger) !important; }
.nav-logout:hover { background: rgba(231, 76, 60, 0.1) !important; }

.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99;
}

/* ===== MAIN WRAPPER ===== */
.main-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: margin-left 0.3s ease;
}

/* ===== ADMIN HEADER ===== */
.admin-header {
    height: var(--header-height);
    background: var(--header-bg);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    padding: 5px;
}

.page-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.theme-toggle, .theme-toggle-mini {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.theme-toggle:hover, .theme-toggle-mini:hover {
    border-color: var(--gold);
    color: var(--gold);
}

[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="light"] .icon-sun { display: none; }
[data-theme="light"] .icon-moon { display: block; }

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--gold-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    color: #0a0a0a;
}

.user-name {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-primary);
}

/* ===== MAIN CONTENT ===== */
.main-content {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    text-decoration: none;
}

.btn-sm { padding: 8px 16px; font-size: 0.8rem; }
.btn-xs { padding: 6px 12px; font-size: 0.75rem; }

.btn-primary {
    background: var(--gold);
    color: #0a0a0a;
}

.btn-primary:hover {
    background: var(--gold-light);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(200, 169, 94, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-outline:hover {
    background: var(--gold);
    color: #0a0a0a;
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}

.btn-danger:hover {
    background: #c0392b;
    transform: translateY(-1px);
}

.btn-success {
    background: var(--success);
    color: #fff;
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-light);
}

.btn-ghost:hover {
    border-color: var(--border-color);
    color: var(--text-primary);
}

.btn-full { width: 100%; justify-content: center; }

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

/* ===== CARDS ===== */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 25px;
    transition: var(--transition);
}

.card:hover {
    border-color: var(--border-color);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-light);
}

.card-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ===== FORM ELEMENTS ===== */
.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 18px;
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.form-group input,
.form-group select,
.form-group textarea {
    background: var(--input-bg);
    border: 1px solid var(--border-light);
    color: var(--text-primary);
    padding: 12px 15px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    transition: var(--transition);
    outline: none;
    border-radius: 6px;
    width: 100%;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(200, 169, 94, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-light);
}

/* Input wrapper for login */
.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper svg {
    position: absolute;
    left: 14px;
    color: var(--text-muted);
    pointer-events: none;
    z-index: 1;
}

.input-wrapper input {
    padding-left: 42px;
}

.toggle-password {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 4px;
    transition: var(--transition-fast);
}

.toggle-password:hover { color: var(--gold); }

/* ===== LOGIN PAGE ===== */
.login-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary);
}

.login-container {
    position: relative;
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

.login-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 40px;
    position: relative;
    z-index: 1;
}

.login-header {
    text-align: center;
    margin-bottom: 35px;
}

.login-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    margin-bottom: 12px;
}

.login-logo .logo-text {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 4px;
    line-height: 1;
}

.login-logo .logo-sub {
    font-family: var(--font-body);
    font-size: 0.65rem;
    letter-spacing: 8px;
    color: var(--gold);
    text-transform: uppercase;
    font-weight: 500;
}

.login-subtitle {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.login-form .form-group { margin-bottom: 20px; }

.login-error {
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid rgba(231, 76, 60, 0.3);
    color: var(--danger);
    padding: 10px 15px;
    border-radius: 6px;
    font-size: 0.85rem;
    margin-bottom: 18px;
}

.login-footer {
    text-align: center;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border-light);
}

.login-bg-decoration {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.deco-line {
    position: absolute;
    width: 1px;
    height: 100%;
    background: var(--border-color);
    opacity: 0.3;
}

.deco-line:nth-child(1) { left: 25%; }
.deco-line:nth-child(2) { left: 50%; }
.deco-line:nth-child(3) { left: 75%; }

/* ===== SECTION PAGE STYLES ===== */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.page-header h3 {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* ===== GRID LAYOUTS ===== */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

/* ===== DATA LIST / TABLE ===== */
.data-list { display: flex; flex-direction: column; gap: 12px; }

.data-item {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 18px;
    transition: var(--transition);
}

.data-item:hover { border-color: var(--border-color); }

.data-item-content { flex: 1; min-width: 0; }

.data-item-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.data-item-subtitle {
    font-size: 0.82rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.data-item-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.icon-btn {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    border: 1px solid var(--border-light);
    background: transparent;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.icon-btn:hover {
    border-color: var(--gold);
    color: var(--gold);
}

.icon-btn.danger:hover {
    border-color: var(--danger);
    color: var(--danger);
}

/* ===== IMAGE UPLOAD ===== */
.image-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: var(--bg-tertiary);
}

.image-upload-area:hover {
    border-color: var(--gold);
    background: rgba(200, 169, 94, 0.05);
}

.image-upload-area svg { color: var(--gold); margin-bottom: 10px; }
.image-upload-area p { font-size: 0.85rem; color: var(--text-secondary); }
.image-upload-area .file-info { font-size: 0.75rem; color: var(--text-muted); margin-top: 5px; }

.image-preview {
    margin-top: 15px;
    position: relative;
    display: inline-block;
}

.image-preview img {
    max-width: 200px;
    max-height: 200px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    object-fit: cover;
}

.image-preview .remove-image {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--danger);
    color: #fff;
    border: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* ===== STARS RATING ===== */
.stars-display { color: var(--gold); font-size: 1rem; letter-spacing: 2px; }
.stars-input { display: flex; gap: 5px; }
.stars-input .star {
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: var(--transition-fast);
    background: none;
    border: none;
    padding: 0;
}
.stars-input .star.active { color: var(--gold); }
.stars-input .star:hover { color: var(--gold-light); }

/* ===== GALLERY GRID ===== */
.gallery-admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.gallery-admin-item {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    overflow: hidden;
    transition: var(--transition);
}

.gallery-admin-item:hover { border-color: var(--border-color); }

.gallery-admin-item img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.gallery-admin-item .item-info {
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.gallery-admin-item .item-info span {
    font-size: 0.82rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ===== MESSAGES ===== */
.message-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 12px;
    transition: var(--transition);
}

.message-card.unread { border-left: 3px solid var(--gold); }
.message-card:hover { border-color: var(--border-color); }

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
    gap: 15px;
    flex-wrap: wrap;
}

.message-sender {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.message-meta {
    display: flex;
    gap: 15px;
    font-size: 0.8rem;
    color: var(--text-muted);
    flex-wrap: wrap;
}

.message-meta span { display: flex; align-items: center; gap: 4px; }

.message-body {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 12px;
}

.message-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

/* ===== HOME / DASHBOARD ===== */
.home-hero {
    text-align: center;
    padding: 50px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 30px;
}

.home-hero .home-logo {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 4px;
    margin-bottom: 5px;
}

.home-hero .home-subtitle {
    color: var(--gold);
    font-size: 0.7rem;
    letter-spacing: 6px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.home-hero p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    max-width: 500px;
    margin: 0 auto 8px;
    line-height: 1.6;
}

.home-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 25px;
}

.info-card {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}

.info-card .info-icon {
    color: var(--gold);
    margin-bottom: 10px;
}

.info-card h4 {
    font-family: var(--font-heading);
    font-size: 1rem;
    margin-bottom: 5px;
    color: var(--text-primary);
}

.info-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.sotecem-footer {
    text-align: center;
    padding: 30px;
    margin-top: 30px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
}

.sotecem-footer .heart { color: #9b59b6; font-size: 1.2rem; }
.sotecem-footer a { color: var(--gold); font-weight: 600; }
.sotecem-footer a:hover { color: var(--gold-light); }
.sotecem-footer p { color: var(--text-secondary); font-size: 0.85rem; margin-bottom: 5px; }
.sotecem-footer .contract { color: var(--text-muted); font-size: 0.8rem; margin-top: 10px; }

/* ===== TOAST NOTIFICATIONS ===== */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 14px 20px;
    min-width: 280px;
    max-width: 400px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 8px 30px var(--shadow-color);
    animation: toastIn 0.3s ease;
    pointer-events: auto;
    font-size: 0.88rem;
    color: var(--text-primary);
}

.toast.toast-success { border-left: 3px solid var(--success); }
.toast.toast-error { border-left: 3px solid var(--danger); }
.toast.toast-warning { border-left: 3px solid var(--warning); }
.toast.toast-info { border-left: 3px solid var(--info); }

.toast.removing { animation: toastOut 0.3s ease forwards; }

.toast-icon { font-size: 1.2rem; flex-shrink: 0; }

@keyframes toastIn {
    from { opacity: 0; transform: translateX(100px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes toastOut {
    from { opacity: 1; transform: translateX(0); }
    to { opacity: 0; transform: translateX(100px); }
}

/* ===== CONFIRM MODAL ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
    max-width: 420px;
    width: 100%;
    text-align: center;
}

.modal-card h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.modal-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 25px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 50px 20px;
    color: var(--text-muted);
}

.empty-state svg { color: var(--border-color); margin-bottom: 15px; }
.empty-state p { font-size: 0.9rem; }

/* ===== LOADING SPINNER ===== */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 50px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border-light);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== TAGS / CHIPS ===== */
.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: rgba(200, 169, 94, 0.1);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 0.78rem;
    color: var(--gold);
}

.chip .remove-chip {
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    opacity: 0.7;
    background: none;
    border: none;
    color: var(--gold);
    padding: 0;
}

.chip .remove-chip:hover { opacity: 1; }

.features-input {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.features-input input { flex: 1; }

.features-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* ===== SVG PREVIEW ===== */
.svg-preview {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-tertiary);
    flex-shrink: 0;
    overflow: hidden;
}

.svg-preview svg { width: 28px; height: 28px; }

/* ===== PAGINATION ===== */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 25px;
}

.pagination button {
    width: 36px;
    height: 36px;
    border: 1px solid var(--border-light);
    background: transparent;
    color: var(--text-secondary);
    border-radius: 6px;
    font-size: 0.85rem;
    transition: var(--transition-fast);
}

.pagination button:hover { border-color: var(--gold); color: var(--gold); }
.pagination button.active { background: var(--gold); color: #0a0a0a; border-color: var(--gold); }
.pagination button:disabled { opacity: 0.3; cursor: not-allowed; }

/* ===== RESPONSIVE ═══════════════════════════════ */
@media (max-width: 1024px) {
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .sidebar-close { display: block; }

    .sidebar-overlay.active {
        display: block;
    }

    .main-wrapper {
        margin-left: 0;
    }

    .menu-toggle { display: block; }

    .main-content { padding: 20px 15px; }

    .admin-header { padding: 0 15px; }

    .form-row { grid-template-columns: 1fr; }

    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }

    .gallery-admin-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .page-header { flex-direction: column; align-items: flex-start; }

    .message-header { flex-direction: column; }

    .user-name { display: none; }

    .data-item { flex-direction: column; align-items: flex-start; text-align: left; }
    .data-item-actions { align-self: flex-end; }

    .modal-card { padding: 20px; }
    .modal-actions { flex-direction: column; }

    .home-hero { padding: 30px 15px; }
    .home-hero .home-logo { font-size: 2.2rem; }
}

@media (max-width: 480px) {
    .main-content { padding: 15px 10px; }
    .card { padding: 18px; }
    .btn { padding: 10px 18px; font-size: 0.82rem; }
    .page-title { font-size: 1rem; }

    .gallery-admin-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .toast { min-width: auto; max-width: 90vw; }
}
