/* ========================================
   Farmers AG Services — Custom Styles
   Midnight Blue + Mint Palette
   ======================================== */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --midnight-950: #040a18;
    --midnight-900: #0a1628;
    --midnight-800: #0f2140;
    --midnight-700: #152d56;
    --midnight-600: #1b3a6e;
    --midnight-500: #214786;
    --midnight-400: #2d5fa0;
    --midnight-300: #4a7fc4;
    --midnight-200: #7ba3d6;
    --midnight-100: #b0c9e8;
    --midnight-50:  #d9e4f2;

    --mint-600: #0d7a6e;
    --mint-500: #14a898;
    --mint-400: #1ec9b4;
    --mint-300: #3dd8c4;
    --mint-200: #7ee0d6;
    --mint-100: #b8ede4;
    --mint-50:  #e4f7f4;

    --amber-500: #d97706;
    --amber-400: #f59e0b;
    --amber-100: #fef3c7;

    --slate-900: #0f172a;
    --slate-800: #1e293b;
    --slate-700: #334155;
    --slate-600: #475569;
    --slate-500: #64748b;
    --slate-400: #94a3b8;
    --slate-300: #cbd5e1;
    --slate-200: #e2e8f0;
    --slate-100: #f1f5f9;
    --slate-50:  #f8fafc;
    --white:     #ffffff;

    --font-display: 'DM Serif Display', Georgia, serif;
    --font-body:    'Inter', system-ui, sans-serif;

    --shadow-sm:  0 1px 3px rgba(10,22,40,0.06), 0 1px 2px rgba(10,22,40,0.04);
    --shadow-md:  0 4px 12px rgba(10,22,40,0.08), 0 2px 4px rgba(10,22,40,0.04);
    --shadow-lg:  0 12px 40px rgba(10,22,40,0.12), 0 4px 12px rgba(10,22,40,0.06);
    --shadow-xl:  0 24px 60px rgba(10,22,40,0.16), 0 8px 20px rgba(10,22,40,0.08);

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --radius-full: 9999px;

    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; font-size: 16px; }
body {
    font-family: var(--font-body);
    color: var(--slate-700);
    background: var(--slate-50);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; }
ul { list-style: none; }
address { font-style: normal; }

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

.skip-link {
    position: absolute; top: -100%; left: 16px;
    background: var(--midnight-800); color: var(--white);
    padding: 8px 16px; border-radius: var(--radius-sm);
    z-index: 9999; font-weight: 600;
}
.skip-link:focus { top: 16px; }

/* --- Typography --- */
.section-label {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 0.8rem; font-weight: 700; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--mint-600);
    margin-bottom: 12px;
}
.section-label::before {
    content: ''; display: block; width: 24px; height: 2px;
    background: var(--mint-400); border-radius: 2px;
}
.section-label--light { color: var(--mint-200); }
.section-label--light::before { background: var(--mint-300); }

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 400; line-height: 1.15;
    color: var(--slate-900); margin-bottom: 20px;
}
.section-title--light { color: var(--white); }
.accent-text { color: var(--mint-500); }
.accent-text-light { color: var(--mint-300); }

.section-subtitle {
    font-size: 1.1rem; color: var(--slate-500);
    max-width: 560px; line-height: 1.7;
}
.text-center { text-align: center; }
.text-center .section-subtitle { margin: 0 auto; }

/* --- Buttons --- */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    font-weight: 600; border-radius: var(--radius-full);
    transition: all var(--transition); white-space: nowrap;
}
.btn-sm { padding: 8px 20px; font-size: 0.875rem; }
.btn-lg { padding: 14px 28px; font-size: 1rem; }
.btn-full { width: 100%; justify-content: center; }

.btn-primary {
    background: var(--mint-500); color: var(--white);
    box-shadow: 0 4px 14px rgba(20,168,152,0.35);
}
.btn-primary:hover {
    background: var(--mint-400); transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(20,168,152,0.45);
}

