/* =========================================================
   Landing page – responsive
   Breakpoints (desktop-first, ca în codul original):
   ≤1200px  laptop mic
   ≤992px   tabletă landscape
   ≤768px   tabletă portrait
   ≤576px   telefon
   ≤380px   telefon mic
   Fonturile mari folosesc clamp() → se scalează fluid între
   breakpoint-uri, deci nu sar brusc de la o mărime la alta.
   ========================================================= */
 

/* ============ LANDING ============ */
/* Imaginile nu pot depăși niciodată containerul */
.hero img,
.features img,
.playbook img,
.demo-img {
  max-width: 100%;
  height: auto;
}
 
/* Ancorele (#features etc.) nu mai ajung ascunse sub navbar-ul fix */
html {
  scroll-padding-top: 80px;
}
 
/* ---------- Landing navbar(not logged in) ---------- */

body {
  background: radial-gradient(circle at top left, rgba(91, 141, 239, 0.08), transparent 40%);
  background-attachment: fixed;   /* opțional: rămâne fix la scroll */
}

.landing-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background-color: var(--bs-body-bg);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 48px;
  border-bottom: 1px solid #2a2a2a;
}
 
.nav-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.nav-logo {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}
.nav-brand {
  font-weight: 700;
  font-size: 1.2em;
  white-space: nowrap;
  min-width: 0;
  overflow: hidden;           /* dacă nu încape, se taie cu „…” în loc să se suprapună */
  text-overflow: ellipsis;
}
 
/* link-uri + buton + hamburger */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 28px;
  flex-shrink: 0;
}
.nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-link {
  color: #cfcfcf;
  text-decoration: none;
  font-size: 0.95em;
  white-space: nowrap;
}
.nav-link:hover {
  color: #fff;
}
 
/* Butonul hamburger – ascuns pe desktop */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
  background: transparent;
  color: #cfcfcf;
  cursor: pointer;
}
.nav-toggle:hover {
  color: #fff;
}
.nav-toggle:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 3px;
}
.nav-toggle-bar {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background-color: currentColor;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
/* ☰ → ✕ când meniul e deschis */
.landing-nav.is-open .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.landing-nav.is-open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.landing-nav.is-open .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
 
@media (prefers-reduced-motion: reduce) {
  .nav-toggle-bar { transition: none; }
}
 
/* ---------- Primary button ---------- */
.btn-primary {
  display: inline-block;
  background-color: #5B8DEF;
  color: #fff;
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95em;
  text-align: center;
  white-space: nowrap;
}
.btn-primary:hover {
  background-color: #4a7ad9;
  color: #fff;
}
.btn-primary:focus-visible,
.nav-link:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 3px;
}
.btn-large {
  padding: 14px 32px;
  font-size: 1.05em;
}
 
/* ---------- Hero ---------- */
.hero {
  text-align: center;
  padding: 100px 24px 60px;   /* 100px sus = loc pentru navbar-ul fix */
  max-width: 800px;
  margin: 0 auto;
}
.hero-title {
  font-size: clamp(2.1em, 6vw, 3.5em);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 24px;
  overflow-wrap: break-word;
  text-wrap: balance;         /* rânduri echilibrate; ignorat de browsere vechi */
}
.hero-subtitle {
  color: #a0a0a0;
  font-size: clamp(1em, 2.2vw, 1.15em);
  line-height: 1.6;
  margin-bottom: 40px;
}
 
/* ---------- Demo image (cele două reguli duplicate, unite) ---------- */
.demo-img {
  max-width: 990px;
  width: 100%;
  display: block;
  margin: 0 auto;
  border-radius: 12px;
  filter: drop-shadow(0 0 50px rgba(0, 0, 0, 0.5));
}
/* imaginea nu mai atinge marginile ecranului pe mobil */
.demo {
  padding: 0 24px;
}
 
/* ---------- Features ---------- */
.features {
  padding: 80px 24px;
  max-width: 1200px;
  margin: 0 auto;
}
.features-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 60px;
}
.eyebrow {
  display: inline-block;
  color: #5B8DEF;
  border: 1px solid rgba(91, 141, 239, 0.3);
  border-radius: 20px;
  padding: 4px 14px;
  font-size: 0.75em;
  font-weight: 600;
  letter-spacing: 0.5px;
  margin-bottom: 20px;
}
.features-title,
.workflow-title,
.playbook-title {
  font-size: clamp(1.8em, 4.5vw, 2.8em);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  text-wrap: balance;
}
.features-subtitle,
.workflow-subtitle,
.playbook-subtitle {
  color: #a0a0a0;
  font-size: clamp(1em, 2vw, 1.1em);
  line-height: 1.6;
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.feature-card {
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 12px;
  padding: 28px 24px;
}
.feature-icon {
  margin-bottom: 20px;
}
.feature-icon img {
  width: 44px;
  height: 44px;
}
.feature-card-title {
  font-size: 1.15em;
  font-weight: 700;
  margin-bottom: 12px;
}
.feature-card-text {
  color: #a0a0a0;
  font-size: 0.95em;
  line-height: 1.6;
}
 
/* ---------- Workflow ---------- */
.workflow {
  padding: 60px 24px 100px;
  max-width: 1100px;
  margin: 0 auto;
}
.workflow-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 60px;
}
 
/* Steps grid */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: 0;
}
.steps li {
  counter-increment: step;
}
.steps li::before {
  content: counter(step, decimal-leading-zero);  /* 01, 02 … 10 corect */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background-color: rgba(91, 141, 239, 0.1);
  border: 1px solid rgba(91, 141, 239, 0.3);
  color: #5B8DEF;
  font-weight: 700;
  font-size: 1.1em;
  margin-bottom: 24px;
}
.steps li h3 {
  font-size: 1.3em;
  font-weight: 700;
  margin-bottom: 12px;
}
.steps li p {
  color: #a0a0a0;
  font-size: 0.95em;
  line-height: 1.6;
}
 
/* ---------- Playbook ---------- */
.playbook {
  padding: 60px 24px 100px;
  max-width: 1200px;
  margin: 0 auto;
}
.playbook-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 60px;
}
.playbook-content {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 60px;
  align-items: center;
}
.playbook-content > * {
  min-width: 0;               /* previne overflow din coloanele grid */
}
.playbook-item {
  margin-bottom: 36px;
}
.playbook-item:last-child {
  margin-bottom: 0;
}
.playbook-label {
  display: block;
  color: #5B8DEF;
  font-weight: 700;
  font-size: 0.95em;
  margin-bottom: 10px;
}
.playbook-item p {
  color: #a0a0a0;
  font-size: 0.95em;
  line-height: 1.6;
}
.playbook-image img {
  width: 100%;
  border-radius: 12px;
  filter: drop-shadow(0 0 50px rgba(0, 0, 0, 0.5));
}
 
/* ---------- CTA ---------- */
.cta {
  text-align: center;
  padding: 100px 24px;
  max-width: 800px;
  margin: 0 auto;
}
.cta-title {
  font-size: clamp(2em, 5.5vw, 3em);
  font-weight: 800;
  line-height: 1.1;
  text-wrap: balance;
  margin-bottom: 20px;
}
.cta-subtitle {
  color: #a0a0a0;
  font-size: clamp(1em, 2vw, 1.1em);
  margin-bottom: 36px;
}
.cta-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}
 
/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--bs-border-color);
  padding: 50px 48px 30px;
  max-width: 1200px;
  margin: 0 auto;
}
.footer-logo-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.footer-logo {
  width: 28px;
  height: 28px;
}
.footer-name {
  font-weight: 700;
  font-size: 1.1em;
}
.footer-desc {
  color: #a0a0a0;
  font-size: 0.9em;
  line-height: 1.6;
  max-width: 400px;
}
.footer-bottom {
  border-top: 1px solid var(--bs-border-color);
  margin-top: 40px;
  padding-top: 20px;
  color: #808080;
  font-size: 0.85em;
}

