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

body {
    background-image: url('../img/fondo01.svg');
    background-repeat: repeat;
    background-size: 450px 450px;
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
}

header {
    background: #00766E;
    color: #ececec;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.titulo-principal {
    font-family: 'Shadows Into Light Two', cursive;
    font-size: 3.5rem;
    font-weight: 700;
    color: #feffd7;
    margin: 0;
}

.subtitulo {
    font-size: 1.3rem;
    font-style: italic;
    color: #feffd7;
    margin: 0;
}

.fecha {
    font-size: 1.1rem;
    color: #feffd7;
    margin: 0;
}

.libreta {
    background: #feffd7;
    border-radius: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    position: relative;
}

.libreta::before {
    content: '';
    position: absolute;
    left: 60px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #e74c3c;
    opacity: 0.3;
}

.libreta-header {
    background: linear-gradient(135deg, #2e2e2e 0%, #4e4e4e 100%);
    padding: 2rem;
}

.input-group-libreta {
    display: flex;
    gap: 0.5rem;
}

.input-tarea {
    flex: 1;
    padding: 0.75rem 1rem;
    font-family: 'Inter', sans-serif;
    font-size: 1.2rem;
    border: 3px solid #fff;
    border-radius: 8px;
    background: rgba(255, 253, 225, 0.95);
    transition: all 0.3s ease;
}

.input-tarea:focus {
    outline: none;
    border-color: #ffd93d;
    box-shadow: 0 0 0 3px rgba(255, 217, 61, 0.3);
}

.boton-agregar {
    padding: 0.75rem 1.5rem;
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    font-weight: bold;
    background: #ffd93d;
    color: #2c3e50;
    border: 3px solid #fff;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.boton-agregar:hover {
    background: #ffc107;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.boton-agregar:active {
    transform: translateY(0);
}

.alerta-mensaje {
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.95);
    border: 3px solid #e74c3c;
    border-radius: 8px;
    color: #c0392b;
    font-size: 1.1rem;
    animation: shake 0.5s ease;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-10px);
    }

    75% {
        transform: translateX(10px);
    }
}

.libreta-contenido {
    padding: 2rem 2rem 2rem 80px;
    min-height: 400px;
    background: #feffd7;
}

.lista-tareas {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tarea-item {
    position: relative;
    padding: 1rem 0;
    border-bottom: 2px dotted #bdc3c7;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
}

.tarea-item:hover {
    background: rgba(103, 126, 234, 0.05);
    padding-left: 0.5rem;
    margin-left: -0.5rem;
}

.tarea-texto {
    font-family: 'Shadows Into Light Two', cursive;
    font-size: 1.8rem;
    color: #2c3e50;
    flex: 1;
    word-wrap: break-word;
    padding-right: 1rem;
}

.tarea-completada .tarea-texto {
    text-decoration: line-through;
    text-decoration-thickness: 3px;
    text-decoration-color: #e74c3c;
    color: #95a5a6;
    opacity: 0.7;
}

.tarea-acciones {
    display: flex;
    gap: 0.5rem;
    flex-shrink: 0;
}

.btn-accion {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.btn-accion:hover {
    transform: scale(1.15);
}

.btn-accion:active {
    transform: scale(0.95);
}

.btn-completar {
    background: #2ecc71;
    color: #fff;
}

.btn-completar:hover {
    background: #27ae60;
    box-shadow: 0 4px 8px rgba(46, 204, 113, 0.3);
}

.btn-editar {
    background: #f39c12;
    color: #fff;
}

.btn-editar:hover {
    background: #e67e22;
    box-shadow: 0 4px 8px rgba(243, 156, 18, 0.3);
}

.btn-eliminar {
    background: #e74c3c;
    color: #fff;
}

.btn-eliminar:hover {
    background: #c0392b;
    box-shadow: 0 4px 8px rgba(231, 76, 60, 0.3);
}

.btn-accion.disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

.mensaje-vacio {
    text-align: center;
    padding: 3rem 0;
    color: #95a5a6;
}

.mensaje-vacio i {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
}

.mensaje-vacio p {
    font-family: 'Caveat', cursive;
    font-size: 2rem;
    margin: 0;
}

footer {
    background: #00766E;
    margin-top: 2rem;
}

.nota-footer {
    font-size: 1rem;
    color: #feffd7;
    margin: 0;
}

.d-none {
    display: none;
}

@media (max-width: 768px) {
    .titulo-principal {
        font-size: 2.5rem;
    }

    .subtitulo {
        font-size: 1.1rem;
    }

    .libreta::before {
        left: 40px;
    }

    .libreta-contenido {
        padding-left: 60px;
    }

    .tarea-texto {
        font-size: 1.5rem;
    }

    .input-group-libreta {
        flex-direction: column;
    }

    .boton-agregar {
        width: 100%;
    }
}

@media print {
    body {
        background: white;
    }

    .libreta-header,
    .tarea-acciones,
    footer {
        display: none;
    }
}