/* General Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    background-color: #f9f9f9;
}

.container {
    max-width: 1800px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    background-color: #ffffff;
    border-bottom: 1px solid #ddd;
    padding: 40px 0;
    text-align: center;
}

header h1 { margin: 0; color: #2c3e50; }
header .subtitle { font-size: 1.2em; color: #666; }
header .authors { font-style: italic; margin-top: 10px; }

/* Sections */
section {
    background: #fff;
    margin-bottom: 30px;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

h2 { border-bottom: 2px solid #eee; padding-bottom: 10px; color: #2c3e50; }
h3 { margin-top: 30px; color: #34495e; }

/* Buttons & Links */
.btn-link {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 16px;
    background: #2c3e50;
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    transition: background 0.2s ease;
}

.btn-link:hover {
    background: #1f2d3a;
}

/* Theory Page */
.theory-container {
    max-width: 1200px;
}

.theory-section p {
    margin: 12px 0;
}

.math-block {
    background: #f6f8fa;
    border: 1px solid #e1e4e8;
    border-radius: 6px;
    padding: 12px 16px;
    margin: 12px 0;
    overflow-x: auto;
}

/* Figures */
.figure-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

figure {
    margin: 0;
    text-align: center;
}

figure img {
    max-width: 100%;
    height: auto;
    border: 1px solid #eee;
    padding: 5px;
}

figcaption {
    margin-top: 8px;
    font-size: 0.9em;
    color: #666;
}

/* Audio Tables */
.table-scroll {
    overflow-x: auto; /* Allows scrolling on mobile */
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    font-size: 0.9em;
}

th, td {
    padding: 8px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

th {
    background-color: #f4f4f4;
    font-weight: 600;
}

/* Audio Player Styling */
audio {
    width: 220px; /* Forces players to be compact so they fit in a row */
    height: 35px;
}

/* Spectrogram Styling */
.spectrogram {
    width: 100%;
    max-width: 220px;
    height: auto;
    display: block;
    margin: 0 auto 10px auto;
    border: 1px solid #ddd;
    border-radius: 4px;
}

td {
    vertical-align: top;
    padding: 12px 8px;
}