/*
 * atelier.css - atelier.slitaz.org
 *
 * Copyright (C) 2026 SliTaz GNU/Linux - BSD License
 *
 * Same family as pelote.css. No JavaScript, no web font, no external
 * file: the vhost CSP allows none.
 */
:root {
	--orange: #e8731c;
	--orange-dark: #b85a0f;
	--green: #6ba539;
	--green-dark: #4c7f25;
	--bg: #fbfaf8;
	--band: #f2eee8;
	--card: #ffffff;
	--text: #1f1c19;
	--muted: #6b645c;
	--line: #e3ddd4;
	--code: #f1ece5;
	--radius: 14px;
	--shadow: 0 1px 2px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.06);
}

@media (prefers-color-scheme: dark) {
	:root {
		--bg: #15130f;
		--band: #1d1a16;
		--card: #24201b;
		--text: #eee8e1;
		--muted: #a59d93;
		--line: #353029;
		--code: #2d2822;
		--shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.3);
	}
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "DejaVu Sans", sans-serif;
	-webkit-font-smoothing: antialiased;
}

a { color: var(--orange-dark); }
@media (prefers-color-scheme: dark) { a { color: var(--orange); } }

code {
	font-family: ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace;
	font-size: .88em;
	background: var(--code);
	padding: .1em .35em;
	border-radius: 5px;
}

h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
h2 { font-size: 2rem; letter-spacing: -.02em; }
h3 { font-size: 1.15rem; }

/* --- Header --- */

