/* ============================================================
   CACHE DETALLE - Página individual de caché
   ============================================================ */

.cache-detalle {
    max-width: 780px;
    margin: 0 auto;
    padding: 0 1rem 3rem;
}

/* --- Cabecera -------------------------------------------- */
.cache-header {
    margin-bottom: 2rem;
}

.cache-header h1 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #1a1a2e;
    line-height: 1.3;
    margin-bottom: 0.5rem;
}

.cache-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.85rem;
    color: #666;
    flex-wrap: wrap;
}

.cache-meta-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: #f0f4ff;
    border: 1px solid #d0d8ff;
    border-radius: 20px;
    padding: 0.2rem 0.7rem;
    font-size: 0.8rem;
    color: #4a5568;
    font-weight: 500;
}

/* --- Descripción ----------------------------------------- */
.cache-descripcion {
    background: #fafafa;
    border-left: 4px solid #f7931a;
    border-radius: 0 8px 8px 0;
    padding: 1.25rem 1.5rem;
    margin-bottom: 2rem;
    font-size: 0.95rem;
    line-height: 1.7;
    color: #333;
    white-space: pre-line;
}

/* --- Pista ---------------------------------------------- */
.cache-pista-wrapper {
    margin-bottom: 2rem;
}

.cache-pista-wrapper h2 {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.cache-pista-box {
    background: #fffbf0;
    border: 1px solid #f7c948;
    border-radius: 10px;
    padding: 1rem 1.25rem;
    position: relative;
}

.cache-pista-texto {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #555;
    filter: blur(6px);
    user-select: none;
    transition: filter 0.3s ease;
    white-space: pre-line;
}

.cache-pista-texto.revelada {
    filter: none;
    user-select: auto;
}

.btn-revelar-pista {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
    width: 100%;
    padding: 0.5rem 1rem;
    background: #f7931a;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-revelar-pista:hover {
    background: #e0821a;
}

/* --- Fotos ---------------------------------------------- */
.cache-fotos-wrapper {
    margin-bottom: 2rem;
}

.cache-fotos-wrapper h2 {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.cache-fotos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1rem;
}

.cache-foto-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    background: #e8e8e8;
    aspect-ratio: 4/3;
}

.cache-foto-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: filter 0.3s ease;
    cursor: pointer;
}

.cache-foto-item img.blur {
    filter: blur(12px);
}

.cache-foto-item img.visible {
    filter: none;
}

.btn-mostrar-foto {
    position: absolute;
    bottom: 0.6rem;
    right: 0.6rem;
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 0.3rem 0.7rem;
    font-size: 0.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: background 0.2s;
    backdrop-filter: blur(4px);
}

.btn-mostrar-foto:hover {
    background: rgba(0,0,0,0.8);
}

.btn-mostrar-foto.ocultar {
    display: none;
}

/* --- Detalles del caché --------------------------------- */
.cache-detalles-wrapper {
    margin-bottom: 2rem;
}

.cache-detalles-wrapper h2 {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.cache-detalles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.cache-detalle-item {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 0.85rem 0.75rem;
    text-align: center;
}

.cache-detalle-item .label {
    font-size: 0.72rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.cache-detalle-item .valor {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
}

.cache-detalle-item .valor.codigo {
    font-size: 1.3rem;
    color: #f7931a;
}

/* --- Coordenadas ---------------------------------------- */
.cache-coordenadas {
    background: #f0f4ff;
    border: 1px solid #c5d0f5;
    border-radius: 10px;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
}

.cache-coordenadas .coord-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #666;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.coord-valor {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.coord-valor span {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a2e;
    font-family: monospace;
    letter-spacing: 0.03em;
}

.btn-copiar-coord {
    background: none;
    border: 1px solid #a0aec0;
    border-radius: 6px;
    padding: 0.25rem 0.6rem;
    font-size: 0.78rem;
    color: #4a5568;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.btn-copiar-coord:hover {
    background: #e2e8f0;
}

.btn-copiar-coord.copiado {
    color: #38a169;
    border-color: #38a169;
}

/* --- Botón Get Directions ------------------------------- */
.btn-directions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1.5rem;
    background: #1a1a2e;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 0.5rem;
}

.btn-directions:hover {
    background: #2d2d4e;
    color: white;
    text-decoration: none;
}

.btn-directions svg {
    flex-shrink: 0;
}

/* --- Navegación volver ---------------------------------- */
.cache-nav {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.btn-volver {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1rem;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.88rem;
    color: #444;
    text-decoration: none;
    transition: all 0.2s;
    font-weight: 500;
}

.btn-volver:hover {
    background: #f5f5f5;
    text-decoration: none;
    color: #222;
}

.btn-escanear-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.1rem;
    background: linear-gradient(135deg, #FE9000, #CB6015);
    border-radius: 8px;
    font-size: 0.88rem;
    color: white;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.2s;
    box-shadow: 0 2px 6px rgba(203, 96, 21, 0.35);
}

.btn-escanear-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(203, 96, 21, 0.45);
    text-decoration: none;
    color: white;
}

/* --- Responsive ----------------------------------------- */
@media (max-width: 500px) {
    .cache-header h1 {
        font-size: 1.3rem;
    }

    .cache-detalles-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .cache-fotos-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Subtítulo del caché --------------------------------- */
.cache-subtitulo {
    font-size: 0.95rem;
    color: #f7931a;
    font-weight: 600;
    margin: 0.25rem 0 0.75rem;
    letter-spacing: 0.01em;
}

/* --- Secciones pendientes -------------------------------- */
.cache-pendiente-wrapper {
    margin-bottom: 2rem;
}

.cache-pendiente-wrapper h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 0.75rem;
}

.cache-pendiente-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    padding: 1.5rem;
    background: #f9f9f9;
    border: 1px dashed #ccc;
    border-radius: 10px;
    text-align: center;
}

.pendiente-icono {
    font-size: 2rem;
    opacity: 0.5;
}

.pendiente-texto {
    font-size: 0.9rem;
    color: #888;
    font-weight: 500;
    margin: 0;
}

.pendiente-subtexto {
    font-size: 0.8rem;
    color: #aaa;
    margin: 0;
}

/* --- Coordenadas pendientes ----------------------------- */
.cache-coordenadas-pendiente {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: #f9f9f9;
    border: 1px dashed #ccc;
    border-radius: 10px;
    margin-top: 1rem;
}

.cache-coordenadas-pendiente .pendiente-icono {
    font-size: 1.5rem;
    opacity: 0.5;
    flex-shrink: 0;
}

.cache-coordenadas-pendiente .pendiente-texto {
    font-size: 0.88rem;
    font-weight: 500;
    margin-bottom: 0.1rem;
}

/* --- Detalle item pendiente ----------------------------- */
.cache-detalle-item.pendiente .valor.codigo,
.cache-detalle-item.pendiente .valor {
    color: #bbb;
}
