:root {
    /* Paleta basada en el diseño Bootstrap 5 */
    --primary-color: #0d6efd; 
    --primary-hover: #0b5ed7;
    
    /* TONOS SUAVES PARA NO LASTIMAR LA VISTA */
    --bg-body: #e9ecef; /* Gris suave en lugar de blanco puro */
    --bg-card: #f8f9fa; /* Blanco roto/crema tenue para las cajas */
    
    --text-main: #212529;
    --text-muted: #6c757d;
    --border-color: #dee2e6;
    --warning-color: #ffc107;
    --warning-hover: #ffca2c;
    --danger-color: #dc3545;
    
    /* Dimensiones estructurales */
    --border-radius: 0.375rem;
    --border-radius-lg: 0.5rem;
    --shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.05);
    --shadow-md: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

@import url('https://fonts.googleapis.com/css2?family=Source+Sans+Pro:ital,wght@0,300;0,400;0,600;0,700;1,400&display=swap');

body {
    font-family: 'Source Sans Pro', system-ui, sans-serif;
    color: var(--text-main);
    background-color: var(--bg-body);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

img, iframe {
    max-width: 100%;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.15s ease-in-out;
}
a:hover {
    color: var(--primary-hover);
}

/* =========================================
   NAVEGACIÓN Y HEADER (LOGO CENTRADO)
   ========================================= */
header {
    background-color: var(--primary-color);
    display: block;
    padding: 15px 0;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.head-bg {
    display: none; /* Se oculta el banner viejo gigante para un look limpio */
}

nav {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0.5rem 1rem;
    display: flex;
    flex-direction: column; /* Apila el logo arriba y los botones abajo */
    align-items: center; /* Centra todo horizontalmente */
    gap: 15px; /* Separación entre el logo y los botones */
    background: transparent;
    border: none;
    box-shadow: none;
    height: auto;
}

.brand-container {
    /* ======================================================== */
    /* PON AQUÍ LA URL DE TU LOGO ENTRE LAS COMILLAS SIMPLES: */
    background-image: url('/images/baner.png'); 
    /* ======================================================== */
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    width: 300px; /* Ancho máximo del logo */
    height: 70px; /* Alto máximo del logo */
    
    /* Estas líneas ocultan el Slogan y Texto para que solo se vea la imagen */
    color: transparent !important;
    text-indent: -9999px;
    overflow: hidden;
    display: block;
    margin: 0;
    padding: 0;
}

nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
}

nav li {
    border: none;
    display: block;
    height: auto;
    padding: 0;
}

nav li a {
    color: rgba(255, 255, 255, 0.85);
    font-weight: 600;
    padding: 0.5rem 1rem;
    display: block;
    border-radius: var(--border-radius);
    text-shadow: none;
    text-transform: uppercase;
    font-size: 0.95rem;
}

nav li a:hover, nav li:hover {
    background-color: rgba(255, 255, 255, 0.15);
    color: #ffffff;
}

/* =========================================
   BARRA DE ADMINISTRACIÓN (Arreglo botones flotantes)
   ========================================= */
.admin-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    list-style: none;
    background-color: var(--bg-card);
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}

.admin-nav li a {
    display: block;
    padding: 8px 16px;
    background-color: var(--bg-body);
    color: var(--text-main);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.admin-nav li a:hover {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
}

/* =========================================
   CONTENEDORES PRINCIPALES (Estilo Cards)
   ========================================= */
.content-wrapper {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 15px 2rem 15px;
}

form, .grey-box, .show_container {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
}

form.new-form {
    margin: 0;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

.input-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    border: none;
    border-bottom: 2px solid var(--border-color);
    border-radius: 0;
    background: transparent;
    padding-left: 0;
}
.input-title:focus {
    border-color: var(--primary-color);
    box-shadow: none;
}

/* =========================================
   INPUTS Y BOTONES
   ========================================= */
input:not([type=radio]), textarea, select {
    width: 100%;
    padding: 0.375rem 0.75rem;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-main);
    background-color: #fff;
    border: 1px solid #ced4da;
    border-radius: var(--border-radius);
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    outline: none;
    margin-bottom: 10px;
}

input:focus, textarea:focus, select:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

button, .btn {
    display: inline-block;
    font-weight: 600;
    text-align: center;
    vertical-align: middle;
    cursor: pointer;
    background-color: var(--primary-color);
    border: 1px solid var(--primary-color);
    color: #fff;
    padding: 0.375rem 0.75rem;
    font-size: 1rem;
    border-radius: var(--border-radius);
    transition: all 0.15s ease-in-out;
}

button:hover, .btn:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.danger { color: var(--danger-color); }
.center { text-align: center; }

/* =========================================
   PESTAÑAS (TABS) - REPARADAS CON FLEXBOX
   ========================================= */
