/* SoulTag — luxury front-end styles for the whole journey (v1.8). */

:root {
	--st-bg: #F2E9DA;
	--st-card: #FBF6EC;
	--st-ink: #33271A;
	--st-muted: #6E6151;
	--st-brown: #5A4226;     /* espresso */
	--st-accent: #9A7637;    /* antique gold */
	--st-gold: #C2A35B;      /* light gold */
	--st-line: rgba(154,118,55,.24);
	--st-danger: #A6402C;
	--st-radius: 6px;
	--st-shadow: 0 30px 70px -38px rgba(60,40,15,.55);
	--st-head: 'Cormorant Garamond', Georgia, serif;
	--st-body: 'EB Garamond', Georgia, serif;
	--st-ui: 'Inter', -apple-system, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }

html, body.soultag-body {
	margin: 0; padding: 0;
	color: var(--st-ink);
	font-family: var(--st-body);
	font-size: 18px;
	min-height: 100vh;
	display: flex; flex-direction: column;
	-webkit-font-smoothing: antialiased;
	/* Fine wallpaper: soft sheen + edge vignette + delicate gold trellis. */
	background-color: var(--st-bg);
	background-image:
		radial-gradient(135% 75% at 50% -10%, rgba(255,255,255,.45), rgba(255,255,255,0) 55%),
		radial-gradient(120% 60% at 50% 112%, rgba(70,45,15,.10), rgba(0,0,0,0) 60%),
		url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='46'%20height='46'%3E%3Cpath%20d='M23%201%2045%2023%2023%2045%201%2023z'%20fill='none'%20stroke='%239a7637'%20stroke-opacity='0.09'/%3E%3Ccircle%20cx='23'%20cy='23'%20r='1.4'%20fill='%239a7637'%20fill-opacity='0.10'/%3E%3C/svg%3E");
	background-position: center top, center bottom, center;
	background-repeat: no-repeat, no-repeat, repeat;
	background-size: auto, auto, 46px 46px;
	background-attachment: fixed, fixed, fixed;
}

.soultag-shell { flex: 1; display: flex; align-items: center; justify-content: center; padding: 32px 18px; }

/* ===== Card ============================================================ */
.st-card {
	position: relative;
	background: var(--st-card);
	border: 1px solid var(--st-line);
	border-radius: var(--st-radius);
	box-shadow: var(--st-shadow);
	max-width: 470px; width: 100%;
	padding: 44px 38px;
	text-align: center;
}
.st-card::before { /* thin gold rule across the top */
	content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px;
	background: linear-gradient(90deg, transparent, var(--st-gold), var(--st-accent), var(--st-gold), transparent);
	border-radius: var(--st-radius) var(--st-radius) 0 0;
}
.st-card-wide { max-width: 740px; }

.st-brand {
	font-family: var(--st-ui);
	font-size: 12px; letter-spacing: .34em; text-transform: uppercase;
	color: var(--st-accent); font-weight: 600; margin-bottom: 12px;
}
.st-card h1 {
	font-family: var(--st-head); font-weight: 600;
	font-size: 38px; line-height: 1.12; margin: 6px 0 10px;
	color: var(--st-brown); letter-spacing: .01em;
}
.st-tagline { font-family: var(--st-head); font-style: italic; font-size: 19px; color: var(--st-muted); margin: 0 0 24px; }
.st-card p { color: var(--st-muted); line-height: 1.6; }

/* ===== Fields & buttons =============================================== */
.st-field {
	width: 100%; padding: 14px 16px; font-size: 16px;
	font-family: var(--st-ui);
	border: 1px solid var(--st-line); border-radius: 8px;
	margin: 10px 0; background: #fffdf8; color: var(--st-ink);
}
.st-field:focus { outline: none; border-color: var(--st-gold); box-shadow: 0 0 0 3px rgba(194,163,91,.22); }
.st-textarea { resize: vertical; min-height: 120px; font-family: var(--st-body); font-size: 18px; line-height: 1.5; }

