:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --bg-dark: #0f172a;
    --bg-panel: rgba(30, 41, 59, 0.7);
    --text-light: #f8fafc;
    --text-muted: #94a3b8;
    --success: #10b981;
    --danger: #ef4444;
    --border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
    height: 100vh;
    overflow: hidden;
    /* Subtle gradient background */
    background: radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.15), transparent 25%),
                radial-gradient(circle at 85% 30%, rgba(16, 185, 129, 0.1), transparent 25%);
    background-color: var(--bg-dark);
}

.app-container {
    display: flex;
    height: 100vh;
}

/* Sidebar Styling */
.main-sidebar {
    width: 280px;
    background: var(--bg-panel);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-right: 1px solid var(--border);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    z-index: 10;
    box-shadow: 4px 0 24px rgba(0,0,0,0.2);
}

.logo-link {
    text-decoration: none;
    color: inherit;
    display: inline-block;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo span {
    color: var(--primary);
}

/* Nav Menu */
.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.nav-menu a {
    text-decoration: none;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-light);
}

.nav-item.active {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.3);
    color: var(--primary);
}

/* Main Content Area */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    position: relative;
    height: 100vh;
}

.view-panel {
    display: none;
    flex-direction: column;
    flex-grow: 1;
    min-height: 100%;
    width: 100%;
    flex-shrink: 0;
}

.view-panel.active {
    display: flex;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: none;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

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

.btn-success {
    background: var(--success);
    color: white;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
}

/* Tool Header */
.tool-header {
    padding: 2rem;
    border-bottom: 1px solid var(--border);
    background: rgba(0,0,0,0.2);
    display: flex;
    justify-content: space-between;
    align-items: center; /* Centered vertically by default */
}

.header-title-area {
    display: flex;
    flex-direction: column;
}

.tool-header h2 {
    margin-bottom: 0.5rem;
}

.tool-header p {
    color: var(--text-muted);
}

.header-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

/* Unified Centered Dropzone */
.upload-area-centered {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    margin: 2rem auto;
    width: 80%;
    max-width: 800px;
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.upload-area-centered:hover {
    border-color: rgba(99, 102, 241, 0.5);
    background: rgba(99, 102, 241, 0.05);
}

.upload-area-centered.drag-active {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.15);
}

/* Strict Discard Button Taxonomy */
.btn-discard-white {
    background-color: transparent !important;
    color: var(--text-light) !important;
    border: 1px solid rgba(255,255,255,0.2) !important;
    box-shadow: none !important;
}

.btn-discard-white:hover {
    background-color: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
}

/* Upload Area (Tools) */
.upload-area {
    padding: 2rem;
    text-align: center;
}

/* Specific to Editor PDF View */
.top-toolbar {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 2rem;
    background: var(--bg-panel);
    border-bottom: 1px solid var(--border);
}

.tool-group.horizontal {
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
}

.tools-section.horizontal {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.5rem;
    margin-left: auto;
}

.tool-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: var(--text-muted);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tool-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-light);
}

.tool-btn.active {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.3);
    color: var(--primary);
}

/* Workspace & PDF Container */
.workspace {
    flex: 1;
    overflow-y: auto;
    overflow-x: auto;
    padding: 2rem;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    position: relative;
}

/* Floating Text Format Pop-up */
.text-format-popup {
    position: absolute;
    z-index: 1000;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    display: flex;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
    transition: opacity 0.2s ease;
    overflow: hidden;
}

.popup-drag-handle {
    width: 24px;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: grab;
    color: var(--text-muted);
}

.popup-drag-handle:active {
    cursor: grabbing;
}

.popup-body {
    padding: 0.5rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.format-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.format-group {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.format-divider {
    width: 1px;
    height: 24px;
    background-color: rgba(255, 255, 255, 0.15);
}

.format-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 6px;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.format-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-light);
}

.format-btn.active {
    background: rgba(99, 102, 241, 0.2);
    border-color: rgba(99, 102, 241, 0.4);
    color: var(--primary);
}

.reset-btn {
    color: var(--danger);
}
.reset-btn:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
}

