/**
 * Style rétro téléphone pour le Livre d'Or Audio
 * Design inspiré des téléphones à clapet des années 2000
 */

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

body {
    font-family: 'Courier New', monospace;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 80px;
    animation: gradientShift 10s ease infinite;
    background-size: 200% 200%;
    position: relative;
    overflow: hidden;
}

/* Particules flottantes magiques */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.1) 1px, transparent 1px),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.1) 1px, transparent 1px),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.05) 2px, transparent 2px);
    background-size: 50px 50px, 80px 80px, 120px 120px;
    animation: floatParticles 20s linear infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes floatParticles {
    0% { transform: translateY(0) rotate(0deg); }
    100% { transform: translateY(-100vh) rotate(360deg); }
}

/* Étoiles scintillantes */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 15% 15%, rgba(255, 255, 255, 0.8) 1px, transparent 1px),
        radial-gradient(circle at 85% 25%, rgba(255, 255, 255, 0.6) 1px, transparent 1px),
        radial-gradient(circle at 25% 85%, rgba(255, 255, 255, 0.7) 1px, transparent 1px),
        radial-gradient(circle at 75% 75%, rgba(255, 255, 255, 0.5) 1px, transparent 1px);
    background-size: 200px 200px;
    animation: twinkle 3s ease-in-out infinite alternate;
    pointer-events: none;
    z-index: 1;
}

@keyframes twinkle {
    0% { opacity: 0.3; }
    50% { opacity: 0.8; }
    100% { opacity: 0.3; }
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Conteneur principal du téléphone */
.container {
    width: 100%;
    /*max-width: 400px;*/
    perspective: 1000px;
    /*z-index: 10;*/
    position: relative;
    padding: 10px;
}

.phone {
    transform-style: preserve-3d;
    animation: phoneFloat 6s ease-in-out infinite;
}

@keyframes phoneFloat {
    0%, 100% { transform: translateY(0) rotateX(2deg) rotateY(-2deg); }
    50% { transform: translateY(-10px) rotateX(-2deg) rotateY(2deg); }
}

.phone-screen {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    border-radius: 30px;
    border: 8px solid #0f3460;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        0 0 30px rgba(102, 126, 234, 0.3),
        0 0 60px rgba(240, 147, 251, 0.2),
        0 0 90px rgba(102, 126, 234, 0.1),
        inset 0 2px 5px rgba(255, 255, 255, 0.2),
        inset 0 -2px 5px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    position: relative;
    animation: phoneGlow 3s ease-in-out infinite alternate, holographic 4s linear infinite;
    backdrop-filter: blur(10px);
    transform: translateZ(50px);
}

@keyframes holographic {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}

@keyframes phoneGlow {
    from { 
        box-shadow: 
            0 20px 40px rgba(0, 0, 0, 0.4), 
            0 0 30px rgba(102, 126, 234, 0.3),
            0 0 60px rgba(240, 147, 251, 0.2),
            inset 0 2px 5px rgba(255, 255, 255, 0.2); 
    }
    to { 
        box-shadow: 
            0 20px 40px rgba(0, 0, 0, 0.4), 
            0 0 50px rgba(240, 147, 251, 0.4),
            0 0 80px rgba(102, 126, 234, 0.3),
            inset 0 2px 5px rgba(255, 255, 255, 0.3); 
    }
}

/* Effet de reflet néon */
.phone-screen::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ff00ff, #00ffff, #ff00ff, #00ffff);
    border-radius: 30px;
    z-index: -1;
    animation: neonBorder 2s linear infinite;
    opacity: 0.7;
}

@keyframes neonBorder {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.8; }
}

/* Header */
.phone-header {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #ffffff;
    padding: 20px;
    text-align: center;
    border-bottom: 2px solid #5a67fd;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.phone-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 3s infinite;
}

.phone-header::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: slideLight 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

@keyframes slideLight {
    0% { left: -100%; }
    100% { left: 100%; }
}

