/* SPDX-FileCopyrightText: 2026 lasse tech, Lars Gossard */
/* SPDX-License-Identifier: LicenseRef-Proprietary */

/* Page layout of account.palaver.social, taken over from the canvas "Palaver – Server mieten"
   (https://claude.ai/artifact/H7cVTbLi4EJX8HoA2c2wKf, rent.css). Sits on top of the Palaver design system (tokens.css + bundle.css) and uses its tokens only.
   Works without JavaScript: links, forms, <details>. One breakpoint at 700 px.
   Every :hover rule sits inside @media (hover: hover). */

.rent { position: relative; min-height: 100%; display: flex; flex-direction: column; background: var(--bg-200); color: var(--fg); font: 400 var(--pv-ts-body) var(--pv-sans); }
.rent *, .rent *::before, .rent *::after { box-sizing: border-box; }
.rent a { color: var(--brass-text); text-underline-offset: 2px; }
.rent a:focus-visible, .rent summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: var(--pv-radius-sm); }
.rent p { margin: 0; }
.rent-vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- Head ---- */
.rent-head { flex: none; display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-2) var(--space-5); min-height: 64px; padding: var(--space-2) var(--space-6); border-bottom: 1px solid var(--line); background: var(--bg-100); }
.rent-brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--fg) !important; text-decoration: none; font: 600 18px/24px var(--pv-display); }
.rent-brand__sub { padding-left: 10px; border-left: 1px solid var(--line-strong); font: 500 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-nav { display: flex; flex-wrap: wrap; gap: var(--space-1); }
.rent-nav a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 var(--space-3); border-radius: var(--pv-radius-md); color: var(--fg-muted); text-decoration: none; font: 500 var(--pv-ts-label) var(--pv-sans); }
.rent-nav a[aria-current="page"] { color: var(--fg); background: var(--bg-400); }
.rent-head__end { margin-left: auto; display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-3); }
.rent-user { font: 400 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-lang { display: inline-flex; border: 1px solid var(--line-strong); border-radius: var(--pv-radius-md); overflow: hidden; }
.rent-lang a { min-width: 44px; min-height: 36px; display: inline-flex; align-items: center; justify-content: center; font: 600 12px/16px var(--pv-sans); color: var(--fg-muted); text-decoration: none; }
.rent-lang a[aria-current="true"] { background: var(--bg-400); color: var(--fg); }
.rent-lang a:focus-visible { outline-offset: -2px; }

/* ---- Main ---- */
.rent-main { flex: 1 0 auto; padding: var(--space-6) var(--space-6) var(--space-7); }
.rent-wrap { width: 100%; max-width: 1120px; margin: 0 auto; }
.rent-mid { width: 100%; max-width: 760px; margin: 0 auto; }
.rent-narrow { width: 100%; max-width: 440px; margin: 0 auto; }
.rent-h1 { margin: 0; font: 600 var(--pv-ts-title-lg) var(--pv-display); letter-spacing: -0.01em; overflow-wrap: anywhere; }
.rent-h2 { margin: 0; font: 600 var(--pv-ts-title) var(--pv-display); }
.rent-h3 { margin: 0; font: 600 var(--pv-ts-h3) var(--pv-sans); }
.rent-pagehead { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); margin-bottom: var(--space-5); }
.rent-pagehead__sub { width: 100%; font: 400 var(--pv-ts-label) var(--pv-mono); color: var(--fg-muted); }
.rent-muted { color: var(--fg-muted); }
.rent-small { font: 400 var(--pv-ts-caption) var(--pv-sans); color: var(--fg-muted); }
.rent-mono { font-family: var(--pv-mono); }
.rent-strong { font-weight: 600; color: var(--fg); }