.format-select {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: var(--text-light);
    padding: 0.25rem 0.5rem;
    font-size: 0.85rem;
    height: 32px;
    outline: none;
    cursor: pointer;
}
.format-select:focus {
    border-color: var(--primary);
}
.format-select option {
    background: var(--bg-dark);
    color: var(--text-light);
}

.format-input {
    width: 50px;
    height: 32px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: var(--text-light);
    text-align: center;
    font-size: 0.85rem;
}
.format-input.size-input {
    width: 60px;
}

.format-input:focus {
    outline: none;
    border-color: var(--primary);
}

/* Chrome, Safari, Edge, Opera */
.format-input::-webkit-outer-spin-button,
.format-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox */
.format-input[type=number] {
  -moz-appearance: textfield;
}

.color-group {
    gap: 0.5rem;
}

.color-swatch {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid transparent;
    transition: transform 0.2s ease, border-color 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.color-swatch:hover {
    transform: scale(1.1);
}

.color-swatch.active {
    border-color: white;
    transform: scale(1.1);
}

.color-picker-label {
    cursor: pointer;
    position: relative;
    display: inline-block;
}

.color-picker-label input[type="color"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    padding: 0;
    margin: 0;
}

.custom-color-btn {
    background: linear-gradient(135deg, #ef4444, #eab308, #22c55e, #3b82f6, #a855f7);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.empty-state {
    text-align: center;
    color: var(--text-muted);
    margin-top: 15vh;
}

.empty-state h2 {
    color: var(--text-light);
    margin-bottom: 0.5rem;
}

.pdf-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    position: relative;
    margin: 0 auto;
}

/* Page Wrapper */
.page-wrapper {
    position: relative;
    background: white;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.pdf-canvas-bg {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 0;
    pointer-events: none;
}

.pdf-canvas-text {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    pointer-events: none;
}

.canvas-container {
    position: absolute !important;
    top: 0;
    left: 0;
    z-index: 2;
}

/* Merge View Specifics */
.merge-list-container {
    padding: 0 2rem;
    flex: 1;
    overflow-y: auto;
}

.sortable-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sortable-list li {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: grab;
}

.sortable-list li:active {
    cursor: grabbing;
    background: rgba(99, 102, 241, 0.1);
}

.action-bar {
    padding: 1.5rem 2rem;
    border-top: 1px solid var(--border);
    background: rgba(0,0,0,0.2);
    display: flex;
    justify-content: flex-end;
}

/* Split View Specifics */
.split-controls {
    padding: 0 2rem;
}

.split-controls-form {
    max-width: 500px;
}

.info-panel {
    background: rgba(255,255,255,0.05);
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.form-group input {
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--border);
    color: white;
    padding: 0.75rem;
    border-radius: 6px;
    font-size: 1rem;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
}

/* Reorder View Specifics */
.reorder-controls {
    padding: 0 2rem 1rem;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

/* Compression Cards */
.compression-cards {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.compression-card {
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.compression-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255,255,255,0.3);
}
.compression-card.active {
    background: rgba(79, 70, 229, 0.1);
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.2);
}
.compression-card .card-icon {
    margin-bottom: 0.75rem;
    color: var(--text-muted);
    transition: color 0.2s;
}
.compression-card.active .card-icon {
    color: var(--primary);
}
.compression-card h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    color: white;
}
.compression-card p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

@media (min-width: 768px) {
    .compression-cards {
        flex-direction: row;
        justify-content: space-between;
    }
    .compression-card {
        flex: 1;
    }
}

/* Dynamic Compression Progress Bar */
.compress-progress-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}
.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}
.progress-header #compress-progress-status {
    color: var(--text-light);
    font-weight: 500;
}
.progress-header #compress-progress-percent {
    color: #38bdf8;
    font-weight: 700;
    font-size: 1.1rem;
}
.progress-bar-track {
    width: 100%;
    height: 10px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}
.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #4f46e5, #06b6d4);
    border-radius: 10px;
    transition: width 0.3s ease;
    box-shadow: 0 0 10px rgba(79, 70, 229, 0.5);
}

