:root {
	/* Default color vars */
	--orange: #FE7F30;
	--pale-orange: #FDCDAE;
	--dark-orange: #44240f;
	--black: #000000;
	--white: #FFFFFF;
	
	--header-bg: var(--black);
	--header-social: var(--orange);
	--hamburger: var(--white);
	--content-bg: var(--pale-orange);
	--content-txt: var(--black);
	--content-links: var(--orange);
	--menu-bg: var(--orange);
	--menu-txt: var(--white);
	--menu-txt-mob: var(--orange);
	--footer-bg: var(--black);
	--footer-txt: var(--white);
	--tbl-outline: var(--orange);
	--tbl-header-bg: var(--orange);
	--tbl-header-txt: var(--white);
	--tbl-content-bg: var(--white);
	--tbl-content-txt: var(--black);
	--tbl-content-link: var(--orange);
}


[data-theme="A"] {
  --header-bg: var(--orange);
  --header-social: var(--orange);
  --hamburger: var(--black);
  --content-bg: var(--pale-orange);
  --content-txt: var(--black);
  --content-links: var(--dark-orange);
  --menu-bg: var(--orange);
  --menu-txt: var(--black);
  	--menu-txt-mob: var(--white);
  --footer-bg: var(--black);
  --footer-txt: var(--white);
	--tbl-outline: var(--orange);
	--tbl-header-bg: var(--orange);
	--tbl-header-txt: var(--white);
	--tbl-content-bg: var(--white);
	--tbl-content-txt: var(--black);
	--tbl-content-link: var(--orange);
}

[data-theme="B"] {
  --header-bg: var(--black);
  --header-social: var(--orange);
  --hamburger: var(--white);
  --content-bg: var(--black);
  --content-txt: var(--white);
  --content-links: var(--pale-orange);
  --menu-bg: var(--dark-orange);
  --menu-txt: var(--white);
  	--menu-txt-mob: var(--white);
  --footer-bg: var(--dark-orange);
  --footer-txt: var(--white);
	--tbl-outline: var(--dark-orange);
	--tbl-header-bg: var(--dark-orange);
	--tbl-header-txt: var(--pale-orange);
	--tbl-content-bg: var(--black);
	--tbl-content-txt: var(--white);
	--tbl-content-link: var(--orange);
}

/* Smooth transitions when swapping themes */
header, .top-banner, nav, footer, .content, .overlay {
  transition: background-color 260ms ease, color 260ms ease, border-color 260ms ease;
}


html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    background: var(--content-bg);
    color: var(--content-txt);
    font-family: 'Open Sans', sans-serif;
    min-height: 100vh;
    line-height: 1.6;
}

h1,
h2,
h3 {
	font-family: 'Montserrat', sans-serif;
}
h2 { margin-bottom: 2px;}
ul {margin-top: 8px;} 	

a {
	color: var(--content-links);
	text-decoration: none;
	font-weight: bold;
	background-color: #fe7f301e;
}

a:hover {
	text-decoration: underline;
}



header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--header-bg);
    color: white;
    transform: translateZ(0);
    backface-visibility: hidden;
	box-shadow: #300 0px -5px 20px 5px
}

.top-banner {
	display: none;
	justify-content: end; 
	align-items: center;
	padding: 10px 60px;
	box-sizing: border-box;
	background: var(--header-bg);
	min-height: 40px;
	flex-wrap: wrap;
	position: relative;
}

main.main-content {
    padding-top: 100px;
    min-height: calc(100vh - 120px);
}

.parallax-section {
    height: 100vh;
	width: 100vw;	/* Forces full viewport width */
    background-attachment: fixed;
    background-position: center;
    background-size: contain; /* cover, contain, 135vw auto */
    background-repeat: no-repeat;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
	overflow: hidden;
}


.logo {
	text-align: center;
	padding: 15px 0;
}

.logo img {
	height: 120px;
	width: auto;
}

.social-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: flex-end;
	gap: 10px;
}

.social-links a {
	margin: 0 15px;
	color: var(--orange);
}

nav {
	background: var(--menu-bg);
}