/* ---- Cards, actions ---- */
.rent-card { background: var(--bg-300); border: 1px solid var(--line); border-radius: var(--pv-radius-lg); padding: var(--space-5); display: flex; flex-direction: column; gap: var(--space-4); min-width: 0; }
.rent-card__head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); }
.rent-card__head .rent-h3 { flex: 1 1 auto; }
.rent-title { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.rent-card__head .rent-title { flex: 1 1 auto; }
.rent-subtitle { font: 400 var(--pv-ts-body) var(--pv-sans); color: var(--fg-muted); }
.rent-table .rent-subtitle { font: 400 var(--pv-ts-caption) var(--pv-sans); }
.rent-card--fixed { border-color: var(--line-strong); }
.rent-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; }
.rent-actions--end { justify-content: flex-end; }
.rent-actions--fill > .pv-btn { flex: 1 1 auto; }
.rent-sep { height: 1px; border: 0; margin: 0; background: var(--line); }
.rent-linkbtn { display: inline-flex; align-items: center; gap: var(--space-1); min-height: 36px; font: 500 var(--pv-ts-label) var(--pv-sans); }
a.pv-btn { text-decoration: none; }
.rent .pv-btn--primary.rent-btn-lg { height: 48px; font-size: 15px; padding: 0 var(--space-5); }

/* ---- Dashboard grid: two columns; on a phone one column in a fixed order ---- */
.rent-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: var(--space-5); align-items: start; }
.rent-col { display: flex; flex-direction: column; gap: var(--space-5); min-width: 0; }

/* ---- Facts ---- */
.rent-facts { margin: 0; display: grid; grid-template-columns: minmax(120px, max-content) minmax(0, 1fr); gap: var(--space-2) var(--space-5); font: 400 var(--pv-ts-label) var(--pv-sans); }
.rent-facts dt { color: var(--fg-muted); }
.rent-facts dd { margin: 0; color: var(--fg); overflow-wrap: anywhere; }

/* ---- Alerts: boxed, an icon, a title, one line, actions ---- */
.rent-alert { display: flex; align-items: flex-start; gap: var(--space-3); padding: var(--space-3) var(--space-4); border: 1px solid var(--line-strong); border-radius: var(--pv-radius-md); background: var(--bg-300); }
.rent-alert__icon { flex: none; display: flex; margin-top: 1px; color: var(--fg-muted); }
.rent-alert__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rent-alert__title { font: 600 var(--pv-ts-label) var(--pv-sans); color: var(--fg); }
.rent-alert__text { font: 400 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-alert .rent-actions { margin-top: var(--space-2); }
.rent-alert--warn { border-color: var(--brass); }
.rent-alert--warn .rent-alert__icon { color: var(--brass-text); }
.rent-alert--danger { border-color: var(--live); }
.rent-alert--danger .rent-alert__icon { color: var(--live); }
.rent-alert--ok .rent-alert__icon { color: var(--pulse-text); }

/* ---- Lifecycle: beantragt → freigegeben → Testphase → aktiv ---- */
.rent-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-2); }
.rent-step { position: relative; display: flex; flex-direction: column; gap: 2px; padding-top: 14px; font: 500 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-step::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; border-radius: var(--radius-pill); background: var(--bg-400); }
.rent-step--done::before, .rent-step--now::before { background: var(--brass); }
.rent-step--now { color: var(--fg); font-weight: 600; }
.rent-step__label { display: inline-flex; align-items: center; gap: 4px; }
.rent-step__when { font: 400 var(--pv-ts-caption) var(--pv-sans); color: var(--fg-muted); }
.rent-steps--off .rent-step::before { background: var(--bg-400); }
.rent-steps--off .rent-step { color: var(--fg-subtle); }

/* ---- Status line ---- */
.rent-status { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); }
.rent-status__text { font: 500 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-days { display: flex; flex-direction: column; gap: 6px; }
.rent-days__row { display: flex; justify-content: space-between; gap: var(--space-3); font: 500 var(--pv-ts-label) var(--pv-sans); }

/* ---- Invite code, command ---- */
.rent-code { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-2) var(--space-2) var(--space-2) var(--space-4); min-height: 48px; background: var(--bg-100); border: 1px solid var(--line); border-radius: var(--pv-radius-md); }
.rent-code pre, .rent-code code { flex: 1; min-width: 0; margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font: 400 var(--pv-ts-code) var(--pv-mono); color: var(--fg); }

