/* ── Dashboard ── */

/* Login overlay */
.login-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-box {
  text-align: center;
  max-width: 320px;
  width: 100%;
  padding: 0 1.5rem;
}

.login-box h2 {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--black);
  margin-bottom: 2rem;
}

.login-input {
  width: 100%;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 300;
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
}

.login-input:focus {
  border-color: var(--black);
}

.login-input::placeholder {
  color: var(--muted);
}

.login-btn {
  width: 100%;
  margin-top: 1rem;
  padding: 0.8rem 1rem;
  background: var(--red);
  color: #fff;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.login-btn:hover {
  background: #a30000;
}

.login-error {
  font-size: 0.8rem;
  color: var(--red);
  margin-top: 0.75rem;
  min-height: 1.2em;
}

/* Dashboard content */
.dash-hidden {
  display: none;
}

.dashboard {
  padding: 80px 0 140px;
}

.dash-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 4rem;
}

.dash-header .section-title {
  margin-bottom: 0;
}

.dash-logout {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
  transition: color 0.2s;
}

.dash-logout:hover {
  color: var(--red);
}

/* Project grid */
.dash-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.dash-card {
  background: var(--bg-alt);
  padding: 40px;
  cursor: pointer;
  transition: border-color 0.3s;
  border-top: 3px solid var(--border);
}

.dash-card:hover {
  border-color: var(--red);
}

.dash-card-logo {
  height: 36px;
  max-width: 140px;
  object-fit: contain;
  object-position: left;
  display: block;
  margin-bottom: 1.5rem;
}

.dash-card-status {
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.75rem;
}

.dash-card-status.active {
  color: #1a8a3f;
}

.dash-card-status.active::before {
  content: '\25CF ';
  animation: pulse-dot 2s ease-in-out infinite;
}

.dash-card-name {
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 0.75rem;
}

.dash-card-summary {
  font-size: 0.95rem;
  font-weight: 300;
  line-height: 1.7;
  color: var(--text);
}

/* Project detail view */
.dash-detail {
  display: none;
  padding: 80px 0 140px;
}

.dash-detail.visible {
  display: block;
}

.dash-detail-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.dash-copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--muted);
  background: none;
  border: 1px solid var(--muted);
  border-radius: 6px;
  padding: 0.35rem 0.75rem;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.2s, border-color 0.2s;
}

.dash-copy-btn:hover {
  color: var(--black);
  border-color: var(--black);
}

.dash-copy-btn.copied {
  color: #16a34a;
  border-color: #16a34a;
}

.dash-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--black);
  color: #fff;
  font-size: 0.85rem;
  padding: 0.6rem 1.2rem;
  border-radius: 8px;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  pointer-events: none;
  z-index: 999;
}

.dash-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.dash-back {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
  background: none;
  border: none;
  font-family: inherit;
  margin-bottom: 2rem;
  display: inline-block;
  transition: color 0.2s;
}

.dash-back:hover {
  color: var(--red);
}

.dash-detail-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.dash-detail-logo {
  height: 40px;
  max-width: 160px;
  object-fit: contain;
}

.dash-detail-status {
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #1a8a3f;
}

.dash-detail-status::before {
  content: '\25CF ';
  animation: pulse-dot 2s ease-in-out infinite;
}

.dash-detail-desc {
  font-size: 1.05rem;
  font-weight: 300;
  line-height: 1.75;
  color: var(--text);
  max-width: 65ch;
  margin-bottom: 3rem;
}

.dash-detail-link {
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--red);
  text-decoration: none;
  margin-bottom: 4rem;
  display: inline-block;
  transition: opacity 0.2s;
}

.dash-detail-link:hover {
  opacity: 0.7;
}

/* Timeline section */
.dash-section-title {
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.dash-timeline {
  margin-bottom: 4rem;
}

.dash-update {
  display: flex;
  gap: 1.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--bg-alt);
}

.dash-update-date {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--muted);
  white-space: nowrap;
  min-width: 90px;
}

.dash-update-items {
  flex: 1;
}

.dash-update-text {
  font-size: 0.95rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--text);
}

.dash-update-text::before {
  content: '\2022 ';
  color: var(--muted);
}

.dash-update-text + .dash-update-text {
  margin-top: 0.25rem;
}

/* Planned items */
.dash-planned-list {
  list-style: none;
}

.dash-planned-list li {
  font-size: 0.95rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--text);
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--bg-alt);
}

.dash-planned-list li::before {
  content: '\2192 ';
  color: var(--muted);
}

/* Responsive */
@media (max-width: 768px) {
  .dash-grid {
    grid-template-columns: 1fr;
  }

  .dash-card {
    padding: 24px;
  }

  .dashboard,
  .dash-detail {
    padding: 40px 0 80px;
  }

  .dash-update {
    flex-direction: column;
    gap: 0.25rem;
  }
}
