/* ================================================
   CodeVibeX — Portfolio Styles
   ================================================ */

/* ── Filter Bar ── */
.portfolio-filters {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 2rem 0 0;
}

.filter-btn {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border-card);
  border-radius: 6px;
  padding: 0.5rem 1.2rem;
  cursor: pointer;
  transition: all 0.22s var(--ease);
}

.filter-btn:hover {
  border-color: var(--accent);
  color: var(--text-secondary);
}

.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 4px 16px var(--accent-glow);
}

/* ── Portfolio Grid ── */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

/* ── Portfolio Card ── */
.portfolio-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.3s var(--ease);
  display: flex;
  flex-direction: column;
}

.portfolio-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-6px);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45),
              0 0 0 1px var(--accent-dim);
}

/* ── Browser Chrome Preview ── */
.portfolio-preview {
  position: relative;
  overflow: hidden;
  background: #08090E;
}

.browser-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 1rem;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid var(--border-card);
}

.browser-dots {
  display: flex;
  gap: 5px;
  flex-shrink: 0;
}

.browser-dots span {
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
}

.browser-dots span:nth-child(1) { background: #FF5F57; }
.browser-dots span:nth-child(2) { background: #FEBC2E; }
.browser-dots span:nth-child(3) { background: #28C840; }

.browser-url {
  flex: 1;
  font-family: 'Space Grotesk', monospace;
  font-size: 0.72rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-card);
  border-radius: 4px;
  padding: 0.2rem 0.6rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.browser-open {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: color 0.2s var(--ease);
  flex-shrink: 0;
}

.browser-open:hover { color: var(--accent-light); }

.browser-open svg {
  width: 14px;
  height: 14px;
}

/* ── iFrame Viewport ── */
.iframe-wrap {
  position: relative;
  width: 100%;
  height: 260px;
  overflow: hidden;
}

.iframe-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  /* Gradient overlay: turns completely solid at 90% to prevent white bleeding through at the very bottom */
  background: linear-gradient(to bottom, rgba(12, 13, 20, 0) 40%, var(--bg-card) 90%, var(--bg-card) 100%);
  pointer-events: none;
  z-index: 1;
}

.card-overlay-link {
  position: absolute;
  inset: 0;
  z-index: 10;
}

.iframe-wrap iframe {
  width: 1280px;
  height: 900px;
  border: none;
  transform: scale(0.47);
  transform-origin: top left;
  pointer-events: none;
  display: block;
}

/* ── Portfolio Info ── */
.portfolio-info {
  padding: 1.5rem 1.75rem 2rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  position: relative;
  z-index: 2;
  margin-top: -2px;
}

.portfolio-tags {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
}

.ptag {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-card);
  border-radius: 4px;
  padding: 0.2rem 0.6rem;
  text-transform: uppercase;
}

.ptag--accent {
  color: var(--accent-light);
  background: var(--accent-dim);
  border-color: rgba(0, 87, 255, 0.2);
}

.portfolio-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.portfolio-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin: 0 0 1.25rem;
  flex: 1;
}

.portfolio-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-light);
  transition: gap 0.2s var(--ease), color 0.2s var(--ease);
  align-self: flex-start;
}

.portfolio-link:hover {
  gap: 0.65rem;
  color: var(--text-primary);
}

.portfolio-link svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

/* ── Enterprise Section ── */
.enterprise-section {
  border-top: 1px solid var(--border-card);
}

.enterprise-card {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 5rem;
  align-items: center;
  margin-top: 3rem;
}

.enterprise-info h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.8rem;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 1rem;
  letter-spacing: -0.03em;
}

.enterprise-info p {
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.enterprise-badge {
  display: inline-block;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-light);
  background: var(--accent-dim);
  border: 1px solid rgba(0, 87, 255, 0.25);
  border-radius: 4px;
  padding: 0.25rem 0.75rem;
  margin-bottom: 1rem;
}

.enterprise-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.75rem;
}

.enterprise-features li {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.enterprise-features li svg {
  width: 16px;
  height: 16px;
  stroke: var(--accent);
  fill: none;
  flex-shrink: 0;
}

.enterprise-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  font-style: italic;
}

/* ── CRM Dashboard Mockup ── */
.enterprise-visual {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 14px;
  overflow: hidden;
  position: relative;
}

.enterprise-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 30%, rgba(0, 87, 255, 0.08), transparent 65%);
  pointer-events: none;
}

.crm-mockup {
  display: flex;
  height: 340px;
}

.crm-sidebar {
  width: 140px;
  min-width: 140px;
  background: rgba(0, 0, 0, 0.25);
  border-right: 1px solid var(--border-card);
  padding: 1.25rem 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.crm-nav-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 0.5rem 0.6rem;
  border-radius: 6px;
  cursor: default;
  transition: all 0.2s var(--ease);
}

.crm-nav-item svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
  flex-shrink: 0;
}

.crm-nav-item--active {
  background: var(--accent-dim);
  color: var(--accent-light);
  border: 1px solid rgba(0, 87, 255, 0.2);
}

.crm-content {
  flex: 1;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.crm-stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.crm-stat {
  background: rgba(0, 87, 255, 0.06);
  border: 1px solid rgba(0, 87, 255, 0.15);
  border-radius: 8px;
  padding: 0.75rem;
  text-align: center;
}

.crm-stat-val {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 400;
  color: var(--text-primary);
  letter-spacing: -0.03em;
}

.crm-stat-lbl {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.2rem;
}

.crm-chart-placeholder {
  flex: 1;
  display: flex;
  align-items: flex-end;
  gap: 6px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-card);
  border-radius: 8px;
  padding: 0.75rem;
}

.crm-bar {
  flex: 1;
  background: rgba(0, 87, 255, 0.2);
  border-radius: 4px 4px 0 0;
  transition: background 0.2s var(--ease);
  animation: barGrow 1.2s var(--ease) both;
}

.crm-bar--accent {
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

@keyframes barGrow {
  from { transform: scaleY(0); transform-origin: bottom; }
  to   { transform: scaleY(1); }
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .enterprise-info h3 {
    display: none;
  }
  
  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .enterprise-card {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

@media (max-width: 768px) {
  .portfolio-filters {
    gap: 0.4rem;
  }

  .filter-btn {
    font-size: 0.76rem;
    padding: 0.4rem 0.9rem;
  }

  .crm-mockup {
    flex-direction: column;
    height: 380px;
  }

  .crm-sidebar {
    width: 100%;
    min-width: unset;
    flex-direction: row;
    justify-content: space-around;
    border-right: none;
    border-bottom: 1px solid var(--border-card);
    padding: 0.75rem 0.5rem;
  }
  .crm-nav-item {
    flex-direction: column;
    gap: 0.3rem;
    padding: 0.25rem;
    font-size: 0.65rem;
    text-align: center;
  }
  .crm-nav-item svg {
    width: 16px;
    height: 16px;
  }
  .crm-content {
    padding: 1rem;
    gap: 0.8rem;
  }
  .crm-stat-row {
    gap: 0.4rem;
  }
  .crm-stat {
    padding: 0.5rem;
  }
  .crm-stat-val {
    font-size: 1.1rem;
  }
  .crm-stat-lbl {
    font-size: 0.55rem;
  }
}