/* ---- Plan, price ---- */
.rent-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 var(--space-2); }
.rent-price__amount { font: 700 48px/52px var(--pv-display); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.rent-price__per { font: 500 var(--pv-ts-body) var(--pv-sans); color: var(--fg-muted); }
.rent-price--sm .rent-price__amount { font-size: 28px; line-height: 34px; }
.rent-checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--space-2); font: 400 var(--pv-ts-label) var(--pv-sans); }
.rent-checks li { display: flex; align-items: flex-start; gap: var(--space-2); }
.rent-checks .pv-icon { flex: none; color: var(--pulse-text); margin-top: 1px; }
.rent-plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--space-5); align-items: start; }
.rent-plan { background: var(--bg-300); border: 1px solid var(--line-strong); border-radius: var(--pv-radius-lg); padding: var(--space-6); display: flex; flex-direction: column; gap: var(--space-4); }
.rent-plan__head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); flex-wrap: wrap; }
.rent-plan .pv-seg { display: flex; width: 100%; }
.rent-plan .pv-seg__opt { flex: 1 1 0; }
.rent-plan__cta { width: 100%; }
.rent-plan__foot { display: flex; flex-direction: column; align-items: center; gap: var(--space-2); text-align: center; }



/* ---- Forms ---- */
.rent-form { display: flex; flex-direction: column; gap: var(--space-5); }
.rent-textarea { height: auto; min-height: 104px; padding-top: var(--space-2); padding-bottom: var(--space-2); resize: vertical; line-height: 20px; }
.rent-sub { display: flex; align-items: stretch; min-height: var(--pv-h-control); border: 1px solid var(--line-strong); border-radius: var(--pv-radius-md); background: var(--bg-300); }
.rent-sub:focus-within { outline: 2px solid var(--focus); outline-offset: 2px; }
.rent-sub .pv-input { flex: 1; min-width: 0; height: auto; border: 0; border-radius: var(--pv-radius-md) 0 0 var(--pv-radius-md); background: transparent; font-family: var(--pv-mono); }
.rent-sub .pv-input:focus, .rent-sub .pv-input:focus-visible { outline: none; box-shadow: none; }
.rent-sub__suffix { flex: none; display: flex; align-items: center; padding: 0 var(--space-3); border-left: 1px solid var(--line); font: 400 var(--pv-ts-label) var(--pv-mono); color: var(--fg-muted); }
.rent-sub--bad { border-color: var(--live); }
.rent-avail { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-height: 20px; font: 500 var(--pv-ts-label) var(--pv-sans); }
.rent-avail--ok { color: var(--pulse-text); }
.rent-avail--bad { color: var(--live); }
.rent-avail--res { color: var(--brass-text); }
.rent-avail--wait { color: var(--fg-muted); }
.rent-suggest { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); font: 400 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-suggest .pv-btn { font-family: var(--pv-mono); }
.rent-order { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: var(--space-6); align-items: start; }
.rent-summary { position: sticky; top: var(--space-5); }

