:root {
	--bg-0: #0c0d10;
	--bg-1: #14161c;
	--text: #f2f0ea;
	--muted: #8b8796;
	--line: rgba(242, 240, 234, 0.12);
	--accent: #ff6b2c;
	--accent-soft: rgba(255, 107, 44, 0.18);
	--ok: #3ecf8e;
	--bad: #ff5c7a;
	--radius: 14px;
	--font-display: "Outfit", system-ui, sans-serif;
	--font-body: "Figtree", system-ui, sans-serif;
	--page-pad: max(1rem, env(safe-area-inset-left)) max(1rem, env(safe-area-inset-right));
}

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

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

html,
body {
	margin: 0;
	min-height: 100%;
	min-height: 100dvh;
}

body {
	font-family: var(--font-body);
	color: var(--text);
	background: var(--bg-0);
	line-height: 1.45;
	-webkit-tap-highlight-color: transparent;
}

.bg {
	position: fixed;
	inset: 0;
	z-index: -1;
	background:
		radial-gradient(900px 500px at 12% -10%, rgba(255, 107, 44, 0.22), transparent 55%),
		radial-gradient(700px 420px at 100% 0%, rgba(64, 180, 255, 0.12), transparent 50%),
		linear-gradient(180deg, #12141a 0%, var(--bg-0) 55%);
}

.shell {
	width: min(440px, 100%);
	margin: 0 auto;
	padding: max(1.75rem, env(safe-area-inset-top)) var(--page-pad)
		max(2.5rem, env(safe-area-inset-bottom));
	animation: rise 0.55s ease-out both;
}

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

.brand {
	margin-bottom: 1.5rem;
}

.brand-home {
	margin-bottom: 2.25rem;
}

.auth-heading {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.15rem 0.25rem;
	margin: 0 0 0.85rem;
}

.auth-heading h1 {
	margin: 0;
	font-family: var(--font-display);
	font-weight: 700;
	font-size: clamp(1.15rem, 4.5vw, 1.35rem);
	letter-spacing: -0.02em;
}

.auth-heading .brand-tag {
	margin: 0;
	font-size: 0.78rem;
}

.auth-heading .brand-tag::before {
	content: " · ";
}

.brand-name {
	margin: 0 0 0.7rem;
	font-family: var(--font-display);
	font-weight: 800;
	font-size: clamp(1.85rem, 8vw, 2.6rem);
	letter-spacing: -0.04em;
	line-height: 1;
}

/* Couleurs du drapeau philippin : bleu, rouge, jaune */
.tix-t {
	color: #3d7eff;
}

.tix-i {
	color: #e11d2e;
}

.tix-x {
	color: #f5d000;
}

.brand h1 {
	margin: 0;
	font-family: var(--font-display);
	font-weight: 700;
	font-size: clamp(1.15rem, 4.5vw, 1.35rem);
	letter-spacing: -0.02em;
}

.brand-tag {
	margin: 0.3rem 0 0;
	color: var(--muted);
	font-size: 0.7rem;
}

.brand > h1 {
	display: inline;
}

.brand > h1 + .brand-tag {
	display: inline;
	margin: 0;
	font-size: 0.78rem;
}

.brand > h1 + .brand-tag::before {
	content: " · ";
}

.brand-home .brand-lede {
	display: inline;
	margin: 0;
}

.brand-home .brand-lede + .brand-tag {
	display: inline;
	margin: 0;
	font-size: 0.78rem;
}

.brand-home .brand-lede + .brand-tag::before {
	content: " · ";
}

.brand-home .brand-lede + .brand-tag::after {
	content: "";
	display: block;
	margin-bottom: 0.15rem;
}

.mode-toggle {
	display: flex;
	align-items: center;
	gap: 0.45rem;
	margin: 0.15rem 0 0.75rem;
}

.mode-btn {
	border: 0;
	background: transparent;
	padding: 0;
	margin: 0;
	font: inherit;
	font-size: 0.72rem;
	font-weight: 500;
	color: var(--muted);
	cursor: pointer;
	opacity: 0.7;
	transition:
		color 0.15s ease,
		opacity 0.15s ease;
}

.mode-btn:hover {
	opacity: 1;
	color: var(--text);
}

.mode-btn.is-active {
	opacity: 1;
	color: var(--text);
	text-decoration: underline;
	text-underline-offset: 0.28em;
	text-decoration-thickness: 1px;
	text-decoration-color: rgba(242, 240, 234, 0.35);
}

.mode-sep {
	color: var(--muted);
	opacity: 0.45;
	font-size: 0.72rem;
	line-height: 1;
	user-select: none;
}

.form {
	display: grid;
	gap: 0.95rem;
}

.field {
	display: block;
}

.label-en {
	display: inline;
	font-weight: 600;
	font-size: 0.9rem;
}

.label-tl {
	display: inline;
	color: var(--muted);
	font-size: 0.72rem;
	line-height: 1.3;
	font-weight: 500;
	margin: 0;
}

.label-tl::before {
	content: " · ";
	color: var(--muted);
	font-weight: 400;
}

.field > input,
.field > select,
.field > textarea,
.field > .cover-picker,
.field > .delivery-options,
.field > .dt-trigger,
.field > .publish-link-row,
.field > .field-hint {
	display: block;
	margin-top: 0.4rem;
	width: 100%;
}

.field > .field-hint {
	width: auto;
	margin-top: 0.35rem;
}

.field > input[type="hidden"] {
	display: none;
	margin: 0;
	width: 0;
}

input {
	width: 100%;
	min-height: 48px;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: rgba(20, 22, 28, 0.85);
	color: var(--text);
	padding: 0.8rem 0.9rem;
	/* 16px minimum avoids iOS focus zoom */
	font-size: 16px;
	font-family: inherit;
	line-height: 1.3;
	outline: none;
	appearance: none;
	-webkit-appearance: none;
	transition:
		border-color 0.15s ease,
		background 0.15s ease,
		box-shadow 0.15s ease;
}

input::placeholder {
	color: #5f5b68;
}

input:focus {
	border-color: rgba(255, 107, 44, 0.65);
	background: var(--bg-1);
	box-shadow: 0 0 0 3px var(--accent-soft);
}

.submit {
	margin-top: 0.25rem;
	min-height: 52px;
	border: 0;
	border-radius: var(--radius);
	background: var(--accent);
	color: #1a0d07;
	padding: 0.85rem 1rem;
	font-family: var(--font-display);
	font-weight: 700;
	cursor: pointer;
	display: inline-flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: baseline;
	gap: 0.15rem 0.2rem;
	touch-action: manipulation;
	transition:
		transform 0.15s ease,
		filter 0.15s ease;
}

.submit:hover:not(:disabled) {
	filter: brightness(1.06);
	transform: translateY(-1px);
}

.submit:active:not(:disabled) {
	transform: translateY(0);
	filter: brightness(0.98);
}

.submit:disabled {
	opacity: 0.6;
	cursor: wait;
}

.btn-en {
	font-size: 1rem;
}

.btn-tl {
	font-family: var(--font-body);
	font-weight: 500;
	font-size: 0.72rem;
	opacity: 0.8;
}

.btn-tl::before {
	content: " · ";
	opacity: 0.9;
}

.error,
.success {
	margin: 0;
	padding: 0.7rem 0.85rem;
	border-radius: 12px;
	font-size: 0.85rem;
}

.error {
	background: rgba(255, 92, 122, 0.12);
	color: #ffb3c2;
}

.success {
	background: rgba(62, 207, 142, 0.12);
	color: #9aefc4;
}

.confirm-shell {
	display: flex;
	flex-direction: column;
	justify-content: center;
	min-height: 100dvh;
	padding-top: max(2rem, env(safe-area-inset-top));
	padding-bottom: max(2rem, env(safe-area-inset-bottom));
}

.confirm-brand {
	margin-bottom: 1.75rem;
	text-align: center;
}

.confirm-brand .brand-name {
	margin-bottom: 0.85rem;
}

.confirm-card {
	display: grid;
	justify-items: center;
	gap: 0.55rem;
	text-align: center;
}

.confirm-lead {
	margin: 0;
	font-family: var(--font-display);
	font-weight: 700;
	font-size: clamp(1.25rem, 5vw, 1.55rem);
	letter-spacing: -0.02em;
}

.confirm-sub {
	display: inline;
	margin: 0;
	color: var(--text);
	font-size: 0.95rem;
	opacity: 0.9;
}

.confirm-sub-tl {
	display: inline;
	margin: 0;
	color: var(--muted);
	font-size: 0.78rem;
}

.confirm-sub-tl::before {
	content: " · ";
}

.confirm-sub-tl::after {
	content: "";
	display: block;
	margin-bottom: 1.35rem;
}

.cta {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: baseline;
	gap: 0.15rem 0.2rem;
	min-height: 52px;
	width: min(100%, 280px);
	margin-top: 0.35rem;
	padding: 0.85rem 1.1rem;
	border-radius: var(--radius);
	background: var(--accent);
	color: #1a0d07;
	text-decoration: none;
	font-family: var(--font-display);
	font-weight: 700;
	touch-action: manipulation;
	transition:
		transform 0.15s ease,
		filter 0.15s ease;
}

.cta:hover {
	filter: brightness(1.06);
	transform: translateY(-1px);
}

.cta:active {
	transform: translateY(0);
	filter: brightness(0.98);
}

.dash-note {
	margin: 0;
	font-size: 0.95rem;
	opacity: 0.9;
}

.dash-note-tl {
	margin: 0.35rem 0 0;
	color: var(--muted);
	font-size: 0.65rem;
}

.brand-lede {
	margin: 0.65rem 0 0;
	font-family: var(--font-display);
	font-weight: 600;
	font-size: clamp(0.95rem, 3.5vw, 1.05rem);
	letter-spacing: -0.02em;
	line-height: 1.35;
	color: var(--text);
}

.brand-home .brand-name {
	margin-bottom: 0.85rem;
}

.auth-signup {
	margin: 1.5rem 0 0;
	text-align: center;
}

.auth-signup-label {
	margin: 0;
	display: inline;
}

.auth-signup-label .label-en {
	display: inline;
	font-size: 0.82rem;
	color: var(--muted);
}

.auth-signup-label .label-tl {
	display: inline;
	font-size: 0.72rem;
	color: var(--muted);
	opacity: 0.85;
	margin: 0;
}

.auth-signup-links {
	margin: 0.55rem 0 0;
	font-size: 0.82rem;
	line-height: 1.5;
}

.auth-signup-links a {
	color: var(--muted);
	text-decoration: none;
	border-bottom: 1px solid rgba(242, 240, 234, 0.2);
}

.auth-signup-links a:hover {
	color: var(--text);
}

.auth-switch {
	margin: 1.25rem 0 0;
	text-align: center;
	font-size: 0.82rem;
}

.auth-switch a {
	color: var(--muted);
	text-decoration: none;
	border-bottom: 1px solid rgba(242, 240, 234, 0.2);
}

.auth-switch a:hover {
	color: var(--text);
}

.auth-switch .label-tl {
	display: inline;
	margin: 0;
	font-size: 0.72rem;
}

.auth-switch .label-tl::before {
	content: none;
}

@media (min-width: 480px) {
	.shell {
		padding-top: 3.5rem;
		padding-bottom: 4rem;
	}

	.brand {
		margin-bottom: 2rem;
	}

	.form {
		gap: 1.1rem;
	}
}