.st-btn {
	display: inline-block; width: 100%;
	padding: 15px 22px; font-size: 15px; font-weight: 600;
	font-family: var(--st-ui); letter-spacing: .02em;
	color: #fff8ec; background: linear-gradient(180deg, #6b4f2c, var(--st-brown));
	border: none; border-radius: 8px; cursor: pointer; margin-top: 10px;
	text-decoration: none; transition: transform .05s ease, filter .15s ease;
	box-shadow: 0 12px 26px -14px rgba(50,32,10,.7);
}
.st-btn:hover { filter: brightness(1.08); color: #fff8ec; }
.st-btn:active { transform: translateY(1px); }
.st-btn-ghost {
	background: transparent; color: var(--st-brown);
	border: 1px solid var(--st-line); box-shadow: none;
}
.st-btn-ghost:hover { color: var(--st-brown); background: #f6efe0; }

.st-consent {
	display: flex; gap: 10px; text-align: left; align-items: flex-start;
	background: #f7f0e2; border: 1px solid var(--st-line); border-radius: 10px;
	padding: 14px; margin: 18px 0; font-size: 15px; color: var(--st-ink); font-family: var(--st-ui);
}
.st-consent input { margin-top: 4px; }
.st-error { background: #f7e7e1; border: 1px solid #e3b6a8; color: var(--st-danger); border-radius: 8px; padding: 11px 14px; font-size: 14px; margin-bottom: 14px; text-align: left; font-family: var(--st-ui); }
.st-note { font-size: 13px; color: var(--st-muted); margin-top: 18px; font-family: var(--st-ui); }
.st-icon { font-size: 40px; margin-bottom: 6px; }

/* ===== Step pills ====================================================== */
.st-steps { display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.st-step { font-family: var(--st-ui); font-size: 11px; letter-spacing: .06em; color: var(--st-muted); background: #f1e7d5; border: 1px solid var(--st-line); border-radius: 999px; padding: 5px 13px; }
.st-step-on { color: #fff8ec; background: var(--st-brown); border-color: var(--st-brown); }
.st-step-done { color: var(--st-accent); background: #fff; }

/* ===== Pick grid (topics/templates) =================================== */
.st-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin-top: 22px; text-align: left; }
.st-grid-2 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.st-pick {
	display: flex; flex-direction: column; gap: 6px;
	background: #fffdf8; border: 1px solid var(--st-line); border-radius: 10px;
	padding: 20px 18px; cursor: pointer; font: inherit; text-align: left;
	transition: transform .07s ease, border-color .15s ease, box-shadow .15s ease;
}
.st-pick:hover { border-color: var(--st-gold); box-shadow: 0 14px 30px -18px rgba(90,55,15,.5); transform: translateY(-3px); }
.st-pick-icon { font-size: 30px; }
.st-pick-title { font-family: var(--st-head); font-weight: 600; color: var(--st-brown); font-size: 21px; }
.st-pick-desc { color: var(--st-muted); font-size: 14px; line-height: 1.5; }

.st-swatch { position: relative; display: block; height: 96px; border-radius: 6px; border: 1px solid var(--st-line); overflow: hidden; margin-bottom: 10px; padding: 12px; }
.st-swatch-dot { display: inline-block; width: 18px; height: 18px; border-radius: 50%; margin-right: 6px; vertical-align: top; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.st-swatch-bar { display: block; height: 8px; width: 70%; border-radius: 6px; margin-top: 12px; opacity: .9; }
.st-swatch-bar-short { width: 45%; margin-top: 7px; opacity: .7; }

/* ===== Build hub blocks =============================================== */
.st-blocks { text-align: left; margin: 20px 0 8px; }
.st-block { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: #fffdf8; border: 1px solid var(--st-line); border-radius: 10px; padding: 16px 18px; margin-bottom: 10px; }
.st-block-main { display: flex; align-items: center; gap: 12px; }
.st-block-ico { font-size: 26px; }
.st-block-main strong { font-family: var(--st-head); font-size: 19px; color: var(--st-brown); }
.st-block-sub { color: var(--st-muted); font-size: 13px; font-family: var(--st-ui); }

/* ===== Question wizard =============================================== */
.st-progress { height: 7px; background: #ece1cd; border-radius: 999px; overflow: hidden; margin: 4px 0 8px; }
.st-progress-bar { height: 100%; background: linear-gradient(90deg, var(--st-gold), var(--st-accent)); border-radius: 999px; transition: width .3s ease; }
.st-progress-label { font-family: var(--st-ui); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--st-muted); margin: 0 0 18px; }
.st-question { font-family: var(--st-head); font-weight: 500; font-size: 30px; line-height: 1.2; color: var(--st-brown); }
.st-wizard-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; }
.st-link { font-family: var(--st-ui); color: var(--st-accent); text-decoration: none; font-weight: 600; font-size: 14px; }
.st-link:hover { color: var(--st-gold); }
.st-card .st-btn + .st-btn { margin-top: 10px; }

/* ===== Photo upload ================================================== */
.st-photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin: 18px 0; }
.st-photo-tile { position: relative; aspect-ratio: 1/1; border-radius: 4px; overflow: hidden; border: 1px solid var(--st-line); background: #efe4d2; box-shadow: 0 8px 18px -12px rgba(60,40,15,.6); }
.st-photo-tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.st-photo-del { position: absolute; top: 5px; right: 5px; width: 24px; height: 24px; border-radius: 50%; border: none; background: rgba(30,18,8,.66); color: #fff; font-size: 16px; line-height: 1; cursor: pointer; }
.st-photo-del:hover { background: var(--st-danger); }
.st-upload-status, .st-rec-status { font-family: var(--st-ui); font-size: 13px; color: var(--st-muted); min-height: 18px; margin: 8px 0; }
.st-upload-error { color: var(--st-danger) !important; }
.st-disabled { opacity: .5; pointer-events: none; }

/* ===== Voice recorder ================================================ */
.st-timer { font-family: var(--st-head); font-size: 44px; color: var(--st-brown); margin: 10px 0; font-variant-numeric: tabular-nums; }
.st-rec-controls { display: flex; flex-direction: column; gap: 8px; }

/* ===== Living Cover (Gold) =========================================== */
.st-living { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--st-line); text-align: center; }
.st-living-h { font-family: var(--st-head); font-size: 22px; color: var(--st-brown); margin: 0 0 4px; }
.st-living-h span { font-family: var(--st-ui); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; background: linear-gradient(180deg, var(--st-gold), var(--st-accent)); color: #1c1407; padding: 3px 9px; border-radius: 999px; vertical-align: middle; margin-left: 6px; }
.st-living-preview { width: 100%; max-height: 280px; border-radius: 10px; margin: 10px 0; background: #000; }

/* ===== My Vault items =============================================== */
.st-vault-item { border-bottom: 1px solid var(--st-line); padding-bottom: 12px; margin-bottom: 12px; }
.st-vault-item:last-child { border-bottom: none; }
.st-vault-pres { font-size: 13px; color: var(--st-muted); margin: 0 0 4px; font-family: var(--st-ui); }
.st-vault-renew { display: flex; gap: 14px; justify-content: center; }

/* ===== Memory Song picker =========================================== */
.st-song { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--st-line); text-align: center; }
.st-song-lbl { display: block; font-family: var(--st-ui); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--st-muted); margin: 16px 0 6px; text-align: left; }
.st-song-pick { display: flex; gap: 8px; align-items: center; }
.st-song-pick select { flex: 1; }
.st-song-current { background: #f7f0e2; border: 1px solid var(--st-line); border-radius: 10px; padding: 14px; margin-bottom: 12px; text-align: left; font-size: 14px; }

/* ===== Footer ======================================================== */
.soultag-footer { text-align: center; padding: 22px; font-family: var(--st-ui); font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--st-muted); }

@media (max-width: 480px) {
	.st-card { padding: 34px 24px; }
	.st-card h1 { font-size: 31px; }
	.st-question { font-size: 25px; }
	.st-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
	.st-grid-2 { grid-template-columns: 1fr; }
	.st-pick { padding: 15px 13px; }
	.st-pick-icon { font-size: 26px; }
	.st-photo-grid { grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); }
}
