/* --- Global Reset & Base Styles --- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
  /* Set black bg here so overscroll matches the dark footer */
  background-color: #000; 
}

body {
    font-family: charter, Georgia, Cambria, "Times New Roman", Times, serif;
    margin: 0;
    padding: 0;
    color: #242424;
    background-color: #f7f4ed; 
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
}

/* --- Header & Nav --- */
header {
    background-color: #f7f4ed;
    border-bottom: 1px solid #242424;
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    font-family: soehne, "Helvetica Neue", Helvetica, Arial, sans-serif;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    font-family: gt-super, Georgia, Cambria, "Times New Roman", Times, serif;
    font-size: 32px;
    font-weight: bold;
    letter-spacing: -1.5px;
}

/* Align links and button in the same row */
.nav-right {
    font-family: soehne, "Helvetica Neue", Helvetica, Arial, sans-serif;
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-links {
    font-family: soehne, "Helvetica Neue", Helvetica, Arial, sans-serif;
    align-items: center;
    font-size: 14px;
}

/* --- Button Variants --- */
.btn {
    font-family: soehne, "Helvetica Neue", Helvetica, Arial, sans-serif;
    color: #fff;
    padding: 10px 20px;
    border: none;
    cursor: pointer;
    border-radius: 25px;
    font-size: 16px;
    display: inline-block;
    background-color: #1a8917; /* Medium green for mobile hero */
}

.btn-black {
    background-color: #191919; /* Force black bg for header button */
}

.btn-large {
    
    padding: 12px 40px;
    font-size: 20px;
    margin-top: 20px;
}

/* --- Hero Section --- */
.hero {
    background: #f7f4ed;
    position: relative; 
    padding: 60px 0;
    /* Prevent the background from leaking under the border edge */
    background-clip: padding-box;
    -webkit-background-clip: padding-box;
}

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

.hero-content {
    text-align: left; 
}

.hero-title {
    font-family: gt-super, Georgia, Cambria, "Times New Roman", Times, serif;
    font-size: 70px;
    line-height: 0.95;
    font-feature-settings: 'pnum' on, 'lnum' on;
    margin-bottom: 24px;
    font-weight: 500;
    word-break: break-word;
    max-width: 100%;
    overflow-wrap: break-word;
}

.hero-subtitle {
    font-family: charter, soehne;
    font-size: 22px;
    line-height: 1.2;
    margin-bottom: 32px;
    color: #242424;
    max-width: 440px;
}

.hero-image {
    display: none; /* Only visible on larger screens */
}

.hero-image img {
    max-height: 450px;
    object-fit: contain;
}

/* --- Footer --- */
footer {
    margin-top: auto;
    padding: 40px 24px;
    background-color: #000;
    font-size: 13px;
    color: white;
    border-top: 1px solid #e5e5e5;
}

.footer-links {
    font-family: soehne, "Helvetica Neue", Helvetica, Arial, sans-serif;
    display: flex;
    justify-content: left;
    gap: 15px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

/* --- Responsive Layouts --- */

/* Small Tablets */
@media (min-width: 552px) {
    .hero-container {
        margin-top: 40px;
    }
    .hero-title {
        font-size: 80px;
        line-height: 72px;
        letter-spacing: -0.055em;
    }
    .hero-subtitle {
        font-size: 16px;
        line-height: 24px;
    }
}

/* Standard Tablets */
@media (min-width: 728px) {
    .hero-container {
        margin-left: 48px;
        margin-right: 48px;
        height: 100%; 
        display: flex;
        flex-direction: column;
        justify-content: center; /* Center content vertically */
    }
    .hero-title {
        font-size: 106px;
        line-height: 95px;
    }
    .hero-subtitle {
        font-size: 22px;
        line-height: 28px;
        margin-bottom: 48px;
    }
    .footer-links {
        justify-content: center;
    }
}

/* Large Screens & Desktop */
@media (min-width: 904px) {
    .nav-links li {
        display: block;
    }
    
    .btn {
        background-color: #191919; /* Swap hero button to black on desktop */
    }
    
    .hero {
        padding: 80px 0;
        min-height: 100vh;
        display: flex;
        align-items: center;
    }
    
    .hero-container {
        max-width: 1192px;
        margin: 0 auto;
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    
    .hero-image {
        display: block;
        position: absolute;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: 40%;
        max-width: 600px;
    }
    
    .hero-title {
        font-size: 120px;
        line-height: 100px;
    }
    
    footer {
        background-color: #f7f4ed;
        color: #242424;
        border-top: 1px solid #e5e5e5;
    }
}

@media (min-width: 1080px) {
    nav, .hero-container {
        max-width: 1192px;
        margin-left: auto;
        margin-right: auto;
    }
}

/* --- Nav Visibility Logic --- */

/* Tablet: Show all links */
@media (min-width: 728px) and (max-width: 903px) {
    .nav-links li {
        display: block;
    }
}

/* Mid-Mobile: Only show 'Sign in' link */
@media (min-width: 552px) and (max-width: 727px) {
    .nav-links li {
        display: none;
    }
    .nav-links li:nth-child(4) { 
        display: block;
    }
}

/* Small Mobile: Hide all nav links to save space */
@media (max-width: 551px) {
    .nav-links li {
        display: none;
    }
    .nav-right {
        gap: 8px;
    }
    .desktop-only {
        display: none;
    }
}

/* --- Polish --- */
.btn:hover,
.nav-link:hover {
    opacity: 0.9;
}

.btn:focus-visible,
a:focus-visible {
    outline: 2px solid #000;
    outline-offset: 2px;
}
