/* ==========================================================================
   content.css - shared look of the content pages that load inside the shell
   frame (index.html). Tokens are the same as css/shell.css :root.
   Type scale (shell: breadcrumb 1.2rem = page title, rail labels .93rem):
   lead 1.2rem > card title 1.15rem (1.05rem on phone) > body 1rem > tile .95rem.
   Reading text stays >= 16px; the rail is navigation chrome and may be smaller.
   Used by modernized pages only; legacy pages keep ccs_1/ccs_2.css until
   they are done. No framework, no build step.
   ========================================================================== */

:root {
	--font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--bg: #f6f4ec;
	--page: #fbfaf5;
	--surface: #fffefb;
	--band: #e9e5d6;
	--line: #d6d0bb;
	--ink: #2b2a24;
	--muted: #5c5848;
	--link: #1f6178;
	--accent: #39798f;
	--tint: #e4eef1;
	--rail: #1b3d49;
	--focus: #0b6bcb;
}

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

html { -webkit-text-size-adjust: 100%; background: var(--page); }
body { margin: 0; background: var(--page); color: var(--ink); font: 16px/1.6 var(--font); }

a { color: var(--link); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }

.page { margin: 0 auto; padding: 32px 28px 20px; }   /* no width cap: the page uses the whole frame */

/* ---------- intro ---------- */
.lead {
	margin: 0 0 28px; padding: 4px 0 4px 18px;
	border-left: 4px solid var(--accent);
	font-size: 1.2rem; line-height: 1.5; font-weight: 500; letter-spacing: -.005em;
	color: var(--ink); text-wrap: balance;   /* one line when the frame is wide enough (about 1300 px), otherwise wrapped evenly */
}

/* ---------- cards ---------- */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.span2 { grid-column: 1 / -1; }   /* full row, whatever the number of columns */
/* wide frames (about 1300 px and more): the four small cards sit side by side */
@media (min-width: 1300px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.card {
	display: flex; flex-direction: column; gap: 10px;
	padding: 20px 22px 22px;
	background: var(--surface);
	border: 1px solid var(--line); border-radius: 14px;
	box-shadow: 0 1px 2px rgba(60,50,20,.05);
}

.card-head { display: flex; align-items: center; gap: 14px; }
.card h2 { margin: 0; font-size: 1.15rem; line-height: 1.25; font-weight: 700; letter-spacing: -.01em; }
.card h2 a { text-decoration: none; color: var(--link); }
.card h2 a:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.card p { margin: 0; color: var(--ink); }

.ico { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; background: var(--tint); color: var(--link); }
.ico svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ico-row { display: flex; gap: 6px; flex: none; }
.ico-row .ico { width: 38px; height: 38px; border-radius: 10px; }
.ico-row .ico svg { width: 21px; height: 21px; }

/* cv strip: one compact horizontal card */
.card.strip { flex-direction: row; align-items: center; gap: 16px; padding: 16px 22px; }
.card.strip .strip-t { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 14px; min-width: 0; }

/* projects: big card with four tiles */
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 6px; }
.tile { padding: 14px 16px; background: var(--page); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 10px; font-size: .95rem; line-height: 1.55; }
.tile + .tile { margin: 0; }
/* very wide frames: the four tiles side by side keeps the lines short */
@media (min-width: 1800px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* privacy note */
.note { display: flex; gap: 14px; align-items: flex-start; margin-top: 18px; padding: 16px 20px; background: var(--tint); border: 1px solid #c6dbe2; border-radius: 14px; }
.note .ico { background: #fff; width: 40px; height: 40px; }
.note p { margin: 0; }

/* contact footer */
.contact { display: flex; gap: 14px; align-items: center; margin-top: 18px; padding: 14px 20px; border-top: 1px solid var(--line); color: var(--muted); }
.contact .ico { width: 36px; height: 36px; border-radius: 10px; }
.contact p { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* ---------- narrow frames / phone ---------- */
@media (max-width: 760px) {
	.page { padding: 20px 16px 16px; }
	.grid, .tiles { grid-template-columns: minmax(0, 1fr); }
	.lead { font-size: 1.1rem; margin-bottom: 20px; }
	.card h2 { font-size: 1.05rem; }
	.card { padding: 16px 16px 18px; }
	.card.strip { padding: 14px 16px; }
	.ico-row { flex-wrap: wrap; }
}

@media print {
	html, body { background: #fff; }
	.page { max-width: none; padding: 0; }
	.card, .note { box-shadow: none; break-inside: avoid; }
		a { color: #000; }
}