/* Compression Results Summary */
.compress-result-summary {
    animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.result-card {
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
}
.result-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #10b981;
    margin-bottom: 1.25rem;
}
.result-header h4 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 600;
}
.result-stats {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
}
.stat-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    min-width: 140px;
}
.stat-box.highlight {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
}
.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}
.stat-value {
    font-size: 1.3rem;
    font-weight: 700;
    color: white;
}
.stat-box.highlight .stat-value {
    color: #34d399;
}
.stat-arrow {
    color: var(--text-muted);
    display: flex;
    align-items: center;
}
.stat-badge {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    font-weight: 800;
    font-size: 1.2rem;
    padding: 0.75rem 1.25rem;
    border-radius: 30px;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.reorder-controls {

    padding: 0 2rem 1rem;
    display: flex;
    justify-content: flex-end;
}

.reorder-grid-container {
    padding: 0 2rem 2rem;
    flex: 1;
    overflow-y: auto;
}

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

.reorder-page-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: grab;
    transition: transform 0.2s;
}

.reorder-page-card:active {
    cursor: grabbing;
}

.reorder-page-card canvas {
    max-width: 100%;
    height: auto;
    border: 1px solid #ddd;
    margin-bottom: 0.5rem;
    background: white;
    transition: transform 0.3s ease;
}

.reorder-page-actions {
    display: flex;
    gap: 0.5rem;
    width: 100%;
    justify-content: space-around;
}

.rotate-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    font-size: 0.8rem;
}

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

/* Status message */
.status-message {
    font-size: 0.85rem;
    color: var(--text-muted);
    padding: 1rem;
    border-radius: 8px;
    background: rgba(0,0,0,0.2);
    display: none;
}

/* Split Page Card */
.split-page-card {
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s ease;
}

.split-page-card.selected {
    border-color: var(--success);
    background: rgba(16, 185, 129, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

/* Merge List Grid & Thumbnail Styles */
#merge-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1.5rem;
    padding: 1rem;
}

#merge-list .merge-item-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    cursor: grab;
    transition: transform 0.2s, background 0.2s;
    /* Reset padding from generic li */
    justify-content: flex-start;
}

#merge-list .merge-item-card:hover {
    background: rgba(255, 255, 255, 0.1);
}

#merge-list .merge-item-card:active {
    cursor: grabbing;
    background: rgba(99, 102, 241, 0.1);
}

.merge-item-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.merge-item-content canvas {
    max-width: 100%;
    height: auto;
    border: 1px solid #ddd;
    margin-bottom: 0.5rem;
    background: white;
    border-radius: 4px;
}

.canvas-placeholder {
    width: 100%;
    aspect-ratio: 1 / 1.414;
    background: rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    border: 1px dashed var(--border);
    border-radius: 4px;
}

.file-name {
    font-size: 0.8rem;
    color: var(--text-light);
    text-align: center;
    word-break: break-all;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    width: 100%;
}

.btn-remove-merge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--danger);
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    transition: transform 0.2s, background 0.2s;
}

.btn-remove-merge:hover {
    background: #dc2626;
    transform: scale(1.1);
}

/* Modal Styling */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}
.modal-content {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    width: 450px;
    max-width: 90%;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5);
}
.modal-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.modal-header h3 {
    margin: 0; font-size: 1.1rem;
}
.btn-close {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.2s;
}
.btn-close:hover {
    color: var(--danger);
}
.modal-tabs {
    display: flex;
    border-bottom: 1px solid var(--border);
}
.tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    padding: 1rem;
    color: var(--text-muted);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}
.tab-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}
.tab-btn.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
}
.modal-body {
    padding: 1.5rem;
}
.tab-content {
    display: none;
}
.tab-content.active {
    display: block;
}
.tab-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
}

/* Pagination Control */
.pagination-control {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 0.25rem 0.75rem;
    margin-left: auto; /* Push to the right if in a flex container */
    color: var(--text-muted);
    font-size: 0.9rem;
}

.page-nav-input {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: 4px;
    width: 40px;
    text-align: center;
    padding: 2px;
    font-size: 0.9rem;
    outline: none;
    margin-right: 0.25rem;
}

.page-nav-input:focus {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.15);
}

/* Remove default up/down arrows from number input */
.page-nav-input::-webkit-inner-spin-button,
.page-nav-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.page-nav-input {
    -moz-appearance: textfield;
}