.menu {
	display: flex;
	justify-content: center;
	list-style: none;
	margin: 0;
	padding: 0;
	flex-wrap: wrap;
}

.menu li {
	margin: 0 15px;
}

.menu a {
	color: var(--menu-txt);
	font-weight: bold;
	padding: 15px 0;
	display: block;
	text-decoration: none;
}

.menu a.active {
	background: rgba(0, 0, 0, 0.2);
}

.mobile-menu-btn {
	position: absolute;
	right: 5px;
	top: 5%;
	display: none;
	background: none;
	border: none;
	cursor: pointer;
	width: 44px;
	height: 44px;
	padding: 0;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	z-index: 1001;
}

.mobile-menu-btn span {
	display: block;
	width: 30px;
	height: 3px;
	background: var(--hamburger);
	margin: 5px 0;
	transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
	border-radius: 2px;
	transform-origin: center;
}

.mobile-menu-btn.active span:nth-child(1) {
	transform: translateY(13px) rotate(45deg);
}

.mobile-menu-btn.active span:nth-child(2) {
	opacity: 0;
	transform: scale(0.2);
}

.mobile-menu-btn.active span:nth-child(3) {
	transform: translateY(-13px) rotate(-45deg);
}

/* Pipette theme picker */
.theme-picker {
	position: absolute;
	right: 5px;
	top: 70px;
	display: inline-block;
	z-index: 1100;
}

.theme-picker-btn {
	background: none;
	border: none;
	color: var(--hamburger);
	cursor: pointer;
	width: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 6px;
}

.theme-picker-btn:focus {
	outline: 2px solid rgba(0,0,0,0.12);
}

.theme-picker-label {
	display: none;
	color: var(--hamburger);
	font-size: 0.9rem;
	cursor: pointer;
	user-select: none;
}

@media (min-width: 769px) {
	.theme-picker {
		position: absolute;
		top: 10px;
		right: 10px;
		display: flex;
		flex-direction: column;
		align-items: center;
		gap: 3px;
	}

	.theme-picker-label {
		display: block;
		text-align: center;
		white-space: nowrap;
		font-size: 0.75rem;
	}
}

.theme-picker-menu {
	display: none;
	position: absolute;
	right: 0;
	top: calc(100% + 12px);
	background: var(--menu-bg);
	border-radius: 8px;
	border: 1px solid black;
	box-shadow: 0 6px 18px rgba(0,0,0,0.12);
	z-index: 1200;
	min-width: 140px;
	flex-direction: column;
}

.theme-picker-menu.open {
	display: flex;
}

.theme-menu-heading {
	background: rgba(0,0,0,0.08);
	color: var(--menu-txt);
	padding: 8px 14px;
	font-weight: bold;
	font-size: 0.85rem;
	border-radius: 8px 8px 0 0;
	border-bottom: 1px solid rgba(0,0,0,0.1);
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.theme-option {
	background: transparent;
	border: none;
	color: var(--menu-txt);
	padding: 10px 14px;
	text-align: left;
	cursor: pointer;
	font-size: 0.95rem;
	transition: background-color 0.2s ease;
}

.theme-option:hover,
.theme-option:focus {
	background-color: rgba(0,0,0,0.1);
	outline: none;
}

.theme-option:last-child {
  border-radius: 0 0 8px 8px;
}


.transition-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: var(--content-bg);
	opacity: 0;
	transition: opacity 380ms ease-in-out;
	z-index: 999;
	pointer-events: none;
	will-change: opacity;
}

.transition-overlay.active {
	opacity: 1;
}




.overlay {
    text-align: center;
    color: white;
    background: rgba(0,0,0,0.55);
    padding: 3rem 2rem;
    border-radius: 12px;
    max-width: 90%;
    opacity: 0;
    transform: translateY(60px);
    transition: all 1.1s ease-out;
}

.overlay.visible {
    opacity: 1;
    transform: translateY(0);
}


.overlay h1 {
	font-size: 4rem;
	margin: 0;
}

.overlay p {
	font-size: 1.5rem;
}


.main-content {
	min-height: calc(100vh - 200px); /* Adjust for header/footer */
	opacity: 1;
	transition: opacity 400ms ease-in-out;
}


