/* MyResume123.me — one small stylesheet, no framework. */

:root {
	--bg: #f7f8fb;
	--surface: #ffffff;
	--text: #161a23;
	--muted: #5b6475;
	--line: #e3e6ee;
	--accent: #3454d1;
	--accent-strong: #2742b0;
	--accent-soft: #eaeefc;
	--on-accent: #ffffff;
	--ok-bg: #e7f6ec;
	--ok-text: #1d6b3a;
	--err-bg: #fdecec;
	--err-text: #a12828;
	--radius: 14px;
	--shadow: 0 1px 2px rgba(20, 24, 40, .06), 0 8px 24px rgba(20, 24, 40, .06);
	color-scheme: light;
}

/* Dark theme: follows the system unless the visitor picked one with the header toggle
   (stored as data-theme on <html>). */
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #0f1218;
		--surface: #171b24;
		--text: #e9ecf2;
		--muted: #9aa3b5;
		--line: #2a3040;
		--accent: #7b93ff;
		--accent-strong: #9aacff;
		--accent-soft: #1f2640;
		--on-accent: #0f1218;
		--ok-bg: #12301f;
		--ok-text: #8fe0ac;
		--err-bg: #3a1717;
		--err-text: #ffaaaa;
		--shadow: none;
		color-scheme: dark;
	}
}

:root[data-theme="dark"] {
	--bg: #0f1218;
	--surface: #171b24;
	--text: #e9ecf2;
	--muted: #9aa3b5;
	--line: #2a3040;
	--accent: #7b93ff;
	--accent-strong: #9aacff;
	--accent-soft: #1f2640;
	--on-accent: #0f1218;
	--ok-bg: #12301f;
	--ok-text: #8fe0ac;
	--err-bg: #3a1717;
	--err-text: #ffaaaa;
	--shadow: none;
	color-scheme: dark;
}

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

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

