/* ICCI 2026 Block Theme: adapts WordPress blocks to the ICCI design in site.css. */

/* ---------- Resets for WordPress block markup ---------- */
.wp-site-blocks > *, .site-main > *, .icci-content > * { margin-block: 0; }
.site-top { display: contents; }
figure.wp-block-image, figure.wp-block-table, .wp-block-image { margin: 0; }
:where(.wp-block-image) img { display: block; max-width: 100%; height: auto; }
.wp-block-image.media img, .split > .wp-block-image img { width: 100%; height: 100%; object-fit: cover; }
.wp-block-group:where(.prose, .doc, .wrap) > * { min-width: 0; }
:where(.wp-block-group.wrap) { max-width: var(--wrap); margin-left: auto; margin-right: auto; }

/* Blocks placed directly on a page (outside an ICCI section) line up with the page width. */
.icci-content > :is(p, h1, h2, h3, h4, ul, ol, .wp-block-image, .wp-block-table, .wp-block-buttons, .wp-block-details, .wp-block-quote, .wp-block-embed, .wp-block-columns, .wp-block-separator, .wp-block-file, .wp-block-gallery, .wp-block-media-text, .wp-block-group:not(.alignfull):not([class*="block"]):not(.facts):not(.hero):not(.page-head):not(.wrap):not(.cta)) {
	max-width: calc(var(--wrap) - 2 * clamp(1.1rem, 3vw, 2rem));
	margin-left: auto; margin-right: auto;
	width: calc(100% - 2 * clamp(1.1rem, 3vw, 2rem));
}
.icci-content > p, .icci-content > ul, .icci-content > ol { max-width: min(72ch, calc(var(--wrap) - 4rem)); margin: .9rem auto; }
.icci-content > h2 { font-size: var(--t-xl); margin: 2.5rem auto 1rem; }
.icci-content > h3 { font-size: var(--t-lg); margin: 1.75rem auto .5rem; }
.icci-content > :first-child:is(p, h2, h3, ul, ol) { margin-top: 3rem; }
.icci-content > :last-child:is(p, h2, h3, ul, ol, .wp-block-buttons, .wp-block-image, .wp-block-table) { margin-bottom: 3.5rem; }
.icci-content > ul, .icci-content > ol { padding-left: 1.25rem; }