.btn-ghost {
    background: rgba(255,255,255,0.12); color: var(--white);
    border: 1.5px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(4px);
}
.btn-ghost:hover {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
    transform: translateY(-2px);
}

/* --- Header --- */
.site-header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    background: rgba(248,250,252,0.85);
    backdrop-filter: blur(16px) saturate(180%);
    border-bottom: 1px solid rgba(148,163,184,0.15);
    transition: box-shadow var(--transition);
}
.site-header.scrolled { box-shadow: var(--shadow-md); }

.header-inner {
    display: flex; align-items: center;
    justify-content: space-between; height: 72px;
}

.logo {
    display: inline-flex; align-items: center; gap: 10px;
    font-family: var(--font-display); font-size: 1.25rem;
    color: var(--midnight-800); font-weight: 400;
}
.logo--light { color: var(--white); }
.logo-mark { color: var(--mint-500); }
.logo--light .logo-mark { color: var(--mint-300); }
.logo-text { font-weight: 600; }
.logo-tag {
    font-family: var(--font-body); font-size: 0.7rem;
    font-weight: 600; letter-spacing: 0.05em;
    text-transform: uppercase; color: var(--slate-400);
    background: var(--slate-100); padding: 2px 8px;
    border-radius: var(--radius-full);
}
.logo--light .logo-tag { background: rgba(255,255,255,0.15); color: var(--slate-300); }

.main-nav { display: flex; align-items: center; gap: 32px; }
.main-nav ul { display: flex; gap: 8px; }
.main-nav a {
    font-size: 0.9rem; font-weight: 500; color: var(--slate-600);
    padding: 6px 14px; border-radius: var(--radius-full);
    transition: all var(--transition);
}
.main-nav a:hover { color: var(--midnight-700); background: var(--slate-100); }
.nav-cta { margin-left: 8px; }

.nav-toggle {
    display: none; flex-direction: column; gap: 5px;
    width: 28px; padding: 4px 0;
}
.hamburger {
    display: block; width: 100%; height: 2px;
    background: var(--slate-700); border-radius: 2px;
    transition: all var(--transition);
}
.nav-toggle[aria-expanded="true"] .hamburger:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .hamburger:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .hamburger:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- Hero --- */
.hero {
    position: relative; min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--midnight-950) 0%, var(--midnight-800) 35%, var(--midnight-600) 65%, var(--mint-600) 100%);
    overflow: hidden; padding: 120px 24px 80px;
}
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-pattern { position: absolute; inset: 0; width: 100%; height: 100%; color: var(--white); opacity: 0.4; }

.gradient-orb {
    position: absolute; border-radius: 50%; filter: blur(80px);
    animation: orbFloat 8s ease-in-out infinite alternate;
}
.orb-1 {
    width: 600px; height: 600px; top: -200px; right: -100px;
    background: radial-gradient(circle, rgba(20,168,152,0.25), transparent 70%);
}
.orb-2 {
    width: 400px; height: 400px; bottom: -100px; left: -50px;
    background: radial-gradient(circle, rgba(45,95,160,0.3), transparent 70%);
    animation-delay: -3s;
}
.orb-3 {
    width: 250px; height: 250px; top: 40%; left: 20%;
    background: radial-gradient(circle, rgba(245,158,11,0.12), transparent 70%);
    animation-delay: -5s;
}
@keyframes orbFloat {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(30px, -20px) scale(1.08); }
}

.hero-content {
    position: relative; z-index: 1;
    text-align: center; max-width: 800px;
}
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.15);
    padding: 6px 16px; border-radius: var(--radius-full);
    font-size: 0.8rem; font-weight: 600; color: var(--mint-200);
    margin-bottom: 28px; backdrop-filter: blur(8px);
}
.badge-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--mint-400);
    animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.4); }
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.4rem, 5.5vw, 4.2rem);
    font-weight: 400; line-height: 1.1;
    color: var(--white); margin-bottom: 24px;
}
.accent-text { color: var(--mint-300); }

