/* JCLALP website styles (home pages: index.html, en.html) */

/*****************************************
Table Of Contents:
- Fonts & Tokens
- Base
- Buttons
- Navigation
- Hero & Latest Issue
- Archive
- Goals
- Domains
- Publishing Rules
- Editorial Board
- Invitation
- Footer
- Animations
- Media Queries
******************************************/


/****************************/
/*     Fonts & Tokens       */
/****************************/
@font-face {
	font-family: 'Sakkal Majalla Regular';
	font-style: normal;
	font-weight: normal;
	font-display: swap;
	src: local('Sakkal Majalla'), url('../webfonts/majalla.woff') format('woff');
}

@font-face {
	font-family: 'Sakkal Majalla Bold';
	font-style: normal;
	font-weight: normal;
	font-display: swap;
	src: local('Sakkal Majalla Bold'), url('../webfonts/majallab.woff') format('woff');
}

:root {
	--green: #024E27;
	--green-dark: #01371b;
	--green-tint: #eef4f0;
	--ink: #191e47;
	--text: #6c717b;
	--surface: #f9fafe;
	--line: #e6e9f2;
	--white: #ffffff;
	--radius: 10px;
	--pill: 30px;
	--font: 'Sakkal Majalla Regular', 'Traditional Arabic', 'Geeza Pro', serif;
	--font-bold: 'Sakkal Majalla Bold', 'Traditional Arabic', 'Geeza Pro', serif;
	--ease: cubic-bezier(0.2, 0.7, 0.2, 1);
	--nav-height: 64px;
}


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

html {
	font-size: 14pt;
	scroll-padding-top: calc(var(--nav-height) + 16px);
}

body {
	margin: 0;
	overflow-x: hidden;
	background: var(--white);
	color: var(--text);
	font: 400 1rem/1.5rem var(--font);
	text-wrap: pretty;
}

h1, h2, h3, h4, h5, h6 {
	margin: 0;
	color: var(--ink);
	font-family: var(--font-bold);
	font-weight: 700;
}

p, ul, ol {
	margin: 0;
}

ul, ol {
	padding: 0;
	list-style: none;
}

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

a {
	color: var(--green);
	text-decoration: none;
}

a:hover {
	color: var(--green-dark);
	text-decoration: underline;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
	outline: 2px solid var(--green);
	outline-offset: 3px;
	border-radius: 4px;
}

.container {
	width: 100%;
	max-width: 1344px;
	margin: 0 auto;
	padding-inline: 16px;
}

.section {
	padding-block: 2.25rem;
}

.section-gray {
	background: var(--surface);
}

.section-head {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	margin-bottom: 1.25rem;
}

.section-title {
	font-size: 1.6rem;
	line-height: 2.05rem;
}

.ltr {
	direction: ltr;
	unicode-bidi: isolate;
}

.skip-link {
	position: absolute;
	top: -100px;
	inset-inline-start: 16px;
	z-index: 100;
	padding: 0.5rem 1rem;
	border-radius: var(--pill);
	background: var(--green);
	color: var(--white);
}

.skip-link:focus {
	top: 12px;
}

.icon {
	flex-shrink: 0;
	width: 20px;
	height: 20px;
}

[dir="ltr"] .icon-flip {
	transform: scaleX(-1);
}


/*****************/
/*    Buttons    */
/*****************/
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	min-height: 52px;
	padding: 0 2rem;
	border: 1px solid var(--green);
	border-radius: var(--pill);
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color 0.2s, color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.btn:hover {
	text-decoration: none;
}

.btn-solid {
	background: var(--green);
	color: var(--white);
}

.btn-solid:hover {
	background: transparent;
	color: var(--green);
}

.btn-outline {
	background: transparent;
	color: var(--green);
}

.btn-outline:hover {
	background: var(--green);
	color: var(--white);
}

.btn-light {
	border-color: var(--white);
	background: var(--white);
	color: var(--green);
}

.btn-light:hover {
	background: transparent;
	color: var(--white);
}

.btn-sm {
	min-height: 42px;
	padding: 0 1.5rem;
}

.link-strong {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.875rem;
	font-weight: 600;
}