/* ============ AUTH (login/signup) ============ */

/* Pagina întreagă */
.auth-page {
  --page-max: 1160px;            /* lățimea zonei de conținut; mărește/micșorează ca să depărtezi/apropii blocurile */
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 32px clamp(24px, 6vw, 120px);
  background:
    radial-gradient(circle at top left, rgba(91, 141, 239, 0.08), transparent 40%),
    radial-gradient(circle at bottom right, rgba(91, 141, 239, 0.08), transparent 40%);
}

/* Header și main au exact aceeași lățime și sunt centrate → margini egale */
.auth-header,
.auth-main {
  width: 100%;
  max-width: var(--page-max);
  margin-inline: auto;
}

/* Header */
.auth-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 32px;
}
.auth-logo-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}
.auth-logo { width: 32px; height: 32px; }
.auth-brand { font-weight: 700; font-size: 1.1em; }

/* Conținut: 2 coloane, lipite de marginile containerului */
.auth-main {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 600px) 420px;
  justify-content: space-between;
  align-items: center;
  gap: 64px;
}

/* Stânga */
.auth-headline {
  font-size: clamp(2rem, 2.8vw, 2.75rem);
  font-weight: 800;
  line-height: 1.15;
  margin: 20px 0;
}
.auth-sub {
  color: #a0a0a0;
  font-size: 1.05em;
  line-height: 1.6;
  max-width: 560px;
  margin-bottom: 40px;
}
.auth-demo-img {
  display: block;
  width: 100%;
  max-width: 560px;
  border-radius: 12px;
  filter: drop-shadow(0 0 40px rgba(0, 0, 0, 0.4));
}

/* Dreapta: cardul de login */
.auth-form-wrap {
  width: 100%;
  max-width: 420px;
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 14px;
  padding: 36px;
}
.auth-form-title { font-size: 1.8em; font-weight: 800; margin-bottom: 8px; }
.auth-form-sub { color: #a0a0a0; font-size: 0.95em; margin-bottom: 28px; }
.auth-label {
  display: block;
  font-size: 0.9em;
  font-weight: 600;
  margin-bottom: 8px;
  margin-top: 18px;
}
.auth-form-wrap input[type="text"],
.auth-form-wrap input[type="email"],
.auth-form-wrap input[type="password"] {
  width: 100%;
  padding: 12px 14px;
  background-color: var(--bs-body-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
  color: var(--bs-body-color);
  font-size: 1rem;
}
.auth-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 20px 0;
}
.auth-remember { color: #a0a0a0; font-size: 0.9em; display: flex; align-items: center; gap: 8px; }
.auth-forgot { color: #5B8DEF; text-decoration: none; font-size: 0.9em; }
.auth-submit {
  width: 100%;
  background-color: #5B8DEF;
  color: #fff;
  border: none;
  padding: 13px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1em;
  cursor: pointer;
}
.auth-submit:hover { background-color: #4a7ad9; }
.auth-switch {
  text-align: center;
  margin-top: 20px;
  color: #a0a0a0;
  font-size: 0.9em;
}
.auth-switch a { color: #5B8DEF; text-decoration: none; }
.auth-error {
  background-color: rgba(220, 53, 69, 0.1);
  border: 1px solid rgba(220, 53, 69, 0.3);
  color: #ff6b6b;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.9em;
  margin-bottom: 16px;
}

.auth-switch.auth-support { margin-top: 8px; }

/* Signup: erori sub câmpuri */
.auth-field-error {
  margin: 6px 0 0;
  font-size: 0.85em;
  color: #ff6b6b;
}
.auth-form-wrap input[aria-invalid="true"] {
  border-color: rgba(255, 107, 107, 0.6);   /* Django marchează singur câmpurile cu erori */
}
.auth-submit-spaced {
  margin-top: 24px;               /* la login spațiul vine din rândul „Remember me” */
}

/* Signup: prenume + nume pe același rând */
.auth-name-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.auth-name-row > div {
  min-width: 0;                   /* câmpurile se micșorează în coloană, nu ies din card */
}

/* Signup: eticheta „Password” cu „Show / Hide” în dreapta */
.auth-label-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: 18px;
  margin-bottom: 8px;
}
.auth-label-row .auth-label {
  margin: 0;                       /* spațiul vine acum din rând, nu din etichetă */
}
.password-toggle {
  padding: 0;
  font-size: 0.85em;
  color: #5B8DEF;
  background: none;
  border: none;
  cursor: pointer;
}
.password-toggle:hover {
  text-decoration: underline;
}
.password-toggle:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
  border-radius: 2px;
}

/* Signup: reguli de parolă bifate live */
.password-rules {
  display: grid;
  gap: 4px;
  margin: 10px 0 0;
  padding: 0;
  font-size: 0.8em;
  color: #808080;
  list-style: none;
}
.password-rules li {
  display: flex;
  align-items: center;
  gap: 6px;
}
.password-rules .rule-met {
  display: none;
}
.password-rules li.is-met {
  color: #4ade80;
}
.password-rules li.is-met .rule-pending {
  display: none;
}
.password-rules li.is-met .rule-met {
  display: inline;
}

/* Telefon: prenume și nume unul sub altul */
@media (max-width: 480px) {
  .auth-name-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

@media (max-width: 960px) {
  .auth-main {
    grid-template-columns: minmax(0, 420px);
    justify-content: center;
    padding-block: 32px;
  }
  .auth-pitch { display: none; }
}

/* Telefoane: card cu padding mai mic, ca inputurile să aibă loc */
@media (max-width: 480px) {
  .auth-form-wrap { padding: 24px; }
}
/* =========================================================
   ≤1200px – laptop mic
   ========================================================= */
@media (max-width: 1200px) {
  .landing-nav { padding: 16px 32px; }
  .features-grid { gap: 20px; }
  .playbook-content { gap: 48px; }
  .footer { padding: 50px 32px 30px; }
}
 
/* =========================================================
   ≤992px – tabletă landscape
   ========================================================= */
@media (max-width: 992px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
 
  .steps { gap: 32px; }
 
  /* text deasupra, imaginea dedesubt */
  .playbook-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .playbook-text {
    max-width: 640px;
    margin: 0 auto;
  }
}
 
/* =========================================================
   ≤768px – tabletă portrait
   ========================================================= */
@media (max-width: 768px) {
  .landing-nav { padding: 12px 20px; }
  .nav-actions { gap: 12px; }
  .nav-toggle { display: inline-flex; }
 
  /* Meniul devine panou sub navbar, ascuns până la click pe hamburger.
     display:none când e închis → link-urile nu primesc focus din Tab. */
  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 4px 0;
    background-color: var(--bs-body-bg);
    border-bottom: 1px solid #2a2a2a;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35);
    max-height: calc(100vh - 64px);
    max-height: calc(100dvh - 64px);
    overflow-y: auto;
  }
  .landing-nav.is-open .nav-menu { display: flex; }
 
  .nav-menu .nav-link {
    padding: 14px 20px;          /* țintă de atingere ≥ 44px */
    font-size: 1em;
  }
  .nav-menu .nav-link + .nav-link {
    border-top: 1px solid #2a2a2a;
  }
 
  html { scroll-padding-top: 70px; }
 
  .hero { padding: 90px 20px 48px; }
  .hero-subtitle { margin-bottom: 32px; }
 
  .features { padding: 64px 20px; }
  .features-header,
  .workflow-header,
  .playbook-header { margin-bottom: 40px; }
 
  .workflow,
  .playbook { padding: 48px 20px 72px; }
 
  /* pașii unul sub altul, centrați */
  .steps {
    grid-template-columns: 1fr;
    gap: 40px;
    max-width: 480px;
    margin: 0 auto;
    text-align: center;
  }
  .steps li::before { margin-bottom: 16px; }
 
  .cta { padding: 72px 20px; }
 
  .footer { padding: 40px 20px 24px; }
  .footer-bottom { margin-top: 32px; }
}

/* ============ APP NAVBAR (logged in) ============ */
.app-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 48px;
  min-height: 77px;
  flex-shrink: 0;
  background-color: var(--bs-body-bg);
  border-bottom: 1px solid #2a2a2a;
}

.app-nav-left {
  display: flex;
  align-items: center;
  gap: 10px;
}
.app-nav-logo {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}
.app-nav-brand {
  font-weight: 700;
  font-size: 1.2em;
}

.app-nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}
.app-nav-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75em;
  font-weight: 600;
  color: #a0a0a0;
}
.app-nav-email {
  color: #a0a0a0;
  font-size: 0.9em;
}
.app-nav-logout {
  background: none;
  border: none;
  color: var(--bs-body-color);
  font-size: 0.9em;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
}
.app-nav-logout:hover {
  color: #fff;
}