.top {
	position: sticky;
	top: 0;
	z-index: 10;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: .7rem max(1.2rem, calc((100% - 1280px) / 2 + 1.2rem));
	min-height: 63px;
	background: var(--bg);
	background: color-mix(in srgb, var(--bg) 85%, transparent);
	backdrop-filter: saturate(1.5) blur(10px);
	border-bottom: 1px solid var(--line);
}
.brand {
	display: flex;
	align-items: center;
	gap: .5rem;
	font-weight: 700;
	font-size: 1.3rem;
	color: var(--text);
	text-decoration: none;
}
.top nav { display: flex; align-items: center; gap: 1.2rem; }
.top nav a { color: var(--muted); text-decoration: none; font-weight: 500; }
.top nav a:hover { color: var(--text); }
.top nav a.button { color: #fff; }

/* --- Buttons --- */

.button {
	display: inline-block;
	padding: .75rem 1.3rem;
	border-radius: 999px;
	background: var(--orange);
	color: #fff;
	font-weight: 600;
	text-decoration: none;
	transition: transform .15s, background .15s;
}
.button:hover {
	background: var(--orange-dark);
	transform: translateY(-1px);
}
.button.small { padding: .45rem .95rem; font-size: .95rem; color: #fff; }
.button.ghost {
	background: transparent;
	color: var(--text);
	box-shadow: inset 0 0 0 2px var(--line);
}
.button.ghost:hover { box-shadow: inset 0 0 0 2px var(--green); background: transparent; }

/* --- Sections --- */

main > section {
	padding: 4.5rem max(1.2rem, calc((100% - 1100px) / 2));
}
main > section.band { background: var(--band); }
main > section > p { max-width: 44em; }
.note { color: var(--muted); font-size: .95rem; }
.small { font-size: .9rem; color: var(--muted); }

/* --- Hero --- */

.hero {
	padding-top: 5rem !important;
	background:
		radial-gradient(900px 400px at 85% 20%, rgba(232,115,28,.14), transparent 60%),
		radial-gradient(700px 400px at 10% 90%, rgba(107,165,57,.12), transparent 60%);
}
.kicker {
	color: var(--green-dark);
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .08em;
	font-size: .85rem;
	margin: 0 0 .8rem;
}
@media (prefers-color-scheme: dark) { .kicker { color: var(--green); } }
.hero h1 {
	font-size: clamp(2.3rem, 5vw, 3.6rem);
	letter-spacing: -.035em;
	margin-bottom: 1rem;
}
/* Plain colour: gradient text breaks in some engines (Soie) */
.hero h1 span { color: var(--orange); }
.lead { font-size: 1.15rem; margin: 0 0 1rem; max-width: 38em; }
.lead.small { font-size: 1rem; }
.cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }

/* --- The two ways: free or Atelier --- */

.ways {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 1.4rem;
	margin: 2rem 0 1rem;
}
.ways article {
	background: var(--card);
	border-radius: var(--radius);
	padding: 1.5rem;
	box-shadow: var(--shadow);
	border-top: 4px solid var(--green);
}
.ways article + article { border-top-color: var(--orange); }
.ways p { margin: 0 0 .6rem; color: var(--muted); }

/* --- Offers --- */

.offers {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 1.4rem;
	margin: 2rem 0 1.5rem;
}
.offers article {
	display: flex;
	flex-direction: column;
	background: var(--card);
	border-radius: var(--radius);
	padding: 1.5rem;
	box-shadow: var(--shadow);
}
.offers p { margin: 0 0 .8rem; color: var(--muted); }
.price, .offers .price {
	font-size: 1.7rem;
	font-weight: 700;
	letter-spacing: -.02em;
	margin: 0 0 .6rem;
	color: var(--text);
}
.price small { font-size: .9rem; font-weight: 500; color: var(--muted); }
/* Two lines kept for the free-way reminder: the buttons above it line
 * up across the three cards whatever the text length. */
.free {
	min-height: 4.4em;
	margin-bottom: 0 !important;
	padding-top: .8rem;
	border-top: 1px solid var(--line);
	font-size: .88rem;
	color: var(--muted);
}
.offers .button { align-self: flex-start; margin: auto 0 1rem; }

/* --- Steps --- */

.steps {
	list-style: none;
	padding: 0;
	margin: 2rem 0 1.5rem;
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 1.4rem;
}
.steps li {
	background: var(--card);
	border-radius: var(--radius);
	padding: 1.5rem;
	box-shadow: var(--shadow);
}
.num {
	display: inline-grid;
	place-items: center;
	width: 2.1rem;
	height: 2.1rem;
	border-radius: 50%;
	background: var(--orange);
	color: #fff;
	font-weight: 700;
	margin-bottom: .8rem;
}
.steps p { margin: 0; color: var(--muted); }

/* --- Support and business boxes --- */

.box {
	display: grid;
	grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
	gap: 2rem;
	align-items: center;
	background: var(--card);
	border-radius: var(--radius);
	padding: 2rem;
	box-shadow: var(--shadow);
	margin: 2rem 0 1rem;
	border-left: 6px solid var(--orange);
}
.box.green { border-left-color: var(--green); }
.box p { margin: 0 0 .8rem; }
.box .side { text-align: center; }
.box .side .small { margin: 1rem 0 0; }

.funding { color: var(--muted); font-size: .95rem; }
.funding progress {
	display: block;
	width: 100%;
	height: 1rem;
	margin-bottom: .4rem;
	accent-color: var(--green);
}

/* --- Accounts --- */

.split {
	display: flex;
	height: 2.6rem;
	border-radius: 999px;
	overflow: hidden;
	margin: 1.5rem 0 .6rem;
	max-width: 44rem;
	font-weight: 600;
	color: #fff;
}
.split span { display: grid; place-items: center; }
.split .dev { width: 70%; background: var(--orange); }
.split .project { width: 30%; background: var(--green-dark); }

table { border-collapse: collapse; margin: 1rem 0 1.5rem; }
th, td {
	padding: .45rem 1.4rem .45rem 0;
	border-bottom: 1px solid var(--line);
	vertical-align: top;
	text-align: left;
}
th { font-size: .9rem; color: var(--muted); }
.ledger {
	width: 100%;
	border-collapse: separate;
	border-spacing: 0;
	margin: 2rem 0 1rem;
	background: var(--card);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	overflow: hidden;
}
.ledger th, .ledger td { padding: .8rem 1.4rem; }
.ledger th { background: var(--band); }
.ledger td:nth-child(1) { white-space: nowrap; color: var(--muted); }
.ledger td:nth-child(2) { width: 100%; }
.ledger td:nth-child(n+3), .ledger th:nth-child(n+3) {
	text-align: right;
	white-space: nowrap;
	font-variant-numeric: tabular-nums;
}
.ledger .total td { font-weight: 700; }
.ledger tr:last-child td { border-bottom: 0; }

/* The three promises under an order: same cards as the two ways */
.rules {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 1.4rem;
	margin: 0 0 1rem;
}
.rules article {
	background: var(--card);
	border-radius: var(--radius);
	padding: 1.5rem;
	box-shadow: var(--shadow);
	border-top: 4px solid var(--green);
}
.rules p { margin: 0; color: var(--muted); }

/* --- Footer --- */

footer {
	padding: 2rem 1.2rem 3rem;
	text-align: center;
	color: var(--muted);
	font-size: .9rem;
	border-top: 1px solid var(--line);
}
footer img { vertical-align: -4px; margin-right: .3rem; }

/* --- Small screens --- */

@media (max-width: 860px) {
	.hero { padding-top: 3rem !important; }
	.ways, .offers, .steps, .rules, .box { grid-template-columns: 1fr; }
	.top nav a:not(.button):not(.lang) { display: none; }
	main > section { padding-top: 3rem; padding-bottom: 3rem; }
}
