body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    text-align: center;
}

.container {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 40px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    width: 90%;
    max-width: 1200px;
    margin: 20px;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

h2 {
    font-size: 1.5rem;
    margin-top: 25px;
    margin-bottom: 10px;
    color: #ffd700;
}

.app-layout {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    flex-wrap: wrap;
    justify-content: center;
}

.controls-column, .visualizer-column {
    flex: 1;
    min-width: 300px;
}

p {
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.bpm-controls {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

#bpm-slider {
    width: 80%;
    max-width: 400px;
}

#bpm-value {
    font-size: 1.5rem;
    font-weight: bold;
}

.controls button, .action-buttons button {
    background-color: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 12px 25px;
    margin: 5px;
    border-radius: 50px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
}

.controls button:hover, .action-buttons button:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.controls button.active {
    background-color: #4CAF50;
    border-color: #4CAF50;
    transform: scale(1.1);
}

.action-buttons button {
    background-color: #ff4d4d;
    border-color: #ff4d4d;
    font-weight: bold;
    margin-top: 20px;
}

.action-buttons #start-button {
    background-color: #4CAF50;
    border-color: #4CAF50;
}

.action-buttons #start-button:hover {
    background-color: #45a049;
}

.action-buttons #stop-button:hover {
    background-color: #e63939;
}

.visualizer {
    margin: 30px 0;
}

#beat-notation {
    min-height: 100px;
    display: flex;
    justify-content: center;
    align-items: center;
}

#time-signature-image {
    max-width: 100%;
    height: auto;
    max-height: 80px;
    margin-bottom: 20px;
}

#beat-container {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.beat-box {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    transition: background-color 0.1s, transform 0.1s;
}

.beat-box.active {
    background-color: #fff;
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.8);
}

.beat-box.strong {
    background-color: #4CAF50;
}

#beat-counter {
    margin-top: 15px;
    font-size: 2.5rem;
    font-weight: bold;
}

.explanation {
    margin-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    padding-top: 20px;
}

footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

footer a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
}

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