/* Mediason Lab — theme tối: glow xanh lá + indigo, Outfit + Space Mono */
:root {
	--nav-h: 64px;
	--bg0: #050507;
	--bg1: #0a0a0d;
	--line: rgba(255, 255, 255, 0.09);
	--line-soft: rgba(255, 255, 255, 0.06);
	--panel: rgba(255, 255, 255, 0.035);
	--panel-hi: rgba(255, 255, 255, 0.055);
	--text: #ececf2;
	--muted: #a2a2ae;
	--dim: #6d6d7a;
	--green: #94e571;
	--green-deep: #397d2d;
	--indigo: #818cf8;
	--radius: 20px;
	--font: 'Outfit', system-ui, -apple-system, sans-serif;
	--mono: 'Space Mono', ui-monospace, 'Cascadia Mono', monospace;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
	margin: 0;
	font-family: var(--font);
	font-weight: 400;
	color: var(--text);
	background:
		radial-gradient(ellipse 90% 55% at 50% -20%, rgba(148, 229, 113, 0.13), transparent 60%),
		radial-gradient(circle at 88% 4%, rgba(129, 140, 248, 0.11), transparent 32%),
		linear-gradient(180deg, var(--bg1), var(--bg0) 480px);
	background-attachment: fixed;
	min-height: 100vh;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}
/* lưới mờ phủ toàn trang */
body::before {
	content: '';
	position: fixed;
	inset: 0;
	z-index: -1;
	background:
		linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
	background-size: 44px 44px;
	mask-image: radial-gradient(ellipse 100% 70% at 50% 0%, #000 30%, transparent 75%);
	pointer-events: none;
}
a { color: inherit; }
img { display: block; max-width: 100%; }
::selection { background: rgba(148, 229, 113, 0.28); }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 22px; }
.mono { font-family: var(--mono); }

/* ---------- nav ---------- */
.nav {
	position: fixed;
	top: 0; left: 0; right: 0;
	z-index: 50;
	height: var(--nav-h);
	border-bottom: 1px solid transparent;
	transition: border-color 0.2s, background 0.2s;
}
.nav.solid {
	background: rgba(7, 7, 9, 0.82);
	backdrop-filter: blur(14px);
	-webkit-backdrop-filter: blur(14px);
	border-bottom-color: var(--line-soft);
}
.nav-in {
	max-width: 1080px;
	margin: 0 auto;
	height: 100%;
	padding: 0 22px;
	display: flex;
	align-items: center;
	gap: 26px;
}
.brand {
	display: flex;
	align-items: center;
	gap: 10px;
	font-weight: 700;
	font-size: 1.02rem;
	letter-spacing: -0.02em;
	text-decoration: none;
}
.brand-dot {
	width: 26px; height: 26px;
	border-radius: 8px;
	background: linear-gradient(135deg, var(--green), var(--indigo));
	box-shadow: 0 0 22px rgba(148, 229, 113, 0.4);
	display: grid;
	place-items: center;
}
.brand-dot svg { width: 14px; height: 14px; }
.nav-links { display: flex; gap: 4px; margin-left: auto; }
.nav-links a {
	font-size: 0.9rem;
	color: var(--muted);
	text-decoration: none;
	padding: 7px 13px;
	border-radius: 999px;
	transition: color 0.15s, background 0.15s;
}
.nav-links a:hover { color: var(--text); background: var(--panel-hi); }
.nav-links a.on { color: var(--green); }

