/* Man-Animal Conflict: the original page had no inline styles; its stylesheet css/man_animal_conflict.css is loaded as is. */

/* Full width (the site style): the blocks run inside the 5% side margins with no 1440px cap; headings left in the site's
   type (Plus Jakarta Sans 800, up to 38px), no bar beside or under them. The page's own designs are unchanged. */
html body .mac-page .mac-wrap { max-width: none; padding-left: 5%; padding-right: 5%; box-sizing: border-box; }
html body .mac-page .mac-section-title { padding-left: 0; border-left: 0; text-align: left; font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: clamp(28px, 2.5vw, 38px); line-height: 1.05; letter-spacing: -.035em; color: #0a2e1a; }
html body .mac-page .mac-section-title::before, html body .mac-page .mac-section-title::after { display: none; }
html body .mac-page .wa-title-bar { display: none; }
@media (max-width: 600px) { html body .mac-page .mac-wrap { padding-left: 20px; padding-right: 20px; } }

/* Field photos smaller: cards up to three to a row, 200px pictures (same card design) */
@media (min-width: 769px) {
    html body .mac-page .mac-parallel-row { grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); max-width: 1100px; gap: 20px; }
    html body .mac-page .mac-img-frame { height: 200px; }
}

/* Tables, minimal and readable: no green header block or white box; small dark column names over a 2px rule, hairline
   rows, figures right-aligned in Roboto with even digits, the first column in bold; a row tints under the pointer */
