/* =========================================
   SUSTAINABLEALTERNATIVE.ORG — MAIN STYLESHEET
   Consistent story images, responsive layout,
   navigation underline and mobile support
========================================= */

:root {
    --ink: #173d39;
    --muted: #405b56;
    --paper: #f7f7f0;
    --line: #dfe3da;
    --green: #214a40;
    --soft-green: #e9eee5;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 15px;
    line-height: 1.7;
}

img {
    max-width: 100%;
}

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

button,
input {
    font: inherit;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1,
h2,
h3 {
    font-family: Georgia, "Times New Roman", serif;
    font-weight: 400;
    letter-spacing: -0.6px;
    line-height: 1.15;
}

/* =========================================
   HEADER AND NAVIGATION
========================================= */

header {
    width: 80%;
    max-width: 1440px;
    min-height: 76px;
    padding: 0;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 26px;
    background: #f8f8f2;
    position: relative;
    z-index: 20;
}

.brand {
    flex-shrink: 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(23px, 1.6vw, 31px);
    letter-spacing: -1px;
    white-space: nowrap;
}

#mainNav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(13px, 1.45vw, 26px);
    white-space: nowrap;
    font-size: clamp(11px, 0.72vw, 14px);
}

#mainNav a {
    position: relative;
    display: inline-block;
    padding: 8px 0;
}

#mainNav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 2px;
    width: 100%;
    height: 1px;
    background: #7d9990;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.25s ease;
}

#mainNav a.active::after,
#mainNav a:hover::after {
    transform: scaleX(1);
}

.head-actions {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    gap: 18px;
}

.search {
    font-size: 20px;
    line-height: 1;
}

.subscribe {
    border: 0;
    border-radius: 24px;
    background: var(--green);
    color: white;
    padding: 10px 21px;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.subscribe:hover {
    background: #16382f;
}

.menu {
    display: none;
    border: 0;
    background: none;
    color: var(--ink);
    font-size: 25px;
    cursor: pointer;
}

/* =========================================
   SHARED IMAGE RULES
========================================= */

.split-image,
.hero-photo,
.newsletter-bg,
.card img {
    display: block;
    width: 100%;
    object-fit: cover;
}

/* =========================================
   HERO SECTION
========================================= */

.hero {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: none;
    min-height: 540px;
    height: clamp(420px, 38vw, 650px);
    overflow: hidden;
    color: white;
    background: #273c2e;
}

.hero-photo {
    position: absolute;
    inset: 0;
    z-index: -2;
    height: 100%;
    object-position: center 45%;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        rgba(5, 25, 19, 0.86) 0%,
        rgba(5, 25, 19, 0.57) 42%,
        rgba(5, 25, 19, 0.08) 100%
    );
}

.hero-copy {
    width: 80%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 55px 0;
    box-sizing: border-box;
}

.eyebrow {
    margin-bottom: 16px;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero h1 {
    margin-bottom: 22px;
    font-size: clamp(40px, 3.4vw, 66px);
    line-height: 1.06;
}

.hero-copy p {
    max-width: 560px;
    margin-bottom: 30px;
    font-size: clamp(15px, 1vw, 19px);
    line-height: 1.75;
}

.arrow-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.55);
    font-size: 14px;
}

/* =========================================
   INTRODUCTION SECTION
========================================= */

main {
    width: 80%;
    max-width: 1440px;
    margin: 0 auto;
}

.intro {
    display: grid;
    grid-template-columns: 1.05fr 0.9fr 1fr;
    align-items: start;
    gap: 4%;
    padding: 52px 4.7%;
}

.intro h2 {
    margin-bottom: 0;
    font-size: clamp(32px, 2.5vw, 46px);
}

.intro-copy {
    padding-top: 12px;
    color: var(--muted);
    font-size: 14px;
}

.topics {
    margin: 0;
    padding: 0;
    list-style: none;
}

.topics li {
    display: grid;
    grid-template-columns: 40px 1fr;
    gap: 12px;
    padding-bottom: 15px;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--line);
}

.topics li:last-child {
    margin-bottom: 0;
    border-bottom: 0;
}

.number {
    color: #9bb3a8;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 27px;
    line-height: 1.2;
}

.topic-title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 16px;
}

.topic-desc {
    display: block;
    margin-top: 4px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.6;
}