/* ---- Auth ---- */
.rent-auth { width: 100%; max-width: 420px; margin: var(--space-5) auto 0; }
.rent-auth .rent-card { padding: var(--space-6); gap: var(--space-5); }
.rent-auth__foot { text-align: center; font: 400 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-auth .pv-btn--primary { width: 100%; }

/* ---- Done state ---- */
.rent-done { display: flex; flex-direction: column; align-items: center; text-align: center; gap: var(--space-3); padding: var(--space-6) var(--space-5); }
.rent-done__icon { width: 56px; height: 56px; border-radius: var(--radius-pill); display: flex; align-items: center; justify-content: center; background: var(--bg-400); color: var(--pulse-text); }
.rent-done .rent-facts { text-align: left; margin-top: var(--space-2); }

/* ---- Tables (admin, invoices) ---- */
.rent-tablebox { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--pv-radius-lg); background: var(--bg-300); }
.rent-table { width: 100%; border-collapse: collapse; font: 400 var(--pv-ts-label) var(--pv-sans); }
.rent-table th { text-align: left; font: var(--pv-fw-bold) var(--pv-ts-overline) var(--pv-sans); letter-spacing: var(--pv-overline-track); text-transform: uppercase; color: var(--fg-subtle); padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--line); white-space: nowrap; }
.rent-table td { padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--line); vertical-align: middle; }
.rent-table tr:last-child td { border-bottom: 0; }
.rent-table td a.rent-rowlink { color: var(--fg); font-weight: 600; text-decoration: none; }
.rent-table .rent-num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rent-invoices { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.rent-invoices li { display: flex; align-items: center; gap: var(--space-3); min-height: 48px; border-top: 1px solid var(--line); font: 400 var(--pv-ts-label) var(--pv-sans); }
.rent-invoices li:first-child { border-top: 0; }
.rent-invoices__what { flex: 1; min-width: 0; }
.rent-invoices__sum { font-variant-numeric: tabular-nums; }
.rent-cards { display: none; }

/* ---- Admin ---- */
.rent-badge-admin { margin-left: var(--space-1); }
.rent-reason { display: flex; flex-direction: column; gap: var(--space-4); padding: var(--space-4); border: 1px solid var(--live); border-radius: var(--pv-radius-md); }

/* ---- Overlay for a dialog on a page ---- */
.rent-overlay .pv-modal--inline { position: absolute; inset: 0; z-index: 40; min-height: 0; }

/* ---- Footer ---- */
.rent-foot { flex: none; border-top: 1px solid var(--line); background: var(--bg-100); padding: var(--space-5) var(--space-6); }
.rent-foot__in { max-width: 1120px; margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-5); font: 400 var(--pv-ts-label) var(--pv-sans); color: var(--fg-muted); }
.rent-foot nav { display: flex; flex-wrap: wrap; gap: 0 var(--space-4); }
.rent-foot nav a { color: var(--fg-muted); text-decoration: none; min-height: 36px; display: inline-flex; align-items: center; }
.rent-foot nav a.rent-foot__cancel { color: var(--fg); font-weight: 600; }
.rent-foot__end { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-4); }
.rent-foot__end a { color: var(--fg-muted); }

/* ---- About / legal page ---- */
.rent-prose { display: flex; flex-direction: column; gap: var(--space-5); }
.rent-prose p, .rent-prose li { font: 400 var(--pv-ts-body) var(--pv-sans); color: var(--fg-muted); max-width: 64ch; }
.rent-placeholder { color: var(--brass-text); font-family: var(--pv-mono); }


/* ---- Phone ---- */
@media (max-width: 699px) {
  .rent-head { padding: var(--space-2) var(--space-4); gap: var(--space-2) var(--space-3); }
  .rent-head .rent-nav { order: 3; width: 100%; }
  .rent-user { display: none; }
  .rent-main { padding: var(--space-5) var(--space-4) var(--space-6); }
  .rent-h1 { font-size: 24px; line-height: 30px; }
  .rent-order { grid-template-columns: minmax(0, 1fr); gap: var(--space-6); }
  .rent-plan { padding: var(--space-5); }
  .rent-summary { position: static; }
  /* one column, cards in a fixed order: server, plan, contract, invoices, move, account */
  .rent-grid { display: flex; flex-direction: column; gap: var(--space-4); }
  .rent-col { display: contents; }
  .rent-o1 { order: 1; } .rent-o2 { order: 2; } .rent-o3 { order: 3; } .rent-o4 { order: 4; } .rent-o5 { order: 5; } .rent-o6 { order: 6; }
  .rent-card { padding: var(--space-4); }
  .rent-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: var(--space-3); }
  .rent-facts { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .rent-facts dd { margin-bottom: var(--space-2); }
  .rent-actions--fill { flex-direction: column; align-items: stretch; }
  .rent-auth { margin-top: 0; }
  .rent-auth .rent-card { padding: var(--space-5); }
  .rent-table--cards { display: none; }
  .rent-cards { display: flex; flex-direction: column; gap: var(--space-3); }
  .rent-foot { padding: var(--space-5) var(--space-4); }
  .rent-foot__end { margin-left: 0; }
}