.hero-subtitle {
    font-size: clamp(1rem, 1.8vw, 1.2rem);
    color: var(--slate-300); max-width: 600px;
    margin: 0 auto 40px; line-height: 1.75;
}
.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 56px; }

.hero-stats {
    display: flex; align-items: center; justify-content: center; gap: 32px;
    flex-wrap: wrap;
}
.stat { text-align: center; }
.stat-number {
    display: block; font-family: var(--font-display);
    font-size: 1.4rem; color: var(--white);
}
.stat-label {
    font-size: 0.78rem; color: var(--slate-400);
    text-transform: uppercase; letter-spacing: 0.06em; font-weight: 500;
}
.stat-divider {
    width: 1px; height: 40px;
    background: rgba(148,163,184,0.3);
}

.hero-wave {
    position: absolute; bottom: -1px; left: 0; right: 0;
    line-height: 0;
}
.hero-wave svg { width: 100%; height: 80px; }

/* --- About --- */
.about { padding: 100px 0; background: var(--slate-50); }
.about-grid {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 64px; align-items: center;
}
.about-images { position: relative; }
.img-card {
    border-radius: var(--radius-lg); overflow: hidden;
    box-shadow: var(--shadow-lg);
}
.img-card--main {
    width: 100%; aspect-ratio: 520/400;
}
.img-card--secondary {
    position: absolute; bottom: -32px; right: -24px;
    width: 65%; aspect-ratio: 340/240;
    border: 5px solid var(--slate-50);
}
.img-card--accent {
    position: absolute; top: -20px; left: -16px;
    width: 100px; height: 100px;
    background: var(--mint-500); border-radius: var(--radius-lg);
    display: flex; align-items: center; justify-content: center;
    color: var(--white); opacity: 0.9;
}
.accent-pattern svg { width: 48px; height: 48px; }

.about-text .section-title { margin-bottom: 20px; }
.about-text > p {
    color: var(--slate-600); margin-bottom: 16px; line-height: 1.75;
}
.about-features { margin-top: 32px; display: flex; flex-direction: column; gap: 20px; }
.feature-item { display: flex; gap: 16px; align-items: flex-start; }
.feature-icon {
    flex-shrink: 0; width: 44px; height: 44px;
    background: var(--mint-50); border-radius: var(--radius-md);
    display: flex; align-items: center; justify-content: center;
    color: var(--mint-600);
}
.feature-item strong {
    display: block; color: var(--slate-900);
    font-size: 0.95rem; margin-bottom: 2px;
}
.feature-item span {
    font-size: 0.875rem; color: var(--slate-500); line-height: 1.5;
}

/* --- Products --- */
.products { padding: 100px 0; background: var(--white); }
.section-header { margin-bottom: 56px; }
.section-header .section-title { margin-bottom: 16px; }

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.product-card {
    background: var(--slate-50);
    border-radius: var(--radius-lg); overflow: hidden;
    border: 1px solid var(--slate-200);
    transition: all var(--transition);
}
.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--mint-200);
}
.product-img {
    position: relative; overflow: hidden;
    aspect-ratio: 320/220;
}
.product-img img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.product-card:hover .product-img img { transform: scale(1.06); }
.product-img-overlay {
    position: absolute; inset: 0;
    background: rgba(10,22,40,0.5);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transition: opacity var(--transition);
    color: var(--white);
}
.product-card:hover .product-img-overlay { opacity: 1; }

.product-info { padding: 20px 24px 24px; }
.product-tag {
    display: inline-block; font-size: 0.7rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em;
    color: var(--mint-600); background: var(--mint-50);
    padding: 3px 10px; border-radius: var(--radius-full);
    margin-bottom: 10px;
}
.product-name {
    font-family: var(--font-display);
    font-size: 1.2rem; color: var(--slate-900);
    margin-bottom: 8px;
}
.product-desc {
    font-size: 0.875rem; color: var(--slate-500); line-height: 1.65;
}

