:root {
    --bg-color: #f0f4f8; /* Un fondo muy suave, casi blanco */
    --circle-color-start: #b4cde6; /* Azul claro y suave */
    --circle-color-end: #8da9c4; /* Azul un poco más profundo */
    --text-color-light: #ffffff;
    --text-color-dark: #3b4a5a;
    --transition-duration: 7s; /* Duración de la inhalación y exhalación */
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh; /* Ocupa toda la altura de la pantalla */
    height: 100svh; /* Mejor para móviles, evita saltos con la UI del navegador */
    background-color: var(--bg-color);
    overflow: hidden; /* Evita barras de scroll accidentales */
}

.breathing-app {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 90vw;
    height: 90vw;
    max-width: 400px;
    max-height: 400px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent; /* Evita el destello azul en móviles al tocar */
}

.circle {
    width: 33%; /* 1/3 del contenedor */
    height: 33%;
    background-color: var(--circle-color-start);
    border-radius: 50%;
    position: absolute;
    transition: all var(--transition-duration) cubic-bezier(0.4, 0, 0.2, 1);
}

.circle.grow {
    transform: scale(3); /* Crecerá hasta ocupar todo el contenedor */
    background-color: var(--circle-color-end);
}

.instruction {
    font-size: clamp(1.2rem, 5vw, 1.8rem); /* Texto responsive */
    font-weight: 500;
    color: var(--text-color-light);
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.2);
    z-index: 10;
    text-align: center;
    padding: 0 20px;
    user-select: none; /* Evita que el texto se pueda seleccionar */
    transition: opacity 0.5s ease;
}

.disclaimer {
    position: absolute;
    bottom: 15px;
    width: 90%;
    max-width: 600px;
    text-align: center;
    color: var(--text-color-dark);
    font-size: 0.75rem;
    opacity: 0.7;
}

/* Icono de Configuración */
.settings-icon, .audio-control {
    font-size: 1.5rem;
    color: var(--text-color-dark);
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.3s, transform 0.3s;
}

.settings-icon:hover, .audio-control:hover {
    opacity: 1;
}

.settings-icon:hover {
    transform: rotate(45deg);
}

/* Panel de Configuración */
.settings-panel {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background-color: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    gap: 15px; /* Espacio entre botones */
    z-index: 101;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
}

.settings-panel.visible {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
}

.settings-panel h2 {
    text-align: center;
    color: var(--text-color-dark);
    margin-bottom: 10px;
}

.tech-btn, #close-settings {
    background-color: var(--bg-color);
    border: 2px solid var(--circle-color-start);
    color: var(--text-color-dark);
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
}

.tech-btn:hover, #close-settings:hover {
    background-color: var(--circle-color-start);
    color: white;
}

.tech-btn.active {
    background-color: var(--circle-color-end);
    border-color: var(--circle-color-end);
    color: white;
    font-weight: bold;
}

/* Controles de la esquina superior */

.audio-control:hover {
    opacity: 1;
}