/* 
   ==========================================================================
   PAC-v3 Premium Design System
   Core Stylings for the El Amasadero PIM
   ========================================================================== */

:root {
    /* Colors - Modern Slate/Indigo Palette */
    --primary: #0f172a;
    --primary-dark: #020617;
    --accent: #6366f1;
    --accent-hover: #4f46e5;
    --accent-light: #eef2ff;

    --success: #10b981;
    --success-light: #ecfdf5;
    --warning: #f59e0b;
    --warning-light: #fffbeb;
    --danger: #ef4444;
    --danger-light: #fef2f2;

    --bg-app: #f8fafc;
    --bg-card: #ffffff;
    --bg-sidebar: #0f172a;

    --text-main: #1e293b;
    --text-muted: #64748b;
    --text-inv: #ffffff;

    --border: #e2e8f0;
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;

    /* Layout */
    --sidebar-width: 260px;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

/* Base Reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', -apple-system, blinkmacsystemfont, 'Segoe UI', roboto, sans-serif;
    background-color: var(--bg-app);
    color: var(--text-main);
    line-height: 1.6;
    font-size: 14px;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4 {
    font-weight: 700;
    color: var(--primary);
    line-height: 1.2;
}

h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

h2 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1.25rem;
}

h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: all 0.2s;
}

a:hover {
    color: var(--accent-hover);
}

/* Layout Infrastructure */
.container {
    margin-left: var(--sidebar-width);
    padding: 2.5rem;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--bg-sidebar);
    color: var(--text-inv);
    display: flex;
    flex-direction: column;
    z-index: 1000;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.1);
}

.sidebar-brand {
    padding: 2rem 1.5rem;
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-brand strong {
    color: var(--accent);
}

.sidebar-user {
    padding: 1.25rem 1.5rem;
    background: rgba(0, 0, 0, 0.2);
    font-size: 0.85rem;
}

.sidebar-user-name {
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.25rem;
}

.sidebar-user-role {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-top: 0.5rem;
}

.sidebar-menu {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.sidebar-menu a,
.submenu-toggle {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    color: #94a3b8;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all 0.2s;
    cursor: pointer;
    user-select: none;
}

.submenu-toggle::after {
    content: '\f107'; /* fa-angle-down */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    margin-left: auto;
    transition: transform 0.2s;
}

.submenu-parent.open .submenu-toggle::after {
    transform: rotate(180deg);
}

.sidebar-menu a:hover,
.submenu-toggle:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.sidebar-menu a.active {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.submenu {
    padding-left: 1rem;
    margin: 0.25rem 0;
    display: none;
    flex-direction: column;
    gap: 1px;
}

.submenu.open {
    display: flex;
}

.submenu a {
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
}

/* Cards & Grid */
.grid,
.form-grid-users {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.card h3 {
    margin-bottom: 0.75rem;
}

.card-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    margin: 0.5rem 0;
}

.card-value-path {
    font-size: 0.95rem;
    color: var(--primary);
    white-space: pre-line;
    word-break: break-all;
}

/* Tables */
.table-container {
    background: #fff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    overflow-x: auto;
    margin-bottom: 2rem;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    background: #f8fafc;
    padding: 1rem 1.5rem;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
}

td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-light);
    color: var(--text-main);
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background: var(--bg-app);
}

/* Buttons */
.button,
button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    font-size: 0.9rem;
    gap: 0.5rem;
}

button.primary,
.button.primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 2px 4px rgba(99, 102, 241, 0.2);
}

button.primary:hover,
.button.primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(99, 102, 241, 0.3);
}

button.secondary,
.button.secondary {
    background: var(--bg-app);
    color: var(--primary);
    border: 1px solid var(--border);
}

button.secondary:hover,
.button.secondary:hover {
    background: var(--border-light);
}

button.danger,
.button.danger {
    background: var(--danger);
    color: #fff;
}

button.danger:hover,
.button.danger:hover {
    filter: brightness(0.9);
}

/* Forms */
.form-section {
    background: #fff;
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    margin-bottom: 2rem;
}

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

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

input[type="text"],
input[type="file"],
input[type="password"],
input[type="email"],
select,
textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

input,
select,
textarea {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    font-size: 0.9375rem;
    transition: border-color 0.2s;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-light);
}