/* --- Services --- */
.services { padding: 100px 0; background: var(--slate-50); }
.services-layout {
    display: grid; grid-template-columns: 1fr 1.4fr;
    gap: 64px; align-items: start;
}
.services-text { position: sticky; top: 120px; }
.services-text .section-subtitle { margin-bottom: 32px; }

.services-list { display: flex; flex-direction: column; gap: 16px; }
.service-row {
    display: grid; grid-template-columns: 48px 1fr 56px;
    gap: 20px; align-items: center;
    background: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    transition: all var(--transition);
}
.service-row:hover {
    border-color: var(--mint-200);
    box-shadow: var(--shadow-md);
    transform: translateX(4px);
}
.service-num {
    font-family: var(--font-display);
    font-size: 1.6rem; color: var(--mint-200);
    font-weight: 400; line-height: 1;
}
.service-body h3 {
    font-size: 1.05rem; font-weight: 700;
    color: var(--slate-900); margin-bottom: 6px;
}
.service-body p {
    font-size: 0.875rem; color: var(--slate-500); line-height: 1.65;
}
.service-icon {
    display: flex; align-items: center; justify-content: center;
    color: var(--mint-400);
}

/* --- Community --- */
.community { padding: 0 0 100px; }
.community-card {
    position: relative; border-radius: var(--radius-xl);
    overflow: hidden; min-height: 500px;
    display: flex; align-items: center;
}
.community-bg { position: absolute; inset: 0; }
.community-photo {
    width: 100%; height: 100%; object-fit: cover;
}
.community-scrim {
    position: absolute; inset: 0;
    background: linear-gradient(105deg,
        rgba(4,10,24,0.92) 0%,
        rgba(15,33,64,0.85) 50%,
        rgba(20,122,110,0.6) 100%
    );
}
.community-pattern {
    position: absolute; inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 24px 24px;
}
.community-content {
    position: relative; z-index: 1;
    padding: 64px; max-width: 600px;
}
.community-content .section-title { margin-bottom: 24px; }
.community-text {
    color: var(--slate-300); font-size: 1.05rem;
    line-height: 1.8; margin-bottom: 16px;
}
.community-stats {
    margin-top: 40px; display: flex; flex-direction: column; gap: 16px;
}
.comm-stat {
    display: flex; align-items: center; gap: 12px;
    color: var(--mint-200); font-size: 0.95rem; font-weight: 500;
}
.comm-stat svg { color: var(--mint-400); flex-shrink: 0; }
.comm-stat-label { color: var(--slate-300); font-weight: 400; font-size: 0.875rem; }

/* --- Contact --- */
.contact { padding: 100px 0; background: var(--white); }
.contact-grid {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: 64px; align-items: start;
}
.contact-details { margin-top: 40px; display: flex; flex-direction: column; gap: 28px; }
.contact-item { display: flex; gap: 16px; align-items: flex-start; }
.contact-icon {
    flex-shrink: 0; width: 48px; height: 48px;
    background: var(--mint-50); border-radius: var(--radius-md);
    display: flex; align-items: center; justify-content: center;
    color: var(--mint-600);
}
.contact-item strong {
    display: block; color: var(--slate-900);
    font-size: 0.9rem; margin-bottom: 4px;
}
.contact-item span, .contact-item a {
    font-size: 0.9rem; color: var(--slate-500); line-height: 1.6;
}
.contact-item a:hover { color: var(--mint-600); }

.contact-form-wrap {
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl); padding: 40px;
}
.contact-form { display: flex; flex-direction: column; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
    font-size: 0.85rem; font-weight: 600;
    color: var(--slate-700);
}
.form-group input, .form-group textarea {
    font-family: var(--font-body); font-size: 0.95rem;
    padding: 12px 16px; border: 1.5px solid var(--slate-200);
    border-radius: var(--radius-md); background: var(--white);
    color: var(--slate-900); transition: all var(--transition);
    outline: none;
}
.form-group input:focus, .form-group textarea:focus {
    border-color: var(--mint-400);
    box-shadow: 0 0 0 3px rgba(20,168,152,0.12);
}
.form-group input::placeholder, .form-group textarea::placeholder {
    color: var(--slate-400);
}
.form-group textarea { resize: vertical; min-height: 120px; }