/* ============ APP Layout (logged in) ============ */
.app-shell {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
}

.app-layout {
  display: flex;
  flex: 1;
  min-height: 0;
}

#sidebar {
  width: 320px;
  flex-shrink: 0;
  overflow-y: auto;
  padding: 20px 16px;
  border-right: 1px solid #2a2a2a;
  background-color: var(--bs-body-bg);
}

#detail-panel {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  padding: 40px 48px 64px;
}

/* ---------- Sidebar: header ---------- */
.sidebar-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.sidebar-header h2 {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #a0a0a0;
}
/* formularul care înlocuiește butonul trece pe rândul de dedesubt, pe toată lățimea */
.sidebar-header form {
  flex-basis: 100%;
  min-width: 0;
}

.sidebar-add-btn {
  background-color: #5B8DEF;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 4px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}
.sidebar-add-btn:hover {
  background-color: #4a7ad9;
}
.sidebar-add-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}

/* ---------- Sidebar: tree (summary + chevron) ---------- */
#sidebar summary {
  list-style: none;              /* ascunde triunghiul nativ (Chrome/Firefox) */
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
  user-select: none;
}
#sidebar summary::-webkit-details-marker {
  display: none;                 /* ascunde triunghiul nativ (Safari) */
}
#sidebar summary:hover {
  background-color: rgba(255, 255, 255, 0.04);
}

/* chevron desenat din CSS: › închis, ⌄ deschis */
#sidebar summary::before {
  content: "";
  width: 6px;
  height: 6px;
  margin: 0 4px;
  flex-shrink: 0;
  border-right: 1.5px solid #a0a0a0;
  border-bottom: 1.5px solid #a0a0a0;
  transform: rotate(-45deg);
  transition: transform 0.15s ease;
}
#sidebar details[open] > summary::before {
  transform: rotate(45deg);
}

/* nivelul Application */
#applications-list > details > summary {
  font-weight: 600;
}
.sidebar-icon {
  color: #5B8DEF;
  font-size: 1rem;
}

@media (prefers-reduced-motion: reduce) {
  #sidebar summary::before { transition: none; }
}

/* ---------- Sidebar: indentare ---------- */
/* div-urile cu copii (categories-of-app-X, issues-of-category-X) se împing spre dreapta */
#sidebar details > div {
  padding-left: 16px;
}

/* nivelul Category */
#sidebar details details > summary {
  font-size: 0.9rem;
}

/* ---------- Sidebar: separator sub aplicația deschisă ---------- */
#applications-list > details[open]:not(:last-child) {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 6px;
  margin-bottom: 6px;
}

/* ---------- Sidebar: mesaj când nu există aplicații ---------- */
.sidebar-empty {
  margin: 8px;
  color: #a0a0a0;
  font-size: 0.85rem;
  line-height: 1.5;
}
/* ascuns cât timp lista are cel puțin o aplicație */
#applications-list:has(> details) + .sidebar-empty {
  display: none;
}

/* ---------- Sidebar: issue ---------- */
#sidebar p.app-item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 6px 8px 6px 22px;   /* 22px stânga = aliniat cu textul categoriei, după chevron */
  border-radius: 6px;
  font-size: 0.875rem;
}
#sidebar p.app-item:hover {
  background-color: rgba(255, 255, 255, 0.04);
}
#sidebar p.app-item a {
  flex: 1;
  min-width: 0;                 /* fără asta, ellipsis nu funcționează în flex */
  color: var(--bs-body-color);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#sidebar p.app-item a:hover {
  color: #fff;
}
.sidebar-doc-icon {
  color: #a0a0a0;
  flex-shrink: 0;
}

/* ---------- Sidebar: butoane „+ Add category / issue” ---------- */
.sidebar-link-btn {
  display: block;
  background: none;
  border: none;
  border-radius: 6px;
  padding: 4px 8px;
  margin: 2px 0;
  color: #5B8DEF;
  font-size: 0.8rem;
  cursor: pointer;
}
.sidebar-link-btn:hover {
  color: #7fa6f3;
  background-color: rgba(91, 141, 239, 0.08);
}
.sidebar-link-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
/* aliniere: „Add category” sub chevron-ul categoriilor, „Add issue” sub iconița issue-urilor */
#applications-list > details > .sidebar-link-btn {
  margin-left: 16px;
}
#sidebar details details > .sidebar-link-btn {
  margin-left: 30px;
}

/* ---------- Sidebar: formulare inline (aplicație / categorie nouă) ---------- */
#sidebar form {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 4px 0;
}
#applications-list > details > form {
  margin-left: 24px;
}
#sidebar form input[type="text"] {
  flex: 1;
  min-width: 0;
  padding: 5px 8px;
  font-size: 0.85rem;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 6px;
}
#sidebar form input[type="text"]:focus {
  outline: none;
  border-color: #5B8DEF;
}
#sidebar form button {
  padding: 5px 10px;
  font-size: 0.8rem;
  color: var(--bs-body-color);
  background: transparent;
  border: 1px solid var(--bs-border-color);
  border-radius: 6px;
  cursor: pointer;
}
#sidebar form button:hover {
  border-color: #a0a0a0;
}
#sidebar form button[type="submit"] {
  color: #fff;
  background-color: #5B8DEF;
  border-color: #5B8DEF;
}
#sidebar form button[type="submit"]:hover {
  background-color: #4a7ad9;
}

/* ---------- Sidebar: butoane ✏️ rename și × delete ---------- */
.edit-btn,
.delete-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  padding: 0;
  background: none;
  border: none;
  border-radius: 4px;
  color: #a0a0a0;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0;                    /* invizibile, dar accesibile din tastatură */
}
.edit-btn {
  font-size: 0.75rem;
}

/* primul buton din dreapta împinge grupul la margine */
.edit-btn,
.delete-btn {
  margin-left: auto;
}
.edit-btn + .delete-btn {
  margin-left: 2px;
}

.app-item:hover .edit-btn,
.app-item:hover .delete-btn,
.edit-btn:focus-visible,
.delete-btn:focus-visible {
  opacity: 1;
}
.edit-btn:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
}
.delete-btn:hover {
  color: #ff6b6b;
  background-color: rgba(220, 53, 69, 0.1);
}
.edit-btn:focus-visible,
.delete-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 1px;
}