.page-nav-separator {
    margin: 0 0.25rem;
}

.page-nav-total {
    font-weight: bold;
    color: white;
}

/* --- Welcome Screen & Interactive Module Cards Grid --- */
.welcome-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2.5rem 2rem;
    width: 100%;
    animation: fadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

.welcome-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.welcome-title {
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.025em;
    color: var(--text-light);
    margin-bottom: 0.75rem;
}

.welcome-title span {
    background: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.welcome-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 650px;
    margin: 0 auto;
    line-height: 1.6;
}

.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.module-card {
    position: relative;
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.module-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.8), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.module-card:hover {
    transform: translateY(-6px);
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(99, 102, 241, 0.4);
    box-shadow: 0 20px 35px -10px rgba(15, 23, 42, 0.8), 0 0 25px rgba(99, 102, 241, 0.15);
}

.module-card:hover::before {
    opacity: 1;
}

.card-badge {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    padding: 0.25rem 0.65rem;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(99, 102, 241, 0.15);
    color: #818cf8;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.card-badge.badge-green {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border-color: rgba(16, 185, 129, 0.3);
}

.card-badge.badge-blue {
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    border-color: rgba(56, 189, 248, 0.3);
}

.card-badge.badge-amber {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
    border-color: rgba(245, 158, 11, 0.35);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

/* Crown Icon for Paid Modules */
.crown-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    color: #f59e0b;
    filter: drop-shadow(0 1px 2px rgba(245, 158, 11, 0.4));
    transition: transform 0.2s ease;
}

.crown-icon:hover {
    transform: scale(1.2) rotate(6deg);
}

.premium-tag {
    display: inline-flex;
    align-items: center;
    margin-left: auto;
}

.card-icon-wrapper {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    transition: transform 0.3s ease;
}

.module-card:hover .card-icon-wrapper {
    transform: scale(1.08);
}

.icon-indigo {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(79, 70, 229, 0.1));
    color: #818cf8;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.icon-green {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(5, 150, 105, 0.1));
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.icon-amber {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(217, 119, 6, 0.1));
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.icon-purple {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.25), rgba(147, 51, 234, 0.1));
    color: #c084fc;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

.icon-cyan {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.25), rgba(8, 145, 178, 0.1));
    color: #22d3ee;
    border: 1px solid rgba(6, 182, 212, 0.3);
}

.icon-rose {
    background: linear-gradient(135deg, rgba(244, 63, 94, 0.25), rgba(225, 29, 72, 0.1));
    color: #fb7185;
    border: 1px solid rgba(244, 63, 94, 0.3);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-light);
    margin-bottom: 0.6rem;
}

.card-description {
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.55;
    margin-bottom: 1.5rem;
    flex: 1;
}

.card-footer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary);
    transition: gap 0.2s ease, color 0.2s ease;
}

.module-card:hover .card-footer {
    color: #818cf8;
    gap: 0.75rem;
}

.card-footer svg {
    transition: transform 0.2s ease;
}

.module-card:hover .card-footer svg {
    transform: translateX(4px);
}

/* ==========================================================================
   USER AUTH & SIDEBAR WIDGET
   ========================================================================== */