.form-success {
    display: flex; align-items: center; gap: 10px;
    padding: 14px 18px; border-radius: var(--radius-md);
    background: var(--mint-50); color: var(--mint-600);
    font-size: 0.9rem; font-weight: 500;
}
.form-success svg { flex-shrink: 0; }

/* --- Footer --- */
.site-footer {
    background: var(--midnight-950); color: var(--slate-400);
    padding: 72px 0 0;
}
.footer-grid {
    display: grid; grid-template-columns: 1.6fr 1fr 1fr;
    gap: 48px; padding-bottom: 56px;
}
.footer-brand p { margin-top: 16px; font-size: 0.9rem; line-height: 1.7; color: var(--slate-400); max-width: 300px; }
.footer-links, .footer-contact { display: flex; flex-direction: column; gap: 16px; }
.footer-links strong, .footer-contact strong {
    font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: 0.08em; color: var(--slate-300);
}
.footer-links ul { display: flex; flex-direction: column; gap: 10px; }
.footer-links a {
    font-size: 0.9rem; color: var(--slate-400);
    transition: color var(--transition);
}
.footer-links a:hover { color: var(--mint-300); }
.footer-contact address { font-size: 0.9rem; line-height: 1.7; color: var(--slate-400); }
.footer-contact a { color: var(--mint-400); font-weight: 500; transition: color var(--transition); }
.footer-contact a:hover { color: var(--mint-300); }
.footer-contact p { margin-top: 4px; }

.footer-bottom {
    border-top: 1px solid rgba(148,163,184,0.12);
    padding: 24px 0;
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 12px;
    font-size: 0.8rem; color: var(--slate-600);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
    .about-grid, .services-layout, .contact-grid {
        grid-template-columns: 1fr; gap: 48px;
    }
    .services-text { position: static; }
    .products-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .community-content { padding: 48px; }
}

@media (max-width: 768px) {
    .nav-toggle { display: flex; }
    .main-nav {
        position: fixed; top: 72px; left: 0; right: 0;
        background: rgba(248,250,252,0.97);
        backdrop-filter: blur(16px);
        padding: 24px; flex-direction: column;
        align-items: stretch; gap: 8px;
        border-bottom: 1px solid var(--slate-200);
        box-shadow: var(--shadow-lg);
        transform: translateY(-120%);
        opacity: 0; pointer-events: none;
        transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    }
    .main-nav.open {
        transform: translateY(0); opacity: 1; pointer-events: all;
    }
    .main-nav ul { flex-direction: column; gap: 4px; }
    .main-nav a { padding: 12px 16px; border-radius: var(--radius-md); }
    .nav-cta { margin-left: 0; text-align: center; margin-top: 8px; }

    .hero { padding: 100px 20px 60px; min-height: auto; }
    .hero-title { font-size: clamp(2rem, 8vw, 2.8rem); }
    .hero-stats { gap: 20px; }
    .stat-divider { display: none; }

    .about { padding: 64px 0; }
    .about-images { max-width: 480px; }
    .img-card--secondary { right: 0; bottom: -24px; }

    .products { padding: 64px 0; }
    .products-grid { grid-template-columns: 1fr; max-width: 480px; }

    .services { padding: 64px 0; }
    .service-row { grid-template-columns: 40px 1fr 44px; padding: 20px 24px; }

    .community { padding: 0 0 64px; }
    .community-card { border-radius: var(--radius-lg); min-height: 400px; }
    .community-content { padding: 32px; }
    .community-content .section-title { font-size: clamp(1.6rem, 5vw, 2.2rem); }

    .contact { padding: 64px 0; }
    .contact-form-wrap { padding: 28px; }

    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .footer-bottom { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .hero-actions { flex-direction: column; align-items: center; }
    .hero-actions .btn { width: 100%; justify-content: center; }
}

/* --- Reduced motion --- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
    .gradient-orb { animation: none; }
}
