/* HARMONIC - Architecture Page Styles
   =================================================== */

/* Page Header */
.page-header {
  padding: calc(64px + var(--space-lg)) 0 var(--space-md);
  background: var(--color-bg-secondary);
  border-bottom: 1px solid var(--color-border);
}

.page-header-content {
  text-align: center;
}

.page-header h1 {
  font-size: 1.75rem;
  margin-bottom: var(--space-sm);
  color: var(--color-primary);
}

.page-header p {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* Architecture Section */
.architecture-section {
  padding: var(--space-xl) 0;
}

.architecture-intro {
  text-align: center;
  margin-bottom: var(--space-lg);
}

.architecture-intro p {
  max-width: 800px;
  margin: 0 auto;
}

.architecture-hint {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 6px var(--space-md);
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-full);
  color: var(--color-accent);
  font-size: 0.85rem;
}

/* Interactive Architecture Container */
.architecture-container {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: var(--space-lg);
  align-items: start;
}

/* Architecture Diagram */
.architecture-diagram {
  position: relative;
  border-radius: var(--radius-md);
  overflow: visible;
  box-shadow: var(--shadow-md);
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
}

.architecture-diagram img {
  width: 100%;
  display: block;
  border-radius: var(--radius-md);
}

/* Hotspots */
.hotspot {
  position: absolute;
  width: 22px;
  height: 22px;
  margin-left: -11px;
  margin-top: -11px;
  cursor: pointer;
  z-index: 10;
  transition: all var(--transition-base);
}

.hotspot::before {
  content: '';
  position: absolute;
  inset: 0;
  background: #ffd700;
  border: 2px solid #000;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: all var(--transition-base);
}

.hotspot::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  background: #8a2be2;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: all var(--transition-base);
}

.hotspot:hover::before {
  background: #ffff00;
  transform: scale(1.1);
}

.hotspot.active::before {
  animation: hotspot-pulse 2s ease-in-out infinite alternate;
}

.hotspot.active::after {
  background: #ff0000;
  box-shadow: 0 0 8px rgba(255, 0, 0, 0.8);
}

@keyframes hotspot-pulse {
  0% {
    background: #ffd700;
    border-color: #000;
    transform: scale(1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  }
  100% {
    background: #ffa500;
    border-color: #ff0000;
    transform: scale(1.2);
    box-shadow:
      0 0 15px rgba(255, 0, 0, 1),
      0 0 25px rgba(255, 0, 0, 0.8),
      0 0 35px rgba(255, 0, 0, 0.6);
  }
}

/* Hotspot color variants */
.hotspot.dark-blue::after { background: #1e3a8a; }
.hotspot.dark-blue:hover::after { background: #1e40af; }
.hotspot.dark-blue.active::after { background: #ff0000; }

.hotspot.navy-blue::after { background: #1e40af; }
.hotspot.navy-blue:hover::after { background: #2563eb; }
.hotspot.navy-blue.active::after { background: #ff0000; }

.hotspot.black::after { background: #000000; }
.hotspot.black:hover::after { background: #333333; }
.hotspot.black.active::after { background: #ff0000; }

.hotspot.deep-green::after { background: #065f46; }
.hotspot.deep-green:hover::after { background: #047857; }
.hotspot.deep-green.active::after { background: #ff0000; }

.hotspot.dark-green::after { background: #166534; }
.hotspot.dark-green:hover::after { background: #15803d; }
.hotspot.dark-green.active::after { background: #ff0000; }

/* Info Panel */
.info-panel {
  background: linear-gradient(135deg, rgba(253, 253, 233, 0.98), rgba(253, 253, 233, 0.95));
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 80px;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
}

.info-panel-default {
  text-align: center;
  padding: var(--space-xl);
  color: #666;
}

.info-panel-default i {
  font-size: 2rem;
  color: var(--color-accent);
  margin-bottom: var(--space-sm);
  display: block;
}

.info-panel-default h3 {
  color: #333;
  margin-bottom: var(--space-xs);
  font-size: 1.1rem;
}

.info-panel-default p {
  color: #666;
  font-size: 0.85rem;
}

.info-panel-content h3 {
  color: #2c3e50;
  font-size: 1.1rem;
  margin-bottom: var(--space-sm);
  padding-bottom: var(--space-xs);
  border-bottom: 2px solid #333;
}

.info-panel-content p {
  color: #333;
  font-size: 0.9rem;
  line-height: 1.6;
  text-align: justify;
}

.info-panel-content video,
.info-panel-content img {
  width: 100%;
  border-radius: var(--radius-sm);
  margin-top: var(--space-sm);
  cursor: pointer;
  transition: transform var(--transition-base);
}

.info-panel-content video:hover,
.info-panel-content img:hover {
  transform: scale(1.02);
}

.info-panel-caption {
  text-align: center;
  font-size: 0.8rem;
  color: #666;
  font-style: italic;
  margin-top: var(--space-xs);
}

/* Layer Descriptions */
.layers-section {
  padding: var(--space-xl) 0;
  background: var(--color-bg-secondary);
}

.layers-section .section-header {
  margin-bottom: var(--space-lg);
}

.layers-section .section-title {
  font-size: 1.5rem;
  margin-bottom: var(--space-xs);
}

.layers-section .section-subtitle {
  font-size: 0.9rem;
}

.layers-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
}

.layer-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  position: relative;
  overflow: hidden;
}

.layer-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
}

.layer-card.strategic::before {
  background: linear-gradient(90deg, #1e40af, #3b82f6);
}

.layer-card.tactical::before {
  background: linear-gradient(90deg, #065f46, #10b981);
}

.layer-badge {
  display: inline-block;
  padding: 3px 8px;
  font-size: 0.7rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}

.layer-card.strategic .layer-badge {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
}

.layer-card.tactical .layer-badge {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.layer-card h3 {
  font-size: 1.1rem;
  margin-bottom: var(--space-sm);
}

.layer-card .card-description {
  font-size: 0.85rem;
  margin-bottom: var(--space-sm);
}

.layer-card ul {
  list-style: none;
  margin-top: var(--space-sm);
}

.layer-card li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin-bottom: 4px;
  color: var(--color-text-secondary);
  font-size: 0.85rem;
}

.layer-card li i {
  color: var(--color-accent);
  margin-top: 3px;
  font-size: 0.75rem;
}

/* Figure Caption */
.figure-caption {
  text-align: center;
  margin-top: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  background: var(--color-bg-card);
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  font-size: 0.85rem;
  line-height: 1.5;
}

.figure-caption p {
  margin: 0;
}

/* Responsive */
@media (max-width: 1200px) {
  .architecture-container {
    grid-template-columns: 1fr 300px;
  }
}

@media (max-width: 1024px) {
  .architecture-container {
    grid-template-columns: 1fr;
  }

  .info-panel {
    position: static;
    max-height: none;
    order: -1;
  }

  .layers-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .page-header {
    padding: calc(64px + var(--space-md)) 0 var(--space-sm);
  }

  .page-header h1 {
    font-size: 1.5rem;
  }

  .hotspot {
    width: 18px;
    height: 18px;
    margin-left: -9px;
    margin-top: -9px;
  }

  .hotspot::after {
    width: 6px;
    height: 6px;
  }

  .architecture-section,
  .layers-section {
    padding: var(--space-lg) 0;
  }
}