.tabs {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0; /* Se pega al contenedor de abajo */
    padding-left: 0;
    gap: 0.25rem;
}

.tabs li {
    background: transparent;
    border: 1px solid transparent;
    border-bottom: none;
    padding: 0.5rem 1rem;
    border-top-left-radius: var(--border-radius);
    border-top-right-radius: var(--border-radius);
    cursor: pointer;
    color: var(--primary-color);
    font-weight: 600;
    height: auto;
    line-height: normal;
    margin-bottom: -1px; /* Superpone el borde inferior */
    flex: 0 1 auto; /* Evita que se estiren */
}

.tabs li:hover {
    border-color: #e9ecef #e9ecef var(--border-color);
}

.tabs li.active {
    color: var(--text-main);
    background-color: var(--bg-card);
    border-color: var(--border-color) var(--border-color) var(--bg-card);
}

.tabs li div {
    border: none;
    height: auto;
    border-radius: 0;
}

.tabs li.active>div {
    border: none;
    background: transparent;
}

.tab_container {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-top: none;
    border-bottom-left-radius: var(--border-radius);
    border-bottom-right-radius: var(--border-radius);
    padding: 1.5rem;
    word-wrap: break-word;
    word-break: break-all;
    box-shadow: var(--shadow-sm);
}

.tab_content { display: none; }
.tab_content.active {
    display: block;
    animation: fade-in 0.3s ease-in-out;
}

.tab_content textarea {
    min-height: 40vh;
    font-family: monospace;
}

.bbuttons {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

@keyframes fade-in {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =========================================
   LISTA DE PASTES (HOME)
   ========================================= */
.content-home {
    display: block;
}

.paste-list {
    display: flex;
    flex-direction: column;
    padding-left: 0;
    margin-bottom: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    box-shadow: var(--shadow-sm);
    list-style: none;
}

.paste-list li {
    display: block;
    padding: 0.75rem 1.25rem;
    text-decoration: none;
    border-bottom: 1px solid var(--border-color);
    font-size: 1.1rem;
    font-weight: 600;
}

.paste-list li:last-child {
    border-bottom: none;
}

.paste-list li a {
    color: var(--primary-color);
    display: block;
}

.paste-list li:hover {
    background-color: var(--bg-body);
}

/* =========================================
   PAGINACIÓN
   ========================================= */
.pagination {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 0;
    gap: 0.25rem;
    margin-top: 1.5rem;
}

.pagination a, .paginate_button {
    display: block;
    padding: 0.375rem 0.75rem;
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--primary-color);
    border-radius: var(--border-radius);
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s;
}

.pagination a:hover {
    background-color: var(--bg-body);
    border-color: var(--border-color);
    color: var(--primary-hover);
}

.pagination .active a, .pagination .current {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    font-weight: 600;
}

/* =========================================
   BADGES INFERIORES Y BOTONES EXTRA
   ========================================= */
.bottom-badge {
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
    padding: 1rem 0 0 0;
    border-top: 1px solid var(--border-color);
    margin-top: 1.5rem;
}

.bottom-badge li a {
    background-color: var(--warning-color);
    color: #000;
    padding: 0.375rem 0.75rem;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 0.875rem;
    transition: background-color 0.2s;
}

.bottom-badge li a:hover {
    background-color: var(--warning-hover);
}

/* =========================================
   TABLAS NATIVAS
   ========================================= */
table {
    width: 100%;
    margin-bottom: 1rem;
    color: var(--text-main);
    vertical-align: top;
    border-color: var(--border-color);
    border-collapse: collapse;
}

th, td {
    padding: 0.75rem 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

th { font-weight: 700; color: var(--primary-color); }

table.striped > tbody > tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.02);
}

table.highlight > tbody > tr:hover {
    background-color: rgba(0, 0, 0, 0.04);
}

#table {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
}

/* =========================================
   FOOTER
   ========================================= */
footer {
    background-color: var(--primary-color);
    color: #fff;
    padding: 1.5rem 2rem;
    margin: 2rem auto 0 auto;
    border-radius: var(--border-radius);
    max-width: 1320px;
    text-align: left;
    font-size: 0.875rem;
}

footer a {
    color: rgba(255, 255, 255, 0.85);
}
footer a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Fixes extras (Swal, Ads, etc) */
.ad-container { margin: 1.5rem 0; text-align: center; }
.swal2-actions button { height: auto; border-radius: var(--border-radius); }
.jdbtn { width: 100%; max-width: 300px; margin-top: 10px; }
.vip { background-color: rgba(255, 193, 7, 0.1); border: 1px solid var(--warning-color); border-radius: var(--border-radius); padding: 1rem; display: flex; justify-content: center; gap: 10px; }
fieldset { padding: 1rem; border: 1px solid var(--border-color); border-radius: var(--border-radius); margin-bottom: 1.5rem; }