/* numele lung se taie cu „…” în loc să împingă butoanele */
#sidebar .item-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ---------- Sidebar: issue activ ---------- */
#sidebar p.app-item.is-active {
  background-color: rgba(91, 141, 239, 0.12);
  box-shadow: inset 0 0 0 1px rgba(91, 141, 239, 0.6);   /* „bordură” fără să mute conținutul */
}
#sidebar p.app-item.is-active a {
  color: #fff;
}
#sidebar p.app-item.is-active .sidebar-doc-icon {
  color: #5B8DEF;
}
#sidebar p.app-item.is-active .delete-btn {
  opacity: 1;
  color: #5B8DEF;
}
#sidebar p.app-item.is-active .delete-btn:hover {
  color: #ff6b6b;
}

/* ---------- Modal (rename) ---------- */
.app-dialog {
  width: min(420px, calc(100vw - 32px));
  padding: 24px;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 12px;
}
.app-dialog::backdrop {
  background-color: rgba(0, 0, 0, 0.6);
}
.dialog-title {
  margin: 0 0 16px;
  font-size: 1.1rem;
  font-weight: 700;
}
.dialog-form input[type="text"] {
  width: 100%;
  padding: 10px 12px;
  font-size: 0.95rem;
  color: var(--bs-body-color);
  background-color: var(--bs-body-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
}
.dialog-form input[type="text"]:focus {
  outline: none;
  border-color: #5B8DEF;
}
.dialog-error {
  margin: 8px 0 0;
  color: #ff6b6b;
  font-size: 0.85rem;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 20px;
}
.dialog-btn {
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--bs-body-color);
  background: transparent;
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
  cursor: pointer;
}
.dialog-btn:hover {
  border-color: #a0a0a0;
}
.dialog-btn-primary {
  color: #fff;
  background-color: #5B8DEF;
  border-color: #5B8DEF;
}
.dialog-btn-primary:hover {
  background-color: #4a7ad9;
  border-color: #4a7ad9;
}

/* ============ EDITOR PANEL ============ */
.issue-editor {
  max-width: 960px;
  margin: 0 auto;               /* centrează coloana în panou */
}

/* ---------- Breadcrumb ---------- */
.issue-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  margin-bottom: 12px;
  font-size: 0.8rem;
  color: #a0a0a0;
}
.issue-breadcrumb span {
  white-space: nowrap;
}
.issue-breadcrumb .bi {
  flex-shrink: 0;
  font-size: 0.6rem;
}
.issue-breadcrumb .breadcrumb-current {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--bs-body-color);
}

/* ---------- Titlu ---------- */
.issue-title-input {
  width: 100%;
  padding: 6px 12px;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--bs-body-color);
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}
.issue-title-input:hover {
  border-color: var(--bs-border-color);
}
.issue-title-input:focus {
  outline: none;
  border-color: #5B8DEF;
}
.issue-title-input::placeholder {
  color: #6c757d;
}

/* ---------- Status („Saving… / Saved / Couldn't save”) ---------- */
.save-status {
  min-height: 1.2em;            /* rezervă locul, ca textul de sub el să nu sară */
  margin: 8px 0 0;
  font-size: 0.8rem;
  color: #a0a0a0;
}
.save-ok {
  color: #4ade80;
}
.save-pending {
  color: #a0a0a0;
}
.save-error {
  color: #ff6b6b;
}

/* ---------- Separator ---------- */
.issue-divider {
  margin: 24px 0;
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 1;                   /* Bootstrap pune opacity: .25 pe <hr> */
}

/* ---------- Starea goală a panoului ---------- */
.panel-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  text-align: center;
  color: #a0a0a0;
}
.panel-empty-icon {
  margin-bottom: 12px;
  font-size: 2.5rem;
  color: #495057;
}
.panel-empty-title {
  margin: 0 0 4px;
  font-weight: 600;
  color: var(--bs-body-color);
}
.panel-empty-hint {
  margin: 0;
  font-size: 0.85rem;
}

/* ---------- Carduri Symptom / Cause / Fix ---------- */
.section-card {
  --section-accent: #5B8DEF;    /* culoarea implicită; o suprascriu clasele de mai jos */
  margin-bottom: 20px;
  padding: 20px 24px;
  background-color: var(--bs-body-bg);   /* același fundal ca sidebar-ul */
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-left: 3px solid var(--section-accent);
  border-radius: 12px;
}
.section-card:focus-within {
  border-color: var(--bs-border-color);
  border-left-color: var(--section-accent);
}

.section-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.section-badge {
  padding: 2px 8px;
  font-family: var(--bs-font-monospace);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--section-accent);
  background-color: color-mix(in srgb, var(--section-accent) 15%, transparent);
  border-radius: 6px;
}
.section-card-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
}

/* ---------- Buton Edit / Done ---------- */
.section-edit-btn {
  margin-left: auto;            /* împinge butonul în dreapta antetului */
  padding: 4px 10px;
  font-size: 0.8rem;
  font-weight: 500;
  color: #a0a0a0;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
}
.section-edit-btn:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.06);
}
.section-edit-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.section-edit-btn .when-view,
.section-edit-btn .when-edit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.section-edit-btn .when-edit {
  display: none;
}

/* în editare: butonul arată „Done”, în culoarea secțiunii */
.section-card.is-editing .section-edit-btn {
  color: var(--section-accent);
  background-color: color-mix(in srgb, var(--section-accent) 15%, transparent);
}
.section-card.is-editing .section-edit-btn .when-view {
  display: none;
}
.section-card.is-editing .section-edit-btn .when-edit {
  display: inline-flex;
}

/* ---------- Mod citire ↔ mod editare ---------- */
.section-textarea,
.section-hint {
  display: none;
}
.section-card.is-editing .section-textarea,
.section-card.is-editing .section-hint {
  display: block;
}
.section-card.is-editing .section-view {
  display: none;
}

/* câmpul de editare */
.section-textarea {
  width: 100%;
  min-height: 3em;
  padding: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--bs-body-color);
  background: transparent;
  border: none;
  resize: none;
  overflow: hidden;
}
.section-textarea:focus {
  outline: none;
}
.section-textarea::placeholder {
  color: #6c757d;
}
.section-hint {
  margin: 10px 0 0;
  font-size: 0.75rem;
  color: #6c757d;
}

/* ---------- Text formatat (mod citire) ---------- */
.section-view {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--bs-body-color);
  overflow-wrap: anywhere;      /* URL-urile lungi nu ies din card */
}

.section-view > :first-child { margin-top: 0; }
.section-view > :last-child  { margin-bottom: 0; }
.section-empty {
  margin: 0;
  color: #6c757d;
}

.section-view p {
  margin: 0 0 0.75em;
}
.section-view ul,
.section-view ol {
  margin: 0 0 0.75em;
  padding-left: 1.5em;
}
.section-view li {
  margin-bottom: 0.3em;
}
.section-view li::marker {
  color: #a0a0a0;
}
.section-view strong {
  font-weight: 600;
  color: #fff;
}
.section-view a {
  color: #5B8DEF;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* cod în linie: `RangeStart` */
.section-view code {
  padding: 0.15em 0.4em;
  font-family: var(--bs-font-monospace);
  font-size: 0.85em;
  color: #e9ecef;               /* Bootstrap colorează implicit codul în roz */
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
}

/* bloc de cod: ```sql ... ``` */
.section-view pre {
  margin: 0 0 0.75em;
  padding: 12px 16px;
  overflow-x: auto;             /* rândurile lungi de cod derulează, nu se rup */
  background-color: #1a1d21;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}
.section-view pre code {
  padding: 0;
  font-size: 0.85rem;
  line-height: 1.6;
  background: none;
}

/* ---------- Bloc de cod cu buton Copy ---------- */
.code-block {
  position: relative;
  margin: 0 0 0.75em;
}
.section-view .code-block pre {
  margin: 0;
  padding-right: 88px;          /* codul nu ajunge sub buton */
}
.code-copy-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  font-size: 0.75rem;
  color: #a0a0a0;
  background-color: var(--bs-body-bg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  cursor: pointer;
}
.code-copy-btn:hover {
  color: #fff;
  border-color: var(--bs-border-color);
}
.code-copy-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.code-copy-btn.is-done {
  color: #4ade80;
}

/* ---------- Toolbar Markdown (doar în modul de editare) ---------- */
.md-toolbar {
  display: none;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
  width: fit-content;
  max-width: 100%;
  margin: 0 0 12px;
  padding: 4px;
  background-color: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}
.section-card.is-editing .md-toolbar {
  display: flex;
}
.md-toolbar button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 28px;
  padding: 0;
  font-size: 1rem;
  color: #a0a0a0;
  background: transparent;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.md-toolbar button:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
}
.md-toolbar button:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 1px;
}
.md-sep {
  width: 1px;
  height: 18px;
  margin: 0 4px;
  background-color: rgba(255, 255, 255, 0.1);
}

