* {
    box-sizing: border-box;
}

/* CURSOR PERSONALIZADO - BUZO */
body, html {
    cursor: url('cursor-diver.png'), auto !important;
}

a, button, .clickable, input[type="submit"], input[type="button"] {
    cursor: url('cursor-diver.png'), pointer !important;
}
/* FIN CURSOR PERSONALIZADO */

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
    margin: 0;
    padding: 20px;
    background-color: #f5f5f5;
    line-height: 1.6;
}

.logo-container {
    text-align: center;
    margin-bottom: 20px;
}

.logo {
    width: 80%;
    max-width: 400px;
    height: auto;
}

.logo1 {
    width: 50%;
    max-width: 200px;
    height: auto;
}

/* Loader animado para splash screen */
.loader {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #e74c3c;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    font-size: 18px;
    color: #555;
    font-weight: 500;
}

h1 {
    text-align: center;
    margin: 20px 0;
    color: #333;
    font-size: 24px;
}

h6 {
    text-align: center;
    margin-top: -15px;
    margin-bottom: 20px;
    margin-left: auto;
    margin-right: auto;
    color: #666;
    font-style: italic;
    font-weight: normal;
    font-size: 14px;
    width: 100%;
    display: block;
}

form {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

fieldset {
    border: 2px solid #e74c3c;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

legend {
    font-weight: bold;
    color: #e74c3c;
    padding: 0 10px;
    font-size: 18px;
}

label {
    display: block;
    margin: 10px 0 5px;
    font-weight: 500;
    color: #333;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"] {
    width: 100%;
    padding: 12px;
    margin: 5px 0 10px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus {
    outline: none;
    border-color: #e74c3c;
}

small {
    display: block;
    color: #666;
    font-size: 12px;
    margin-top: -8px;
    margin-bottom: 10px;
}

/* Estilos para equipos */
.equipment-item {
    margin: 10px 0;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 5px;
    transition: background-color 0.2s;
}

.equipment-item:hover {
    background: #f0f0f0;
}

input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 10px;
    vertical-align: middle;
    cursor: pointer;
}

.equipment-item label {
    display: inline;
    cursor: pointer;
    font-size: 16px;
    vertical-align: middle;
}

/* Botones mejorados para móvil */
.button-group {
    text-align: center;
    margin: 20px 0;
}

button {
    padding: 15px 30px;
    font-size: 18px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s;
    width: 100%;
    max-width: 300px;
}

.btn-calculate {
    background-color: #3498db;
    color: white;
}

.btn-calculate:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-submit {
    background-color: #e74c3c;
    color: white;
}

.btn-submit:hover {
    background-color: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

button:disabled {
    background-color: #95a5a6;
    cursor: not-allowed;
    transform: none;
}

/* Display del total */
.total-display {
    text-align: center;
    font-size: 24px;
    font-weight: bold;
    color: #27ae60;
    margin: 20px 0;
    padding: 15px;
    background: #d5f4e6;
    border-radius: 8px;
    border: 2px solid #27ae60;
    display: none;
}

/* Mensajes de error y éxito */
.error-message,
.success-message {
    max-width: 600px;
    margin: 20px auto;
    padding: 20px;
    border-radius: 8px;
    font-weight: 600;
    text-align: center;
    font-size: 18px;
    line-height: 1.6;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.error-message {
    background-color: #fadbd8;
    color: #c0392b;
    border: 3px solid #e74c3c;
}

.success-message {
    background-color: #d5f4e6;
    color: #27ae60;
    border: 3px solid #27ae60;
}

.error-message:empty,
.success-message:empty {
    display: none;
    padding: 0;
    margin: 0;
    border: none;
}

/* Animaciones para mensajes */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.success-message {
    animation: fadeIn 0.5s ease-out;
}

.error-message {
    animation: shake 0.5s ease-out;
}

footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px 0;
    border-top: 2px solid #ddd;
    background: white;
    border-radius: 8px;
}

footer a {
    color: #e74c3c;
    text-decoration: none;
    display: block;
    margin: 5px 0;
}

footer a:hover {
    text-decoration: underline;
}

footer p {
    margin: 10px 0 0;
    color: #666;
}

footer span {
    display: block;
    margin: 5px 0;
    color: #333;
}

/* Responsive para tablets */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    h1 {
        font-size: 20px;
    }
    
    .logo {
        width: 90%;
    }
    
    form {
        padding: 15px;
    }
    
    legend {
        font-size: 16px;
    }
}

/* Optimización para móviles pequeños */
@media (max-width: 480px) {
    h1 {
        font-size: 18px;
    }
    
    h6 {
        text-align: center;
        font-size: 13px;
        margin-top: -12px;
        padding: 0 10px;
        width: 100%;
        display: block;
    }
    
    fieldset {
        padding: 10px;
    }
    
    button {
        font-size: 16px;
        padding: 12px 20px;
    }
    
    .total-display {
        font-size: 20px;
    }
    
    .equipment-item label {
        font-size: 14px;
    }
    
    /* Mensajes más visibles en móvil */
    .error-message,
    .success-message {
        margin: 30px 10px;
        padding: 20px 15px;
        font-size: 16px;
        position: relative;
        z-index: 1000;
        width: calc(100% - 20px);
        max-width: 100%;
        box-sizing: border-box;
    }
}
