/* Orion public site. Used by resources/views/master.blade.php. */

:root {
    --ink: #1D1420;
    --ink-soft: #4E4352;
    --muted: #6B5D6E;
    --cream: #FFFAF4;
    --sand: #FBF1E6;
    --line: #F0E4D6;
    --line-strong: #E3D3C2;
    --accent-a: #F7A93B;
    --accent-b: #E063C9;
    --link-hover: #A3218F;
    --radius: 24px;
    --wrap: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--cream);
    color: var(--ink);
    font-family: 'Libre Franklin', Arial, sans-serif;
    font-size: 17px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--ink); }
a:hover { color: var(--link-hover); }

h1, h2, h3, h4 { margin: 0; line-height: 1.15; font-weight: 700; }
p { margin: 0; }

:focus-visible { outline: 3px solid var(--link-hover); outline-offset: 3px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 32px; }

.skip-link {
    position: absolute; left: 16px; top: -60px; z-index: 100;
    background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 8px;
}
.skip-link:focus { top: 16px; color: #fff; }

.visually-hidden {
    position: absolute !important; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 48px; padding: 0 26px; border-radius: 999px;
    font: inherit; font-weight: 600; font-size: 16px; text-decoration: none;
    border: 1.5px solid transparent; cursor: pointer;
    transition: background-color .2s, color .2s, border-color .2s;
}
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #3A2B3F; color: #fff; }
.btn-outline { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-outline:hover { background: var(--ink); color: #fff; }
.btn-brand { background: linear-gradient(100deg, var(--accent-a), var(--accent-b)); color: var(--ink); }
.btn-brand:hover { color: var(--ink); filter: brightness(1.05); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }

.text-link { font-weight: 600; }

/* ---------- Header ---------- */

.site-header {
    background: var(--cream); border-bottom: 1px solid var(--line);
    position: sticky; top: 0; z-index: 50;
}
.site-header .wrap {
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; min-height: 80px;
}
.logo img { height: 40px; width: auto; }

.nav-toggle {
    display: none; align-items: center; gap: 8px;
    min-height: 44px; padding: 0 16px; border-radius: 999px;
    border: 1px solid var(--line-strong); background: #fff; color: var(--ink);
    font: inherit; font-weight: 600; cursor: pointer;
}

.site-nav ul {
    list-style: none; margin: 0; padding: 0;
    display: flex; align-items: center; gap: 28px;
}
.site-nav a { text-decoration: none; font-weight: 500; font-size: 15px; color: #3B2F3F; }
.site-nav a:hover { color: var(--link-hover); }
.site-nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.site-nav .btn { min-height: 44px; padding: 0 22px; color: var(--ink); font-weight: 600; }

@media (max-width: 960px) {
    .nav-toggle { display: inline-flex; }
    .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%;
        background: var(--cream); border-bottom: 1px solid var(--line); padding: 8px 32px 24px; }
    .site-nav.is-open { display: block; }
    .site-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
    .site-nav li a:not(.btn) { display: block; padding: 12px 0; font-size: 17px; border-bottom: 1px solid var(--line); }
    .site-nav .btn { margin-top: 16px; width: 100%; }
}

/* ---------- Sections ---------- */

.section { padding: 96px 0; }
.section-sand { background: var(--sand); }
.section-tight { padding: 72px 0; }
.section-head { display: flex; flex-direction: column; gap: 8px; margin-bottom: 40px; }
.section-head-row { flex-direction: row; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.section-title { font-size: 44px; line-height: 1.1; }
.section-sub { color: var(--ink-soft); }

/* Inner page title band */
.page-head { padding: 64px 0 56px; border-bottom: 1px solid var(--line); }
.breadcrumbs { list-style: none; margin: 0 0 12px; padding: 0; display: flex; gap: 8px; font-size: 15px; color: var(--muted); }
.breadcrumbs li + li::before { content: "/"; margin-right: 8px; }
.breadcrumbs a { color: var(--muted); }
.page-title { font-size: clamp(40px, 5vw, 56px); }

/* ---------- Home hero ---------- */

.hero { padding: 56px 0 80px; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center; }
.hero-copy { display: flex; flex-direction: column; gap: 24px; }
.hero-title { font-size: clamp(34px, 3.8vw, 50px); line-height: 1.1; max-width: 15em; }
.hero-lead { font-size: 19px; color: var(--ink-soft); max-width: 34rem; }
.hero-figure { margin: 0; }
.hero-figure figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); text-align: right; }
.hero-figure figcaption a { color: var(--muted); }
.hero-photo { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }

/* Figure band */
.stat-band { background: var(--ink); color: #fff; padding: 56px 0; }
.stat-band .wrap { display: flex; gap: 40px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.stat-figure { font-size: 64px; font-weight: 700; line-height: 1; }
.stat-text { font-size: 22px; line-height: 1.45; max-width: 36rem; color: #F3EAF2; }
.stat-text a { color: #fff; font-weight: 600; }
.stat-text a:hover { color: var(--accent-a); }

/* ---------- Cards and grids ---------- */

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }

.card {
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
    padding: 32px; display: flex; flex-direction: column; gap: 14px;
}
.card-title { font-size: 26px; }
.card p { color: var(--ink-soft); }
.card .text-link { margin-top: auto; }

.meta { font-size: 14px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px 14px; }

/* Causes (home) */
.causes { display: grid; grid-template-columns: repeat(6, 1fr); gap: 24px; }
.cause { grid-column: span 2; background: #fff; border-radius: var(--radius); overflow: hidden; }
.cause.is-wide { grid-column: span 3; }
.cause img { width: 100%; height: 220px; object-fit: cover; }
.cause h3 { padding: 22px 24px; font-size: 21px; line-height: 1.25; }
.cause a { text-decoration: none; }

/* Post and event cards */
.entry { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.entry-img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--sand); }
.entry-body { padding: 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.entry-title { font-size: 21px; line-height: 1.25; }
.entry-title a { text-decoration: none; }
.entry-excerpt { color: var(--ink-soft); font-size: 16px; }
.entry .text-link { margin-top: auto; }

.empty { color: var(--ink-soft); }

/* Gallery */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.gallery a { display: block; border-radius: 16px; overflow: hidden; }
.gallery img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; transition: transform .4s ease; }
.gallery a:hover img { transform: scale(1.03); }

/* ---------- Team ---------- */

.team { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px 24px; }

.member { display: flex; flex-direction: column; gap: 12px; text-decoration: none; color: var(--ink); }
.member:hover { color: var(--ink); }
.member-media {
    position: relative; overflow: hidden; border-radius: var(--radius);
    aspect-ratio: 4 / 5; background: var(--ink);
}
/* The layer underneath: an arrow that the photo slides away to reveal. */
.member-reveal {
    position: absolute; top: 0; right: 0; bottom: 0; width: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
}
.member-reveal span {
    width: 56px; height: 56px; border-radius: 999px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--accent-a), var(--accent-b)); color: var(--ink);
    transform: translateX(-12px); opacity: 0; transition: transform .5s ease, opacity .5s ease;
}
.member-photo {
    position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: cover; object-position: top;
    transition: transform .55s cubic-bezier(.22,.61,.36,1);
}
.member:hover .member-photo, .member:focus-visible .member-photo { transform: translateX(-50%); }
.member:hover .member-reveal span, .member:focus-visible .member-reveal span { transform: none; opacity: 1; }
.member:focus-visible { outline: none; }
.member:focus-visible .member-media { outline: 3px solid var(--link-hover); outline-offset: 4px; }
.member-name { font-size: 18px; }
.member-role { color: var(--ink-soft); font-size: 15px; }

/* Touch screens have no hover: keep the photo still and show a small arrow instead. */
.member-badge { display: none; }
@media (hover: none) {
    .member:hover .member-photo { transform: none; }
    .member-badge {
        display: flex; position: absolute; right: 14px; bottom: 14px;
        width: 44px; height: 44px; border-radius: 999px; background: #fff;
        align-items: center; justify-content: center; color: var(--ink);
    }
}

/* Team list on the About page */
.team-list { display: flex; flex-direction: column; gap: 32px; }
.profile {
    display: grid; grid-template-columns: 240px 1fr; gap: 40px; align-items: start;
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
    scroll-margin-top: 110px;
}
.profile img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: top; border-radius: 16px; }
.profile-body { display: flex; flex-direction: column; gap: 14px; }
.profile-name { font-size: 26px; }
.profile-role { color: var(--ink-soft); margin-top: -8px; }
.profile-body h4 { font-size: 15px; color: var(--ink-soft); margin-top: 4px; }
.profile-body ul { margin: 0; padding-left: 20px; }

/* ---------- Text content ---------- */

.prose { max-width: 46rem; }
.prose p + p, .prose p + ul, .prose ul + p { margin-top: 1rem; }
.prose ul { padding-left: 1.4rem; margin: .75rem 0 0; }
.prose li + li { margin-top: .35rem; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split-photo { width: 100%; height: 440px; object-fit: cover; border-radius: var(--radius); }

.accordion { display: flex; flex-direction: column; gap: 12px; }
.accordion details { background: #fff; border: 1px solid var(--line); border-radius: 16px; }
.accordion summary {
    list-style: none; cursor: pointer; padding: 20px 24px; font-weight: 600; font-size: 19px;
    display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after { content: "+"; font-size: 26px; font-weight: 400; line-height: 1; }
.accordion details[open] summary::after { content: "\2212"; }
.accordion .accordion-body { padding: 0 24px 24px; color: var(--ink-soft); }

.offices { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.office { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 32px; }
.office h3 { font-size: 22px; margin-bottom: 12px; }
.office p, .office li { color: var(--ink-soft); }
.office ul { margin: 12px 0 0; padding-left: 20px; }

.cause-row { display: grid; grid-template-columns: 1fr 1.3fr; gap: 48px; align-items: center; }
.cause-row + .cause-row { margin-top: 72px; }
.cause-row img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }
.cause-row h2 { font-size: 32px; margin-bottom: 16px; }
.cause-row:nth-child(even) .cause-row-media { order: 2; }
.photo-missing {
    aspect-ratio: 4 / 3; border-radius: var(--radius); background: var(--sand);
    display: flex; align-items: center; justify-content: center; color: var(--muted); text-align: center; padding: 24px;
}

/* ---------- Blog ---------- */

.blog-layout { display: grid; grid-template-columns: 1fr 320px; gap: 56px; align-items: start; }
.post-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }

.sidebar { display: flex; flex-direction: column; gap: 32px; }
.sidebar h2 { font-size: 20px; margin-bottom: 14px; }
.search { display: flex; gap: 8px; }
.search input { flex: 1; min-width: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags a { display: inline-block; padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid var(--line-strong); text-decoration: none; font-size: 15px; }
.recent { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.recent a { display: grid; grid-template-columns: 64px 1fr; gap: 14px; align-items: center; text-decoration: none; }
.recent img { width: 64px; height: 64px; object-fit: cover; border-radius: 12px; background: var(--sand); }
.recent strong { display: block; font-size: 16px; line-height: 1.3; }
.recent span { font-size: 14px; color: var(--muted); }

.article-img { width: 100%; max-height: 520px; object-fit: cover; border-radius: var(--radius); margin-bottom: 32px; }
.article-title { font-size: clamp(32px, 4vw, 44px); margin-bottom: 12px; }

.post-body { line-height: 1.8; font-size: 18px; margin-top: 28px; }
.post-body > * + * { margin-top: 1rem; }
.post-body h2 { font-size: 28px; margin-top: 2rem; }
.post-body h3 { font-size: 22px; margin-top: 1.5rem; }
.post-body ul, .post-body ol { padding-left: 1.5rem; }
.post-body blockquote { border-left: 4px solid var(--accent-a); padding: .25rem 1rem; color: var(--ink-soft); margin: 1.25rem 0; font-style: italic; }
.post-body pre { background: #fff; border: 1px solid var(--line); padding: .75rem 1rem; overflow-x: auto; border-radius: 12px; }
.post-body a { text-decoration: underline; }

.comments { margin-top: 64px; display: flex; flex-direction: column; gap: 16px; }
.comments h2 { font-size: 28px; }
.comment { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 20px 24px; }
.comment-head { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; margin-bottom: 6px; }
.comment-head span { font-size: 14px; color: var(--muted); }

.pagination { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 40px 0 0; }
.pagination .page-link {
    display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 12px;
    border-radius: 999px; border: 1px solid var(--line-strong); background: #fff; text-decoration: none; color: var(--ink);
}
.pagination .active .page-link { background: var(--ink); border-color: var(--ink); color: #fff; }
.pagination .disabled .page-link { color: #B3A6B5; }

/* ---------- Forms ---------- */

.form { display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 500; font-size: 15px; }
input[type="text"], input[type="email"], input[type="search"], textarea {
    font: inherit; font-size: 16px; padding: 12px 14px; width: 100%;
    border: 1px solid var(--line-strong); border-radius: 12px; background: #fff; color: var(--ink);
}
textarea { resize: vertical; min-height: 120px; }
.form .btn { align-self: flex-start; }

.alert { border-radius: 12px; padding: 14px 18px; font-size: 16px; }
.alert ul { margin: 0; padding-left: 18px; }
.alert-error { background: #FDECEC; color: #8A1C1C; }
.alert-success { background: #E8F5EC; color: #1E5B32; }

.contact-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 20px; }
.contact-list h3 { font-size: 15px; color: var(--ink-soft); margin-bottom: 4px; }

/* ---------- Footer ---------- */

.site-footer { background: var(--ink); color: #E9DDE8; padding: 72px 0 40px; font-size: 15px; }
.site-footer a { color: #E9DDE8; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1.4fr .8fr 1.4fr; gap: 40px; }
.site-footer h2 { font-size: 17px; color: #fff; margin-bottom: 14px; }
.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-social { list-style: none; margin: 8px 0 0; padding: 0; display: flex; gap: 10px; }
.footer-social a {
    width: 44px; height: 44px; border-radius: 999px; border: 1px solid #4A3B4F;
    display: flex; align-items: center; justify-content: center; color: #E9DDE8;
    transition: background-color .2s, color .2s, border-color .2s;
}
.footer-social a:hover { background: #fff; border-color: #fff; color: var(--ink); }
.footer-posts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.footer-posts span { display: block; color: #B9A9B7; font-size: 13px; }
.footer-bottom { margin-top: 48px; color: #B9A9B7; font-size: 14px; }

.whatsapp {
    position: fixed; right: 20px; bottom: 20px; z-index: 40;
    width: 56px; height: 56px; border-radius: 999px; background: #1F8A3B; color: #fff;
    display: flex; align-items: center; justify-content: center; box-shadow: 0 8px 24px rgba(29,20,32,.2);
}
.whatsapp:hover { color: #fff; background: #187030; }

/* ---------- Small screens ---------- */

@media (max-width: 900px) {
    .hero .wrap, .split, .grid-2, .grid-3, .blog-layout, .cause-row, .offices { grid-template-columns: 1fr; }
    .cause-row:nth-child(even) .cause-row-media { order: 0; }
    .causes { grid-template-columns: 1fr 1fr; }
    .cause, .cause.is-wide { grid-column: auto; }
    .team, .gallery { grid-template-columns: 1fr 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .profile { grid-template-columns: 160px 1fr; gap: 24px; }
}

@media (max-width: 600px) {
    .wrap { padding: 0 20px; }
    .section { padding: 64px 0; }
    .hero { padding: 48px 0 64px; }
    .section-title { font-size: 34px; }
    .stat-figure { font-size: 48px; }
    .causes, .post-list, .footer-grid { grid-template-columns: 1fr; }
    .profile { grid-template-columns: 1fr; }
    .profile img { max-width: 240px; }
    .split-photo { height: 300px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

.photo-credits { margin-top: 72px; font-size: 14px; color: var(--muted); }
.photo-credits a { color: var(--muted); }