/********************/
/*    Navigation    */
/********************/
.site-nav {
	position: sticky;
	top: 0;
	z-index: 50;
	background: var(--white);
	box-shadow: 0 2px 6px 0 rgba(0, 0, 0, 0.05);
}

.site-nav .container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 2rem;
	height: var(--nav-height);
}

.brand img {
	width: 124px;
	height: 34px;
	object-fit: contain;
}

.nav-links {
	display: none;
}

.nav-links a {
	color: var(--ink);
	font-size: 0.875rem;
	font-weight: 600;
	text-decoration: none;
	transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
	color: var(--green);
}

.nav-actions {
	display: flex;
	align-items: center;
	gap: 0.25rem;
}

.nav-lang {
	display: flex;
	align-items: center;
	min-height: 44px;
	padding: 0 0.6rem;
	color: var(--ink);
	font-size: 0.875rem;
	font-weight: 600;
}

.nav-submit {
	display: none;
}

.nav-toggle {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--ink);
	cursor: pointer;
}

.nav-toggle .icon {
	width: 24px;
	height: 24px;
}

.nav-toggle .icon-close,
.nav-open .nav-toggle .icon-menu {
	display: none;
}

.nav-open .nav-toggle .icon-close {
	display: block;
}

.nav-open .nav-links {
	position: absolute;
	top: var(--nav-height);
	inset-inline: 0;
	display: flex;
	flex-direction: column;
	padding: 0.5rem 16px 1rem;
	background: var(--white);
	box-shadow: 0 12px 24px rgba(25, 30, 71, 0.08);
	animation: nav-drop 0.25s var(--ease);
}

.nav-open .nav-links a {
	display: flex;
	align-items: center;
	min-height: 48px;
	border-bottom: 1px solid var(--line);
	font-size: 1rem;
}

.nav-open .nav-links a:last-child {
	border-bottom: 0;
}

@keyframes nav-drop {
	from {
		opacity: 0;
		transform: translateY(-8px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}


/*****************************/
/*    Hero & Latest Issue    */
/*****************************/
.hero {
	padding-block: 2.25rem 2.5rem;
}

.hero-grid {
	display: grid;
	gap: 2rem;
	align-items: center;
}

.hero-text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.9rem;
}

.eyebrow {
	color: var(--green);
	font-size: 0.8rem;
	font-weight: 600;
	line-height: 1.2rem;
}

.hero-title {
	font-size: 2.05rem;
	line-height: 2.6rem;
	letter-spacing: -0.4px;
}

.hero-lead {
	max-width: 640px;
	font-size: 1rem;
	line-height: 1.6rem;
}

.hero-actions {
	display: flex;
	flex-direction: column;
	gap: 0.65rem;
	align-self: stretch;
	margin-top: 0.4rem;
}

.hero-facts {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0.65rem 2.15rem;
	align-self: stretch;
	margin-top: 0.4rem;
	padding-top: 0.9rem;
	border-top: 1px solid var(--line);
	font-size: 0.8rem;
	line-height: 1.2rem;
}

.hero-facts div {
	display: flex;
	flex-direction: column;
}

.hero-facts dt {
	font-weight: 400;
}

.hero-facts dd {
	margin: 0;
	color: var(--ink);
	font-weight: 600;
}

.latest {
	display: flex;
	flex-direction: column;
	gap: 1.1rem;
	padding: 1.1rem;
	border-radius: var(--radius);
	background: var(--surface);
}

.latest-head {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
}

.latest-cover {
	flex-shrink: 0;
	border-radius: 4px;
}

.latest-cover img {
	width: 112px;
	height: 158px;
	object-fit: cover;
	border-radius: 4px;
	box-shadow: 0 12px 28px rgba(25, 30, 71, 0.16);
	transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.latest-cover:hover img {
	transform: translateY(-4px) rotate(-1deg);
	box-shadow: 0 18px 36px rgba(25, 30, 71, 0.2);
}

.latest-meta {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.3rem;
}

.badge {
	padding: 2px 12px;
	border-radius: var(--pill);
	background: var(--green);
	color: var(--white);
	font-size: 0.75rem;
	line-height: 1.2rem;
}

.latest-title {
	font-size: 1.6rem;
	line-height: 2.1rem;
}

.latest-sub {
	font-size: 0.875rem;
}

.latest-articles {
	display: flex;
	flex-direction: column;
	border-top: 1px solid var(--line);
}

.latest-articles-label {
	padding-top: 0.85rem;
	padding-bottom: 0.2rem;
	color: var(--ink);
	font-size: 0.75rem;
	font-weight: 600;
}

.article-link {
	display: flex;
	flex-direction: column;
	padding-block: 0.55rem;
	border-bottom: 1px solid var(--line);
	text-decoration: none;
	transition: padding 0.25s var(--ease);
}

.latest-articles li:last-child .article-link {
	border-bottom: 0;
}

.article-link:hover {
	padding-inline-start: 0.4rem;
	text-decoration: none;
}

.article-title {
	color: var(--ink);
	font-size: 0.94rem;
	line-height: 1.4rem;
	transition: color 0.2s;
}

.article-link:hover .article-title {
	color: var(--green);
}

.article-author {
	color: var(--text);
	font-size: 0.75rem;
	line-height: 1.1rem;
}


/*****************/
/*    Archive    */
/*****************/
.archive-head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 0.75rem 1.5rem;
	margin-bottom: 1.25rem;
}

.archive-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0.65rem;
}