/* =========================================
   HOMEPAGE STORY ROWS — DESKTOP
   All four story rows and images have the
   same 400px height. Images are cropped,
   never stretched or split.
========================================= */

.split,
.farmer-row {
    display: grid;
    grid-template-columns: 45% 55%;
    align-items: stretch;
    height: 400px;
    min-height: 0;
}

.split > .split-image,
.farmer-row > .split-image {
    display: block;
    width: 100%;
    height: 400px;
    min-height: 0;
    max-height: none;
    object-fit: cover;
    object-position: center;
}

.split-copy {
    display: flex;
    align-items: center;
    min-width: 0;
    padding: 42px clamp(28px, 5vw, 80px);
}

.split-copy > div {
    width: 100%;
}

.eyebrow.small {
    margin-bottom: 12px;
    color: #47675e;
    font-size: 10px;
    letter-spacing: 1.5px;
}

.split-copy h2 {
    margin-bottom: 16px;
    font-size: clamp(25px, 1.9vw, 35px);
    line-height: 1.2;
}

.split-copy p {
    max-width: 540px;
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.8;
}

/* Farmer and field-report copy */
.farmer-copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-width: 0;
    padding: 42px clamp(28px, 5vw, 80px);
}

.farmer-copy h2 {
    margin-bottom: 16px;
    font-size: clamp(28px, 2.1vw, 40px);
    line-height: 1.2;
}

.farmer-copy p {
    max-width: 520px;
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.8;
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 13px;
}

.text-link:hover {
    text-decoration: underline;
}

/* =========================================
   INSIGHT CARDS
========================================= */

.cards {
    display: grid;
    grid-template-columns: 1fr 1fr 0.9fr;
    align-items: stretch;
    gap: clamp(20px, 2vw, 38px);
    padding: 44px 4.7%;
}

.card {
    min-width: 0;
    padding-right: clamp(18px, 2vw, 36px);
    border-right: 1px solid var(--line);
}

.card:last-child {
    padding-right: 0;
    border-right: 0;
}

.card img {
    width: 100%;
    height: clamp(150px, 12vw, 230px);
    margin-bottom: 16px;
    object-fit: cover;
    object-position: center;
}

.card .eyebrow {
    margin-bottom: 8px;
    font-size: 10px;
    letter-spacing: 1.4px;
}

.card h3 {
    margin-bottom: 12px;
    font-size: clamp(19px, 1.3vw, 25px);
    line-height: 1.25;
}

.card p {
    margin-bottom: 16px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
}

/* =========================================
   INDIAN TOBACCO ECONOMY CARD
========================================= */

.card.economy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-width: 0;
    padding: clamp(24px, 2.5vw, 42px);
    background: var(--soft-green);
    border: 0;
}

.card.economy .economy-leaf {
    margin-bottom: 22px;
    line-height: 0;
}

.card.economy .economy-leaf svg {
    width: 48px;
    height: 48px;
    max-width: 100%;
}

.card.economy .eyebrow {
    color: #49675b;
    font-size: 10px;
    line-height: 1.5;
}

.card.economy h3 {
    margin: 0 0 16px;
    color: var(--ink);
    font-size: clamp(21px, 1.5vw, 29px);
    line-height: 1.25;
}

.card.economy p {
    max-width: 360px;
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
}

.card.economy .text-link {
    margin-top: auto;
    color: var(--green);
    font-size: 13px;
}

.card.economy .text-link:hover {
    text-decoration: underline;
}

/* =========================================
   NEWSLETTER
========================================= */

.newsletter {
    position: relative;
    isolation: isolate;
    display: block;
    width: 100%;
    max-width: none;
    min-height: 165px;
    padding: 32px 0;
    overflow: hidden;
    color: white;
    background: #455c48; margin-top: 2%;
}

.newsletter-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 57%;
}

.newsletter::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        rgba(13, 38, 31, 0.78),
        rgba(13, 38, 31, 0.38)
    );
}

.newsletter-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 35px;
    width: 80%;
    max-width: 1440px;
    margin: 0 auto;
}

.newsletter-copy {
    position: relative;
    z-index: 1;
    max-width: 580px;
}

.newsletter-copy .eyebrow {
    margin-bottom: 8px;
    font-size: 10px;
}