.user-auth-widget {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.btn-auth {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem;
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-auth:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

.user-info-card {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.user-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-light);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-plan-badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    background: rgba(99, 102, 241, 0.2);
    color: #818cf8;
    border: 1px solid rgba(99, 102, 241, 0.3);
    align-self: flex-start;
}

.user-plan-badge.paid {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border-color: rgba(16, 185, 129, 0.3);
}

.user-credits-info {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.btn-logout {
    margin-top: 0.5rem;
    padding: 0.4rem;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: 6px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: var(--danger);
    color: var(--danger);
}

/* ==========================================================================
   AUTH MODAL & TABS
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-card {
    background: #1e293b;
    border: 1px solid var(--border);
    border-radius: 16px;
    width: 100%;
    max-width: 440px;
    padding: 2rem;
    position: relative;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.modal-card.auth-modal-card {
    background: #090e1a;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    width: 100%;
    max-width: 420px;
    padding: 2.2rem 2rem 2rem 2rem;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.75);
}

.auth-header-top {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    position: relative;
    width: 100%;
}

.auth-title {
    font-size: 1.65rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    letter-spacing: -0.02em;
}

.auth-subtitle {
    font-size: 0.88rem;
    color: #94a3b8;
    line-height: 1.45;
    margin-bottom: 1rem;
}

.auth-verify-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
    text-align: center;
}

.auth-modal-card .modal-close {
    position: absolute;
    top: 1.2rem;
    right: 1.25rem;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s ease;
    z-index: 10;
}

.auth-modal-card .modal-close:hover {
    color: #ffffff;
}

.auth-tabs {
    display: inline-flex;
    gap: 0.25rem;
    background: rgba(255, 255, 255, 0.06);
    padding: 0.25rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-tab {
    padding: 0.55rem 1.1rem;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 0.88rem;
    font-weight: 600;
    border-radius: 9px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.auth-tab.active {
    background: #2563eb;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.35);
}

/* Social Google Login Button */
.social-auth-container {
    width: 100%;
}

.btn-google-auth {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px;
    color: #f8fafc;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-google-auth:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.22);
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.1rem 0;
    color: #64748b;
    font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-divider span {
    padding: 0 0.75rem;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s ease;
}

.form-input:focus {
    border-color: var(--primary);
}

/* Inputs with Left Icons */
.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.input-icon {
    position: absolute;
    left: 1rem;
    color: #64748b;
    pointer-events: none;
    transition: color 0.2s ease;
}

.input-wrapper:focus-within .input-icon {
    color: #3b82f6;
}

.form-input.icon-input {
    width: 100%;
    padding: 0.85rem 1rem 0.85rem 2.75rem;
    background: #080d19;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    color: #f8fafc;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.2s ease;
}

.form-input.icon-input::placeholder {
    color: #475569;
}

.form-input.icon-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

/* Password Recovery Link */
.forgot-pass-wrapper {
    display: flex;
    justify-content: flex-end;
    margin-top: 0.4rem;
}

.forgot-pass-link {
    color: #3b82f6;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s ease;
}

.forgot-pass-link:hover {
    color: #60a5fa;
    text-decoration: underline;
}

.auth-back-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 0.75rem;
}

/* Vibrant Submit Buttons (Ingresar & Crear cuenta) */
.btn-auth-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.9rem 1.5rem;
    background: #0066ff;
    border: none;
    border-radius: 14px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px rgba(0, 102, 255, 0.35);
    margin-top: 0.5rem;
}

.btn-auth-submit:hover {
    background: #0052cc;
    box-shadow: 0 6px 22px rgba(0, 102, 255, 0.45);
    transform: translateY(-1px);
}

.btn-auth-submit:disabled {
    opacity: 0.65;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.trial-info-badge {
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 8px;
    padding: 0.75rem;
    font-size: 0.82rem;
    color: #c7d2fe;
    line-height: 1.4;
}

.auth-error-msg {
    color: #f87171;
    font-size: 0.85rem;
    background: rgba(239, 68, 68, 0.12);
    padding: 0.7rem 0.85rem;
    border-radius: 10px;
    border: 1px solid rgba(239, 68, 68, 0.25);
    line-height: 1.4;
}

.auth-success-msg {
    color: #34d399;
    font-size: 0.85rem;
    background: rgba(16, 185, 129, 0.12);
    padding: 0.7rem 0.85rem;
    border-radius: 10px;
    border: 1px solid rgba(16, 185, 129, 0.25);
    line-height: 1.4;
}

.auth-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    display: inline-block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.w-full {
    width: 100%;
}

/* ==========================================================================
   PRICING & LEGAL VIEWS
   ========================================================================== */
.legal-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2.5rem 1.5rem;
    width: 100%;
}

.legal-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.legal-header h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.legal-header p {
    color: var(--text-muted);
    font-size: 1.05rem;
}

.badge-tag {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(99, 102, 241, 0.15);
    color: #818cf8;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.pricing-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    align-items: stretch;
}

.pricing-card {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.pricing-card:hover {
    transform: translateY(-4px);
    border-color: rgba(99, 102, 241, 0.4);
}

.pricing-card.featured {
    border-color: var(--primary);
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.9), rgba(99, 102, 241, 0.08));
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.2);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    right: 24px;
    background: var(--primary);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    text-transform: uppercase;
}

