/* HSLC theme — warm cream + shelter blue, matching the Forever Home / HSLC materials. */
:root {
    --hslc-blue: #2f6f9f;
    --hslc-blue-dark: #1d4e72;
    --hslc-ink: #2b2b2b;
    --hslc-cream: #f7f4ec;
    --hslc-green: #4a8a3d;
    --hslc-border: #e3ddcf;
}

body {
    color: var(--hslc-ink);
    background-color: var(--hslc-cream);
}

/* Interior (non-home) pages render inside a centered wrap with vertical padding. */
.site-main { min-height: 55vh; }
/* Higher specificity than .wrap (which sets `padding: 0 24px`) so the top/bottom
   breathing room sticks and content never butts against the header or footer. */
.site-main.wrap { padding-top: 40px; padding-bottom: 80px; }
/* Content links (the redesign resets <a> to inherit) — make them visibly clickable,
   without affecting buttons, filter chips, pet cards, or memorial cards. */
.site-main a:not(.btn):not(.chip):not(.pet-card):not(.memorial-card) { color: var(--terracotta-dk, #1E80B8); font-weight: 600; }
.site-main a:not(.btn):not(.chip):not(.pet-card):not(.memorial-card):hover { text-decoration: underline; }
/* Restore readable spacing for generic content (the redesign reset removes default margins). */
.site-main h1 { margin-bottom: .4rem; color: var(--bark); }
.site-main h2 { margin: 1.9rem 0 .6rem; color: var(--bark); }
.site-main h3 { margin: 1rem 0 .4rem; }
.site-main p { margin-bottom: .8rem; }
.site-main ul:not(.req-list) { padding-left: 1.4rem; margin-bottom: .8rem; }
.site-main li { margin-bottom: .25rem; }
.site-main .lead { font-size: 1.15rem; color: var(--moss-dk); margin-bottom: 1rem; }
.site-main .page-hero { width: 100%; height: auto; border-radius: 16px; margin: .5rem 0 1.5rem; }
.site-main .info-stack { display: flex; flex-direction: column; gap: 20px; }

/* Animal detail: photo left (sized to fit), details right (stacks on mobile) */
.detail-grid { display: grid; grid-template-columns: minmax(280px, 440px) 1fr; gap: 36px; align-items: start; margin-top: .5rem; }
/* Detail page shows the WHOLE animal at its natural shape (no crop, no box, no stretch) */
.detail-hero { display: block; width: 100%; height: auto; border-radius: 14px; }
.detail-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; margin-top: 10px; }
.detail-thumbs img { width: 100%; aspect-ratio: 1/1; object-fit: cover; object-position: center top; border-radius: 8px; }
@media (max-width: 760px) { .detail-grid { grid-template-columns: 1fr; } }
/* Real photos inside hero carousel slides */
.slide img { width: 100%; height: 100%; object-fit: cover; object-position: center top; display: block; }

a, .btn-link { color: var(--hslc-blue); }
a:hover { color: var(--hslc-blue-dark); }

h1, h2, h3 { color: var(--hslc-blue-dark); }
h1 { font-weight: 700; }
h2 { margin-top: 1.6rem; }

.content { max-width: 1100px; padding-bottom: 2rem; }

/* Buttons */
.btn-primary { background-color: var(--hslc-blue); border-color: var(--hslc-blue); color: #fff; }
.btn-primary:hover { background-color: var(--hslc-blue-dark); border-color: var(--hslc-blue-dark); }
.btn-success { background-color: var(--hslc-green); border-color: var(--hslc-green); }

/* Hero */
.hero {
    background: linear-gradient(180deg, #ffffff 0%, var(--hslc-cream) 100%);
    border: 1px solid var(--hslc-border);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 1.5rem;
}
.hero .lead { font-size: 1.25rem; color: var(--hslc-blue); font-style: italic; }
.cta-row { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1rem; }

/* Hero / page banner images */
.hero-img {
    width: 100%;
    height: 340px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 1.25rem;
    display: block;
}
.page-hero {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 0.5rem 0 1.5rem;
    display: block;
}

/* Info grid (home) */
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; margin-top: 1.5rem; }

/* Card grids (animals, memorials) */
.animal-grid, .memorial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}
.card {
    border: 1px solid var(--hslc-border);
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    text-decoration: none;
    color: inherit;
    transition: box-shadow .15s ease;
}
.card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.08); }
.animal-card img, .memorial-card img { width: 100%; height: 180px; object-fit: cover; display: block; }
.card .card-body { padding: 0.75rem 1rem; }
.card h3 { margin: 0 0 .25rem; font-size: 1.1rem; }