.newsletter-copy h2 {
    margin-bottom: 8px;
    font-size: clamp(27px, 1.8vw, 38px);
}

.newsletter-copy p {
    margin-bottom: 0;
    font-size: 14px;
}

.newsletter-signup {
    position: relative;
    z-index: 1;
    flex-shrink: 0;
    width: 38%;
    max-width: 500px;
    min-width: 280px;
}

.newsletter-signup .newsletter-form {
    width: 100%;
    max-width: none;
    min-width: 0;
}

.newsletter-status {
    margin: 10px 6px 0;
    color: white;
    font-size: 13px;
}

.newsletter-status:empty {
    display: none;
}

.newsletter-form {
    position: relative;
    z-index: 1;
    display: flex;
    flex-shrink: 0;
    width: 38%;
    max-width: 500px;
    min-width: 280px;
    overflow: hidden;
    border: 1px solid white;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.95);
}

.newsletter-form input {
    width: 100%;
    min-width: 0;
    flex: 1;
    padding: 14px 17px;
    border: 0;
    outline: none;
    background: transparent;
    color: var(--ink);
    font-size: 13px;
}

.newsletter-form input:focus-visible {
    outline: 2px solid #8cae9c;
    outline-offset: -3px;
}

.newsletter-form button {
    flex-shrink: 0;
    padding: 0 22px;
    border: 0;
    background: var(--green);
    color: white;
    font-size: 13px;
    cursor: pointer;
}

.newsletter-form button:hover {
    background: #16382f;
}

/* =========================================
   FOOTER
========================================= */

footer {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 32px 0;
    box-sizing: border-box;
    font-size: 11px;
}

.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    width: 80%;
    max-width: 1440px;
    margin: 0 auto;
}

.footer-brand {
    display: block;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 20px;
}

.footer-note {
    color: #687c74;
    font-size: 10px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 18px;
}

.footer-links a:hover,
.legal a:hover {
    text-decoration: underline;
}

.social {
    white-space: nowrap;
    font-size: 15px;
    font-weight: bold;
}

.legal {
    padding-left: 18px;
    border-left: 1px solid var(--line);
    color: var(--muted);
    white-space: nowrap;
}

/* =========================================
   TABLET
========================================= */

@media (max-width: 1050px) {
    header {
        width: 90%;
        gap: 18px;
    }

    #mainNav {
        gap: 14px;
        font-size: 11px;
    }

    .head-actions {
        gap: 12px;
    }

    .subscribe {
        padding: 9px 15px;
    }

    main,
    .newsletter-inner,
    .footer-inner {
        width: 90%;
    }

    .intro {
        gap: 25px;
    }

    .split,
    .farmer-row {
        height: 360px;
    }

    .split > .split-image,
    .farmer-row > .split-image {
        height: 360px;
    }

    .split-copy,
    .farmer-copy {
        padding: 32px;
    }

    .cards {
        gap: 20px;
    }

    .hero-copy {
        width: 90%;
    }
}

/* =========================================
   MOBILE AND SMALL TABLETS
========================================= */

