:root {
    --undip-blue: #002147;
    --undip-gold: #c5a059;
    --danger: #e74c3c;
    --success: #2ecc71;
    --text-main: #2d3436;
    --bg-body: #f0f3f7;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
    background-color: var(--bg-body);
}

.card {
    background: white;
    padding: 2rem;
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    text-align: center;
    width: 100%;
    max-width: 400px;
    border-top: 10px solid var(--undip-blue);
}

.app-header h1 {
    color: var(--undip-blue);
    margin: 0;
    font-size: 1.6rem;
    letter-spacing: -0.5px;
}

.subtitle {
    color: #7f8c8d;
    font-size: 0.85rem;
    margin-top: 5px;
    margin-bottom: 20px;
}

.timer {
    font-size: 3rem;
    font-weight: 700;
    color: var(--undip-blue);
    font-variant-numeric: tabular-nums;
    margin-bottom: 10px;
}

.volume-meter {
    width: 100%;
    height: 6px;
    background: #ecf0f1;
    border-radius: 10px;
    margin-bottom: 15px;
    overflow: hidden;
}

.volume-fill {
    width: 0%;
    height: 100%;
    background: var(--success);
    transition: width 0.1s linear;
}

.status-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 50px;
    background: #f1f2f6;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 25px;
    color: var(--text-main);
}

.controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.btn {
    padding: 14px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.btn-start {
    background: var(--success);
    color: white;
    grid-column: span 2;
}

.btn-stop {
    background: var(--danger);
    color: white;
}

.btn-reset {
    background: #95a5a6;
    color: white;
}

.btn:disabled {
    background: #dfe6e9 !important;
    color: #b2bec3;
    cursor: not-allowed;
    transform: none !important;
}

.btn:hover:not(:disabled) {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

.result-area {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #f8f9fa;
}

.preview-label {
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 10px;
}

audio {
    width: 100%;
    margin-bottom: 20px;
}

.btn-download {
    display: block;
    background: var(--undip-blue);
    color: white;
    padding: 12px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.2s ease;
}

.btn-download:hover {
    filter: brightness(1.2);
    transform: translateY(-2px);
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    .card {
        padding: 1.5rem 1rem;
        border-radius: 16px;
    }

    .timer {
        font-size: 2.5rem;
    }

    .app-header h1 {
        font-size: 1.3rem;
    }

    .subtitle {
        font-size: 0.75rem;
    }

    .controls {
        gap: 8px;
    }

    .btn {
        padding: 12px;
        font-size: 0.85rem;
    }

    .status-badge {
        font-size: 0.75rem;
        padding: 4px 12px;
        margin-bottom: 20px;
    }

    .result-area {
        margin-top: 20px;
        padding-top: 15px;
    }
}