.pricing-card-header h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.price-box {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
    margin: 1rem 0;
}

.price-box .currency {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-muted);
}

.price-box .amount {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-light);
}

.price-box .period {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.pricing-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin: 1.5rem 0;
    flex: 1;
}

.pricing-features li {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.92rem;
    color: var(--text-muted);
}

.pricing-features li svg {
    color: var(--success);
    flex-shrink: 0;
}

.btn-select-plan {
    width: 100%;
    padding: 0.85rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

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

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-light);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.legal-content {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    line-height: 1.6;
}

.legal-content h3 {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-top: 0.5rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

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

.contact-info {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

/* ==========================================================================
   PERU LIBRO DE RECLAMACIONES FORM
   ========================================================================== */
.reclamaciones-container {
    max-width: 900px;
}

.reclamaciones-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(185, 28, 28, 0.05));
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 14px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.reclamaciones-logo-badge {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    border-radius: 12px;
    padding: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.reclamaciones-title-main {
    font-size: 1.4rem;
    font-weight: 800;
    color: #f87171;
    letter-spacing: 0.5px;
}

.reclamaciones-subtitle-main {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-top: 0.3rem;
}

.provider-info-box {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.25rem;
    margin-bottom: 2rem;
}

.provider-info-box h3 {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
}

.provider-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.provider-grid .full-width {
    grid-column: span 2;
}

.reclamaciones-form {
    background: var(--bg-panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.reclamaciones-form h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-light);
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
    margin-top: 0.5rem;
}

.form-row {
    display: flex;
    gap: 1rem;
}

@media (max-width: 640px) {
    .form-row {
        flex-direction: column;
    }
}

.flex-1 { flex: 1; }
.flex-2 { flex: 2; }

.radio-group {
    display: flex;
    gap: 1.5rem;
    padding: 0.5rem 0;
}

.radio-group label {
    font-size: 0.9rem;
    color: var(--text-light);
    cursor: pointer;
}

.checkbox-group label {
    font-size: 0.85rem;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.reclamaciones-submit-row {
    margin-top: 1rem;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.05rem;
    width: 100%;
}

/* ==========================================================================
   RESPONSIVE FOOTER (PERU COMPLIANT)
   ========================================================================== */
.app-footer {
    background: rgba(15, 23, 42, 0.95);
    border-top: 1px solid var(--border);
    padding: 3rem 2rem 1.5rem;
    margin-top: auto;
    width: 100%;
    height: fit-content;
    flex-shrink: 0;
    position: relative;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 2rem;
}

.footer-col h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1.2rem;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-col a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.footer-col a:hover {
    color: var(--primary);
}

.plan-pill {
    display: inline-block;
    font-size: 0.8rem;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-weight: 500;
}

.plan-pill.free { background: rgba(99, 102, 241, 0.15); color: #818cf8; }
.plan-pill.monthly { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.plan-pill.yearly { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }

/* Highlighted Libro de Reclamaciones Box */
.footer-reclamaciones-col {
    grid-column: span 1;
}

@media (min-width: 1024px) {
    .footer-grid {
        grid-template-columns: repeat(4, 1fr) 1.5fr;
    }
}

.reclamaciones-badge-link {
    text-decoration: none;
    display: block;
}

.reclamaciones-box {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(185, 28, 28, 0.25));
    border: 1px solid rgba(239, 68, 68, 0.4);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.reclamaciones-box:hover {
    transform: translateY(-2px);
    border-color: #ef4444;
    box-shadow: 0 8px 20px rgba(239, 68, 68, 0.25);
}

.reclamaciones-icon {
    color: #f87171;
    flex-shrink: 0;
}

.reclamaciones-text {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.reclamaciones-title {
    font-size: 0.9rem;
    font-weight: 800;
    color: #f87171;
    letter-spacing: 0.5px;
}

.reclamaciones-sub {
    font-size: 0.72rem;
    color: #fca5a5;
    line-height: 1.3;
}

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
    gap: 1rem;
}

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

.footer-social {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.social-icon {
    color: var(--text-muted);
    transition: color 0.2s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.social-icon:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