@media (hover: hover) {
  .rent a:hover { text-decoration-thickness: 2px; }
  .rent-nav a:hover, .rent-lang a:hover { color: var(--fg); background: var(--bg-400); }
  .rent-foot nav a:hover, .rent-foot__end a:hover { color: var(--fg); text-decoration: underline; }
  .rent-table tbody tr:hover { background: var(--bg-400); }
}

/* ---- Additions for the server-rendered pages ----
   No inline styles (CSP style-src 'self'): what the canvas set per element stands here. */
html { background: var(--bg-200); }
body.rent { min-height: 100vh; }
.rent-done--flush { padding: 0; }
.rent-actions--center { justify-content: center; }
.rent-stack { display: flex; flex-direction: column; gap: var(--space-2); }
.rent-gap { height: var(--space-4); }
.rent-back { margin-bottom: var(--space-2); }
.rent-h1--host { font-size: 24px; }
.rent-danger-link { color: var(--live); align-self: flex-start; }
.rent-card--link { text-decoration: none; color: var(--fg) !important; gap: 6px; }
.rent-card__row { display: flex; justify-content: space-between; gap: var(--space-2); align-items: center; }
.rent-links { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); }
.rent-inline { display: inline; margin: 0; }
.rent-decide { flex-direction: column; align-items: stretch; }
.rent-pre { white-space: pre-wrap; }
/* Native progress for the trial days (a width in a style attribute would need inline styles). */
.rent-progress { display: block; width: 100%; height: 4px; border: 0; border-radius: var(--radius-pill); background: var(--bg-400); overflow: hidden;
  appearance: none; -webkit-appearance: none; color: var(--brass); }
.rent-progress::-webkit-progress-bar { background: var(--bg-400); border-radius: var(--radius-pill); }
.rent-progress::-webkit-progress-value { background: var(--brass); border-radius: var(--radius-pill); }
.rent-progress::-moz-progress-bar { background: var(--brass); border-radius: var(--radius-pill); }
/* Status tabs of the admin list: links styled as the design system's tabs. */
.rent-tabs a.pv-tab { text-decoration: none; }
/* Copy buttons appear only with JavaScript (app.js). */
.rent-copy[hidden] { display: none; }
/* Show/hide on password fields: the eye shows what a press does next. */
.rent-pwtoggle[hidden] { display: none; }
.rent-pwtoggle .rent-eye, .rent-pwtoggle .rent-eye-off { display: flex; }
.rent-pwtoggle .rent-eye-off, .rent-pwtoggle[aria-pressed="true"] .rent-eye { display: none; }
.rent-pwtoggle[aria-pressed="true"] .rent-eye-off { display: flex; }
/* Links that look like buttons keep the button's text colour, not the link colour of .rent a. */
.rent a.pv-btn--primary { color: var(--on-brass); }
.rent a.pv-btn--secondary { color: var(--fg); }
.rent a.pv-btn--ghost { color: var(--fg-muted); }
.rent a.pv-btn--danger { color: var(--on-live); }
.rent a.rent-danger-link, .rent .rent-danger-link { color: var(--live); }
.rent-suggest[hidden] { display: none; }
@media (max-width: 699px) {
  /* The grid's align-items: start would shrink the cards in the one column. */
  .rent-grid { align-items: stretch; }
}