html body .mac-page .mac-table-container { padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; overflow-x: auto; }
html body .mac-page .mac-table { width: 100%; border-collapse: collapse; border-spacing: 0; background: transparent; font-size: 16px; }
html body .mac-page .mac-table thead, html body .mac-page .mac-table thead tr, html body .mac-page .mac-table th { background: transparent !important; color: #0a2e1a !important; border-radius: 0 !important; }
html body .mac-page .mac-table th { padding: 12px 16px !important; border: 0 !important; font: 700 13px/1.35 'Plus Jakarta Sans', sans-serif !important; letter-spacing: 0 !important; text-transform: none !important; text-align: right !important; vertical-align: bottom !important; white-space: normal; }
html body .mac-page .mac-table thead tr:last-child th, html body .mac-page .mac-table thead th[rowspan] { border-bottom: 2px solid #0a2e1a !important; }
html body .mac-page .mac-table th:first-child { text-align: left !important; }
html body .mac-page .mac-table th[colspan] { text-align: center !important; color: #2d6a4f !important; border-bottom: 1px solid rgba(10, 46, 26, .2) !important; padding-bottom: 6px !important; }
html body .mac-page .mac-table td { padding: 16px !important; border: 0 !important; border-bottom: 1px solid rgba(10, 46, 26, .1) !important; background: transparent !important; text-align: right; color: #1f2a22;
    font: 500 17px/1.4 Roboto, sans-serif; font-variant-numeric: tabular-nums; transition: background-color 150ms; }
html body .mac-page .mac-table td:first-child { text-align: left; font: 700 16px/1.4 'Plus Jakarta Sans', sans-serif; color: #0a2e1a; }
html body .mac-page .mac-table td.mac-highlight-td { font-weight: 500; color: #1f2a22; }
html body .mac-page .mac-table tbody tr:hover td { background: #f2ede1 !important; }
html body .mac-page .mac-table tbody tr:hover td:first-child { color: #1a472a; }

/* Anti-Depredation Measures, immersive: deep-green cards, each with its number large and faint in the corner; pointing at
   a card tilts it toward the pointer, a warm light follows the pointer, a gold line draws across its top, the icon fills
   gold and lifts, the title turns gold (--rx/--ry/--gx/--gy from js/designs/wl_conflict.js) */
html body .mac-page .mac-measures-grid { gap: 12px; counter-reset: macm; }
html body .mac-page .mac-measure-card { counter-increment: macm; position: relative; overflow: hidden; isolation: isolate; padding: 32px 24px; border: 0; border-radius: 8px; background: #0a2e1a; box-shadow: none; opacity: 1;
    transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform 200ms cubic-bezier(.4, 0, .2, 1), background-color 200ms; }
html body .mac-page .mac-measure-card::before { content: counter(macm, decimal-leading-zero); position: absolute; right: 16px; bottom: -18px; z-index: -1; font: 500 120px/1 Roboto, sans-serif; letter-spacing: -.06em;
    color: rgba(255, 255, 255, .05); transition: color 300ms, transform 400ms cubic-bezier(.16, 1, .3, 1); }
html body .mac-page .mac-measure-card::after { content: ''; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity 200ms; pointer-events: none;
    background: radial-gradient(300px circle at var(--gx, 50%) var(--gy, 50%), rgba(241, 196, 15, .18), transparent 60%), linear-gradient(#f1c40f, #f1c40f) no-repeat 0 0 / 100% 3px; }
html body .mac-page .mac-measure-card:hover { background: #0f3a22; transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(-4px); box-shadow: 0 20px 40px -20px rgba(10, 46, 26, .6); }
html body .mac-page .mac-measure-card:hover::after { opacity: 1; }
html body .mac-page .mac-measure-card:hover::before { color: rgba(241, 196, 15, .14); transform: translateY(-8px); }
html body .mac-page .mac-measure-icon { width: 52px; height: 52px; border-radius: 50%; background: rgba(255, 255, 255, .1); color: #8fc9a3; box-shadow: none;
    transition: background-color 150ms, color 150ms, transform 300ms cubic-bezier(.34, 1.56, .64, 1); }
html body .mac-page .mac-measure-card:hover .mac-measure-icon { background: #f1c40f; color: #0a2e1a; transform: translateY(-4px) rotate(-8deg); }
html body .mac-page .mac-measure-title { margin-top: 20px; font-size: 19px; font-weight: 800; color: #fff; transition: color 150ms; }
html body .mac-page .mac-measure-card:hover .mac-measure-title { color: #f1c40f; }
html body .mac-page .mac-measure-desc, html body .mac-page .mac-measure-desc p { font-size: 15px; line-height: 1.65; color: rgba(255, 255, 255, .75); }
@media (prefers-reduced-motion: reduce) { html body .mac-page .mac-measure-card { transform: none !important; } }

/* The other blocks brought up to the measures cards: deep green, gold accents, pointer light and tilt */
/* causes: golden split, gold title and icon left, words right, a light that follows the pointer */
.mac-cause { position: relative; overflow: hidden; isolation: isolate; display: grid; grid-template-columns: 38.2fr 61.8fr; gap: 52px; align-items: start; margin-bottom: 20px; padding: 52px; border-radius: 8px; background: #0a2e1a; }
.mac-cause::after { content: ''; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity 200ms; pointer-events: none; background: radial-gradient(420px circle at var(--gx, 50%) var(--gy, 50%), rgba(241, 196, 15, .14), transparent 60%); }
.mac-cause:hover::after { opacity: 1; }
.mac-cause-title { display: flex; flex-direction: column; gap: 20px; margin: 0; font-family: 'Plus Jakarta Sans', sans-serif; font-size: clamp(24px, 2.2vw, 32px); font-weight: 800; line-height: 1.15; letter-spacing: -.02em; color: #f1c40f; }
.mac-cause-icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: #f1c40f; color: #0a2e1a; font-size: 18px; box-shadow: 0 0 0 8px rgba(241, 196, 15, .15); transition: transform 300ms cubic-bezier(.34, 1.56, .64, 1); }
.mac-cause:hover .mac-cause-icon { transform: rotate(-10deg) scale(1.06); }
.mac-cause-words p { margin: 0 0 12px; font-size: 17px; line-height: 1.75; color: rgba(255, 255, 255, .85); }
.mac-cause-words p:last-child { margin-bottom: 0; }

/* tables: inside a sand panel; the row under the pointer turns deep green with white figures and a gold marker */
html body .mac-page .mac-table-container { padding: 12px 24px 24px; border-radius: 8px; background: #f2ede1; }
html body .mac-page .mac-table tbody tr { position: relative; }
html body .mac-page .mac-table td { transition: background-color 150ms, color 150ms; }
html body .mac-page .mac-table tbody tr:hover td { background: #0a2e1a !important; color: #fff !important; }
html body .mac-page .mac-table tbody tr:hover td:first-child { color: #f1c40f !important; box-shadow: inset 3px 0 0 #f1c40f; }
html body .mac-page .mac-table tbody tr:last-child td { border-bottom: 0 !important; }

/* field photos: green captioned cards that tilt toward the pointer; the picture zooms and opens in full view */
html body .mac-page .mac-img-card { border: 0; border-radius: 8px; background: #0a2e1a; box-shadow: none; opacity: 1;
    transform: perspective(1000px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform 200ms cubic-bezier(.4, 0, .2, 1); }
html body .mac-page .mac-img-card:hover { transform: perspective(1000px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(-4px); }
html body .mac-page .mac-img-frame img { cursor: zoom-in; transition: transform 600ms cubic-bezier(.16, 1, .3, 1); }
html body .mac-page .mac-img-card:hover .mac-img-frame img { transform: scale(1.05); }
html body .mac-page .mac-img-info { padding: 20px 24px 24px; }
html body .mac-page .mac-img-title { margin: 0 0 4px; font-size: 17px; font-weight: 800; color: #fff; transition: color 150ms; }
html body .mac-page .mac-img-card:hover .mac-img-title { color: #f1c40f; }
html body .mac-page .mac-img-cap { margin: 0; font-size: 14px; line-height: 1.55; color: rgba(255, 255, 255, .72); }
@media (max-width: 900px) { .mac-cause { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 32px 20px; } }

/* Field photos fill the row (no empty space beside them): the cards share the full width, pictures kept short */
@media (min-width: 769px) {
    html body .mac-page .mac-parallel-row { max-width: none; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); }
    html body .mac-page .mac-img-frame { height: 240px; }
}

/* Field photo cards as one frame split in half: the picture on one half, the title and words on the other */
@media (min-width: 769px) {
    html body .mac-page .mac-img-card { display: grid; grid-template-columns: 1fr 1fr; align-items: stretch; min-height: 260px; }
    html body .mac-page .mac-img-frame { height: auto; min-height: 260px; }
    html body .mac-page .mac-img-frame img { width: 100%; height: 100%; object-fit: cover; }
    html body .mac-page .mac-img-info { display: flex; flex-direction: column; justify-content: center; padding: 32px; }
    html body .mac-page .mac-img-title { font-size: 19px; margin-bottom: 8px; }
    html body .mac-page .mac-img-cap { font-size: 15px; line-height: 1.65; }
}

/* ── Sections added in the CMS (no slot: drawn as standard bands) in the site design, as on Territorial Overview:
   left-aligned headings on the 5% margins with no gold bar (the tables themselves follow the standard table design in
   css/wing_design.css). An empty cards section (only a title) reads as the heading of the tables under it. ── */
html body .mac-page .dz-band .dz-wrap { max-width: none; padding: 0 5%; }
html body .mac-page .dz-band { padding: 32px 0 !important; }
html body .mac-page .dz-title,
html body .mac-page .dz-title.dz-centred { margin: 0 0 20px; text-align: left; font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800;
    font-size: clamp(28px, 2.5vw, 38px); line-height: 1.1; letter-spacing: -.035em; color: #0a2e1a; text-wrap: balance; }
html body .mac-page .dz-underline { display: none; }
html body .mac-page .dz-k-cards:not(:has(.dz-card-item)) { padding-top: 84px !important; padding-bottom: 0 !important; }
html body .mac-page .dz-k-cards:not(:has(.dz-card-item)) .dz-title { max-width: 62ch; margin: 0; }
@media (max-width: 900px) {
    html body .mac-page .dz-band .dz-wrap { padding: 0 20px; }
    html body .mac-page .dz-k-cards:not(:has(.dz-card-item)) { padding-top: 52px !important; }
}

/* the tables' heading rows: deep green with bold yellow text (as on Parks & Gardens, Joint Forest Management) */
html body .dz-page.mac-page .dz-table thead th { background: #0b3d2c !important; color: #f1c40f !important; font-weight: 700 !important; }
