/* Legal pages, legal forms and the contact page (LEGAL-SEO team). Uses dl.css tokens only. */

/* ---------- hero ---------- */
.lg-hero { padding: var(--dl-s6) 0 var(--dl-s6); }
@media (min-width: 960px) { .lg-hero { padding: var(--dl-s7) 0; } }
.lg-hero__title { font-size: clamp(2rem, 1.3rem + 2.6vw, 3.25rem); max-width: 18ch; }
.lg-hero__lead { max-width: 62ch; }
.lg-meta { list-style: none; margin: var(--dl-s4) 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--dl-s2); }
.lg-meta li { font-size: var(--dl-fs-sm); font-weight: 600; color: var(--dl-paper); border: 1px solid var(--dl-line-dark); border-radius: var(--dl-r-pill); padding: 4px 14px; }

/* ---------- tabs: one per legal page ---------- */
.lg-tabs { background: var(--dl-paper); border-bottom: 1px solid var(--dl-line); }
.lg-tabs__list { list-style: none; margin: 0; padding: var(--dl-s3) 0; display: flex; gap: var(--dl-s2); overflow-x: auto; scrollbar-width: thin; }
.lg-tabs__list li { flex: none; }
.lg-tabs__link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 var(--dl-s4); border-radius: var(--dl-r-pill); border: 1px solid var(--dl-line); background: var(--dl-card); color: var(--dl-ink); font-size: var(--dl-fs-sm); font-weight: 600; text-decoration: none; white-space: nowrap; }
.lg-tabs__link:hover { border-color: var(--dl-ink); text-decoration: none; }
.lg-tabs__link[aria-current="page"] { background: var(--dl-ink); border-color: var(--dl-ink); color: var(--dl-paper); }

/* ---------- two columns: sticky contents + section cards ---------- */
.lg-area { padding: var(--dl-s5) 0 var(--dl-s7); }
.lg-wrap { display: grid; gap: var(--dl-s5); }
@media (min-width: 960px) {
	.lg-area { padding: var(--dl-s6) 0 var(--dl-s8); }
	.lg-wrap { grid-template-columns: 280px minmax(0, 1fr); gap: var(--dl-s6); align-items: start; }
	.lg-aside { position: sticky; top: var(--dl-s4); max-height: calc(100vh - 2 * var(--dl-s4)); overflow-y: auto; scrollbar-width: thin; }
}
.lg-aside { display: flex; flex-direction: column; gap: var(--dl-s4); min-width: 0; }
.lg-aside__seller { font-size: var(--dl-fs-sm); }
.lg-aside__seller p { margin-bottom: var(--dl-s1); }
@media (max-width: 959.98px) { .lg-aside__seller { display: none; } }

.lg-toc__summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; min-height: 32px; font-family: var(--dl-font-head); font-weight: 700; color: var(--dl-ink); }
.lg-toc__summary::-webkit-details-marker { display: none; }
.lg-toc__summary::after { content: ''; width: 9px; height: 9px; border-right: 2px solid var(--dl-ink); border-bottom: 2px solid var(--dl-ink); transform: rotate(45deg); margin: -4px 4px 0 0; }
.lg-toc[open] > .lg-toc__summary::after { transform: rotate(-135deg); margin-top: 4px; }
.lg-toc[open] > .lg-toc__summary { margin-bottom: var(--dl-s2); }
.lg-toc__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.lg-toc__list a { display: flex; gap: var(--dl-s2); align-items: baseline; padding: 6px 8px; border-radius: 8px; font-size: var(--dl-fs-sm); line-height: 1.35; color: var(--dl-text); text-decoration: none; }
.lg-toc__list a:hover { background: var(--dl-paper); color: var(--dl-ink); text-decoration: underline; }
.lg-toc__list a[aria-current] { background: var(--dl-mint-tint); color: var(--dl-ink); box-shadow: inset 3px 0 0 var(--dl-mint-dark); }
.lg-toc__num { flex: none; min-width: 22px; font-family: var(--dl-font-mono); font-size: var(--dl-fs-xs); font-weight: 600; color: var(--dl-text); }
@media (min-width: 640px) and (max-width: 959.98px) { .lg-toc__list { display: grid; grid-template-columns: 1fr 1fr; } }
.lg-actions { display: flex; flex-direction: column; gap: var(--dl-s2); margin-top: var(--dl-s4); padding-top: var(--dl-s4); border-top: 1px solid var(--dl-line); }
.lg-toc + .lg-actions { margin-top: var(--dl-s4); }
.dl-card > .lg-actions:first-child { margin-top: 0; padding-top: 0; border-top: 0; }

.lg-body { display: flex; flex-direction: column; gap: var(--dl-s4); min-width: 0; }
.lg-section { background: var(--dl-card); border: 1px solid var(--dl-line); border-radius: var(--dl-r-lg); padding: var(--dl-s5); scroll-margin-top: var(--dl-s4); }
@media (min-width: 640px) { .lg-section { padding: var(--dl-s6); } }
.lg-section__title { display: flex; align-items: center; gap: var(--dl-s3); font-size: var(--dl-fs-xl); letter-spacing: -0.02em; line-height: 1.25; margin: 0 0 var(--dl-s4); }
.lg-section__num { flex: none; display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: var(--dl-r-sm); background: var(--dl-ink); color: var(--dl-paper); font-family: var(--dl-font-mono); font-size: var(--dl-fs-sm); font-weight: 600; letter-spacing: 0; }