.phone-title {
    font-size: 1.5em;
    margin-bottom: 5px;
    text-shadow: 
        2px 2px 4px rgba(0, 0, 0, 0.5),
        0 0 20px rgba(255, 255, 255, 0.3);
    animation: titleGlow 2s ease-in-out infinite alternate;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.phone-icon {
    font-size: 1.2em;
    animation: iconPulse 2s ease-in-out infinite alternate;
    filter: drop-shadow(0 0 10px rgba(102, 126, 234, 0.6));
    transition: all 0.3s ease;
}

.phone-icon:hover {
    transform: scale(1.1) rotate(10deg);
    filter: drop-shadow(0 0 20px rgba(240, 147, 251, 0.8));
}

@keyframes iconPulse {
    0% {
        transform: scale(1) rotate(0deg);
        filter: drop-shadow(0 0 10px rgba(102, 126, 234, 0.6));
    }
    50% {
        transform: scale(1.05) rotate(5deg);
        filter: drop-shadow(0 0 15px rgba(240, 147, 251, 0.8));
    }
    100% {
        transform: scale(1) rotate(0deg);
        filter: drop-shadow(0 0 10px rgba(102, 126, 234, 0.6));
    }
}

@keyframes titleGlow {
    from { text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5), 0 0 20px rgba(255, 255, 255, 0.3); }
    to { text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5), 0 0 30px rgba(255, 255, 255, 0.5); }
}

/* Contenu principal */

@keyframes fadeInOut {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* Contenu principal */
.phone-content {
    background: linear-gradient(135deg, #2d3748, #1a202c);
    padding: 20px;
    min-height: 300px;
    position: relative;
}

/* Style pour le sous-titre simple et net */
.phone-subtitle {
    font-size: 1.3em;
    font-weight: 700;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.85);
    padding: 18px 25px;
    border-radius: 8px;
    border: 2px solid #ffffff;
    text-align: center;
    letter-spacing: 1px;
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.6),
        0 0 20px rgba(102, 126, 234, 0.4),
        inset 0 0 8px rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 10;
    text-shadow: 
        0 1px 2px rgba(0, 0, 0, 0.8),
        0 0 4px rgba(102, 126, 234, 0.6);
    display: block;
    width: 100%;
    /* max-width: 320px; */
    margin: 0 auto;
    line-height: 1.3;
    animation: none !important;
    opacity: 1 !important;
}

@keyframes textShimmer {
    0%, 100% {
        background-position: 0% 50%;
        background-size: 200% 100%;
    }
    50% {
        background-position: 100% 50%;
        background-size: 200% 200%;
    }
    100% {
        background-position: 200% 50%;
        background-size: 200% 200%;
    }
}

@keyframes textFlow {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 200% 50%; }
}

@keyframes textGlow {
    0%, 100% {
        text-shadow: 
            0 0 10px rgba(255, 255, 255, 0.3),
            0 0 20px rgba(102, 126, 234, 0.6),
            0 0 30px rgba(240, 147, 251, 0.4);
    }
    50% {
        text-shadow: 
            0 0 15px rgba(255, 255, 255, 0.5),
            0 0 40px rgba(102, 126, 234, 0.8),
            0 0 50px rgba(240, 147, 251, 0.6);
    }
}

