/* ==========================================================================
   Atmosphere360 — shared chrome
   Sticky header + mega menu, footer, intro loader, workshop notice, enquiry
   modal and the mock assistant. Mirrors the Svelte components of the same name.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Wordmark
   -------------------------------------------------------------------------- */
.wordmark {
	display: inline-flex;
	align-items: center;
	gap: 0.7rem;
	font-size: 1.05rem;
	font-weight: 600;
	letter-spacing: -0.035em;
	white-space: nowrap;
}

.wordmark .mark {
	display: block;
	width: 1.85rem;
	height: 1.85rem;
}

.wordmark .mark img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.wordmark .name {
	background: linear-gradient(105deg, #1f7cba, #0f5f92 52%, #59b2ea);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.wordmark.inverted .name {
	background: linear-gradient(105deg, #8ecbf0, #2a8ace 52%, #59b2ea);
	-webkit-background-clip: text;
	background-clip: text;
}

/* --------------------------------------------------------------------------
   Header + mega menu
   -------------------------------------------------------------------------- */
.header {
	position: sticky;
	top: 0;
	z-index: 40;
	padding: 0.75rem 0;
	color: var(--ink);
}

.header.inverted {
	color: white;
}

.header .bar {
	position: relative;
	/* Above the full-screen mobile nav so the logo and close button stay
	   reachable — `backdrop-filter` makes this bar its own stacking context. */
	z-index: 42;
	display: flex;
	min-height: 4.2rem;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 0.4rem 0.45rem 0.4rem 1.15rem;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: rgba(255, 253, 249, 0.82);
	box-shadow: 0 14px 40px rgba(6, 43, 68, 0.09);
	backdrop-filter: blur(18px);
	-webkit-backdrop-filter: blur(18px);
	transition:
		background-color 200ms ease,
		border-color 200ms ease,
		box-shadow 200ms ease;
}

.header.inverted .bar {
	border-color: rgba(255, 255, 255, 0.16);
	background: rgba(6, 43, 68, 0.55);
	box-shadow: 0 14px 40px rgba(0, 0, 0, 0.28);
}

.header .logo {
	position: relative;
	z-index: 42;
}

.desktop-nav {
	display: flex;
	align-items: center;
	gap: 0.15rem;
}

.nav-group > a {
	display: block;
	padding: 0.65rem 0.9rem;
	border-radius: 999px;
	font-size: 0.83rem;
	transition: background-color 160ms ease;
}

.nav-group:hover > a,
.nav-group:focus-within > a {
	background: rgba(31, 124, 186, 0.08);
}

.header.inverted .nav-group:hover > a,
.header.inverted .nav-group:focus-within > a {
	background: rgba(255, 255, 255, 0.1);
}

.dropdown {
	position: absolute;
	top: calc(100% + 0.7rem);
	right: 0;
	left: 0;
	display: grid;
	grid-template-columns: 1fr 2fr;
	gap: 0.5rem;
	min-height: 21rem;
	padding: 0.6rem;
	border: 1px solid var(--line);
	border-radius: 1.6rem;
	opacity: 0;
	background: var(--surface);
	color: var(--ink);
	box-shadow: 0 30px 80px rgba(6, 43, 68, 0.18);
	pointer-events: none;
	transform: translateY(0.4rem);
	transition:
		opacity 160ms ease,
		transform 160ms ease;
}

.dropdown::before {
	position: absolute;
	right: 0;
	bottom: 100%;
	left: 0;
	height: 1rem;
	content: '';
}

.dropdown.open {
	opacity: 1;
	pointer-events: auto;
	transform: translateY(0);
}

.dropdown-list {
	display: grid;
	align-content: start;
	gap: 0.25rem;
	padding: 0.4rem;
	border-radius: 1.2rem;
	background: rgba(31, 124, 186, 0.05);
}

.dropdown-list a {
	display: grid;
	gap: 0.2rem;
	padding: 0.85rem 1rem;
	border-radius: 1rem;
	transition:
		background-color 160ms ease,
		box-shadow 160ms ease;
}

.dropdown-list a:hover,
.dropdown-list a:focus-visible,
.dropdown-list a.active {
	background: white;
	box-shadow: 0 10px 26px rgba(6, 43, 68, 0.08);
}

.dropdown-list span,
.dropdown-list small {
	display: block;
}

.dropdown-list span {
	font-size: 0.95rem;
	font-weight: 600;
}

.dropdown-list small {
	margin-top: 0.18rem;
	color: var(--muted);
	font-size: 0.78rem;
}

.dropdown-detail {
	display: none;
	align-content: start;
	gap: 1rem;
	padding: clamp(1.2rem, 2vw, 1.9rem);
}

.dropdown-detail.active {
	display: grid;
}

.dropdown-detail .eyebrow {
	font-size: 0.68rem;
}

.dropdown-detail h3 {
	margin: 0;
	font-size: clamp(2rem, 3vw, 2.7rem);
	line-height: 0.95;
}

.dropdown-text {
	max-width: 34rem;
	margin: 0;
	color: var(--muted);
	font-size: 0.95rem;
	line-height: 1.65;
}

.dropdown-detail ul {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.55rem 1.2rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.dropdown-detail li {
	position: relative;
	padding-left: 1.35rem;
	font-size: 0.88rem;
}

.dropdown-detail li::before {
	position: absolute;
	top: 0.42rem;
	left: 0;
	width: 0.42rem;
	height: 0.42rem;
	border-radius: 999px;
	content: '';
	background: linear-gradient(135deg, var(--violet), var(--orange));
}

.dropdown-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.7rem;
	margin-top: 0.4rem;
}

.dropdown-actions .button {
	min-height: 2.9rem;
	font-size: 0.85rem;
}

.sign-in {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.65rem 0.2rem;
	border: 0;
	background: transparent;
	color: var(--violet);
	font-size: 0.85rem;
	font-weight: 600;
	cursor: pointer;
}

.sign-in:hover {
	color: var(--magenta);
}

@media (max-width: 1150px) {
	.dropdown {
		grid-template-columns: 1fr 1.6fr;
	}

	.dropdown-detail ul {
		grid-template-columns: 1fr;
	}
}

.header .talk {
	min-height: 2.6rem;
	padding-inline: 1rem;
	font-size: 0.8rem;
}

.menu-toggle {
	position: relative;
	z-index: 42;
	display: none;
	width: 2.75rem;
	height: 2.75rem;
	border: 1px solid var(--line);
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.75);
	color: var(--ink);
	cursor: pointer;
}

.menu-toggle span {
	position: absolute;
	left: 0.78rem;
	width: 1.1rem;
	height: 1px;
	background: currentColor;
	transition: transform 180ms ease;
}

.menu-toggle span:first-child {
	top: 1.1rem;
}

.menu-toggle span:last-child {
	top: 1.55rem;
}

.menu-toggle.active span:first-child {
	top: 1.33rem;
	transform: rotate(45deg);
}

.menu-toggle.active span:last-child {
	top: 1.33rem;
	transform: rotate(-45deg);
}

.mobile-nav {
	position: fixed;
	inset: 0;
	z-index: 41;
	overflow-y: auto;
	padding: 6rem 0 2rem;
	background: var(--surface);
	color: var(--ink);
}

.mobile-nav .shell {
	display: grid;
	gap: 1.5rem;
}

.mobile-group {
	display: grid;
	grid-template-columns: 7rem 1fr;
	gap: 0.4rem 1rem;
	padding-bottom: 1.25rem;
	border-bottom: 1px solid var(--line);
}

.mobile-group p {
	margin: 0;
	color: var(--muted);
	font-size: 0.72rem;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.mobile-group a {
	grid-column: 2;
	padding: 0.2rem 0;
}

.mobile-group span,
.mobile-group small {
	display: block;
}

.mobile-group span {
	font-weight: 600;
}

.mobile-group small {
	margin-top: 0.15rem;
	color: var(--muted);
	font-size: 0.78rem;
}

@media (max-width: 950px) {
	.desktop-nav,
	.header .talk {
		display: none;
	}

	.menu-toggle {
		display: block;
	}

	.header.inverted .menu-toggle {
		border-color: rgba(255, 255, 255, 0.2);
		background: rgba(255, 255, 255, 0.08);
		color: white;
	}
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.site-footer {
	padding: 5rem 0 2rem;
}

.site-footer .footer-grid {
	display: grid;
	grid-template-columns: 1.2fr 0.8fr 0.8fr;
	gap: 3rem;
	padding-bottom: 4rem;
}

.site-footer .brand p {
	margin: 1.7rem 0 0;
	font-size: clamp(2rem, 4vw, 3.4rem);
	line-height: 0.98;
}

.site-footer .brand em {
	color: var(--violet);
}

.site-footer nav {
	display: grid;
	align-content: start;
	gap: 0.85rem;
	font-size: 0.9rem;
}

.site-footer nav a,
.site-footer nav button {
	width: fit-content;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--muted);
	font-size: inherit;
	cursor: pointer;
}

.site-footer nav a:hover,
.site-footer nav button:hover {
	color: var(--ink);
}

.site-footer .location {
	display: grid;
	align-content: start;
	justify-items: end;
	gap: 0.7rem;
	color: var(--muted);
	font-size: 0.85rem;
	text-align: right;
}

.site-footer .legal {
	display: flex;
	justify-content: space-between;
	padding-top: 1.5rem;
	border-top: 1px solid var(--line);
	color: var(--muted);
	font-size: 0.72rem;
}

@media (max-width: 750px) {
	.site-footer .footer-grid {
		grid-template-columns: 1fr 1fr;
	}

	.site-footer .brand {
		grid-column: 1 / -1;
	}

	.site-footer .location {
		justify-items: start;
		text-align: left;
	}
}

/* --------------------------------------------------------------------------
   Intro loader
   -------------------------------------------------------------------------- */
.loader {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: grid;
	place-items: center;
	background: var(--paper);
	animation: loader-out 500ms ease 2500ms forwards;
}

.loader-inner {
	display: flex;
	align-items: center;
	gap: 0.85rem;
}

.loader-mark {
	display: block;
	width: 2.6rem;
	height: 2.6rem;
	animation:
		mark-in 900ms cubic-bezier(0.2, 0.8, 0.2, 1) both,
		mark-pulse 1200ms ease-in-out 1500ms both;
}

.loader-mark img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	filter: drop-shadow(0 14px 36px rgba(31, 124, 186, 0.34));
}

.loader-name {
	font-size: 1.55rem;
	font-weight: 600;
	letter-spacing: -0.035em;
	background: linear-gradient(105deg, #1f7cba, #0f5f92 52%, #59b2ea);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	animation: name-in 700ms cubic-bezier(0.2, 0.8, 0.2, 1) 350ms both;
}

@keyframes mark-in {
	from {
		opacity: 0;
		transform: scale(0.3);
	}

	to {
		opacity: 1;
		transform: scale(1);
	}
}

@keyframes mark-pulse {
	0%,
	100% {
		transform: scale(1);
	}

	50% {
		transform: scale(1.12);
	}
}

@keyframes name-in {
	from {
		opacity: 0;
		transform: translateY(14px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes loader-out {
	to {
		opacity: 0;
		visibility: hidden;
	}
}

/* --------------------------------------------------------------------------
   Workshop notice
   -------------------------------------------------------------------------- */
.notice {
	position: fixed;
	top: 5.25rem;
	left: 50%;
	z-index: 10000;
	display: flex;
	align-items: center;
	gap: 1.1rem;
	width: min(100% - 2rem, 46rem);
	min-height: 7.75rem;
	padding: 1.4rem 1.4rem 1.4rem 1.6rem;
	border: 1px solid var(--line);
	border-radius: 1.6rem;
	background: var(--surface);
	box-shadow: 0 20px 50px rgba(6, 43, 68, 0.2);
	opacity: 0;
	pointer-events: none;
	transform: translate(-50%, calc(-100% - 6rem));
	transition:
		transform 360ms cubic-bezier(0.2, 0.85, 0.25, 1),
		opacity 260ms ease;
}

.notice.show {
	opacity: 1;
	pointer-events: auto;
	transform: translate(-50%, 0);
}

.notice-body {
	display: grid;
	flex: 1;
	gap: 0.3rem;
}

.notice-eyebrow {
	margin: 0;
	color: var(--violet);
	font-size: 0.7rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.notice-title {
	margin: 0;
	color: var(--ink);
	font-size: 1.08rem;
	font-weight: 600;
	line-height: 1.3;
}

.notice-sub {
	margin: 0;
	color: var(--muted);
	font-size: 0.9rem;
	line-height: 1.4;
}

.notice-actions {
	display: flex;
	flex: none;
	align-items: center;
	gap: 0.6rem;
}

.notice-dot {
	width: 0.6rem;
	height: 0.6rem;
	flex: none;
	border-radius: 50%;
	background: var(--orange);
	box-shadow: 0 0 0 0 rgba(89, 178, 234, 0.6);
	animation: notice-pulse 1.6s ease-out infinite;
}

@keyframes notice-pulse {
	to {
		box-shadow: 0 0 0 0.7rem rgba(89, 178, 234, 0);
	}
}

.notice-cta {
	flex: none;
	padding: 0.6rem 1rem;
	border: 0;
	border-radius: 999px;
	background: var(--night);
	color: white;
	font-size: 0.82rem;
	font-weight: 600;
	cursor: pointer;
}

.notice-close {
	display: grid;
	width: 2.2rem;
	height: 2.2rem;
	flex: none;
	place-items: center;
	border: 1px solid var(--line);
	border-radius: 50%;
	background: var(--paper);
	color: var(--muted);
	font-size: 1.15rem;
	line-height: 1;
	cursor: pointer;
}

@media (max-width: 620px) {
	.notice {
		min-height: 0;
		flex-wrap: wrap;
		align-items: flex-start;
		gap: 0.8rem;
		padding: 1.1rem;
		border-radius: 1.4rem;
	}

	.notice-actions {
		width: 100%;
		justify-content: flex-end;
	}

	.notice-title {
		font-size: 1rem;
	}

	.notice-sub {
		font-size: 0.84rem;
	}
}

/* --------------------------------------------------------------------------
   Enquiry modal
   -------------------------------------------------------------------------- */
.enquiry-dialog {
	width: min(100% - 1.2rem, 49rem);
	margin: auto;
	max-height: calc(100vh - 1.2rem);
	padding: 0;
	border: 0;
	border-radius: 1.8rem;
	background: transparent;
	box-shadow: 0 40px 120px rgba(12, 7, 21, 0.35);
}

.enquiry-dialog::backdrop {
	background: rgba(6, 43, 68, 0.68);
	backdrop-filter: blur(10px);
}

.enquiry-modal {
	position: relative;
	overflow-y: auto;
	max-height: calc(100vh - 1.2rem);
	padding: clamp(1.5rem, 5vw, 3.5rem);
	border: 1px solid rgba(255, 255, 255, 0.8);
	border-radius: inherit;
	background:
		radial-gradient(circle at 100% 0, rgba(15, 95, 146, 0.17), transparent 32%), var(--surface);
}

.enquiry-close {
	position: absolute;
	top: 1rem;
	right: 1rem;
	display: grid;
	width: 2.5rem;
	height: 2.5rem;
	place-items: center;
	border: 1px solid var(--line);
	border-radius: 50%;
	background: white;
	font-size: 1.4rem;
	cursor: pointer;
}

.enquiry-modal .intro {
	max-width: 34rem;
}

.enquiry-modal h2 {
	margin: 0.8rem 0 0;
	font-size: clamp(2.7rem, 7vw, 4.7rem);
	font-weight: 400;
	line-height: 0.9;
}

.enquiry-modal .intro > p:last-child,
.enquiry-modal .success > p:nth-of-type(2) {
	max-width: 34rem;
	margin: 1rem 0 0;
	color: var(--muted);
	line-height: 1.6;
}

.enquiry-modal form {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 1rem;
	margin-top: 2rem;
}

.enquiry-modal label {
	display: grid;
	gap: 0.45rem;
}

.enquiry-modal label:has(select),
.enquiry-modal label:has(textarea) {
	grid-column: 1 / -1;
}

.enquiry-modal label span {
	font-size: 0.78rem;
	font-weight: 600;
}

.enquiry-modal input,
.enquiry-modal select,
.enquiry-modal textarea {
	width: 100%;
	border: 1px solid var(--line);
	border-radius: 0.9rem;
	background: white;
	color: var(--ink);
	box-shadow: none;
}

.enquiry-modal input,
.enquiry-modal select {
	min-height: 3.2rem;
}

.enquiry-modal textarea {
	resize: vertical;
}

.enquiry-modal input:focus,
.enquiry-modal select:focus,
.enquiry-modal textarea:focus {
	border-color: var(--violet);
	outline: 3px solid rgba(31, 124, 186, 0.12);
	box-shadow: none;
}

.enquiry-modal .submit {
	grid-column: 1 / -1;
	justify-self: start;
	margin-top: 0.5rem;
}

.enquiry-modal .success {
	display: grid;
	min-height: 30rem;
	align-content: center;
	justify-items: start;
}

.success-mark {
	display: grid;
	width: 4rem;
	height: 4rem;
	margin-bottom: 2rem;
	place-items: center;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--violet), var(--orange));
	color: white;
	font-size: 1.7rem;
}

.enquiry-modal .success .button {
	margin-top: 2rem;
}

@media (max-width: 600px) {
	.enquiry-modal form {
		grid-template-columns: 1fr;
	}

	.enquiry-modal label:nth-child(4),
	.enquiry-modal .submit {
		grid-column: auto;
	}
}

/* --------------------------------------------------------------------------
   Mock assistant
   -------------------------------------------------------------------------- */
.chat-widget {
	position: fixed;
	right: 1.25rem;
	bottom: 1.25rem;
	z-index: 60;
	width: 3.6rem;
	height: 3.6rem;
}

.chat-fab {
	display: grid;
	width: 3.6rem;
	height: 3.6rem;
	place-items: center;
	border: 0;
	border-radius: 50%;
	background: linear-gradient(145deg, #1f7cba, #074a74);
	color: white;
	box-shadow: 0 16px 40px rgba(7, 74, 116, 0.4);
	cursor: pointer;
	transition:
		transform 180ms ease,
		box-shadow 180ms ease;
}

.chat-fab svg {
	width: 1.6rem;
	height: 1.6rem;
}

.chat-fab:hover,
.chat-widget.open .chat-fab {
	transform: translateY(-2px) scale(1.04);
	box-shadow: 0 20px 50px rgba(7, 74, 116, 0.5);
}

.chat-teaser {
	position: absolute;
	right: 0;
	bottom: calc(100% + 0.85rem);
	width: min(19rem, calc(100vw - 2.5rem));
	padding: 0.95rem 1.1rem;
	border: 1px solid var(--line);
	border-radius: 1.1rem;
	background: var(--surface);
	box-shadow: 0 20px 50px rgba(6, 43, 68, 0.16);
	transition:
		opacity 160ms ease,
		transform 160ms ease;
}

.chat-teaser::after {
	position: absolute;
	right: 1.4rem;
	bottom: -0.5rem;
	width: 0.9rem;
	height: 0.9rem;
	border-right: 1px solid var(--line);
	border-bottom: 1px solid var(--line);
	background: var(--surface);
	content: '';
	transform: rotate(45deg);
}

.chat-teaser-label {
	margin: 0 0 0.5rem;
	color: var(--muted);
	font-size: 0.68rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.chat-prompt-stage {
	display: grid;
	min-height: 2.6rem;
	align-items: center;
}

.chat-prompt {
	margin: 0;
	color: var(--ink);
	font-size: 0.9rem;
	line-height: 1.4;
	animation: chat-prompt-in 340ms ease both;
}

@keyframes chat-prompt-in {
	from {
		opacity: 0;
		transform: translateY(0.4rem);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@media (prefers-reduced-motion: reduce) {
	.chat-prompt {
		animation: none;
	}
}

.chat-panel {
	position: absolute;
	right: 0;
	bottom: 0;
	display: flex;
	width: min(28rem, calc(100vw - 2.5rem));
	height: 34rem;
	max-height: calc(100vh - 3rem);
	flex-direction: column;
	overflow: hidden;
	border: 1px solid var(--line);
	border-radius: 1.3rem;
	background: var(--surface);
	box-shadow: 0 30px 80px rgba(6, 43, 68, 0.28);
	opacity: 0;
	pointer-events: none;
	transform: translateY(0.6rem) scale(0.98);
	transform-origin: bottom right;
	transition:
		opacity 180ms ease,
		transform 180ms ease;
}

.chat-widget.open .chat-panel {
	opacity: 1;
	pointer-events: auto;
	transform: translateY(0) scale(1);
}

.chat-widget.open .chat-teaser {
	opacity: 0;
	pointer-events: none;
	transform: translateY(0.4rem);
}

.chat-panel header {
	display: flex;
	align-items: center;
	gap: 0.7rem;
	padding: 0.9rem 1rem;
	border-bottom: 1px solid var(--line);
	background: linear-gradient(140deg, #0c3d5e, #1f7cba);
	color: white;
}

.chat-avatar {
	display: grid;
	width: 2.2rem;
	height: 2.2rem;
	flex: none;
	place-items: center;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.18);
}

.chat-avatar svg {
	width: 1.1rem;
	height: 1.1rem;
}

.chat-panel header div {
	display: grid;
}

.chat-panel header strong {
	font-size: 1rem;
}

.chat-panel header small {
	color: rgba(255, 255, 255, 0.7);
	font-size: 0.68rem;
}

.chat-close {
	margin-left: auto;
	border: 0;
	background: none;
	color: rgba(255, 255, 255, 0.85);
	font-size: 1.3rem;
	line-height: 1;
	cursor: pointer;
}

.chat-log {
	display: flex;
	flex: 1;
	flex-direction: column;
	gap: 0.5rem;
	overflow-y: auto;
	padding: 1rem;
}

.chat-log p {
	max-width: 85%;
	margin: 0;
	padding: 0.65rem 0.9rem;
	border-radius: 0.9rem;
	background: var(--paper);
	font-size: 0.9rem;
	line-height: 1.5;
}

.chat-log p.user {
	align-self: flex-end;
	background: var(--night);
	color: white;
}

.chat-input {
	display: flex;
	gap: 0.4rem;
	padding: 0.7rem;
	border-top: 1px solid var(--line);
}

.chat-input input {
	flex: 1;
	min-width: 0;
	padding: 0.65rem 0.9rem;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: var(--paper);
	font-size: 0.9rem;
}

.chat-input input:focus {
	border-color: var(--violet);
	outline: 3px solid rgba(31, 124, 186, 0.15);
}

.chat-input button {
	display: grid;
	width: 2.4rem;
	height: 2.4rem;
	flex: none;
	place-items: center;
	border: 0;
	border-radius: 50%;
	background: var(--violet);
	color: white;
	font-size: 1rem;
	cursor: pointer;
}

@media (max-width: 480px) {
	.chat-teaser {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.notice {
		transition: none;
	}
}