.issue-card {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	height: 100%;
	padding: 0.65rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
	transition: box-shadow 0.25s var(--ease), transform 0.25s var(--ease);
}

.issue-card:hover {
	box-shadow: 0 10px 30px rgba(25, 30, 71, 0.1);
	transform: translateY(-3px);
}

.issue-card-cover img {
	width: 100%;
	aspect-ratio: 3 / 4.2;
	object-fit: cover;
	border-radius: 3px;
	box-shadow: 0 6px 16px rgba(25, 30, 71, 0.12);
}

.issue-card-body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.15rem;
}

.issue-card-title {
	font-size: 1.15rem;
	line-height: 1.5rem;
}

.issue-card-sub {
	font-size: 0.8rem;
}

.issue-card .link-strong {
	margin-top: 0.4rem;
	min-height: 32px;
}


/***************/
/*    Goals    */
/***************/
.goals-grid {
	display: grid;
	gap: 1.25rem;
}

.goal {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	padding-top: 0.9rem;
	border-top: 2px solid var(--green);
}

.goal-num {
	align-self: flex-start;
	color: var(--green);
	font-family: var(--font-bold);
	font-size: 1.5rem;
	line-height: 1.8rem;
}

.goal p {
	color: var(--ink);
	font-size: 1.05rem;
	line-height: 1.65rem;
}


/*****************/
/*    Domains    */
/*****************/
.domains-grid {
	display: grid;
	gap: 1rem;
}