/* ---------- hero ---------- */
.hero {
	position: relative;
	text-align: center;
	padding: calc(var(--nav-h) + 76px) 20px 70px;
}
.hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background:
		radial-gradient(ellipse 75% 50% at 50% -12%, rgba(148, 229, 113, 0.16), transparent 58%),
		radial-gradient(circle at 18% 0%, rgba(129, 140, 248, 0.12), transparent 30%);
	pointer-events: none;
}
.hero > * { position: relative; }
.eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-family: var(--mono);
	font-size: 0.76rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--green);
	border: 1px solid rgba(148, 229, 113, 0.32);
	background: rgba(148, 229, 113, 0.07);
	padding: 7px 15px;
	border-radius: 999px;
	margin-bottom: 26px;
}
.eyebrow::before {
	content: '';
	width: 7px; height: 7px;
	border-radius: 999px;
	background: var(--green);
	box-shadow: 0 0 12px var(--green);
}
.hero h1 {
	font-size: clamp(2.5rem, 5.6vw, 4.2rem);
	font-weight: 800;
	line-height: 1.04;
	letter-spacing: -0.045em;
	margin: 0 auto 20px;
	max-width: 16ch;
	background: linear-gradient(180deg, #ffffff 0%, #f1efff 34%, #aab4cc 100%);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
}
.hero h1 em {
	font-style: normal;
	background: linear-gradient(120deg, var(--green), var(--indigo));
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
}
.hero .lede {
	font-size: 1.1rem;
	color: var(--muted);
	max-width: 58ch;
	margin: 0 auto 32px;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/* ---------- nút ---------- */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	min-height: 46px;
	padding: 12px 26px;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, 0.12);
	background: linear-gradient(135deg, #ffffff, #eef0ff);
	color: #0a0a0d;
	font-family: var(--font);
	font-weight: 700;
	font-size: 0.95rem;
	text-decoration: none;
	cursor: pointer;
	box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25);
	transition: transform 0.12s, box-shadow 0.2s, background 0.2s;
}
.btn:hover { background: var(--green); color: #061c07; transform: translateY(-1px); }
.btn:active { transform: scale(0.98); }
.btn-ghost {
	background: var(--panel);
	color: var(--text);
	box-shadow: none;
}
.btn-ghost:hover { background: var(--panel-hi); color: var(--green); border-color: rgba(148, 229, 113, 0.4); }
.btn-sm { min-height: 38px; padding: 8px 18px; font-size: 0.88rem; }
.btn[disabled] { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn-green {
	background: linear-gradient(135deg, #4d963b, var(--green-deep));
	color: #fff;
	border-color: rgba(148, 229, 113, 0.35);
}
.btn-green:hover { background: linear-gradient(135deg, #5cab45, #438a36); color: #fff; }

/* ---------- section ---------- */
section { padding: 34px 0; }
.sec-head { text-align: center; margin-bottom: 38px; }
.sec-head .kicker {
	font-family: var(--mono);
	font-size: 0.74rem;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--indigo);
}
.sec-head h2 {
	font-size: clamp(1.7rem, 3.4vw, 2.4rem);
	font-weight: 800;
	letter-spacing: -0.03em;
	margin: 10px 0 12px;
}
.sec-head p { color: var(--muted); max-width: 56ch; margin: 0 auto; }

/* ---------- lưới tool ---------- */
.tools {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 16px;
}
.tcard {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 26px 24px 22px;
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: linear-gradient(180deg, var(--panel-hi), var(--panel));
	text-decoration: none;
	overflow: hidden;
	transition: transform 0.18s, border-color 0.18s, box-shadow 0.18s;
}
.tcard::before {
	content: '';
	position: absolute;
	inset: 0;
	background: radial-gradient(circle at 50% -30%, rgba(148, 229, 113, 0.14), transparent 55%);
	opacity: 0;
	transition: opacity 0.2s;
	pointer-events: none;
}
.tcard:hover { transform: translateY(-3px); border-color: rgba(148, 229, 113, 0.4); box-shadow: 0 18px 44px rgba(0, 0, 0, 0.4); }
.tcard:hover::before { opacity: 1; }
.tcard > * { position: relative; }
.tcard .ticon {
	width: 46px; height: 46px;
	border-radius: 14px;
	display: grid;
	place-items: center;
	background: rgba(148, 229, 113, 0.1);
	border: 1px solid rgba(148, 229, 113, 0.28);
	color: var(--green);
}
.tcard.ti-indigo .ticon { background: rgba(129, 140, 248, 0.1); border-color: rgba(129, 140, 248, 0.3); color: var(--indigo); }
.tcard h3 { margin: 0; font-size: 1.12rem; font-weight: 700; letter-spacing: -0.02em; }
.tcard p { margin: 0; font-size: 0.92rem; color: var(--muted); flex: 1; }
.tcard .tlink {
	font-family: var(--mono);
	font-size: 0.78rem;
	color: var(--green);
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.tcard.ti-indigo .tlink { color: var(--indigo); }
.tcard .tlink svg { transition: transform 0.15s; }
.tcard:hover .tlink svg { transform: translateX(3px); }

/* ---------- intro / cách hoạt động ---------- */
.intro-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 16px;
}
.icard {
	padding: 24px;
	border-radius: var(--radius);
	border: 1px solid var(--line-soft);
	background: var(--panel);
}
.icard .num {
	font-family: var(--mono);
	font-size: 0.8rem;
	color: var(--green);
	display: inline-grid;
	place-items: center;
	width: 30px; height: 30px;
	border: 1px solid rgba(148, 229, 113, 0.35);
	border-radius: 999px;
	margin-bottom: 14px;
}
.icard h3 { margin: 0 0 8px; font-size: 1.02rem; font-weight: 700; }
.icard p { margin: 0; font-size: 0.9rem; color: var(--muted); }
.note-card {
	margin-top: 18px;
	display: flex;
	gap: 14px;
	align-items: flex-start;
	padding: 20px 22px;
	border-radius: var(--radius);
	border: 1px solid rgba(129, 140, 248, 0.25);
	background: rgba(129, 140, 248, 0.06);
}
.note-card .nicon { color: var(--indigo); flex-shrink: 0; margin-top: 2px; }
.note-card p { margin: 0; font-size: 0.92rem; color: var(--muted); }
.note-card strong { color: var(--text); }

/* ---------- trang công cụ ---------- */
.tool-hero {
	position: relative;
	padding: calc(var(--nav-h) + 52px) 0 10px;
}
.tool-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background: radial-gradient(ellipse 70% 60% at 50% -20%, rgba(148, 229, 113, 0.13), transparent 60%);
	pointer-events: none;
}
.tool-hero > * { position: relative; }
.tool-hero .crumb {
	font-family: var(--mono);
	font-size: 0.74rem;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--dim);
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 18px;
}
.tool-hero .crumb b { color: var(--green); font-weight: 400; }
.tool-title { display: flex; align-items: center; gap: 16px; }
.tool-title .ticon {
	width: 54px; height: 54px;
	border-radius: 16px;
	display: grid;
	place-items: center;
	background: rgba(148, 229, 113, 0.1);
	border: 1px solid rgba(148, 229, 113, 0.28);
	color: var(--green);
	flex-shrink: 0;
}
.tool-title h1 { margin: 0; font-size: clamp(1.7rem, 3.6vw, 2.5rem); font-weight: 800; letter-spacing: -0.03em; }
.tool-hero .lede { color: var(--muted); max-width: 62ch; margin: 14px 0 0; }

.panel {
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: linear-gradient(180deg, var(--panel-hi), var(--panel));
	padding: 22px;
	margin: 18px 0;
}
.panel-h {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 14px;
}
.panel-h h2 { margin: 0; font-size: 1rem; font-weight: 700; letter-spacing: -0.01em; }
.panel-h .hint { font-size: 0.8rem; color: var(--dim); font-family: var(--mono); }

.field { display: flex; gap: 10px; flex-wrap: wrap; }
.field input[type='text'],
.field input[type='url'],
.field textarea {
	flex: 1;
	min-width: 240px;
	background: rgba(0, 0, 0, 0.32);
	border: 1px solid var(--line);
	border-radius: 12px;
	color: var(--text);
	font-family: var(--mono);
	font-size: 0.86rem;
	padding: 13px 15px;
	outline: none;
	transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus,
.field textarea:focus { border-color: rgba(148, 229, 113, 0.5); box-shadow: 0 0 0 3px rgba(148, 229, 113, 0.12); }
.field textarea { resize: vertical; min-height: 74px; width: 100%; }

.status {
	font-family: var(--mono);
	font-size: 0.82rem;
	color: var(--dim);
	min-height: 1.4em;
	margin-top: 12px;
}
.status.err { color: #ff9c9c; }
.status.ok { color: var(--green); }

/* kết nối tài khoản */
.acct { border-style: dashed; }
.acct-head { display: flex; align-items: center; gap: 10px; }
.acct-dot { width: 9px; height: 9px; border-radius: 999px; background: var(--dim); }
.acct-dot.on { background: var(--green); box-shadow: 0 0 10px var(--green); }
.acct-head .lbl { font-size: 0.9rem; font-weight: 600; }
.acct-head .sub { font-size: 0.8rem; color: var(--dim); margin-left: auto; font-family: var(--mono); }
.acct-body { display: none; margin-top: 14px; }
.acct.open .acct-body { display: block; }
.acct .chev { transition: transform 0.18s; color: var(--dim); }
.acct.open .chev { transform: rotate(180deg); }
.acct-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.acct-tip { font-size: 0.8rem; color: var(--dim); margin-top: 10px; }
.acct-tip code { font-family: var(--mono); color: var(--indigo); font-size: 0.78rem; }

/* kết quả bài hát */
.song {
	display: flex;
	gap: 16px;
	align-items: center;
	padding: 16px;
	border: 1px solid var(--line-soft);
	border-radius: 16px;
	background: rgba(0, 0, 0, 0.24);
	margin-top: 16px;
}
.song img {
	width: 74px; height: 74px;
	border-radius: 12px;
	object-fit: cover;
	border: 1px solid var(--line);
}
.song .s-meta { min-width: 0; flex: 1; }
.song .s-title { font-weight: 700; font-size: 1.02rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.song .s-sub { font-family: var(--mono); font-size: 0.76rem; color: var(--dim); margin-top: 4px; }
.dl-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }

/* danh sách stem */
.stem-row {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 13px 16px;
	border: 1px solid var(--line-soft);
	border-radius: 14px;
	background: rgba(0, 0, 0, 0.24);
	margin-top: 10px;
}
.stem-row .st-ic {
	width: 38px; height: 38px;
	border-radius: 10px;
	display: grid;
	place-items: center;
	background: rgba(129, 140, 248, 0.09);
	border: 1px solid rgba(129, 140, 248, 0.25);
	color: var(--indigo);
	flex-shrink: 0;
}
.stem-row .st-name { font-weight: 600; font-size: 0.94rem; flex: 1; min-width: 0; }
.stem-row .st-badge {
	font-family: var(--mono);
	font-size: 0.7rem;
	padding: 4px 10px;
	border-radius: 999px;
	border: 1px solid var(--line);
	color: var(--dim);
}
.stem-row .st-badge.done { color: var(--green); border-color: rgba(148, 229, 113, 0.35); }

/* lyrics */
.lyrics-box {
	background: rgba(0, 0, 0, 0.3);
	border: 1px solid var(--line-soft);
	border-radius: 14px;
	padding: 20px 22px;
	margin-top: 16px;
	max-height: 520px;
	overflow: auto;
	font-size: 0.95rem;
	line-height: 1.9;
	white-space: pre-wrap;
}
.lyrics-box .lrow { display: flex; gap: 14px; }
.lyrics-box .lrow time {
	font-family: var(--mono);
	font-size: 0.74rem;
	color: var(--indigo);
	min-width: 5.2em;
	padding-top: 0.35em;
}
.empty {
	text-align: center;
	padding: 44px 20px;
	border: 1px dashed var(--line);
	border-radius: var(--radius);
	color: var(--dim);
	font-size: 0.9rem;
	margin-top: 16px;
}
.empty svg { opacity: 0.5; margin-bottom: 10px; }

/* extension */
.ext-hero {
	display: grid;
	grid-template-columns: 1.1fr 0.9fr;
	gap: 34px;
	align-items: center;
	margin: 26px 0 8px;
}
@media (max-width: 820px) { .ext-hero { grid-template-columns: 1fr; } }
.badge-soon {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-family: var(--mono);
	font-size: 0.72rem;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--indigo);
	border: 1px solid rgba(129, 140, 248, 0.4);
	background: rgba(129, 140, 248, 0.08);
	padding: 6px 13px;
	border-radius: 999px;
}
.badge-soon::before { content: ''; width: 6px; height: 6px; border-radius: 999px; background: var(--indigo); box-shadow: 0 0 10px var(--indigo); }
.feat { display: grid; gap: 12px; margin-top: 22px; }
.feat li {
	list-style: none;
	display: flex;
	gap: 12px;
	align-items: flex-start;
	font-size: 0.94rem;
	color: var(--muted);
}
.feat li::before {
	content: '';
	width: 8px; height: 8px;
	margin-top: 0.45em;
	border-radius: 999px;
	background: linear-gradient(135deg, var(--green), var(--indigo));
	box-shadow: 0 0 14px rgba(148, 229, 113, 0.4);
	flex-shrink: 0;
}
.mock {
	border: 1px solid var(--line);
	border-radius: var(--radius);
	background: linear-gradient(180deg, var(--panel-hi), var(--panel));
	padding: 18px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}
.mock-bar { display: flex; gap: 7px; margin-bottom: 14px; }
.mock-bar i { width: 10px; height: 10px; border-radius: 999px; background: var(--line); }
.mock-pop {
	border: 1px solid var(--line-soft);
	border-radius: 14px;
	background: rgba(0, 0, 0, 0.35);
	padding: 16px;
}
.mock-pop .mp-title { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 0.9rem; margin-bottom: 12px; }
.mock-pop .mp-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line-soft); border-radius: 10px; margin-top: 8px; font-size: 0.82rem; color: var(--muted); }
.mock-pop .mp-row .mp-ic { color: var(--green); }
.mock-btn { display: block; width: 100%; text-align: center; margin-top: 12px; padding: 10px; border-radius: 999px; background: linear-gradient(135deg, var(--green), #6fc44f); color: #06230a; font-weight: 700; font-size: 0.85rem; }

/* ---------- footer ---------- */
footer {
	border-top: 1px solid var(--line-soft);
	margin-top: 60px;
	padding: 34px 0 44px;
}
.foot { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; justify-content: space-between; }
.foot .f-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 0.95rem; }
.foot .f-brand .brand-dot { width: 22px; height: 22px; border-radius: 7px; }
.foot nav { display: flex; gap: 18px; }
.foot nav a { font-size: 0.84rem; color: var(--dim); text-decoration: none; }
.foot nav a:hover { color: var(--green); }
.foot .f-note { font-family: var(--mono); font-size: 0.72rem; color: var(--dim); width: 100%; }

/* responsive */
@media (max-width: 640px) {
	.nav-links { gap: 0; }
	.nav-links a { padding: 7px 9px; font-size: 0.82rem; }
	.brand span { display: none; }
	.tool-title .ticon { width: 44px; height: 44px; }
	.song img { width: 58px; height: 58px; }
}