.section-view blockquote {
  margin: 0 0 0.75em;
  padding-left: 12px;
  color: #a0a0a0;
  border-left: 3px solid var(--bs-border-color);
}
.section-view table {
  display: block;
  max-width: 100%;
  margin-bottom: 0.75em;
  overflow-x: auto;
  font-size: 0.9rem;
  border-collapse: collapse;
}
.section-view th,
.section-view td {
  padding: 6px 12px;
  text-align: left;
  border: 1px solid var(--bs-border-color);
}
.section-view th {
  font-weight: 600;
  background-color: rgba(255, 255, 255, 0.04);
}

/* culorile secțiunilor: șterge aceste 3 reguli pentru varianta monocromă */
.section-symptom { --section-accent: #f59e0b; }   /* chihlimbar: ce se vede */
.section-cause   { --section-accent: #a78bfa; }   /* violet: de ce */
.section-fix     { --section-accent: #4ade80; }   /* verde: ce faci */
 
/* =========================================================
   ≤576px – telefon
   ========================================================= */
@media (max-width: 576px) {
  .landing-nav { padding: 10px 16px; }
  .nav-logo { width: 28px; height: 28px; }
  .nav-brand { font-size: 1.05em; }
 
  .landing-nav .btn-primary {
    padding: 8px 14px;
    font-size: 0.875em;
  }
  /* „Get Started Free” → „Get Started” în navbar, pe telefon */
  .nav-cta-extra { display: none; }
  .nav-toggle { width: 38px; height: 38px; }
  .nav-menu .nav-link { padding: 14px 16px; }
 
  .hero { padding: 84px 16px 40px; }
 
  /* <br>-urile forțate din titluri lasă cuvinte orfane pe ecran îngust;
     textul curge natural (necesită spațiu înainte de <br> în HTML) */
  .hero-title br,
  .cta-title br { display: none; }
 
  .demo { padding: 0 16px; }
 
  .demo-img,
  .playbook-image img {
    border-radius: 8px;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.45));
  }
 
  .features { padding: 56px 16px; }
  .features-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .feature-card { padding: 24px 20px; }
 
  .workflow,
  .playbook { padding: 40px 16px 64px; }
  .playbook-item { margin-bottom: 28px; }
 
  .cta { padding: 64px 16px; }
 
  /* butoanele CTA pe toată lățimea – ușor de apăsat cu degetul */
  .cta-buttons {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .cta-buttons .btn-primary,
  .cta-buttons a {
    width: 100%;
  }
  .btn-large {
    padding: 14px 20px;
    white-space: normal;
  }
 
  .footer { padding: 36px 16px 20px; }
  .footer-desc { max-width: none; }
}
 
/* =========================================================
   ≤380px – telefoane mici (iPhone SE, Android compact)
   ========================================================= */
@media (max-width: 380px) {
  .nav-brand { display: none; }     /* rămân logo + Sign In + buton */
  .nav-actions { gap: 10px; }
  .eyebrow { font-size: 0.7em; }
}
 
/* =========================================================
   Telefon în landscape (ecran scund): navbar mai subțire
   ========================================================= */
@media (max-height: 500px) and (orientation: landscape) {
  .landing-nav { padding-top: 8px; padding-bottom: 8px; }
  .hero { padding-top: 72px; }
}

/* ============ NOTIFICĂRI (Django messages) ============ */
/* fixe sus pe ecran: nu mai împing pagina în jos */
.messages {
  position: fixed;
  top: 16px;
  left: 50%;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
  transform: translateX(-50%);
}

.messages li {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: min(520px, calc(100vw - 32px));   /* mesajele lungi se rup pe rânduri, nu ies din ecran */
  padding: 10px 10px 10px 16px;
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  transition: opacity 0.4s ease;
}
.messages li.success { border-color: rgba(74, 222, 128, 0.5); }
.messages li.info    { border-color: rgba(91, 141, 239, 0.5); }
.messages li.warning { border-color: rgba(245, 158, 11, 0.6); }
.messages li.error   { border-color: rgba(255, 107, 107, 0.5); }
.messages li.is-hiding { opacity: 0; }

.messages-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  margin-left: auto;
  padding: 0;
  font-size: 0.85rem;
  color: #a0a0a0;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.messages-close:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
}
.messages-close:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 1px;
}

/* ============ APP NAVBAR: link-uri ============ */
.app-nav-left {
  color: inherit;
  text-decoration: none;
}
.app-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  font-size: 0.9em;
  color: #a0a0a0;
  text-decoration: none;
  border-radius: 6px;
}
.app-nav-link:hover,
.app-nav-link.is-active {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.06);
}
.app-nav-link:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}

/* ============ PAGINI SIMPLE (Members etc.) ============ */
.page-main {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 40px 48px 64px;
}
.page-container {
  max-width: 720px;
  margin: 0 auto;
}
.page-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
  font-size: 0.85rem;
  color: #a0a0a0;
  text-decoration: none;
}
.page-back:hover {
  color: #fff;
}
.page-header {
  margin-bottom: 24px;
}
.page-title {
  margin: 0;
  font-size: 2rem;
  font-weight: 700;
}
.page-subtitle {
  margin: 4px 0 0;
  color: #a0a0a0;
}
.page-card {
  margin-bottom: 20px;
  padding: 20px 24px;
  background-color: var(--bs-body-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}
.page-card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  font-size: 1.05rem;
  font-weight: 600;
}
.page-card-text {
  margin: 0 0 16px;
  font-size: 0.9rem;
  color: #a0a0a0;
}
.page-count {
  padding: 1px 8px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #a0a0a0;
  background-color: rgba(255, 255, 255, 0.06);
  border-radius: 10px;
}

/* formularul de invitație */
.invite-form {
  display: flex;
  gap: 8px;
}
.invite-form input[type="email"] {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  font-size: 0.95rem;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
}
.invite-form input[type="email"]:focus {
  outline: none;
  border-color: #5B8DEF;
}
.form-error {
  margin: 8px 0 0;
  font-size: 0.85rem;
  color: #ff6b6b;
}

/* lista de membri / invitații */
.people-list {
  margin: 8px 0 0;
  padding: 0;
  list-style: none;
}
.people-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.people-row:first-child {
  border-top: none;
}
.people-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #a0a0a0;
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 50%;
}
.people-avatar-pending {
  border-style: dashed;
}
.people-name {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}
.people-meta {
  font-size: 0.8rem;
  color: #a0a0a0;
}
.people-you {
  margin-left: 6px;
  font-size: 0.75rem;
  color: #a0a0a0;
}
.role-badge {
  flex-shrink: 0;
  padding: 2px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #a0a0a0;
  background-color: rgba(255, 255, 255, 0.06);
  border-radius: 10px;
}
.role-owner {
  color: #5B8DEF;
  background-color: rgba(91, 141, 239, 0.15);
}