.phone-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 80%, rgba(102, 126, 234, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(240, 147, 251, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

/* Messages de statut */
.message {
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    font-weight: bold;
    text-align: center;
    animation: slideIn 0.3s ease-out;
}

.message.success {
    background: #27ae60;
    color: white;
    border: 1px solid #229954;
}

.message.error {
    background: #e74c3c;
    color: white;
    border: 1px solid #c0392b;
}

/* Espacement après les messages */
.message + .phone-content,
.message + form {
    margin-top: 15px;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Formulaire */
.retro-form {
    background: #3a3a3a;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #555;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    color: #ecf0f1;
    margin-bottom: 8px;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9em;
}

.form-group input[type="text"] {
    width: 100%;
    padding: 12px;
    background: rgba(42, 42, 42, 0.8);
    border: 2px solid #555;
    border-radius: 12px;
    color: #ecf0f1;
    font-family: 'Courier New', monospace;
    font-size: 1em;
    transition: all 0.4s ease;
    backdrop-filter: blur(10px);
    position: relative;
}

.form-group input[type="text"]::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.form-group input[type="text"]:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 
        0 0 20px rgba(52, 152, 219, 0.4),
        0 0 40px rgba(52, 152, 219, 0.2),
        inset 0 0 10px rgba(52, 152, 219, 0.1);
    background: rgba(42, 42, 42, 0.95);
    transform: translateY(-2px);
}

.form-group input[type="text"]:focus::before {
    opacity: 1;
}

/* Enregistreur audio avec effets avancés */
.recorder-container {
    background: rgba(42, 42, 42, 0.8);
    padding: 20px;
    border-radius: 15px;
    border: 1px solid #555;
    text-align: center;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.recorder-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.1) 0%, transparent 70%);
    animation: rotate 10s linear infinite;
}

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

.recorder-status {
    color: #ecf0f1;
    font-weight: bold;
    margin-bottom: 15px;
    padding: 8px;
    background: rgba(52, 152, 219, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(52, 152, 219, 0.3);
    animation: statusPulse 2s ease-in-out infinite;
}

@keyframes statusPulse {
    0%, 100% { 
        box-shadow: 0 0 5px rgba(52, 152, 219, 0.2);
        transform: scale(1);
    }
    50% { 
        box-shadow: 0 0 15px rgba(52, 152, 219, 0.4);
        transform: scale(1.02);
    }
}

.timer {
    font-size: 1.2em;
    color: #e74c3c;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    font-family: 'Courier New', monospace;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.timer-display {
    font-size: 2em;
    color: #e74c3c;
    font-weight: bold;
    margin-bottom: 15px;
    font-family: 'Courier New', monospace;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.recorder-controls {
    margin-bottom: 15px;
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.record-btn, .stop-btn, .submit-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 25px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.4s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(5px);
}

.record-btn {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    box-shadow: 
        0 4px 15px rgba(255, 107, 107, 0.4),
        0 0 30px rgba(255, 107, 107, 0.2);
    position: relative;
}

.record-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.4), transparent);
    transition: all 0.5s ease;
    transform: translate(-50%, -50%);
}

.record-btn::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ff00ff, #00ffff, #ff00ff);
    border-radius: 25px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    animation: plasma 2s linear infinite;
}

@keyframes plasma {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}

.record-btn:hover::after {
    opacity: 0.7;
}

.record-btn:hover:not(:disabled) {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 
        0 8px 25px rgba(255, 107, 107, 0.6),
        0 0 40px rgba(255, 107, 107, 0.3);
}

.record-btn:hover:not(:disabled)::before {
    width: 150%;
    height: 150%;
}

.record-btn:active:not(:disabled) {
    transform: translateY(-2px) scale(1.02);
}

.stop-btn {
    background: linear-gradient(135deg, #feca57, #ff9ff3);
    color: white;
    box-shadow: 
        0 4px 15px rgba(254, 202, 87, 0.4),
        0 0 30px rgba(254, 202, 87, 0.2);
}

.stop-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.4), transparent);
    transition: all 0.5s ease;
    transform: translate(-50%, -50%);
}

.stop-btn::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ffff00, #ff00ff, #00ffff);
    border-radius: 25px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    animation: plasma 2s linear infinite;
}

.stop-btn:hover::after {
    opacity: 0.7;
}

.stop-btn:hover:not(:disabled) {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 
        0 8px 25px rgba(254, 202, 87, 0.6),
        0 0 40px rgba(254, 202, 87, 0.3);
}

.stop-btn:hover:not(:disabled)::before {
    width: 150%;
    height: 150%;
}