.view {
	display: none;
}

.view.active {
	display: block;
}


/* Content (All pages) */
.content {
	max-width: 1000px;
	margin: 30px auto 40px;
	padding: 20px;
	line-height: 1.6;
}

.team-table {
	width: 100%;
	border-collapse: collapse;
	margin: 30px 0;
}
.team-table th,
.team-table td {
	border: 1px solid var(--tbl-outline);
	padding: 12px;
	text-align: left;
	word-wrap: break-word;
}
.team-table th {
	background-color: var(--tbl-header-bg);
	color: var(--tbl-header-txt);
}

.logos {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 24px;
	margin: 24px 0;
	align-items: center;
	padding: 10px 0;
	background-color: #FFFFFF;
}

.logos > .partner-logo {
		flex: 0 0 calc((100% - 48px) / 3);
		display: block;
		width: 100%;
		height: auto;
		max-width: 100%;
		max-height: 70px;
		object-fit: contain;
		margin: 0 auto;
}

.logos > .supported-logo {
		flex: 0 0 calc((100% - 48px) / 3);
		display: block;
		width: 100%;
		height: auto;
		max-width: 100%;
		max-height: 40px; 
		object-fit: contain;
		margin: 0 auto;
}

@media (max-width: 768px) {
	.logos > .partner-logo {
		flex: 0 0 calc((100% - 24px) / 2);
		width: 100%;
		height: auto;
		max-height: 65px;
	}
	.logos > .supported-logo {
		flex: 0 0 calc((100% - 24px) / 2);
		width: 100%;
		height: auto;
		max-height: 35px;
	}
}

footer {
	position: fixed;
	bottom: 0;
	left:0;
	z-index: 1001;
	width: 100%;
    background: var(--footer-bg);
    color: var(--footer-txt);
    text-align: center;
    padding: 0.5rem;
    margin-top: 3rem;
}

.back-to-top {
	position: fixed;
	bottom: 65px;
	right: 10px;
	background: var(--orange);
	color: var(--white);
	width: 45px;
	height: 45px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.8rem;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
	cursor: pointer;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
	z-index: 2000 !important;
}

.back-to-top.visible {
	opacity: 0.7;
	visibility: visible;
}

.page-nav {
	position: fixed;
	display: none;
	pointer-events: none;
	z-index: 2000;
}

.page-nav.visible {
	display: flex;
}

.page-nav-prev {
	position: fixed;
	bottom: 6px;
	left: 10px;
}

.page-nav-next {
	position: fixed;
	bottom: 6px;
	right: 10px;
}

.page-nav button {
	background: var(--orange);
	color: var(--white);
	width: 45px;
	height: 45px;
	border-radius: 50%;
	border: none;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.8rem;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
	cursor: pointer;
	pointer-events: auto;
	opacity: 0.8;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

.page-nav.visible button.visible {
	opacity: 0.8;
	visibility: visible;
}


#home {
	width: 100%;
	overflow-x: hidden;
}

main ul > li { /* more spacing between list items site-wide */
    margin-top: 0.7em;
}

#achievements ul > li {
    margin-top: 1em; /* bigger spacing between items */
}
#achievements ul ul > li {
    margin-top: 0.25em;   /* reduce spacing for sub‑items */
}

.img-full-width {
	width: 100%;
	height: auto;
	margin: 20px 0;
	border-radius: 8px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

#upcoming h3 {
	margin-top: 40px;
}

.intlink.bttn {
	background-color: var(--orange);
	color: var(--white);
	padding: 4px 10px;
	border-radius: 4px;
	font-weight: bold;
	margin-left: 8px;
}