/* ============ SIDEBAR: antetul de workspace ============ */
.workspace-switcher {
  position: relative;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.workspace-switcher-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: left;
  color: var(--bs-body-color);
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
}
.workspace-switcher-btn:hover,
.workspace-switcher-btn[aria-expanded="true"] {
  background-color: rgba(255, 255, 255, 0.06);
}
.workspace-switcher-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.workspace-switcher-btn .bi-chevron-expand {
  margin-left: auto;
  color: #a0a0a0;
}
.workspace-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.workspace-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  background-color: #5B8DEF;
  border-radius: 6px;
}
.workspace-avatar-sm {
  width: 22px;
  height: 22px;
  font-size: 0.7rem;
  border-radius: 5px;
}

/* meniul */
.workspace-menu {
  position: absolute;
  top: calc(100% - 6px);
  left: 0;
  right: 0;
  z-index: 100;
  padding: 6px;
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}
.workspace-menu[hidden] {
  display: none;
}
.workspace-menu-label {
  margin: 4px 8px 6px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #a0a0a0;
}
/* selectorii încep cu #sidebar ca să bată stilurile formularelor inline din sidebar */
#sidebar .workspace-menu form {
  display: block;
  margin: 0;
}
#sidebar .workspace-menu .workspace-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 7px 8px;
  font-size: 0.875rem;
  font-weight: 400;
  text-align: left;
  text-decoration: none;
  color: var(--bs-body-color);
  background: transparent;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
#sidebar .workspace-menu .workspace-menu-item:hover {
  background-color: rgba(255, 255, 255, 0.06);
}
#sidebar .workspace-menu .workspace-menu-item:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: -2px;
}
#sidebar .workspace-menu .workspace-menu-item.is-current {
  cursor: default;
  opacity: 1;                   /* butoanele disabled sunt estompate implicit */
}
#sidebar .workspace-menu .workspace-menu-item.is-current .bi-check2 {
  margin-left: auto;
  color: #5B8DEF;
}
.workspace-menu-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* iconițele din meniu (Create, Members, Rename) aliniate cu pătrățelele workspace-urilor */
.workspace-menu-item > .bi:first-child {
  width: 22px;
  text-align: center;
  color: #a0a0a0;
}
.workspace-menu-sep {
  height: 1px;
  margin: 6px 4px;
  background-color: rgba(255, 255, 255, 0.08);
}

/* ============ PAGINA DE INVITAȚIE ============ */
.invite-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-block: 32px;
}
.invite-card {
  text-align: center;
}
.invite-avatar {
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  font-size: 1.3rem;
  border-radius: 10px;
}
.invite-icon {
  display: block;
  margin-bottom: 12px;
  font-size: 2.5rem;
  color: #495057;
}
.invite-text {
  margin-bottom: 20px;
  font-size: 0.9rem;
  color: #a0a0a0;
}
.invite-btn {
  display: block;
  text-align: center;
  text-decoration: none;
}
.invite-btn:hover {
  color: #fff;
}

/* butonul „Copy link” din lista de invitații */
.copy-link-btn {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  font-size: 0.8rem;
  color: #a0a0a0;
  background: transparent;
  border: 1px solid var(--bs-border-color);
  border-radius: 6px;
  cursor: pointer;
}
.copy-link-btn:hover {
  color: #fff;
  border-color: #a0a0a0;
}
.copy-link-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.copy-link-btn.is-done {
  color: #4ade80;
  border-color: rgba(74, 222, 128, 0.5);
}

/* butoane mici de acțiune pe rânduri (Remove, Cancel, Leave) */
.people-row form {
  flex-shrink: 0;
  margin: 0;
}
.row-action-btn {
  padding: 4px 10px;
  font-size: 0.8rem;
  color: #a0a0a0;
  background: transparent;
  border: 1px solid var(--bs-border-color);
  border-radius: 6px;
  cursor: pointer;
}

.row-action-btn:hover {
  color: #fff;
  border-color: #a0a0a0;
}

.row-action-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.row-action-danger:hover {
  color: #ff6b6b;
  border-color: rgba(255, 107, 107, 0.5);
  background-color: rgba(220, 53, 69, 0.08);
}
.page-card-danger {
  border-color: rgba(255, 107, 107, 0.2);
}

/* „My workspace”: iconiță de persoană, culoare neutră, ca să se deosebească de echipe */
.workspace-avatar-personal {
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
}

/* =========================================================
   APP pe mobil (aplicația logată)
   Aceleași praguri ca landing-ul: ≤768px tabletă/telefon, ≤380px telefon mic
   ========================================================= */
@media (max-width: 768px) {
  /* ---------- Navbar compact ---------- */
  .app-nav {
    gap: 12px;
    min-height: 60px;
    padding: 10px 16px;
  }
  .app-nav-logo {
    width: 28px;
    height: 28px;
  }
  .app-nav-brand {
    font-size: 1.05em;
    white-space: nowrap;          /* „Polaris Vault” pe un singur rând */
  }
  .app-nav-email {
    display: none;                /* avatarul cu inițiale rămâne */
  }
  .app-nav-logout {
    white-space: nowrap;          /* „Log out” nu se mai rupe pe două rânduri */
  }
}

@media (max-width: 380px) {
  .app-nav-brand {
    display: none;                /* pe ecrane foarte mici rămâne doar logo-ul */
  }
}

/* ---------- Mobil: sidebar-ul ca panou glisant ---------- */
.app-nav-start {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
/* pe desktop nu există: butonul ☰, × din panou și fundalul întunecat */
.sidebar-toggle,
.sidebar-close,
.sidebar-backdrop {
  display: none;
}

@media (max-width: 768px) {
  .sidebar-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 40px;                  /* țintă de atingere confortabilă */
    height: 40px;
    padding: 0;
    font-size: 1.4rem;
    color: var(--bs-body-color);
    background: transparent;
    border: 1px solid var(--bs-border-color);
    border-radius: 8px;
    cursor: pointer;
  }
  .sidebar-toggle:focus-visible,
  .sidebar-close:focus-visible {
    outline: 2px solid #5B8DEF;
    outline-offset: 2px;
  }

  /* panoul: scos din layout, ascuns în stânga ecranului */
  #sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1100;
    width: min(320px, 85vw);
    padding-top: 16px;
    border-right: 1px solid var(--bs-border-color);
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
    transform: translateX(-100%);
    visibility: hidden;           /* ascuns complet: Tab nu ajunge în el cât e închis */
    transition: transform 0.25s ease, visibility 0s linear 0.25s;
  }
  .app-shell.sidebar-open #sidebar {
    transform: none;
    visibility: visible;
    transition: transform 0.25s ease;
  }

  .sidebar-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1050;
    background-color: rgba(0, 0, 0, 0.55);
    opacity: 0;
    pointer-events: none;         /* invizibil și „transparent” la click cât e închis */
    transition: opacity 0.25s ease;
  }
  .app-shell.sidebar-open .sidebar-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  .sidebar-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 16px;
    right: 12px;
    width: 40px;
    height: 40px;
    padding: 0;
    font-size: 1.1rem;
    color: #a0a0a0;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
  }
  .sidebar-close:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.06);
  }
  .workspace-switcher {
    margin-right: 44px;           /* loc pentru × în dreapta antetului */
  }
}

@media (prefers-reduced-motion: reduce) {
  #sidebar,
  .sidebar-backdrop {
    transition: none !important;
  }
}

/* ---------- Mobil: buton „Browse issues” în starea goală ---------- */
.panel-empty-browse {
  display: none;                  /* pe desktop sidebar-ul e oricum vizibil */
}

