/* --- RESET GENERAL --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

html, body {
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)),
        url('../images/Ocosingo.jpg')
        no-repeat center center/cover;
    color: #fff;
    overflow-x: hidden;
}

/* --- CONTENEDOR PRINCIPAL --- */
.container {
    position: relative;
    z-index: 2;
    width: 90%;
    max-width: 1200px;
    margin: 50px auto;
    padding-bottom: 80px; /* Espacio para el footer fijo */
    text-align: center;
    animation: fadeIn 1s ease-in-out;
}

/* --- TITULO --- */
h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-align: center;
    text-shadow: 2px 2px 6px #000;
}

/* --- TEXTO INTRODUCTORIO --- */
.intro-text,
p.subtitle {
    font-size: 1.3rem;
    max-width: 650px;
    margin: 0 auto 50px auto;
    text-align: center;
    text-shadow: 1px 1px 3px #000;
}

/* --- FOOTER --- */
footer {
    background: rgba(255, 255, 255, 0.05); /* Transparente estilo glass */
    backdrop-filter: blur(12px); /* efecto blur */
    border-top: 2px solid rgba(255, 193, 7, 0.3); /* borde amarillo */
    box-shadow: 0 -4px 20px rgba(255, 193, 7, 0.3); /* glow amarillo */
    color: #fff;
    text-align: center;
    padding: 12px 20px;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000;
    overflow: hidden;
    border-radius: 15px 15px 0 0; /* esquinas redondeadas arriba */
}

footer p {
    margin: 2px 0;
}

footer p:first-child {
    color: #ffcc00;
    text-shadow: 0 0 10px #ffcc00;
    font-weight: 600;
}

/* --- ANIMACIONES --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- GRID TARJETAS --- */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 25px;
}

/* --- TARJETAS FLIP 3D (compartidas entre taxistas y sobre) --- */
.card {
    perspective: 1000px;
    min-height: 400px;
}

.card:nth-child(1) { animation-delay: 0.1s; }
.card:nth-child(2) { animation-delay: 0.2s; }
.card:nth-child(3) { animation-delay: 0.3s; }
.card:nth-child(4) { animation-delay: 0.4s; }
.card:nth-child(5) { animation-delay: 0.5s; }
.card:nth-child(6) { animation-delay: 0.6s; }

.card-inner {
    position: relative;
    width: 100%;
    height: 400px;
    transition: all 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-style: preserve-3d;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.card:hover .card-inner {
    transform: rotateY(180deg);
}

.card-front, .card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 15px;
    overflow: hidden;
}

.card-front {
    background: rgba(26,26,26,0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.1);
    display: flex;
    flex-direction: column;
}

.card-front img {
    width: 100%;
    height: 60%;
    object-fit: cover;
    border-radius: 20px 20px 0 0;
    transition: all 0.3s ease;
}

.card:hover .card-front img {
    transform: scale(1.05);
}

.card-front .card-body {
    padding: 25px;
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    z-index: 2;
    position: relative;
}

.card-front .card-body h2 {
    font-size: 1.2rem;
    margin-bottom: 5px;
    color: #ffc107;
}

.card-front .card-body p {
    font-size: 0.95rem;
    color: #fff;
    margin: 0;
}

.card-back {
    background: rgba(26,26,26,0.9);
    backdrop-filter: blur(10px);
    color: #fff;
    transform: rotateY(180deg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    border: 1px solid rgba(255,255,255,0.1);
}

.card-back h2 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #ffc107;
    width: 100%;
}

.card-back h3 {
    font-size: 1rem;
    margin-top: 8px;
    margin-bottom: 5px;
    color: #ffc107;
    width: 100%;
}

.card-back p {
    font-size: 0.95rem;
    margin-bottom: 8px;
    color: #ddd;
    width: 100%;
}

.card-back hr {
    width: 100%;
    border: 0;
    border-top: 1px solid rgba(255,255,255,0.2);
    margin: 10px 0;
}

/* --- ESTADO VACÍO --- */
.empty-state {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: 15px;
    color: #fff;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    grid-column: 1 / -1;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #ffc107;
}

.empty-state p {
    font-size: 1rem;
    color: #ddd;
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }
    .container {
        margin: 30px auto;
        padding-bottom: 90px; /* Más espacio en móvil */
    }
    footer {
        padding: 10px 15px;
        font-size: 0.7rem;
    }
    .card-inner {
        height: 380px;
    }
}

/* --- ESTILOS PARA PÁGINA OFFLINE --- */
.hoja-libreta {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    border: 2px solid rgba(255, 193, 7, 0.3);
    border-radius: 15px;
    padding: 30px;
    margin: 20px auto;
    max-width: 800px;
    color: #fff;
    box-shadow: 0 4px 20px rgba(255, 193, 7, 0.3);
}

.hoja-titulo {
    color: #ffc107;
    text-shadow: 0 0 10px rgba(255, 193, 7, 0.5);
    font-size: 2rem;
    margin-bottom: 20px;
    text-align: center;
}

.hoja-aviso {
    color: #fff;
    text-align: center;
    padding: 20px;
    font-size: 1.1rem;
}

.lista-cat {
    color: #fff;
    padding: 10px;
    margin: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* --- DESHABILITAR IMPRESIÓN --- */
@media print {
    * {
        display: none !important;
    }
    
    body::before {
        content: "Esta página no está diseñada para imprimirse.";
        display: block !important;
        text-align: center;
        padding: 50px;
        font-size: 18px;
    }
}