/* News & events */
.news-item, .event-item { border-bottom: 1px solid var(--hslc-border); padding: 1.25rem 0; }
.news-image, .event-image { max-width: 100%; border-radius: 8px; margin: .5rem 0; }

/* Admin stat cards */
.stat-grid { display: flex; flex-wrap: wrap; gap: 1rem; margin: 1rem 0 1.5rem; }
.stat {
    background: #fff; border: 1px solid var(--hslc-border); border-radius: 10px;
    padding: 1rem 1.5rem; min-width: 140px; text-align: center;
}
.stat .num { display: block; font-size: 2rem; font-weight: 700; color: var(--hslc-blue); }
.stat .label { color: #666; font-size: .9rem; }

/* Admin */
.admin-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 1rem; }
.admin-table { width: 100%; background: #fff; border: 1px solid var(--line, #D8EAF3); border-radius: 12px; overflow: hidden; border-collapse: collapse; margin-bottom: 1rem; }
.admin-table th, .admin-table td { text-align: left; padding: 11px 14px; font-size: 14px; border-bottom: 1px solid var(--line, #D8EAF3); }
.admin-table thead th { background: #eef7fb; color: var(--bark, #16455F); font-weight: 600; }
.admin-table tbody tr:last-child td { border-bottom: none; }
.admin-table tbody tr:hover { background: #f7fbfe; }
.admin-table a { color: var(--terracotta-dk, #1E80B8); font-weight: 600; }
/* Animal list thumbnails + status pills */
.admin-thumb-link { position: relative; display: inline-block; line-height: 0; }
.admin-thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line, #D8EAF3); display: block; }
.admin-thumb-badge { position: absolute; bottom: -6px; right: -6px; background: var(--bark, #16455F); color: #fff; font-size: 11px; font-weight: 700; border-radius: 10px; padding: 1px 7px; line-height: 1.5; }
.admin-thumb-missing { display: inline-flex; align-items: center; justify-content: center; min-width: 56px; height: 56px; padding: 0 10px; border-radius: 10px; border: 2px dashed var(--terracotta, #2BA0DA); color: var(--terracotta-dk, #1E80B8); font-size: 12px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.admin-thumb-missing:hover { background: #f0f9ff; }
.admin-animal-name { font-size: 15px; }
.pill { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 11px; border-radius: 30px; }
.pill-green { background: #e2f2ee; color: #1f6f5c; }
.pill-gray { background: #eee; color: #6b6b6b; }
/* Event editor flyer preview */
.current-flyer { margin-bottom: 10px; }
.current-flyer img { display: block; max-width: 320px; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line, #D8EAF3); margin-bottom: 6px; }
.admin-form { background: #fff; border: 1px solid var(--line, #D8EAF3); border-radius: 16px; padding: 26px; max-width: 640px; }
.admin-form .form-label { font-weight: 600; color: var(--bark, #16455F); font-size: 14px; }
.admin-card { background: #fff; border: 1px solid var(--line, #D8EAF3); border-radius: 14px; padding: 20px 24px; }
.admin-links { list-style: none; padding: 0; }
.admin-links li { padding: 10px 0; border-bottom: 1px solid var(--line, #D8EAF3); }
.admin-links li:last-child { border-bottom: none; }

/* "Today" event highlight */
.today-badge { display:inline-block; background:#F1582F; color:#fff; font-size:10px; font-weight:700; letter-spacing:.06em; padding:2px 9px; border-radius:20px; margin-bottom:4px; }
.event.event-today { border-color:#2BA0DA; box-shadow:0 0 0 2px #2BA0DA inset; }

/* Simple bar chart (site stats) */
.bar-chart { margin: 1rem 0; max-width: 640px; }
.bar-row { display: flex; align-items: center; gap: .75rem; margin-bottom: .35rem; }
.bar-label { width: 4rem; font-size: .85rem; color: #666; text-align: right; }
.bar { flex: 1; background: #eee; border-radius: 4px; height: 1.1rem; overflow: hidden; }
.bar-fill { display: block; height: 100%; background: var(--hslc-blue); }
.bar-value { width: 3rem; font-size: .85rem; }

/* Top row tagline + footer */
.brand-tagline { color: var(--hslc-blue-dark); font-style: italic; }
.site-footer {
    background: #fff;
    border-top: 1px solid var(--hslc-border);
    padding: 1.5rem 2rem;
    margin-top: 2rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 1rem;
    font-size: .9rem;
}
.site-footer a { text-decoration: none; }