/* ---------- Mobil: editorul ---------- */
@media (max-width: 768px) {
  #detail-panel {
    padding: 20px 16px 48px;
  }

  .issue-breadcrumb {
    font-size: 0.75rem;
  }
  .issue-title-input {
    padding: 6px 10px;
    font-size: 1.5rem;
  }
  .issue-divider {
    margin: 16px 0;
  }

  .section-card {
    margin-bottom: 16px;
    padding: 16px;
  }
  .section-card-header {
    gap: 8px;
  }
  .section-view {
    font-size: 1rem;              /* text mai ușor de citit pe ecran mic */
  }

  /* toolbar: butoane mai mari pentru deget */
  .md-toolbar button {
    width: 38px;
    height: 36px;
  }
  /* indicația pomenește scurtături de tastatură; pe telefon toolbar-ul face aceeași treabă */
  .section-card.is-editing .section-hint {
    display: none;
  }

  /* iOS mărește pagina la focus pe câmpuri sub 16px -> le ducem la 16px */
  .section-textarea,
  #sidebar form input[type="text"],
  .dialog-form input[type="text"],
  .invite-form input[type="email"] {
    font-size: 16px;
  }

  .panel-empty-browse {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 20px;
    padding: 10px 18px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #fff;
    background-color: #5B8DEF;
    border: none;
    border-radius: 8px;
    cursor: pointer;
  }
}

/* ---------- Ecrane tactile: butoanele „de hover” devin vizibile și mai mari ---------- */
/* pe ecrane înguste SAU pe dispozitive fără hover (telefoane, tablete) */
@media (max-width: 768px), (hover: none) {
  .edit-btn,
  .delete-btn {
    opacity: 1;                   /* fără hover, altfel n-ar putea fi găsite deloc */
    width: 32px;
    height: 32px;
  }
  .edit-btn {
    font-size: 0.9rem;
  }
  .delete-btn {
    font-size: 1.15rem;
  }

  /* rânduri puțin mai înalte: mai greu de apăsat rândul greșit */
  #sidebar summary,
  #sidebar p.app-item {
    padding-top: 8px;
    padding-bottom: 8px;
  }
  .sidebar-link-btn {
    padding: 8px;
  }
}

/* ---------- Members: rolul + butoanele, grupate ---------- */
/* desktop: în dreapta rândului, ca înainte */
.people-actions {
  display: flex;
  flex-shrink: 0;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

/* ---------- Mobil: pagina Members ---------- */
@media (max-width: 768px) {
  .page-main {
    padding: 20px 16px 48px;
  }
  .page-title {
    font-size: 1.6rem;
  }
  .page-header {
    margin-bottom: 20px;
  }
  .page-card {
    margin-bottom: 16px;
    padding: 16px;
  }

  /* rolul și butoanele trec sub email, aliniate cu textul (32px avatar + 12px spațiu) */
  .people-row {
    flex-wrap: wrap;
    row-gap: 8px;
  }
  .people-actions {
    flex-basis: 100%;
    justify-content: flex-start;
    padding-left: 44px;
  }

  /* butoane puțin mai mari pentru deget */
  .row-action-btn,
  .copy-link-btn {
    padding: 7px 12px;
  }
}

/* telefoane mici: câmpul de invitație și butonul unul sub altul */
@media (max-width: 380px) {
  .invite-form {
    flex-direction: column;
  }
}

/* ============ ATAȘAMENTE ============ */
/* imaginile din text */
.section-view img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0.5em 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}

/* lista de documente a secțiunii */
.section-files {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}
.section-files:not(:has(li)) {
  display: none;                  /* fără documente -> fără spațiu gol */
}
.section-file {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  font-size: 0.875rem;
  background-color: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}
.section-file .bi {
  flex-shrink: 0;
  color: #a0a0a0;
}
.section-file-link {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--bs-body-color);
  text-decoration: none;
}
.section-file-link:hover {
  color: #5B8DEF;
  text-decoration: underline;
}
.section-file-size {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: #808080;
}
/* × pentru ștergere apare doar în modul de editare */
.section-file-delete {
  display: none;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  padding: 0;
  font-size: 1.1rem;
  line-height: 1;
  color: #a0a0a0;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.section-card.is-editing .section-file-delete {
  display: inline-flex;
}
.section-file-delete:hover {
  color: #ff6b6b;
  background-color: rgba(220, 53, 69, 0.1);
}
.section-file-delete:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 1px;
}

/* card evidențiat când tragi fișiere peste el */
.section-card.is-dragover {
  outline: 2px dashed var(--section-accent);
  outline-offset: 4px;
  background-color: color-mix(in srgb, var(--section-accent) 6%, var(--bs-body-bg));
}

/* eroare de încărcare, afișată în cardul respectiv */
.upload-error {
  margin: 0 0 12px;
  padding: 8px 12px;
  font-size: 0.85rem;
  line-height: 1.5;
  color: #ff6b6b;
  background-color: rgba(220, 53, 69, 0.1);
  border: 1px solid rgba(220, 53, 69, 0.3);
  border-radius: 8px;
}
.upload-error[hidden] {
  display: none;
}

/* ---------- Imaginile din text: mărire la click ---------- */
.section-view img {
  cursor: zoom-in;
}
.section-view img:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}

.lightbox {
  max-width: 95vw;
  max-height: 95vh;
  padding: 0;
  overflow: visible;
  background: transparent;
  border: none;
}
.lightbox::backdrop {
  background-color: rgba(0, 0, 0, 0.85);
}
.lightbox-bar {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-bottom: 8px;
}
.lightbox-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 0.85rem;
  color: #fff;
  text-decoration: none;
  background-color: rgba(255, 255, 255, 0.12);
  border: none;
  border-radius: 8px;
  cursor: pointer;
}
.lightbox-btn:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.2);
}
.lightbox-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.lightbox-image {
  display: block;
  max-width: 95vw;
  max-height: 85vh;
  margin: 0 auto;
  border-radius: 8px;
}

/* ---------- Document în curs de încărcare ---------- */
.section-file.is-uploading {
  color: #a0a0a0;
}
.upload-spinner {
  flex-shrink: 0;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: #5B8DEF;
  border-radius: 50%;
  animation: upload-spin 0.8s linear infinite;
}
@keyframes upload-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .upload-spinner { animation: none; }
}

/* ---------- Members: spațiul folosit (<progress> nativ) ---------- */
.storage-bar {
  display: block;
  width: 100%;
  height: 8px;
  overflow: hidden;
  appearance: none;               /* fără stilul implicit al sistemului */
  background-color: rgba(255, 255, 255, 0.08);
  border: none;
  border-radius: 4px;
}
/* Safari / Chrome desenează bara prin două pseudo-elemente */
.storage-bar::-webkit-progress-bar {
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
}
.storage-bar::-webkit-progress-value {
  background-color: #5B8DEF;
  border-radius: 4px;
}
/* Firefox are un singur pseudo-element */
.storage-bar::-moz-progress-bar {
  background-color: #5B8DEF;
  border-radius: 4px;
}
/* peste 90%: avertizare */
.storage-bar.is-almost-full::-webkit-progress-value {
  background-color: #f59e0b;
}
.storage-bar.is-almost-full::-moz-progress-bar {
  background-color: #f59e0b;
}

/* ============ BANNER: email neconfirmat ============ */
.verify-banner {
  display: flex;
  flex-shrink: 0;                 /* în .app-shell (coloană flex) nu se turtește */
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 10px 48px;
  font-size: 0.875rem;
  color: #fde68a;
  background-color: rgba(245, 158, 11, 0.12);
  border-bottom: 1px solid rgba(245, 158, 11, 0.3);
}
.verify-banner .bi {
  flex-shrink: 0;
  color: #f59e0b;
}
.verify-banner-text {
  flex: 1;
  min-width: 0;
}
.verify-banner form {
  margin: 0;
}
.verify-banner-btn {
  padding: 4px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #1f1f1f;
  background-color: #f59e0b;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.verify-banner-btn:hover {
  background-color: #fbbf24;
}
.verify-banner-btn:focus-visible {
  outline: 2px solid #fde68a;
  outline-offset: 2px;
}