@media (max-width: 768px) {
	.theme-control { display: none; }
	.theme-picker-btn { display: flex; }
	.theme-picker-dropdown { right: 8px; left: auto; top: calc(100% + 6px); }
	.theme-option {	color: var(--menu-txt-mob);}

	.top-banner {
		justify-content: space-evenly;
		padding: 10px 50px 10px 10px;
	}

	.social-links a {
		margin: 0 6px;
		/* tighter spacing on mobile to prevent wrap pushing */
		font-size: 1.2rem;
		/* optional: slightly smaller icons */
	}

	.mobile-menu-btn {
		display: flex;
	}

	.menu {
		position: absolute;
		top: 100%;
		left: 0;
		width: 100%;
		background: var(--menu-bg);
		flex-direction: column;
		max-height: 0;
		overflow: hidden;
		transition: max-height 0.25s ease-out, opacity 0.25s ease-out;
		opacity: 0;
	}
	.menu.active {
		max-height: 500px;	/* large enough for all items */
		opacity: 1;
	}
	.menu li {
		margin: 0;
		width: 100%;
	}
	.menu a {
		padding: 12px;
		text-align: center;
		border-bottom: 1px solid rgba(255, 255, 255, 0.2);
		color: var(--menu-txt-mob);
	}

	.logo img {
		height: 10vh;
	}

	.parallax-section {
		background-size: cover; /* cover, contain, 135vw auto */
	}


	.overlay {
		margin-bottom: 15vh;
	    padding: 1rem 1rem;

	}
	.overlay h1 {
		font-size: 2.5rem;
	}
	.overlay p {
		font-size: 1.2rem;
	}

	main.main-content {
		padding-top: 80px; 	  /* slightly less top padding on mobile */
	}

	.team-table,
	.team-table thead,
	.team-table tbody,
	.team-table th,
	.team-table td,
	.team-table tr {
		display: block;
	}
	/* Hide desktop header row (accessibility-friendly) */
	.team-table thead tr {
		position: absolute;
		top: -9999px;
		left: -9999px;
	}
	/* Each row becomes a card */
	.team-table tr {
		border: 2px solid var(--tbl-outline);
		border-radius: 8px;
		margin-bottom: 25px;
		padding: 15px;
		background-color: var(--tbl-content-bg);
		box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
	}
	.team-table td {
		border: none;
		padding: 1px 0;
		position: relative;
		padding-left: 4%;
		/* Space for label */
		text-align: right;
		color: var(--tbl-content-txt);
	}
	.team-table td:nth-child(1):before {
		content: "Role: ";
	}
	.team-table td:nth-child(2):before {
		content: "Name: ";
	}
	.team-table td:nth-child(3):before {
		content: "Email: ";
	}
	.team-table td:before { 
		position: absolute;
		left: 0;
		width: 35%;
		padding-right: 10px;
		font-weight: bold;
		text-align: left;
		color: var(--tbl-content-txt);
	}

	.page-nav {
		display: none;
		/* JS will toggle .visible to flex */
	}
	.page-nav.visible {
		display: block;
		/* Allows individual positioning */
	}

}

/* Desktop: ensure prev/next stay hidden */
@media (min-width: 769px) {
	.menu a {
		padding: 6px 4px;
	    margin-top: 4px;
    	margin-bottom: 6px;
	}
	
	.menu a.active {
		background: rgba(0, 0, 0, 0.2);
		box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 5px 3px;
		color: rgba(255, 255, 255, 0.7);
		border-radius: 6px;
	}
	.menu a:hover {
		background: rgba(0, 0, 0, 0.1);
		box-shadow: rgba(0, 0, 0, 0.2) 0px 0px 5px 3px;
		border-radius: 6px;
	}	

	/* Desktop header row: logo left, menu right */
	.header-row {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: 4px 60px;
		gap: 20px;
	}

	.header-row .logo {
		text-align: left;
		padding: 8px 0;
	}

	.header-row nav {
		flex: 1 1 auto;
		display: flex;
		justify-content: flex-end;
		align-items: center;
		background: transparent; /* let menu items sit beside logo */
	}

	.header-row nav .menu {
		justify-content: flex-end;
	}

	/* Responsive logo sizing */
	.logo img {
		height: clamp(56px, 9vw, 120px); /* clamps between 56px and 120px based on viewport width */
		width: auto;
	}

}

/* iOS Safari has bug preventing background-attachment:fixed from working properly. Use scroll instead. */
@supports (-webkit-touch-callout: none) and (font: -apple-system-body) {
  .parallax-section {
    background-attachment: scroll !important;
  }
}