@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500&family=Playfair+Display:wght@700&display=swap');

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

body {
    font-family: 'Roboto', sans-serif;
    background: #f9f9f5;
    color: #333;
    line-height: 1.6;
}

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

header nav {
    background: #2e5d34;
    color: white;
    padding: 1rem 0;
}

header nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.site-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: white !important;
    margin: 0;
    text-decoration: none;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
    margin: 0;
}

nav a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background 0.3s;
}

nav a:hover {
    background: #6b4c2e;
}

nav a.active {
    background: #6b4c2e;
    font-weight: 600;
}

/* Species page hero banner – FORCE WHITE TEXT */
.species-hero {
    background: #2e5d34;
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.species-hero h1 {
    margin: 0;
    font-size: 2.8rem;
    font-family: 'Playfair Display', serif;
    color: white !important;      /* Force white – fixes invisible common name */
}

.species-hero em {
    font-size: 1.5rem;
    font-style: italic;
    opacity: 0.9;
    color: white !important;      /* Force white for scientific name too */
}

/* Hero / home */
.hero {
    position: relative;
    height: clamp(300px, 45vh, 480px);
    min-height: 260px;
    background: #006400;
    overflow: hidden;
}

.hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 40%;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.35), rgba(0,0,0,0.55));
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    padding: 1rem;
}

.hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2rem, 5.5vw, 3.2rem);
    margin: 0 0 0.6rem;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.7);
}

.hero p {
    font-size: clamp(1rem, 2.8vw, 1.25rem);
    margin: 0;
    max-width: 80%;
}

/* Main content */
main.container { padding: 2rem 0; }

h1, h2, h3 {
    color: #006400;
    font-family: 'Playfair Display', serif;
}

.intro {
    background: white;
    padding: 1.8rem;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.07);
}

/* CTA Buttons */
.cta-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2rem;
    justify-content: center;
    margin-top: 1.5rem;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    font-size: 1.15rem;
    font-weight: 500;
    text-decoration: none;
    text-align: center;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 100, 0, 0.15);
    min-width: 220px;
    background: #006400;
    color: white;
    border: 2px solid #006400;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 100, 0, 0.25);
    background: #004d00;
    border-color: #004d00;
}

/* Species List (profiles.html) */
.species-list { margin: 2rem 0; }

.species-row {
    display: block;
    padding: 0.8rem 1.4rem;
    text-decoration: none;
    color: #006400;
    transition: all 0.25s ease;
    border-radius: 6px;
    margin-bottom: 0.4rem;
}

.species-row .names {
    display: flex;
    align-items: baseline;
    gap: 1.2rem;
    flex-wrap: wrap;
}

.common { font-size: 1.35rem; font-weight: 600; }

.scientific { font-size: 1.05rem; color: #555; font-style: italic; }

.species-row:nth-child(odd) { background: #f8fdf8; }
.species-row:nth-child(even) { background: #fdfdf8; }

.species-row:hover {
    background: #e8f5e8 !important;
    transform: translateX(8px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.07);
}

/* Species Profile – Grid layout */
.content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.photos {
    text-align: center;
}

.photos img {
    max-width: 100%;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    margin: 1rem 0;
    display: block;
}

.section {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid #d4c9b0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.section h3 {
    color: #2e5d34;
    margin-bottom: 1rem;
    border-bottom: 2px solid #006400;
    padding-bottom: 0.5rem;
}

/* Back link */
.back-link {
    display: inline-block;
    margin: 2rem 0 1rem;
    padding: 0.9rem 1.8rem;
    background: #6b4c2e;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: background 0.3s;
}

.back-link:hover {
    background: #8a6640;
}

/* Table (flight.html) */
.table-wrapper { overflow-x: auto; }
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
    background: white;
}
th, td {
    padding: 0.8rem;
    text-align: left;
    border: 1px solid #d4c9b0;
}
th { background: #2e5d34; color: white; }
tr:nth-child(even) { background: #f0ede5; }

/* Footer */
footer {
    background: #2e5d34;
    color: white;
    text-align: center;
    padding: 1.5rem 0;
    margin-top: 3rem;
}

/* Responsive */
@media (max-width: 768px) {
    .content-grid { grid-template-columns: 1fr; }
    nav .container { flex-direction: column; }
    nav ul { margin-top: 1rem; flex-direction: column; align-items: center; }
    nav a { margin: 0.5rem 0; }
}