@media (max-width: 768px) {
  .verify-banner {
    padding: 10px 16px;
  }
}

/* ============ CĂUTARE ============ */
/* butonul din sidebar */
.sidebar-search-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-bottom: 16px;
  padding: 7px 10px;
  font-size: 0.85rem;
  text-align: left;
  color: #a0a0a0;
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
  cursor: pointer;
}
.sidebar-search-btn:hover {
  color: #fff;
  border-color: #a0a0a0;
}
.sidebar-search-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}
.shortcut-hint {
  margin-left: auto;
  padding: 1px 6px;
  font-family: inherit;
  font-size: 0.7rem;
  color: #a0a0a0;
  background-color: rgba(255, 255, 255, 0.06);   /* Bootstrap colorează <kbd> închis, cu text alb */
  border: 1px solid var(--bs-border-color);
  border-radius: 4px;
}

/* fereastra */
.search-dialog {
  width: min(640px, calc(100vw - 24px));
  max-height: min(70vh, 560px);
  margin: 10vh auto auto;
  padding: 0;
  overflow: hidden;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 12px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
}
.search-dialog[open] {
  display: flex;
  flex-direction: column;
}
.search-dialog::backdrop {
  background-color: rgba(0, 0, 0, 0.6);
}
.search-box {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.search-box .bi-search {
  color: #a0a0a0;
}
.search-box input {
  flex: 1;
  min-width: 0;
  font-size: 1rem;                /* 16px: iOS nu mai mărește pagina la focus */
  color: var(--bs-body-color);
  background: transparent;
  border: none;
  outline: none;
}
.search-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  padding: 0;
  color: #a0a0a0;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}
.search-close:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
}

/* rezultatele */
.search-results {
  overflow-y: auto;
  padding: 6px;
}
.search-hint,
.search-more {
  margin: 0;
  padding: 24px 16px;
  text-align: center;
  font-size: 0.9rem;
  color: #a0a0a0;
}
.search-more {
  padding: 8px 16px;
  font-size: 0.8rem;
}
.search-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.search-result {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  color: inherit;
  text-decoration: none;
  border-radius: 8px;
}
.search-result:hover,
.search-result:focus-visible {
  color: inherit;
  background-color: rgba(91, 141, 239, 0.12);
  outline: none;
}
.search-result-title {
  font-size: 0.95rem;
  font-weight: 600;
}
.search-result-path {
  font-size: 0.75rem;
  color: #a0a0a0;
}
.search-result-snippet {
  font-size: 0.85rem;
  line-height: 1.5;
  color: #cfcfcf;
}
.search-result-where {
  margin-right: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: #a0a0a0;
}
.search-results mark {
  padding: 0 2px;
  color: #1f1f1f;
  background-color: #fde68a;
  border-radius: 3px;
}

@media (max-width: 768px) {
  .search-dialog {
    max-height: 85vh;
    margin-top: 12px;
  }
  .shortcut-hint {
    display: none;                /* pe telefon nu există tastatură fizică */
  }
}

/* ---------- Fereastra de confirmare ---------- */
.confirm-message {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5;
}
.dialog-btn-danger {
  color: #fff;
  background-color: #dc3545;
  border-color: #dc3545;
}
.dialog-btn-danger:hover {
  background-color: #bb2d3b;
  border-color: #bb2d3b;
}
.dialog-btn:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}

/* ---------- Confirmare prin scrierea numelui ---------- */
.danger-label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.85rem;
  color: #a0a0a0;
}
.danger-label strong {
  color: var(--bs-body-color);
}
.danger-row {
  display: flex;
  gap: 8px;
}
.danger-row input[type="text"] {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  font-size: 0.95rem;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
}
.danger-row input[type="text"]:focus {
  outline: none;
  border-color: #dc3545;
}
.dialog-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

@media (max-width: 768px) {
  .danger-row input[type="text"] {
    font-size: 16px;               /* iOS nu mai mărește pagina la focus */
  }
}
@media (max-width: 380px) {
  .danger-row {
    flex-direction: column;
  }
}

/* ============ ACCOUNT ============ */
/* link-ul din navbar (avatar + email) */
.app-nav-account {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 4px 4px;
  color: inherit;
  text-decoration: none;
  border-radius: 20px;
}
.app-nav-account:hover {
  background-color: rgba(255, 255, 255, 0.06);
}
.app-nav-account:focus-visible {
  outline: 2px solid #5B8DEF;
  outline-offset: 2px;
}

/* formularele din paginile de setări */
.settings-form label {
  display: block;
  margin: 14px 0 6px;
  font-size: 0.85rem;
  font-weight: 600;
}
.settings-form .auth-label-row {
  margin-top: 14px;
  margin-bottom: 6px;
}
.settings-form .auth-label-row label {
  margin: 0;
}
.settings-form input[type="text"],
.settings-form input[type="password"] {
  width: 100%;
  padding: 9px 12px;
  font-size: 0.95rem;
  color: var(--bs-body-color);
  background-color: var(--bs-secondary-bg);
  border: 1px solid var(--bs-border-color);
  border-radius: 8px;
}
.settings-form input:focus {
  outline: none;
  border-color: #5B8DEF;
}
.settings-form input[aria-invalid="true"] {
  border-color: rgba(255, 107, 107, 0.6);
}
.settings-form button[type="submit"] {
  margin-top: 18px;
}
.settings-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.settings-row > div {
  min-width: 0;
}
a.row-action-btn {
  display: inline-block;
  text-decoration: none;
}

/* stări mici (email confirmat / neconfirmat) */
.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 8px;
  padding: 1px 8px;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 10px;
}
.status-ok {
  color: #4ade80;
  background-color: rgba(74, 222, 128, 0.12);
}
.status-warn {
  color: #f59e0b;
  background-color: rgba(245, 158, 11, 0.12);
}

@media (max-width: 768px) {
  .settings-form input[type="text"],
  .settings-form input[type="password"] {
    font-size: 16px;               /* iOS nu mai mărește pagina la focus */
  }
}
@media (max-width: 480px) {
  .settings-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

/* ---------- Ștergerea contului ---------- */
.page-card-warning {
  border-color: rgba(245, 158, 11, 0.4);
}
.page-card-warning .page-card-title .bi {
  color: #f59e0b;
}
.plain-list {
  margin: 0 0 12px;
  padding-left: 1.2em;
  font-size: 0.9rem;
  line-height: 1.7;
}
.plain-list li::marker {
  color: #a0a0a0;
}

/* ---------- Capturile produsului pe landing ---------- */
.demo-img,
.playbook-image img {
  border: 1px solid rgba(255, 255, 255, 0.14);        /* conturul: separă imaginea de fundal */
  border-radius: 12px;
  box-shadow:
    0 30px 80px -20px rgba(0, 0, 0, 0.8),             /* umbra: o ridică de pe pagină */
    0 0 120px -30px rgba(91, 141, 239, 0.45);         /* strălucirea albastră a brandului */
}

/* imaginea mare se estompează spre jos: pare că aplicația continuă */
.demo-img {
  -webkit-mask-image: linear-gradient(to bottom, #000 80%, transparent);
  mask-image: linear-gradient(to bottom, #000 80%, transparent);
}

/* ---------- Butonul Copy nu mai acoperă codul (fix pentru aplicație) ---------- */
.code-block pre {
  padding-right: 80px;                                 /* loc pentru butonul Copy din colț */
}