body {
    background-color: #0a192f; /* Dark blue */
    color: #ccd6f6; /* Light blue/grey */
    font-family: sans-serif;
    margin: 0;
    padding: 0.5rem 2rem 2rem;
}

h1, h2, h3 {
    color: #64ffda; /* A bright accent color */
    border-bottom: 1px solid #233554;
    padding-bottom: 10px;
}

h1 {
    font-size: 3rem;
    text-align: center;
}

header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

header h1 {
    flex: 1;
    margin: 0;
}

header button {
    flex: 0 0 auto;
}

h2 {
    font-size: 2rem;
    margin-top: 3rem;
}

h3 {
    font-size: 1.5rem;
    margin-top: 2rem;
}

.container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.column {
    flex: 1;
    min-width: 400px; /* Minimum width for columns */
    background-color: #112240;
    padding: 2rem;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

table {
    width: 100%;
    margin-top: 1.5rem;
    border-collapse: collapse;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #233554; /* Darker blue for separators */
}

th {
    background-color: #233554;
    color: #64ffda;
}

tr:hover {
    background-color: #233554;
}

td:first-child {
    font-weight: bold;
    color: #8892b0; /* Greyish blue */
}

a {
    color: #64ffda;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

img {
    max-width: 100%;
    height: auto;
    margin-top: 1.5rem;
    border-radius: 5px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

iframe {
    margin-top: 1.5rem;
    border: 3px solid #233554;
    border-radius: 5px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    width: 100%;
    aspect-ratio: 16 / 9; /* Maintain 16:9 aspect ratio */
    height: auto;
}

p {
    line-height: 1.6;
}

.launch-details {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 2rem;
}

.launch-details table {
    flex: 1;
    margin-top: 0;
}

.launch-image {
    flex: 1;
    margin: 0;
    min-width: 0; /* Add this to allow flex items to shrink below their intrinsic size */
}

.mission-patches {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.mission-patches img {
    margin: 0;
}

/* Countdown clock styling: centered, larger and red */
.countdown {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.25rem;
    text-align: center;
    color: #ff3333; /* bright red */
    font-weight: 700;
    font-size: 2rem; /* large */
    margin-bottom: 1rem;
    margin-top: 1rem;
}

.countdown span {
    display: inline-block;
    min-width: 2ch;
}

@media (max-width: 768px) {
    body {
        padding: 0.5rem 1rem 1.5rem;
    }

    .container {
        flex-direction: column;
    }

    .column {
        flex: 1 1 100%;
        min-width: 0;
        width: 100%;
        box-sizing: border-box;
    }

    .countdown {
        font-size: 1.75rem;
    }

    .launch-details {
        flex-direction: column;
    }
}

/* Timeline countdown toggle button */
.button {
    display: inline-block;
    box-sizing: border-box;
    background-color: #64ffda;
    color: #0a192f;
    border: none;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.button:hover, button.button:hover {
    background-color: #4db39a;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(100, 255, 218, 0.3);
    text-decoration: none;
}

.button:active, button.button:active {
    transform: translateY(0);
}

.button.active, #toggle-timeline-countdown.active {
    background-color: #ff3333;
    color: #fff;
}

.button.active:hover, #toggle-timeline-countdown.active:hover {
    background-color: #cc2222;
    box-shadow: 0 4px 12px rgba(255, 51, 51, 0.3);
}

/* Tabs styling */
.tabs {
    margin-top: 1.5rem;
}

.tab-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    border-bottom: 2px solid #233554;
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

.tab-button {
    background-color: #233554;
    color: #ccd6f6;
    border: 1px solid #233554;
    padding: 0.6rem 1.2rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab-button:hover {
    background-color: #32476d;
    color: #64ffda;
    transform: translateY(-1px);
}

.tab-button.active {
    background-color: #64ffda;
    color: #0a192f;
    border-color: #64ffda;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* Footer styling */
footer {
    margin-top: 3rem;
    padding: 2rem 0;
    border-top: 1px solid #233554;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

footer p {
    margin: 0;
    color: #8892b0;
}

.footer-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    width: 100%;
}

@media (max-width: 600px) {
    .footer-buttons {
        flex-direction: column;
        align-items: stretch;
        max-width: 320px;
    }

    .footer-buttons .button {
        width: 100%;
    }
}