.domain {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	padding: 1.1rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.domain-head {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 0.25rem 1rem;
}

.domain-title {
	font-size: 1.3rem;
	line-height: 1.7rem;
}

.domain-en {
	font-size: 0.8rem;
}

.chips {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}

.chip {
	padding: 0.25rem 0.9rem;
	border-radius: var(--pill);
	background: var(--green-tint);
	color: var(--green);
	font-size: 0.875rem;
	transition: background-color 0.2s, color 0.2s;
}

.chip:hover {
	background: var(--green);
	color: var(--white);
}


/**************************/
/*    Publishing Rules    */
/**************************/
.rules-grid {
	display: grid;
	gap: 1.5rem;
	align-items: start;
}

.rules-intro {
	display: flex;
	flex-direction: column;
	gap: 0.85rem;
}

.rules-intro p {
	font-size: 1.05rem;
	line-height: 1.65rem;
}

.contact-box {
	display: flex;
	flex-direction: column;
	gap: 0.2rem;
	margin-top: 0.4rem;
	padding: 0.9rem 1.2rem;
	border-radius: var(--radius);
	background: var(--surface);
	font-size: 0.875rem;
}

.contact-box a {
	align-self: flex-start;
	font-size: 1.1rem;
	font-weight: 600;
}

.rules-details {
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.rules-details summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	min-height: 56px;
	padding: 0 1rem;
	color: var(--ink);
	font-family: var(--font-bold);
	font-size: 1.2rem;
	cursor: pointer;
	list-style: none;
}

.rules-details summary::-webkit-details-marker {
	display: none;
}

.rules-details summary .icon {
	transition: transform 0.25s var(--ease);
}

.rules-details[open] summary .icon {
	transform: rotate(180deg);
}

.rules-list {
	padding: 0 1rem 0.5rem;
}

.rules-list li {
	display: flex;
	gap: 0.85rem;
	padding-block: 0.75rem;
	border-top: 1px solid var(--line);
	color: var(--ink);
}

.rules-list .icon {
	margin-top: 3px;
	color: var(--green);
}


/*************************/
/*    Editorial Board    */
/*************************/
.board-grid {
	display: grid;
	gap: 1rem;
}

.chief {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1.1rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.chief img {
	flex-shrink: 0;
	width: 84px;
	height: 84px;
	border-radius: 50%;
	object-fit: cover;
}

.chief-name {
	font-size: 1.3rem;
	line-height: 1.75rem;
}

.chief-role {
	color: var(--green);
	font-weight: 600;
}

.chief-title {
	font-size: 0.875rem;
}

.board-panel {
	display: grid;
	gap: 1.25rem 2.15rem;
	padding: 1.1rem 1.25rem;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: var(--white);
}

.board-group {
	display: flex;
	flex-direction: column;
	gap: 0.3rem;
}

.board-group + .board-group {
	margin-top: 1.25rem;
}

.board-label {
	margin-bottom: 0.15rem;
	color: var(--green);
	font-size: 0.875rem;
	line-height: 1.3rem;
}

.board-group li,
.board-group p {
	color: var(--ink);
}


/********************/
/*    Invitation    */
/********************/
.invite {
	padding-block: 2rem;
	background: var(--green);
}

.invite .container {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.invite-text {
	display: flex;
	flex-direction: column;
	gap: 0.4rem;
	max-width: 820px;
}

.invite h2 {
	color: var(--white);
	font-size: 1.45rem;
	line-height: 1.9rem;
}

.invite p {
	color: rgba(255, 255, 255, 0.82);
}


/****************/
/*    Footer    */
/****************/
.site-footer {
	padding-block: 2.25rem 1rem;
	background: var(--surface);
	font-size: 0.875rem;
}

.footer-grid {
	display: grid;
	gap: 1.75rem;
}

.footer-col {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.footer-logo {
	width: 160px;
	height: 44px;
	object-fit: contain;
	object-position: right;
}

[dir="ltr"] .footer-logo {
	object-position: left;
}

.footer-col h2 {
	color: var(--ink);
	font-size: 1rem;
	line-height: 1.4rem;
}

.footer-col ul a {
	display: inline-flex;
	align-items: center;
	min-height: 36px;
	color: var(--text);
}

.footer-email {
	align-self: flex-start;
	font-weight: 600;
}

.social {
	display: flex;
	gap: 0.55rem;
}

.social a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: var(--green);
	color: var(--white);
	transition: transform 0.2s var(--ease), background-color 0.2s;
}

.social a:hover {
	background: var(--green-dark);
	transform: translateY(-3px);
}

.social svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
}

.copyright {
	margin-top: 1.75rem;
	padding-top: 1rem;
	border-top: 1px solid var(--line);
	font-size: 0.75rem;
	text-align: center;
}

.copyright a {
	color: inherit;
}


/********************/
/*    Animations    */
/********************/
@media (prefers-reduced-motion: no-preference) {
	html {
		scroll-behavior: smooth;
	}

	.hero-text > *,
	.latest {
		animation: rise 0.8s var(--ease) both;
	}

	.hero-text > :nth-child(2) { animation-delay: 0.06s; }
	.hero-text > :nth-child(3) { animation-delay: 0.12s; }
	.hero-text > :nth-child(4) { animation-delay: 0.18s; }
	.hero-text > :nth-child(5) { animation-delay: 0.24s; }
	.latest { animation-delay: 0.2s; }

	.reveal {
		opacity: 0;
		transform: translateY(24px);
		transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
		transition-delay: var(--reveal-delay, 0s);
	}

	.reveal.is-visible {
		opacity: 1;
		transform: none;
	}

	.btn:hover,
	.social a:hover {
		box-shadow: 0 6px 16px rgba(2, 78, 39, 0.18);
	}

	.btn:hover {
		transform: translateY(-2px);
	}
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition-duration: 0.01ms !important;
		animation-duration: 0.01ms !important;
	}
}

@keyframes rise {
	from {
		opacity: 0;
		transform: translateY(18px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}


/***********************/
/*    Media Queries    */
/***********************/
@media (min-width: 600px) {
	.hero-actions {
		flex-direction: row;
		align-self: flex-start;
	}

	.hero-facts {
		display: flex;
		gap: 2.15rem;
		align-self: flex-start;
	}

	.goals-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.board-panel {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.latest-cover img {
		width: 150px;
		height: 212px;
	}
}

@media (min-width: 768px) {
	.container {
		padding-inline: 24px;
	}

	.section {
		padding-block: 4.25rem;
	}

	.section-head {
		margin-bottom: 2.15rem;
	}

	.section-title {
		font-size: 2rem;
		line-height: 2.5rem;
	}

	.archive-head {
		margin-bottom: 2.15rem;
	}

	.domains-grid,
	.footer-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.domain {
		padding: 1.9rem;
	}

	.invite {
		padding-block: 3.4rem;
	}

	.invite .container {
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		gap: 2.5rem;
	}

	.invite h2 {
		font-size: 1.75rem;
		line-height: 2.25rem;
	}

	.invite .btn {
		flex-shrink: 0;
		min-height: 60px;
		padding: 0 2.6rem;
	}

	.issue-card {
		flex-direction: row;
		align-items: flex-start;
		gap: 1.05rem;
		padding: 1.3rem;
	}

	.issue-card-cover {
		flex-shrink: 0;
	}

	.issue-card-cover img {
		width: 96px;
		height: 136px;
	}

	.issue-card-title {
		font-size: 1.5rem;
		line-height: 2rem;
	}
}

@media (min-width: 992px) {
	:root {
		--nav-height: 76px;
	}

	.nav-links {
		display: flex;
		align-items: center;
		gap: 1.9rem;
		margin-inline-start: auto;
	}

	.nav-toggle,
	.nav-lang {
		display: none;
	}

	.nav-submit {
		display: inline-flex;
	}

	.hero {
		padding-block: 4.7rem 5.15rem;
	}

	.hero-grid {
		grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
		gap: 3.85rem;
	}

	.hero-text {
		gap: 1.3rem;
	}

	.eyebrow {
		font-size: 0.875rem;
	}

	.hero-title {
		font-size: 3.2rem;
		line-height: 3.85rem;
	}

	.hero-lead {
		font-size: 1.125rem;
		line-height: 1.8rem;
	}

	.hero-actions .btn {
		min-height: 60px;
		padding: 0 2.6rem;
	}

	.hero-facts {
		font-size: 0.875rem;
	}

	.latest {
		padding: 1.7rem;
		gap: 1.3rem;
	}

	.latest-head {
		gap: 1.3rem;
	}

	.domains-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.archive-grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 1.3rem;
	}

	.goals-grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 1.7rem;
	}

	.rules-grid {
		grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
		gap: 3.85rem;
	}

	.rules-details {
		border: 0;
		background: transparent;
	}

	.rules-details summary {
		min-height: 0;
		padding: 0 0 0.65rem;
		font-size: 1.5rem;
		cursor: default;
		pointer-events: none;
	}

	.rules-details summary .icon {
		display: none;
	}

	.rules-list {
		padding: 0;
	}

	.rules-list li:last-child {
		border-bottom: 1px solid var(--line);
	}

	.board-grid {
		grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
		gap: 1.3rem;
	}

	.chief {
		flex-direction: column;
		justify-content: center;
		padding: 1.7rem;
		text-align: center;
	}

	.chief img {
		width: 128px;
		height: 128px;
	}

	.chief-name {
		font-size: 1.5rem;
		line-height: 2rem;
	}

	.board-panel {
		padding: 1.7rem 1.9rem;
	}

	.footer-grid {
		grid-template-columns: minmax(0, 5fr) minmax(0, 3fr) minmax(0, 4fr);
		gap: 2.5rem;
	}

	.site-footer {
		padding-block: 3.4rem 1.3rem;
	}
}
