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

/* =========================
   DESIGN TOKENS
========================= */
:root {
    --primary: #16a34a;
    --primary-soft: #dcfce7;

    --secondary: #2563eb;
    --secondary-soft: #e0e7ff;

    --accent: #f59e0b;

    --bg: #f8fafc;
    --surface: #ffffff;
    --border: #e5e7eb;

    --text-main: #0f172a;
    --text-muted: #64748b;

    --radius-lg: 24px;
    --radius-md: 18px;
}

/* =========================
   BODY
========================= */
body {
    font-family: "Inter", system-ui, sans-serif;
    background: linear-gradient(180deg, #f1f5f9, var(--bg));
    color: var(--text-main);
}

/* =========================
   DASHBOARD
========================= */
.agri-dashboard {
    min-height: 100vh;
    width: 100%;
    padding: 32px 40px;
}

/* =========================
   HERO
========================= */
.hero-banner {
    background: linear-gradient(135deg, #15803d, var(--primary));
    border-radius: var(--radius-lg);
    padding: 36px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #fff;
    box-shadow: 0 30px 80px rgba(22, 163, 74, 0.35);
}

.hero-text h1 {
    font-size: 2.4rem;
    font-weight: 800;
    letter-spacing: -0.6px;
}

.hero-text p {
    margin-top: 6px;
    opacity: 0.9;
}

.time-badge {
    background: rgba(255,255,255,0.15);
    padding: 10px 20px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.3);
    font-weight: 600;
}

/* =========================
   STATS (FIXED ALIGNMENT)
========================= */
/* =========================
   STATS (PERFECT ALIGNMENT)
========================= */
.stats-container {
    margin-top: 34px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

/* CARD */
.stat-card {
    background: var(--surface);
    border-radius: var(--radius-md);
    padding: 22px 24px;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 18px;
    border: 1px solid var(--border);
    box-shadow: 0 14px 35px rgba(0,0,0,0.06);
}

/* ICON */
.icon-box {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    line-height: 1;
    background: var(--primary-soft);
    color: var(--primary);
}

.icon-box.orange {
    background: #fef3c7;
    color: var(--accent);
}

.icon-box.blue {
    background: var(--secondary-soft);
    color: var(--secondary);
}

/* CONTENT */
.stat-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

/* TITLE */
.stat-content h4 {
    font-size: 0.95rem;
    color: var(--text-muted);
    font-weight: 600;
    white-space: nowrap;
}

/* NUMBER */
.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-main);
    text-align: right;
    min-width: 42px;
}

/* =========================
   MOBILE FIX
========================= */
@media (max-width: 768px) {
    .stats-container {
        grid-template-columns: 1fr;
    }

    .stat-card {
        padding: 18px 20px;
    }

    .stat-value {
        font-size: 1.9rem;
    }
}

/* TEXT ALIGNMENT FIX */
.stat-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.stat-info h4 {
    font-size: 0.95rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.stat-info .value {
    font-size: 1.9rem;
    font-weight: 800;
    line-height: 1.1;
}

/* =========================
   SECTION TITLE
========================= */
.section-title {
    margin: 46px 0 20px;
    font-size: 1.55rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-title::before {
    content: "";
    width: 10px;
    height: 30px;
    border-radius: 10px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
}

/* =========================
   GRID
========================= */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

/* =========================
   DASH ITEMS
========================= */
.dash-item {
    background: var(--surface);
    border-radius: var(--radius-md);
    padding: 26px;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 220px;
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.dash-item:hover {
    transform: translateY(-6px);
}

.dash-item::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(240,253,244,0.6), transparent 60%);
    opacity: 0;
}

.dash-item:hover::before {
    opacity: 1;
}

.item-icon {
    font-size: 38px;
    color: var(--primary);
}

.item-content h3 {
    margin-top: 18px;
    font-size: 1.3rem;
    font-weight: 800;
}

.item-content p {
    margin-top: 8px;
    color: var(--text-muted);
    line-height: 1.45;
}

.action-arrow {
    margin-top: 18px;
    font-weight: 700;
    color: var(--secondary);
}

/* =========================
   FOOTER
========================= */
.dashboard-footer {
    margin-top: 70px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 1200px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .agri-dashboard {
        padding: 20px;
    }

    .hero-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .hero-text h1 {
        font-size: 1.8rem;
    }

    .stats-container {
        grid-template-columns: 1fr;
    }

    .bento-grid {
        grid-template-columns: 1fr;
    }
}