/* Groupe de boutons */
.button-group {
    display: flex;
    gap: 10px;
    margin-top: 10px;
    width: 100%;
}

.reload-btn {
    flex: 1;
    padding: 15px 30px;
    border: none;
    border-radius: 25px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.4s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(5px);
    background: linear-gradient(135deg, #feca57, #ff9ff3);
    color: white;
    box-shadow: 
        0 4px 15px rgba(254, 202, 87, 0.4),
        0 0 30px rgba(254, 202, 87, 0.2);
}

.reload-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.4), transparent);
    transition: all 0.5s ease;
    transform: translate(-50%, -50%);
}

.reload-btn::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ffff00, #ff00ff, #00ffff);
    border-radius: 25px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    animation: plasma 2s linear infinite;
}

.reload-btn:hover::after {
    opacity: 0.7;
}

.reload-btn:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 
        0 8px 25px rgba(254, 202, 87, 0.6),
        0 0 40px rgba(254, 202, 87, 0.3);
}

.reload-btn:hover::before {
    width: 120%;
    height: 120%;
}

.reload-btn:active {
    transform: translateY(-1px) scale(1.01);
}

.submit-btn {
    flex: 2;
    width: 100%;
    background: linear-gradient(135deg, #00d2d3, #54a0ff);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 210, 211, 0.4);
    margin-top: 0;
    position: relative;
    overflow: hidden;
}

.submit-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3), transparent);
    transition: all 0.4s ease;
    transform: translate(-50%, -50%);
}

.submit-btn:hover::before {
    width: 120%;
    height: 120%;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 25px rgba(0, 210, 211, 0.5);
}

.submit-btn:disabled {
    background: #555;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Indicateur d'enregistrement */
.recording-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e74c3c;
    font-weight: bold;
    margin-bottom: 15px;
}

.recording-dot {
    width: 12px;
    height: 12px;
    background: #e74c3c;
    border-radius: 50%;
    margin-right: 8px;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

/* Aperçu audio */
.audio-preview {
    margin-top: 15px;
    padding: 15px;
    background: #1a1a1a;
    border-radius: 8px;
    border: 1px solid #555;
}

.audio-preview audio {
    width: 100%;
    height: 40px;
}

/* Lien admin */
.admin-link {
    text-align: center;
    margin-top: 20px;
}

.admin-btn {
    display: inline-block;
    padding: 12px 24px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1.1em;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.admin-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, #5a67fd, #764ba2);
    background: rgba(52, 152, 219, 0.2);
    transform: translateY(-1px);
}

/* Footer principal */
.footer-content {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    padding: 20px;
    /* margin-top: 20px; */
    border-top: 2px solid #5a67fd;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-radius: 0 0 30px 30px;
}

.footer-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    animation: footerSweep 4s infinite;
}

@keyframes footerSweep {
    0% { left: -100%; }
    100% { left: 100%; }
}

.footer-text {
    color: #ffffff;
    font-size: 0.9em;
    font-weight: bold;
    margin-bottom: 5px;
    text-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
    animation: footerGlow 2s ease-in-out infinite alternate;
}

.footer-subtitle {
    color: #b8c5d6;
    font-size: 0.8em;
    opacity: 0.8;
    animation: footerFade 3s ease-in-out infinite alternate;
}

@keyframes footerGlow {
    from { text-shadow: 0 0 10px rgba(102, 126, 234, 0.5); }
    to { text-shadow: 0 0 20px rgba(240, 147, 251, 0.8); }
}

@keyframes footerFade {
    from { opacity: 0.6; }
    to { opacity: 1; }
}

.phone-footer {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    /*  padding: 15px;   */
    /*  border-top: 2px solid #5a67fd;*/
    position: relative;
    overflow: hidden;
}

.phone-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    animation: keyboardSweep 3s infinite;
}