/* Tables: the core table block adds its own borders. */
.wp-block-table table { border-collapse: collapse; width: 100%; }
.wp-block-table :where(td, th) { border: 0; padding: 0; }
.tbl-wrap > .wp-block-table { overflow: visible; }
figure.wp-block-table.tbl { display: block; }
.tbl-wrap .wp-block-table thead, .tbl-wrap .wp-block-table tfoot { border: 0; }
.wp-block-table.tbl table th, .wp-block-table.tbl table td, .tbl th, .tbl td { padding: .75rem 1rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.wp-block-table.tbl table th, .tbl th { background: var(--surface-2); font-weight: 600; color: var(--navy); font-size: var(--t-sm); }
.wp-block-table.is-style-icci-table table { border-collapse: collapse; width: 100%; background: #fff; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.wp-block-table.is-style-icci-table th, .wp-block-table.is-style-icci-table td { padding: .75rem 1rem; border-bottom: 1px solid var(--line); text-align: left; }
.wp-block-table.is-style-icci-table th { background: var(--surface-2); color: var(--navy); font-size: var(--t-sm); }

/* Details: hide the browser marker, keep ICCI chevrons. */
.wp-block-details > summary { list-style: none; cursor: pointer; }
.wp-block-details > summary::-webkit-details-marker { display: none; }
details.wp-block-details.area > summary::after, details.wp-block-details.faq > summary::after, details.wp-block-details:not([class*=" "]) > summary::after {
	content: ""; flex: none; width: 18px; height: 18px; margin-left: .75rem;
	background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") center/contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") center/contain no-repeat;
	transition: transform .2s; color: var(--muted);
}
details.wp-block-details[open] > summary::after { transform: rotate(180deg); }
details.wp-block-details:not(.area):not(.faq):not([class*=" "]) { border: 1px solid var(--line); border-radius: var(--r); background: #fff; margin: .6rem 0; }
details.wp-block-details:not(.area):not(.faq):not([class*=" "]) > summary { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.25rem; font-weight: 600; color: var(--navy); }
details.wp-block-details:not(.area):not(.faq):not([class*=" "]) > :not(summary) { padding: 0 1.25rem; }
details.wp-block-details:not(.area):not(.faq):not([class*=" "]) > :last-child:not(summary) { padding-bottom: 1.1rem; }

/* Tick lists (the "Tick marks" list style and the ICCI .ticks and .pro-facts lists). */
ul.ticks, ul.pro-facts, ul.is-style-icci-ticks { list-style: none; margin-left: 0 !important; padding-left: 0 !important; display: grid; }
ul.ticks, ul.is-style-icci-ticks { gap: .75rem; }
ul.ticks > li, ul.pro-facts > li, ul.is-style-icci-ticks > li { display: block; position: relative; padding-left: 1.85rem; max-width: none; }
ul.pro-facts > li { padding-left: 1.6rem; }
ul.ticks > li::before, ul.pro-facts > li::before, ul.is-style-icci-ticks > li::before {
	content: ""; position: absolute; left: 0; top: .3em; width: 18px; height: 18px; background: var(--orange);
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
}
ul.pro-facts > li::before { top: .15em; background: var(--orange-ink); }
.ap-side ul.ticks > li::before { background: var(--blue); }
ul.ticks > li > svg, ul.pro-facts > li > svg { display: none; }
.prose ul.ticks, .prose ul.pro-facts { margin-left: 0; }

/* Key-value lists and fact strips built from paragraphs. */

/* ---------- Buttons ---------- */
.wp-block-buttons { display: flex; flex-wrap: wrap; gap: .75rem; }
.wp-block-button__link, .wp-element-button {
	display: inline-flex; align-items: center; gap: .5rem; padding: .75rem 1.25rem; border-radius: 999px; font-weight: 700; font-size: var(--t-sm);
	text-decoration: none; white-space: nowrap; background: var(--orange); color: var(--navy); border: 0; font-family: var(--body); line-height: 1.6; cursor: pointer;
	transition: background .18s, color .18s;
}
.wp-block-button__link:hover { background: #ffa83f; color: var(--navy); }
.is-style-icci-blue .wp-block-button__link { background: var(--blue); color: #fff; }
.is-style-icci-blue .wp-block-button__link:hover { background: var(--navy); color: #fff; }
.is-style-icci-ghost .wp-block-button__link { background: transparent; border: 1.5px solid currentColor; color: var(--navy); }
.is-style-icci-ghost .wp-block-button__link:hover { background: var(--navy); color: #fff; }
.is-style-icci-light .wp-block-button__link { background: transparent; border: 1.5px solid rgba(255, 255, 255, .6); color: #fff; }
.is-style-icci-light .wp-block-button__link:hover { background: #fff; color: var(--navy); }
p:has(> a.btn) { max-width: none; }
p > a.btn + a.btn { margin-left: .6rem; }

/* ---------- Section looks for Group blocks ---------- */
.wp-block-group.is-style-icci-alt { background: var(--surface-2); padding: clamp(3rem, 7vw, 5.5rem) 0; }
.wp-block-group.is-style-icci-dark { background: var(--navy); color: #dfe2ff; padding: clamp(3rem, 7vw, 5.5rem) 0; }
.wp-block-group.is-style-icci-dark :is(h2, h3, h4) { color: #fff; }
.wp-block-group.is-style-icci-warm { background: #fdf3e6; padding: clamp(3rem, 7vw, 5.5rem) 0; }

/* ---------- Header ---------- */
.util .u-left, .util .u-links { margin: 0; max-width: none; display: flex; gap: 1.25rem; flex-wrap: wrap; }
.util .u-right { display: flex; align-items: center; gap: 1.25rem; }
.util .wp-block-social-links.social.sm { margin: 0 0 0 .5rem; padding: 0; gap: .35rem; list-style: none; display: flex; }
.util .wp-block-social-links .wp-social-link { margin: 0; background: transparent !important; }
.util .wp-block-social-links .wp-block-social-link-anchor { width: 24px; height: 24px; padding: 0; border: 0; background: transparent; display: grid; place-items: center; color: #fff !important; }
.util .wp-block-social-links svg { width: 15px; height: 15px; fill: currentColor; }
.util .wp-block-social-links .wp-block-social-link-anchor:hover { color: var(--orange) !important; }

header.site .wrap { position: relative; }
header.site .brand { flex: none; }
header.site .brand a { display: block; }
header.site .brand img { width: 210px !important; height: auto; }
header.site .head-cta .wp-block-buttons { gap: 0; }

nav.wp-block-navigation.main { flex: 1 1 auto; justify-content: center; font-size: var(--t-sm); }
nav.wp-block-navigation.main .wp-block-navigation__container { list-style: none; display: flex; gap: .25rem; align-items: center; flex-wrap: nowrap; }
nav.wp-block-navigation.main .wp-block-navigation-item__content { display: block; white-space: nowrap; padding: .55rem .6rem; border-radius: 8px; text-decoration: none; color: var(--ink); font-weight: 500; font-size: var(--t-sm); }
nav.wp-block-navigation.main .wp-block-navigation-item__content:hover { background: var(--sky); color: var(--navy); }
nav.wp-block-navigation.main .wp-block-navigation-item__content[aria-current="page"] { color: var(--blue); box-shadow: inset 0 -2px 0 var(--orange); border-radius: 0; }
nav.wp-block-navigation.main .nav-apply { display: none; }
nav.wp-block-navigation.main .wp-block-navigation__responsive-container-open { width: 44px; height: 44px; border-radius: 10px; align-items: center; justify-content: center; border: 1px solid var(--line); color: var(--navy); }

/* Collapse the menu at the same width as the 2026 design. */
@media (max-width: 1180px) {
	nav.wp-block-navigation.main { order: 3; flex: none; display: flex; position: static; background: none; border: 0; box-shadow: none; margin-left: .5rem; }
	nav.wp-block-navigation.main ul { padding: 0; }
	nav.wp-block-navigation.main .wp-block-navigation-item__content[aria-current="page"] { box-shadow: inset 3px 0 0 var(--orange); background: var(--sky); border-radius: 8px; }
	nav.wp-block-navigation.main .wp-block-navigation__responsive-container-open:not(.always-shown) { display: flex; }
	nav.wp-block-navigation.main .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none; }
	nav.wp-block-navigation.main .wp-block-navigation__responsive-container.is-menu-open { padding: 1.25rem; background: #fff; }
	nav.wp-block-navigation.main .is-menu-open .wp-block-navigation__container { flex-direction: column; align-items: stretch; gap: .25rem; width: 100%; }
	nav.wp-block-navigation.main .is-menu-open .wp-block-navigation-item { width: 100%; }
	nav.wp-block-navigation.main .is-menu-open .wp-block-navigation-item__content { padding: .85rem 1rem; font-size: var(--t-base); width: 100%; }
	nav.wp-block-navigation.main .is-menu-open .wp-block-navigation__responsive-container-content { padding-top: 3rem; align-items: stretch; }
	nav.wp-block-navigation.main .is-menu-open .nav-apply { display: block; }
	nav.wp-block-navigation.main .is-menu-open .nav-apply .wp-block-navigation-item__content { background: var(--orange); color: var(--navy); font-weight: 700; border-radius: 10px; text-align: center; margin-top: .5rem; }
	header.site .head-cta { margin-left: auto; }
}

/* Header search: a round button that opens a search box. */
.icci-search.wp-block-search { margin: 0; }
.icci-search .wp-block-search__inside-wrapper { display: flex; align-items: center; gap: .4rem; border: 0; padding: 0; }
.icci-search .wp-block-search__button { width: 44px; height: 44px; min-width: 44px; padding: 0; margin: 0; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: var(--navy); border: 1px solid var(--line); background: #fff; }
.icci-search .wp-block-search__button:hover { background: var(--navy); color: #fff; border-color: var(--navy); }
.icci-search .wp-block-search__button svg { width: 22px; height: 22px; fill: currentColor; min-width: 22px; }
.icci-search .wp-block-search__input { font: inherit; font-size: var(--t-sm); padding: .6rem .9rem; border: 1.5px solid var(--line); border-radius: 999px; width: 240px; }
.icci-search.wp-block-search__searchfield-hidden .wp-block-search__input { width: 0; padding: 0; border-width: 0; }
@media (max-width: 640px) { .head-apply { display: none; } .icci-search .wp-block-search__input { width: 160px; } }

/* ---------- Footer ---------- */
footer.site .wrap > .cols { display: grid; }
footer.site p { max-width: none; }
footer.site .logo-pill { background: #fff; border-radius: 12px; padding: .75rem 1rem; display: inline-block; margin: 0 0 1rem; }
footer.site .logo-pill img { width: 190px; }
footer.site h4.f-follow { margin-top: 1.5rem; }
footer.site .wp-block-list { list-style: none; display: grid; gap: .5rem; padding: 0; }
footer.site .f-label { color: #fff; font-weight: 600; }
footer.site .base p { margin: 0; }
footer.site .wp-block-social-links.social { list-style: none; padding: 0; margin: 0; display: flex; gap: .6rem; flex-wrap: wrap; }
footer.site .wp-block-social-links .wp-social-link { margin: 0; background: transparent !important; border-radius: 50%; }
footer.site .wp-block-social-links .wp-block-social-link-anchor { width: 38px; height: 38px; padding: 0; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .08); color: #fff !important; border: 1px solid rgba(255, 255, 255, .16); transition: background .2s, color .2s; }
footer.site .wp-block-social-links .wp-block-social-link-anchor:hover { background: var(--orange); color: var(--navy) !important; border-color: var(--orange); }
footer.site .wp-block-social-links svg { width: 18px; height: 18px; fill: currentColor; }

/* ---------- Page parts ---------- */
.page-head .wp-block-post-title { font-size: var(--t-2xl); }
.prose-wrap { max-width: 860px; }
.narrow { max-width: 860px; }
.plain-content > * + * { margin-top: .9rem; }
.tab-panel[hidden] { display: none; }
.sr-only, .tab-panel > .tab-title.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.adm-grid { display: grid; grid-template-columns: 1fr 320px; gap: clamp(2rem, 5vw, 4rem); }
@media (max-width: 899px) { .adm-grid { grid-template-columns: 1fr; } }
.toc a { display: block; }
.toc[hidden] { display: none; }
[data-pool][hidden], .p-card[hidden], details.course[hidden] { display: none; }

/* News article */
.article .a-wrap { max-width: 780px; }
.article .n-meta { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; }
.article .n-meta .wp-block-post-terms a { color: inherit; text-decoration: none; }
.article .wp-block-post-title { font-size: var(--t-2xl); margin: .75rem 0 1.25rem; }
.article .a-img img { width: 100%; border-radius: var(--r-lg); }
.article .a-body > * + * { margin-top: 1rem; }

/* Search and archive lists */
.icci-loop .sr-list { list-style: none; padding: 0; display: grid; }
.icci-loop .sr-list > li { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.icci-loop .wp-block-post-title { font-size: var(--t-lg); font-family: var(--body); font-weight: 600; }
.icci-loop .wp-block-post-title a { text-decoration: none; }
.icci-loop .wp-block-post-excerpt { color: var(--muted); font-size: var(--t-sm); margin-top: .25rem; }
.icci-loop .wp-block-query-pagination { margin-top: 1.5rem; gap: .75rem; display: flex; }
.sr-form-b .wp-block-search__inside-wrapper { display: flex; gap: .6rem; }
.sr-form-b .wp-block-search__input { flex: 1; min-width: 0; font: inherit; font-size: 1.05rem; padding: .75rem 1rem; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
.sr-form-b .wp-block-search__button { margin: 0; }
.page-head .wp-block-query-title { font-size: var(--t-2xl); }

/* Admissions sidebar apply button spans the column, as in the preview. */
.adm-grid .side > p:has(> a.btn:only-child) { margin: 0; }
.adm-grid .side > p > a.btn:only-child { display: flex; width: 100%; justify-content: center; }

/* A styled link that sat directly in a layout (for example a president card) behaves as its own grid item. */
p.dv:has(> a[class]:only-child) { display: contents; }

/* Small screens: keep the top strip to the phone number, Populi login and one social icon, as in the preview. */
@media (max-width: 640px) {
	.util .wp-block-social-links .wp-social-link:not(:first-child) { display: none; }
	header.site .brand img { width: 170px !important; }
}
header.site .head-cta { flex: none; }
