:root {
    --app-green: #2f5d34;
    --app-green-dark: #234527;
}

body {
    background: #f4f5f1;
}

.app-nav {
    background: var(--app-green);
}

.app-nav .nav-link.active {
    font-weight: 600;
    border-bottom: 2px solid #fff;
}

.farm-badge {
    background: var(--app-green-dark);
    color: #fff;
    padding: .25rem .6rem;
    border-radius: .35rem;
    text-decoration: none;
    white-space: nowrap;
}

.nav-user {
    color: #fff;
    text-decoration: none;
}

.btn-primary {
    --bs-btn-bg: var(--app-green);
    --bs-btn-border-color: var(--app-green);
    --bs-btn-hover-bg: var(--app-green-dark);
    --bs-btn-hover-border-color: var(--app-green-dark);
    --bs-btn-active-bg: var(--app-green-dark);
    --bs-btn-active-border-color: var(--app-green-dark);
}

.card {
    border: 1px solid #dfe2d8;
}

.table {
    background: #fff;
}

.table td, .table th {
    vertical-align: middle;
}

.num {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.stat {
    font-size: 1.6rem;
    font-weight: 600;
    line-height: 1.2;
}

.stat-label {
    color: #6c757d;
    font-size: .85rem;
}

.crop-dot {
    display: inline-block;
    width: .8rem;
    height: .8rem;
    border-radius: 50%;
    margin-right: .35rem;
    vertical-align: baseline;
}

.neg {
    color: #b02a37;
}

.pos {
    color: #1e7b34;
}

/* Fruchtfolge-Matrix */
.rotation-wrap {
    overflow-x: auto;
}

.rotation th:first-child, .rotation td:first-child {
    position: sticky;
    left: 0;
    background: #fff;
    z-index: 1;
    min-width: 11rem;
}

.rotation td.cell {
    min-width: 11rem;
    border-left: 6px solid transparent;
}

.rotation td.cell select + select {
    margin-top: .25rem;
}

.rotation .warn {
    color: #9a5b00;
    font-size: .78rem;
    line-height: 1.25;
    margin-top: .25rem;
}

.rotation th.current-year {
    background: #e4edd9;
}

.need {
    color: #6c757d;
    font-size: .78rem;
    line-height: 1.25;
    margin-top: .25rem;
    cursor: help;
}

.need-required {
    color: #9a5b00;
    font-weight: 600;
}

.need-ok {
    color: #1e7b34;
}

.warn-text {
    color: #9a5b00;
    font-size: .8rem;
    line-height: 1.25;
}

.preferred-list {
    max-height: 22rem;
    overflow-y: auto;
}

.role-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
    gap: 0 1rem;
}

.read-only .write-only {
    display: none !important;
}

@media print {
    body {
        background: #fff;
    }

    main {
        padding: 0 !important;
    }

    .card {
        border: 0;
    }

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