@keyframes keyboardSweep {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Responsive */
@media (max-width: 480px) {
    body {
        padding: 8px;
        overflow: hidden;
    }
    
    .container {
        max-width: 100%;
        height: calc(100vh - 40px);
        max-height: calc(100vh - 40px);
        display: flex;
        align-items: center;
        justify-content: center;
        overflow: hidden;
    }
    
    .phone {
        width: 100%;
        /* height: calc(100vh - 40px); */
        /* max-height: calc(100vh - 40px); */
        overflow: hidden;
        /* margin: 20px 0; */
    }
    
    .phone-screen {
        border-radius: 20px;
        border-width: 4px;
        overflow: hidden;
        flex-direction: column;
    }
    
    .phone-header {
        padding: 12px;
        flex-shrink: 0;
    }
    
    .phone-title {
        font-size: 1.2em;
        gap: 8px;
        margin-bottom: 3px;
    }
    
    .phone-subtitle {
        font-size: 0.9em;
        padding: 8px 12px;
        margin: 5px auto;
    }
    
    .phone-content {
        padding: 12px;
        flex: 1;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }
    
    .form-group {
        margin-bottom: 12px;
    }
    
    .form-group input[type="text"] {
        padding: 8px;
        font-size: 0.85em;
    }
    
    .recorder-container {
        padding: 12px;
        flex: 1;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }
    
    .recorder-controls {
        gap: 6px;
        margin-bottom: 8px;
    }
    
    .record-btn, .stop-btn {
        padding: 10px 15px;
        font-size: 0.85em;
    }
    
    .timer {
        font-size: 0.9em;
        min-height: 25px;
        margin-bottom: 8px;
    }
    
    .recorder-status {
        margin-bottom: 8px;
        font-size: 0.8em;
        padding: 6px;
    }
    
    .button-group {
        flex-direction: column;
        gap: 6px;
        margin-top: 8px;
        flex-shrink: 0;
    }
    
    .reload-btn, .submit-btn {
        width: 100%;
        flex: none;
        padding: 10px 15px;
        font-size: 0.85em;
    }
    
    .reload-btn {
        order: 2;
    }
    
    .submit-btn {
        order: 1;
    }
    
    .footer-content {
        padding: 8px;
        flex-shrink: 0;
    }
    
    .footer-text {
        font-size: 0.7em;
    }
    
    .footer-subtitle {
        font-size: 0.6em;
    }
}

/* iPhone SE et très petits écrans */
@media (max-width: 375px) {
    body {
        padding: 5px;
        overflow: hidden;
    }

    .container {
        max-width: 100%;
        height: calc(100vh - 40px);
        max-height: calc(100vh - 40px);
        display: flex;
        align-items: center;
        justify-content: center;
        overflow: hidden;
    }
    
    .phone {
        padding-top: 10px;
    }
    
    .phone-title {
        font-size: 1.1em;
    }
    
    .phone-subtitle {
        font-size: 0.85em;
        padding: 6px 10px;
        margin: 3px auto;
    }
    
    .phone-content {
        padding: 10px;
    }
    
    .form-group input[type="text"] {
        padding: 6px;
        font-size: 0.8em;
    }
    
    .recorder-container {
        padding: 10px;
    }
    
    .record-btn, .stop-btn {
        padding: 8px 12px;
        font-size: 0.8em;
    }
    
    .timer {
        font-size: 0.8em;
        min-height: 20px;
    }
    
    .recorder-status {
        font-size: 0.75em;
        padding: 4px;
    }
    
    .reload-btn, .submit-btn {
        padding: 8px 12px;
        font-size: 0.8em;
    }
    
    .footer-content {
        padding: 6px;
    }
    
    .footer-text {
        font-size: 0.65em;
    }
    
    .footer-subtitle {
        font-size: 0.55em;
    }
}

/* Animations */
.record-btn:active:not(:disabled),
.stop-btn:active:not(:disabled),
.submit-btn:active:not(:disabled) {
    transform: translateY(0);
}

/* Scrollbar personnalisée */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #2a2a2a;
}

::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #666;
}