@media (max-width: 800px) {
    header {
        width: 92%;
        height: 68px;
        min-height: 68px;
        padding: 0;
    }

    .brand {
        font-size: 23px;
    }

    #mainNav {
        display: none;
        position: absolute;
        top: 68px;
        left: -4.35%;
        right: -4.35%;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 20px 5% 24px;
        background: var(--paper);
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
        white-space: normal;
        font-size: 14px;
    }

    #mainNav.open {
        display: flex;
    }

    #mainNav a {
        padding: 5px 0;
    }

    .head-actions {
        margin-left: auto;
    }

    .menu {
        display: block;
    }

    .hero {
        height: auto;
        min-height: 450px;
    }

    .hero-photo {
        object-position: 60% center;
    }

    .hero-copy {
        width: 90%;
        max-width: 620px;
        padding: 48px 0;
    }

    .hero h1 {
        font-size: clamp(36px, 7vw, 50px);
    }

    .hero-copy p {
        font-size: 15px;
    }

    main {
        width: 92%;
    }

    .intro {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 36px 5%;
    }

    .intro h2 {
        font-size: 34px;
    }

    .intro-copy {
        padding: 0;
        font-size: 14px;
    }

    .topic-title {
        font-size: 15px;
    }

    .topic-desc {
        font-size: 13px;
    }

    /* Mobile images stack and share a 3:2 ratio */
    .split,
    .farmer-row {
        grid-template-columns: 1fr;
        height: auto;
        min-height: 0;
    }

    .split > .split-image,
    .farmer-row > .split-image {
        width: 100%;
        height: auto;
        aspect-ratio: 3 / 2;
        min-height: 0;
        max-height: none;
        object-fit: cover;
        object-position: center;
    }

    .split-copy,
    .farmer-copy {
        padding: 32px 5%;
    }

    .split-copy h2 {
        font-size: 29px;
    }

    .split-copy p,
    .farmer-copy p {
        font-size: 14px;
    }

    .farmer-copy h2 {
        font-size: 32px;
    }

    .cards {
        grid-template-columns: 1fr 1fr;
        gap: 26px;
        padding: 32px 5%;
    }

    .card {
        padding-right: 18px;
    }

    .card:nth-child(2) {
        padding-right: 0;
        border-right: 0;
    }

    .card img {
        height: clamp(150px, 25vw, 220px);
    }

    .card h3 {
        font-size: 21px;
    }

    .card p {
        font-size: 13px;
    }

    .card.economy {
        grid-column: 1 / -1;
        min-height: 260px;
        padding: 30px;
    }

    .card.economy h3 {
        font-size: 25px;
    }

    .newsletter-inner {
        width: 92%;
        align-items: flex-start;
        flex-direction: column;
        gap: 20px;
    }

    .newsletter-form,
    .newsletter-signup {
        width: 100%;
        max-width: 480px;
        min-width: 0;
    }

    .footer-inner {
        width: 92%;
        align-items: flex-start;
        flex-direction: column;
    }

    .footer-links {
        order: 3;
        width: 100%;
        justify-content: flex-start;
    }

    .legal {
        padding-left: 0;
        border-left: 0;
    }
}

/* =========================================
   SMALL PHONES
========================================= */

@media (max-width: 480px) {
    header {
        width: 92%;
    }

    .brand {
        font-size: 17px;
        letter-spacing: -0.5px;
    }

    .head-actions {
        gap: 10px;
    }

    .subscribe {
        padding: 8px 12px;
        font-size: 11px;
    }

    .search {
        font-size: 18px;
    }

    .hero {
        min-height: 440px;
    }

    .hero-copy {
        width: 90%;
        padding: 38px 0;
    }

    .hero h1 {
        font-size: 33px;
    }

    .hero-copy p {
        font-size: 14px;
        line-height: 1.7;
    }

    .intro h2 {
        font-size: 31px;
    }

    /* Keep the same ratio on small phones; no conflicting fixed height */
    .split > .split-image,
    .farmer-row > .split-image {
        height: auto;
        aspect-ratio: 3 / 2;
    }

    .split-copy,
    .farmer-copy {
        padding: 28px 5%;
    }

    .split-copy h2 {
        font-size: 27px;
    }

    .farmer-copy h2 {
        font-size: 29px;
    }

    .cards {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 28px 5%;
    }

    .card,
    .card:nth-child(2) {
        padding: 0 0 22px;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .card:last-child {
        grid-column: auto;
        padding: 24px;
        border-bottom: 0;
    }

    .card img {
        height: 190px;
    }

    .card h3 {
        font-size: 22px;
    }

    .card.economy {
        min-height: 250px;
    }

    .card.economy h3 {
        font-size: 23px;
    }

    .desktop-break {
        display: none;
    }

    .newsletter-copy h2 {
        font-size: 27px;
    }

    .newsletter-copy p {
        font-size: 13px;
    }

    .newsletter-form input {
        padding: 13px 12px;
        font-size: 12px;
    }

    .newsletter-form button {
        padding: 0 14px;
        font-size: 12px;
    }

    footer {
        padding: 25px 0;
    }

    .footer-links {
        gap: 10px 15px;
    }

    .legal {
        white-space: normal;
    }
}

/* Respect visitors who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

/* Homepage category rows (generated by build.py): "Read the story" + "All <category>" */
.row-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 28px;
}

.split-copy h2 a,
.farmer-copy h2 a {
    color: inherit;
}

.split-copy h2 a:hover,
.farmer-copy h2 a:hover {
    text-decoration: underline;
}