body {
	margin: 0;
	background: var(--bg);
	color: var(--text);
	font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

a { color: var(--accent); }

img { max-width: 100%; display: block; }

.container { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.container.narrow { max-width: 760px; }

/* Header / footer */

.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo { font-weight: 800; font-size: 20px; letter-spacing: -.02em; color: var(--text); text-decoration: none; }
.logo span { color: var(--accent); }
.site-header nav a { color: var(--muted); text-decoration: none; margin-left: 20px; font-size: 15px; }
.site-header nav a:hover { color: var(--text); }
@media (max-width: 440px) { .site-header nav a.wide-only { display: none; } }
.site-header nav { display: flex; align-items: center; }

.theme-toggle {
	display: inline-grid; place-items: center;
	width: 40px; height: 40px; margin-left: 16px; padding: 0;
	border: 1px solid var(--line); border-radius: 10px;
	background: transparent; color: var(--muted); cursor: pointer;
}
.theme-toggle:hover { color: var(--text); background: var(--accent-soft); }
.theme-toggle svg { width: 20px; height: 20px; }
/* Show the icon of the theme you'd switch TO. */
.theme-toggle .moon { display: block; }
.theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: block; }

.site-footer { border-top: 1px solid var(--line); margin-top: 72px; padding: 28px 0; color: var(--muted); font-size: 14px; }
.site-footer .container { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }

/* Landing */

.hero { padding: 64px 0 40px; text-align: center; }
.hero h1 { font-size: clamp(32px, 6vw, 52px); line-height: 1.1; letter-spacing: -.03em; margin: 0 0 16px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero p { color: var(--muted); font-size: 18px; max-width: 560px; margin: 0 auto 28px; }

.badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 20px; padding: 0; list-style: none; }
.badges li { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: 14px; color: var(--muted); }

.steps { display: grid; gap: 16px; grid-template-columns: 1fr; margin: 24px 0 56px; padding: 0; list-style: none; counter-reset: step; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; counter-increment: step; }
.steps li::before {
	content: counter(step);
	display: inline-grid; place-items: center;
	width: 32px; height: 32px; border-radius: 50%;
	background: var(--accent-soft); color: var(--accent); font-weight: 700;
	margin-bottom: 10px;
}
.steps h3 { margin: 0 0 4px; font-size: 17px; }
.steps p { margin: 0; color: var(--muted); font-size: 15px; }

.section-title { font-size: 26px; letter-spacing: -.02em; margin: 0 0 6px; }
.section-lead { color: var(--muted); margin: 0 0 24px; }

.templates { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 560px) { .templates { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .templates { grid-template-columns: repeat(4, 1fr); } }

.template {
	display: flex; flex-direction: column;
	background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
	box-shadow: var(--shadow); overflow: hidden; color: inherit; text-decoration: none;
	transition: transform .15s ease, border-color .15s ease;
}
.template:hover, .template:focus-visible { transform: translateY(-2px); border-color: var(--accent); }
.template .preview { aspect-ratio: 1 / 1; background: #fff; border-bottom: 1px solid var(--line); overflow: hidden; padding: 12px 8px 0; }
.template .preview img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.template .preview.stack { position: relative; background: var(--accent-soft); padding: 0; }
.template .preview.stack img {
	position: absolute; width: 62%; height: auto; aspect-ratio: 1 / 1;
	border-radius: 6px; box-shadow: 0 4px 14px rgba(0, 0, 0, .15); background: #fff;
}
.template .preview.stack img:nth-child(1) { left: 6%;  top: 14%; transform: rotate(-6deg); }
.template .preview.stack img:nth-child(2) { left: 32%; top: 14%; transform: rotate(6deg); }
.template .preview.stack img:nth-child(3) { left: 19%; top: 8%; }
.template .body { padding: 16px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.template h3 { margin: 0; font-size: 17px; }
.template p { margin: 0 0 12px; color: var(--muted); font-size: 14px; flex: 1; }
.template .tag { align-self: flex-start; font-size: 12px; font-weight: 600; color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 2px 10px; }

.note { margin-top: 40px; padding: 16px 20px; border-radius: var(--radius); background: var(--accent-soft); color: var(--text); font-size: 15px; }

/* Buttons */

.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 44px; padding: 0 20px; border-radius: 10px;
	font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
	border: 1px solid transparent; background: var(--accent); color: var(--on-accent);
}
.btn:hover { background: var(--accent-strong); }
.btn-lg { min-height: 52px; padding: 0 28px; font-size: 17px; }
.btn-ghost { background: transparent; color: var(--accent); border-color: var(--line); }
.btn-ghost:hover { background: var(--accent-soft); }
.btn-link { background: none; border: 0; color: var(--muted); padding: 0; min-height: 0; font-weight: 500; text-decoration: underline; }
.btn-link:hover { background: none; color: var(--err-text); }
.btn-block { width: 100%; }

.visually-hidden {
	position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Alerts */

.alert { border-radius: 10px; padding: 12px 16px; margin: 24px 0 0; font-size: 15px; }
.alert strong { display: block; }
.alert-ok { background: var(--ok-bg); color: var(--ok-text); }
.alert-err { background: var(--err-bg); color: var(--err-text); }

/* Form page */

.progress { display: flex; gap: 8px; margin: 32px 0 8px; padding: 0; list-style: none; font-size: 14px; color: var(--muted); }
.progress li { flex: 1; border-top: 4px solid var(--line); padding-top: 8px; }
.progress li.done, .progress li.current { border-color: var(--accent); }
.progress li.current { color: var(--text); font-weight: 600; }

.form-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; margin: 16px 0 24px; }
.form-head h1 { margin: 0; font-size: 30px; letter-spacing: -.02em; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
@media (min-width: 640px) { .card { padding: 24px 28px; } }
.card > legend, .card > h2 { font-size: 18px; font-weight: 700; padding: 0; margin: 0 0 4px; }
fieldset.card { min-width: 0; }
/* Floating the legend keeps it inside the card instead of on its border. */
fieldset.card > legend { float: left; width: 100%; margin-bottom: 4px; }
fieldset.card > legend + * { clear: both; }
.card .hint { color: var(--muted); font-size: 14px; margin: 0 0 16px; }

.grid { display: grid; gap: 14px 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid.two { grid-template-columns: 1fr 1fr; } }

.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 14px; font-weight: 600; }
.field label .req { color: var(--err-text); margin-left: 2px; }
.field small { color: var(--muted); font-size: 13px; }

input[type="text"], input[type="email"], input[type="tel"], textarea {
	width: 100%; min-height: 44px; padding: 10px 12px;
	border: 1px solid var(--line); border-radius: 10px;
	background: var(--bg); color: var(--text); font: inherit;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
input:user-invalid, textarea:user-invalid { border-color: var(--err-text); }

.entry { border-top: 1px dashed var(--line); padding-top: 16px; margin-top: 16px; }
.entry:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.entry-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 14px; color: var(--muted); font-weight: 600; }
.entry:only-of-type .remove { display: none; }

.add { margin-top: 16px; }

.choices { display: grid; gap: 10px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .choices { grid-template-columns: repeat(3, 1fr); } }
.choice {
	display: flex; gap: 10px; align-items: flex-start; cursor: pointer;
	padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg);
}
.choice:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.choice input { margin-top: 4px; accent-color: var(--accent); }
.choice span { display: flex; flex-direction: column; gap: 2px; }
.choice small { color: var(--muted); font-size: 13px; }
.employer { margin-top: 16px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.submit-bar { display: flex; flex-direction: column; gap: 10px; align-items: stretch; margin-top: 24px; }
.submit-bar p { margin: 0; color: var(--muted); font-size: 14px; text-align: center; }
@media (min-width: 640px) {
	.submit-bar { flex-direction: row; align-items: center; justify-content: space-between; }
	.submit-bar p { text-align: left; }
}