/* ---------- legal text ---------- */
.lg-content { max-width: 72ch; color: var(--dl-text); }
.lg-content > :last-child { margin-bottom: 0; }
.lg-content h3 { font-size: var(--dl-fs-lg); margin: var(--dl-s5) 0 var(--dl-s2); }
.lg-content p, .lg-content li { line-height: 1.7; }
.lg-content ul, .lg-content ol { margin: 0 0 var(--dl-s4); padding-left: 1.3em; }
.lg-content li { margin-bottom: 6px; }
.lg-content li::marker { color: var(--dl-ink); }
.lg-content a { overflow-wrap: anywhere; }
.lg-content code { font-size: .9em; background: var(--dl-paper); border: 1px solid var(--dl-line); border-radius: 6px; padding: 1px 6px; color: var(--dl-ink); white-space: nowrap; }
.lg-content .legal-box { border: 1px solid var(--dl-line); border-left: 4px solid var(--dl-ink); background: var(--dl-paper); border-radius: var(--dl-r-sm); padding: var(--dl-s4); margin: 0 0 var(--dl-s4); }
.lg-content .legal-box > :last-child { margin-bottom: 0; }
.lg-content .legal-box ul { margin-bottom: var(--dl-s3); }
.lg-content table { width: 100%; border-collapse: collapse; margin: 0 0 var(--dl-s4); font-size: var(--dl-fs-sm); }
.lg-content th, .lg-content td { text-align: left; vertical-align: top; padding: 10px 12px; border: 1px solid var(--dl-line); line-height: 1.55; }
.lg-content thead th { background: var(--dl-ink); color: var(--dl-paper); border-color: var(--dl-ink); font-weight: 600; }
.lg-content tbody th { background: var(--dl-paper); color: var(--dl-ink); font-weight: 600; width: 38%; }
.lg-content tbody tr:nth-child(even) td { background: #FAF8F2; }
@media (max-width: 639.98px) {
	/* wide tables scroll sideways instead of squeezing the words */
	.lg-content table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
	.lg-content thead th, .lg-content td { min-width: 150px; }
	.lg-content tbody th { min-width: 130px; }
}
.lg-sal { display: block; width: 181px; height: 45px; background: #fff; border-radius: 6px; padding: 2px 6px; box-sizing: content-box; }

/* clause a lawyer must re-check (remove the mark when it is checked) */
.lg-verify { display: inline-block; background: var(--dl-orange); color: var(--dl-ink); font-family: var(--dl-font-mono); font-size: var(--dl-fs-xs); font-weight: 600; line-height: 1.4; padding: 0 6px; border-radius: 4px; letter-spacing: 0; }
.lg-verify-banner { margin: 0; }

/* closing contact card */
.lg-cta { margin-top: var(--dl-s2); }
.lg-cta p { max-width: 60ch; }
/* long labels ("Scrie-ne: contact@domeniuliber.ro") must wrap inside the card on 320-360px screens */
.lg-cta .dl-btn, .lg-actions .dl-btn { white-space: normal; max-width: 100%; text-align: center; overflow-wrap: anywhere; padding-block: var(--dl-s2); }

.lg-cta .lg-cta__mail { margin: var(--dl-s4) 0 0; font-size: var(--dl-fs-sm); overflow-wrap: anywhere; }
.lg-cta .lg-cta__mail a { font-family: var(--dl-font-mono); color: inherit; }
@media (max-width: 479px) { .lg-cta .dl-cluster > .dl-btn { flex: 1 1 100%; } }

/* ---------- legal forms (inside a section card) ---------- */
.lg-form { margin-top: var(--dl-s5); }
.lg-section .lg-form > form.dl-card { padding: 0; border: 0; background: transparent; border-radius: 0; }
.lg-textarea--sm { min-height: 96px; }
.lg-form .dl-check { margin: var(--dl-s2) 0 var(--dl-s4); }
.lg-form .dl-check span { color: var(--dl-ink); }

/* ---------- contact page ---------- */
.lg-contact h1 { font-size: var(--dl-fs-3xl); }
.lg-contact .dl-lead { max-width: 56ch; }
.lg-contact__side { display: flex; flex-direction: column; gap: var(--dl-s4); }
.lg-contact__addr { font-family: var(--dl-font-mono); font-size: var(--dl-fs-lg); font-weight: 600; overflow-wrap: anywhere; }
.lg-contact__addr a { color: var(--dl-mint); }
.lg-contact__small { font-size: var(--dl-fs-sm); }
.lg-contact .company-info p { font-size: var(--dl-fs-sm); margin-bottom: var(--dl-s1); }
.lg-links { list-style: none; margin: 0; padding: 0; }
.lg-links li { border-top: 1px solid var(--dl-line); }
.lg-links li:first-child { border-top: 0; }
.lg-links a { display: flex; justify-content: space-between; align-items: center; min-height: 44px; color: var(--dl-ink); font-weight: 600; text-decoration: none; }
.lg-links a::after { content: '→'; font-weight: 400; }
.lg-links a:hover { text-decoration: underline; }

/* ---------- print: the text only ---------- */
@media print {
	.lg-tabs, .lg-aside, .lg-cta, .lg-verify-banner, .dl-cookie, #dl-cookie { display: none !important; }
	.lg-hero { background: none !important; color: #000; padding: 0 0 12px; }
	.lg-hero .dl-kicker, .lg-hero h1, .lg-hero .dl-lead, .lg-meta li { color: #000 !important; border-color: #999; }
	.lg-area { padding: 0; }
	.lg-wrap { display: block; }
	.lg-section { border: 0; padding: 8px 0; background: none; }
	.lg-section__num { background: none; color: #000; border: 1px solid #000; }
	.lg-content { max-width: none; }
}