/* Alerts */
.alert {
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.alert-success {
    background: var(--success-light);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.alert-danger {
    background: var(--danger-light);
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Utilities */
.text-muted {
    color: var(--text-muted);
}

.mt-1 {
    margin-top: 1rem;
}

.mt-2 {
    margin-top: 2rem;
}

.mb-1 {
    margin-bottom: 1rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

.flex {
    display: flex;
}

.align-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-1 {
    gap: 1rem;
}

/* Interactive Blocks */
.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.badge-accent {
    background: var(--accent-light);
    color: var(--accent);
}

/* Responsive */
@media (max-width: 1024px) {
    .container {
        margin-left: 0;
        padding: 1.5rem;
    }

    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s;
    }

    .sidebar.open {
        transform: translateX(0);
    }
}

/* Missing Utility Classes for Dashboard */
.form-section-mt {
    margin-top: 2rem;
}

.select-mt {
    margin-top: 0.5rem;
}

.flex-end {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 1rem;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.link-small {
    font-size: 0.85rem;
    font-weight: 600;
}

.th-numeric {
    text-align: right;
}

.td-numeric-strong {
    text-align: right;
    font-weight: 700;
    color: var(--accent);
}

.empty-state {
    padding: 2rem;
    text-align: center;
    color: var(--text-muted);
    font-style: italic;
}

.badge-pill-accent {
    background: var(--accent-light);
    color: var(--accent);
    padding: 0.25rem 1rem;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
}

.import-summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.import-file-title {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0.25rem 0;
}

.import-meta-muted {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.import-stats {
    margin-top: 0.75rem;
    font-size: 0.9rem;
}

.text-red {
    color: var(--danger);
    font-weight: 700;
}

.pre-markdown-help {
    background: #1e293b;
    color: #cbd5e1;
    padding: 1.5rem;
    border-radius: var(--radius-md);
    overflow-x: auto;
    font-family: 'Fira Code', monospace;
    font-size: 0.85rem;
    line-height: 1.5;
    margin: 1rem 0;
}

.quick-actions-row {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.copy-feedback {
    font-size: 0.85rem;
    color: var(--success);
    font-weight: 700;
    opacity: 0;
    transition: opacity 0.3s;
}

.copy-feedback.is-visible-inline {
    opacity: 1;
}

/* Product Listing Specifics */
.products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.btn-import-header {
    background: var(--accent);
    color: #fff;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.btn-import-header:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
}

.products-filter-form {
    display: flex;
    gap: 1.5rem;
    align-items: flex-end;
    flex-wrap: wrap;
}

.filter-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.th-sort-link {
    color: inherit;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.th-sort-link:hover {
    color: var(--accent);
}

.product-link-strong {
    font-weight: 700;
    color: var(--primary);
}

.product-link-strong:hover {
    color: var(--accent);
}

.familia-pill {
    background: #f1f5f9;
    color: #475569;
    padding: 2px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
}

.btn-row-sm {
    padding: 4px 8px;
    font-size: 0.7rem;
    border-radius: 4px;
    text-transform: uppercase;
    font-weight: 800;
}

.button-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.button-link.primary {
    background: var(--accent);
    color: #fff;
}

.button-link.secondary {
    background: var(--bg-app);
    color: var(--primary);
    border: 1px solid var(--border);
}

/* Unified action button sizing */
.btn-ui-md {
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    line-height: 1.2;
    padding: 0.55rem 1rem !important;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
}

/* Unified tabs (e.g. Gestor de Informes) */
.view-tabs {
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.tab-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.55rem 1rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: #fff;
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
}

.tab-link:hover {
    background: var(--bg-app);
    border-color: #cbd5e1;
    color: var(--primary);
}

.tab-link.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.25);
}

.inline-form {
    display: inline-block;
}

.btn-text-danger {
    background: transparent;
    color: var(--text-muted);
    padding: 4px;
    cursor: pointer;
}

.btn-text-danger:hover {
    color: var(--danger);
    background: var(--danger-light);
    border-radius: 8px;
}

/* 
   ==========================================================================
   Media Library Premium Styles
   ========================================================================== */

.media-container {
    max-width: 1400px;
}

.upload-zone {
    border: 2px dashed #cbd5e1;
    border-radius: var(--radius-lg);
    background: #fff;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.upload-zone:hover,
.upload-zone.is-drag {
    border-color: var(--accent);
    background: var(--accent-light);
}

.upload-zone .upload-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.upload-zone h3 {
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.upload-zone p {
    color: var(--text-muted);
}

.upload-area input[type="file"] {
    display: none;
}

/* Media Grid */
.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.media-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.media-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.media-thumb-container {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    background: #f1f5f9;
    background-image: radial-gradient(#cbd5e1 1px, transparent 1px);
    background-size: 20px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.media-thumb {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.5s ease;
}

.media-card:hover .media-thumb {
    transform: scale(1.05);
}

.media-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    opacity: 0;
    transition: all 0.2s ease;
}

.media-card:hover .media-overlay,
.media-card:focus-within .media-overlay {
    opacity: 1;
}

.media-btn-circle {
    width: 48px;
    height: 48px;
    border-radius: 100%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1.1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.media-btn-circle:hover {
    background: var(--accent);
    color: #fff;
    transform: scale(1.1);
}

.media-btn-circle.danger:hover {
    background: var(--danger);
}

.media-content {
    padding: 1rem;
    border-top: 1px solid var(--border-light);
}

.media-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    margin-bottom: 0.25rem;
}

.media-meta {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    justify-content: space-between;
}

.media-badge-header {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    background: var(--accent);
    color: #fff;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Modal Preview */
.media-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.media-modal.is-active {
    display: flex;
}

.media-modal-content {
    max-width: 90%;
    max-height: 90%;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.media-modal-img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: var(--radius-md);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
    object-fit: contain;
}

.media-modal-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.media-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

.media-modal-info {
    margin-top: 1.5rem;
    color: #fff;
    text-align: center;
}

.media-modal-info strong {
    display: block;
    font-size: 1.25rem;
    margin-bottom: 0.25rem;
}

.products-empty-cell {
    padding: 4rem !important;
    text-align: center;
    color: var(--text-muted);
    font-weight: 500;
    font-style: italic;
}

/* Import Page Specifics */
.alert-danger-solid {
    background: var(--danger);
    color: #fff;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    font-weight: 700;
}

.import-label {
    display: block;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
}

.input-file-pad {
    padding: 2rem !important;
    border: 2px dashed var(--border);
    background: var(--bg-app);
    cursor: pointer;
    text-align: center;
}

.input-file-pad:hover {
    border-color: var(--accent);
    background: var(--accent-light);
}

.hint-sm {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    font-weight: 500;
}

.import-notes-list {
    padding-left: 1.25rem;
    margin-top: 1rem;
    color: var(--text-muted);
}

.import-notes-list li {
    margin-bottom: 0.5rem;
    position: relative;
}

.btn-flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    max-width: 400px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.upload-area {
    display: inline-block;
    border: 2px dashed var(--accent);
    border-radius: 12px;
    padding: 2.5rem;
    text-align: center;
    background: var(--accent-light);
    cursor: pointer;
    transition: background 0.2s;
}

pre.pre-truncate {
    max-width: 300px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 0.25rem 0.5rem;
    margin: 0;
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* Login (standalone page) */
.login-body {
    margin: 0;
    min-height: 100vh;
    display: grid;
    place-items: center;
    background: #0f172a;
}

.login-shell {
    width: min(480px, 92vw);
    background: #fff;
    border-radius: 14px;
    padding: 1.5rem;
    box-shadow: 0 18px 45px rgba(2, 6, 23, 0.28);
}

.login-title {
    margin: 0 0 0.4rem;
    font-size: 1.35rem;
}

.login-intro {
    margin: 0 0 1rem;
    color: #64748b;
}

.login-h2 {
    margin: 0 0 0.8rem;
    font-size: 1.05rem;
}

.login-label {
    display: block;
    margin-bottom: 0.7rem;
}

.login-label-tight {
    display: block;
    margin-bottom: 0.8rem;
}

.login-label-last {
    display: block;
    margin-bottom: 1rem;
}

.login-input-wide input,
.login-input-wide {
    width: 100%;
}

.login-code-input {
    width: 100%;
    letter-spacing: 0.25em;
    text-align: center;
    font-size: 1.2rem;
}

.login-btn-block {
    width: 100%;
}

.login-btn-block-spaced {
    width: 100%;
    margin-bottom: 0.5rem;
}

.login-form-gap {
    margin-bottom: 0.75rem;
}

.login-text-muted {
    margin: 0 0 0.4rem;
    color: #475569;
}

.login-text-muted-b {
    margin: 0 0 1rem;
    color: #475569;
}

.login-section {
    padding: 0.9rem;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    margin-bottom: 0.8rem;
}

.login-section:last-of-type {
    margin-bottom: 0;
}

.login-h3 {
    margin: 0 0 0.7rem;
    font-size: 1rem;
}

.alert-login-error {
    margin-bottom: 1rem;
    background: #fee2e2;
    border: 1px solid #fecaca;
    color: #991b1b;
    padding: 0.7rem;
    border-radius: 8px;
}

/* 
   ==========================================================================
   Header Editor Specific Styles
   ========================================================================== */

.header-editor-panel {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-sm);
}

.header-editor-panel h4 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--accent);
    border-bottom: 1px solid var(--border-light);
    padding-bottom: 0.5rem;
}

.logo-preview-container {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: var(--bg-app);
    padding: 1rem;
    border-radius: var(--radius-sm);
    border: 1px dashed var(--border);
}

.logo-preview-box {
    width: 80px;
    height: 80px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.logo-preview-box img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

.logo-preview-empty {
    color: var(--text-muted);
    font-size: 1.5rem;
}

.input-group-compact {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
}

.input-label-sm {
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.attr-line-box {
    background: var(--bg-app);
    padding: 0.75rem;
    border-radius: var(--radius-sm);
}

.alert-login-success {
    margin-bottom: 1rem;
    background: #ecfdf3;
    border: 1px solid #a7f3d0;
    color: #065f46;
    padding: 0.7rem;
    border-radius: 8px;
}