/* Portfolio Styles - Mobile-first responsive design */

.portfolio-hero {
  text-align: center;
  padding: 8rem 1.5rem 4rem;
  max-width: 800px;
  margin: 0 auto;
}

.portfolio-hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #ffffff, #00aaff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.portfolio-hero .subtitle {
  font-size: 1.4rem;
  color: #ccc;
  margin-bottom: 2rem;
}

.portfolio-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.cta-button {
  padding: 0.8rem 1.5rem;
  border: 2px solid #00aaff;
  border-radius: 8px;
  color: #00aaff;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
}

.cta-button:hover {
  background: #00aaff;
  color: #000;
  box-shadow: 0 0 20px rgba(0, 170, 255, 0.3);
}

.cta-button.primary {
  background: #00aaff;
  color: #000;
}

.cta-button.primary:hover {
  background: #0088cc;
  box-shadow: 0 0 20px rgba(0, 170, 255, 0.5);
}

.why-me-section {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 2rem;
  margin: 2rem auto 4rem;
  max-width: 800px;
  backdrop-filter: blur(10px);
}

.why-me-section h2 {
  color: #00aaff;
  margin-bottom: 1.5rem;
  font-size: 1.8rem;
}

.why-me-list {
  list-style: none;
  padding: 0;
}

.why-me-list li {
  padding: 0.8rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: #ccc;
  line-height: 1.6;
}

.why-me-list li:last-child {
  border-bottom: none;
}

.why-me-list li::before {
  content: "→";
  color: #00aaff;
  font-weight: bold;
  margin-right: 0.8rem;
}

/* Portfolio Grid */
.portfolio-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
}

@media (min-width: 1024px) {
  .portfolio-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Case Card Styles */
.case-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 2rem;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.case-card:hover {
  border-color: rgba(0, 170, 255, 0.3);
  box-shadow: 0 8px 32px rgba(0, 170, 255, 0.1);
  transform: translateY(-2px);
}

.case-card-title {
  font-size: 1.4rem;
  color: #fff;
  margin-bottom: 1rem;
  line-height: 1.3;
}

.case-card-oneliner {
  font-size: 1.1rem;
  color: #ccc;
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

.case-card-content h4 {
  color: #00aaff;
  font-size: 1rem;
  margin: 1.5rem 0 0.8rem 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.case-card-outcomes ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.case-card-outcomes li {
  padding: 0.3rem 0;
  color: #ccc;
  line-height: 1.5;
}

.case-card-outcomes li::before {
  content: "✓";
  color: #00aaff;
  font-weight: bold;
  margin-right: 0.5rem;
}

/* Stack Badges */
.stack-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.stack-badge {
  background: rgba(0, 170, 255, 0.1);
  border: 1px solid rgba(0, 170, 255, 0.3);
  color: #00aaff;
  padding: 0.3rem 0.8rem;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 500;
}

.stack-badge.more-badge {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.2);
  color: #ccc;
  cursor: help;
}

/* Screenshot Strip */
.screenshot-strip {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding: 0.8rem 0;
  margin-bottom: 1rem;
}

.screenshot-thumb {
  flex-shrink: 0;
  width: 180px;
  cursor: pointer;
  transition: all 0.3s ease;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
}

.screenshot-thumb:hover,
.screenshot-thumb:focus {
  border-color: #00aaff;
  box-shadow: 0 8px 24px rgba(0, 170, 255, 0.4);
  transform: translateY(-2px) scale(1.02);
  outline: none;
}

.screenshot-thumb img {
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.screenshot-label {
  display: block;
  font-size: 0.8rem;
  color: #fff;
  padding: 0.5rem 0.8rem;
  text-align: center;
  font-weight: 500;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
}

.mobile-badge {
  background: rgba(0, 170, 255, 0.2);
  color: #00aaff;
  padding: 0.3rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
  margin-left: 0.5rem;
}

.no-screenshots {
  color: #666;
  font-style: italic;
  text-align: center;
  padding: 1rem;
}

/* Project Links */
.case-card-links {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.project-link {
  color: #00aaff;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.project-link:hover {
  color: #ffffff;
}

.project-link.disabled {
  color: #666;
  cursor: not-allowed;
}

/* Disclosure */
.case-card-disclosure {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.case-card-disclosure small {
  color: #888;
  font-style: italic;
}

/* Screenshot Modal */
.screenshot-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.95);
}

.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
}

.modal-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 2rem;
  backdrop-filter: blur(20px);
  z-index: 10001;
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
  z-index: 10002;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
}

.modal-content img {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 8px;
  display: block;
  margin: 0 auto;
}

.modal-caption {
  text-align: center;
  margin-top: 1rem;
}

.modal-caption h4 {
  color: #00aaff;
  margin-bottom: 0.5rem;
}

.modal-caption p {
  color: #ccc;
  font-size: 0.9rem;
}

/* Empty State */
.portfolio-empty {
  text-align: center;
  padding: 4rem 2rem;
  color: #666;
}

.portfolio-empty h3 {
  color: #aaa;
  margin-bottom: 1rem;
}

/* Loading State */
.portfolio-loading {
  text-align: center;
  padding: 4rem 2rem;
  color: #00aaff;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(0, 170, 255, 0.2);
  border-top: 3px solid #00aaff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Mobile Optimizations */
@media (max-width: 768px) {
  .portfolio-hero h1 {
    font-size: 2.5rem;
  }
  
  .portfolio-hero .subtitle {
    font-size: 1.2rem;
  }
  
  .portfolio-cta {
    flex-direction: column;
    align-items: center;
  }
  
  .cta-button {
    width: 100%;
    max-width: 280px;
    text-align: center;
  }
  
  .case-card {
    padding: 1.5rem;
  }
  
  .case-card-title {
    font-size: 1.2rem;
  }
  
  .screenshot-strip {
    gap: 0.8rem;
  }
  
  .screenshot-thumb {
    width: 150px;
  }
  
  .screenshot-thumb img {
    height: 100px;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .case-card {
    border-color: rgba(255, 255, 255, 0.3);
  }
  
  .stack-badge {
    border-color: rgba(0, 170, 255, 0.6);
  }
}