/* ============================================
   ARCHETYPE PAGE STYLES
   Device frames, template previews, showcase
   ============================================ */

/* Archetype Hero */
.arch-hero {
  position: relative;
  padding: 120px 0 80px;
  overflow: hidden;
}

.arch-hero-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, #2c5f4a, #3a7d5f, #4a9670);
  z-index: 0;
}

.arch-hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.25;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
  background-size: 256px;
}

.arch-hero .container { position: relative; z-index: 1; }

.arch-back {
  display: inline-block;
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  margin-bottom: 32px;
  transition: color var(--transition);
}
.arch-back:hover { color: rgba(255,255,255,0.9); }

.arch-hero-content { max-width: 640px; }

.arch-hero .section-eyebrow { color: rgba(255,255,255,0.5); }

.arch-hero h1 {
  font-size: clamp(32px, 5vw, 52px);
  color: var(--white);
  margin-bottom: 20px;
}

.arch-hero-desc {
  font-size: 17px;
  color: rgba(255,255,255,0.7);
  line-height: 1.7;
  margin-bottom: 28px;
}

.arch-meta {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.arch-meta-item {
  font-size: 14px;
  color: rgba(255,255,255,0.5);
}

/* Template Gallery */
.template-gallery {
  padding: 80px 0;
  background: var(--paper);
}

.template-showcase {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 48px;
  align-items: center;
  padding: 64px 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.template-showcase:last-child { border-bottom: none; }

.template-showcase.reverse {
  grid-template-columns: 1.3fr 1fr;
}

.template-showcase.reverse .template-info { order: 2; }
.template-showcase.reverse .template-devices { order: 1; }

.template-number {
  display: block;
  font-family: var(--font-display);
  font-size: 48px;
  color: rgba(0,0,0,0.08);
  line-height: 1;
  margin-bottom: 8px;
}

.template-info h2 {
  font-size: clamp(28px, 3.5vw, 40px);
  margin-bottom: 8px;
}

.template-tagline {
  font-size: 16px;
  color: var(--accent-dark);
  font-style: italic;
  margin-bottom: 16px;
}

.template-desc {
  font-size: 15px;
  color: var(--ink-muted);
  line-height: 1.7;
  margin-bottom: 20px;
}

.template-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}

.template-features span {
  font-size: 12px;
  font-weight: 500;
  padding: 4px 12px;
  background: var(--paper-warm);
  border-radius: 100px;
  color: var(--ink-muted);
  border: 1px solid rgba(0,0,0,0.06);
}

.template-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.template-actions .btn { padding: 12px 24px; font-size: 14px; }

/* ============================================
   DEVICE FRAMES
   ============================================ */

.template-devices {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  justify-content: center;
}

/* Laptop frame */
.device-frame-laptop {
  width: 420px;
  flex-shrink: 0;
}

.device-bezel {
  background: #222;
  border-radius: 12px 12px 0 0;
  padding: 8px 8px 0;
  position: relative;
}

.device-bezel::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #444;
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translateX(-50%);
}

.device-screen-inner {
  width: 100%;
  aspect-ratio: 16/10;
  background: var(--white);
  border-radius: 2px 2px 0 0;
  overflow: hidden;
}

.device-base {
  height: 14px;
  background: linear-gradient(to bottom, #333, #444);
  border-radius: 0 0 4px 4px;
  position: relative;
}

.device-base::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 4px;
  background: #555;
  border-radius: 0 0 8px 8px;
}

/* Phone frame */
.device-frame-phone {
  width: 100px;
  flex-shrink: 0;
}

.phone-bezel {
  background: #222;
  border-radius: 16px;
  padding: 10px 4px;
  position: relative;
}

.phone-notch {
  width: 32px;
  height: 4px;
  background: #333;
  border-radius: 4px;
  margin: 0 auto 6px;
}

.phone-screen {
  width: 100%;
  aspect-ratio: 9/18;
  background: var(--white);
  border-radius: 4px;
  overflow: hidden;
}

/* ============================================
   TEMPLATE PREVIEW MOCKUPS
   Miniature website layouts inside frames
   ============================================ */

.tmpl-preview {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

/* Shared preview elements */
.tp-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
}

.tp-logo {
  width: 28px;
  height: 6px;
  border-radius: 3px;
}

.tp-nav-links {
  display: flex;
  gap: 8px;
}

.tp-link {
  width: 28px;
  height: 5px;
  border-radius: 2px;
}

.tp-cta {
  width: 44px;
  height: 16px;
  border-radius: 8px;
}

.tp-hamburger {
  width: 14px;
  height: 10px;
  border-top: 2px solid;
  border-bottom: 2px solid;
  position: relative;
}
.tp-hamburger::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background: inherit;
  transform: translateY(-50%);
}

.tp-hero {
  padding: 24px 16px;
}

.tp-hero-text { max-width: 70%; }

.tp-eyebrow {
  width: 50px;
  height: 4px;
  border-radius: 2px;
  margin-bottom: 10px;
}

.tp-h1 {
  height: 10px;
  border-radius: 3px;
  margin-bottom: 6px;
}

.tp-p {
  height: 6px;
  width: 80%;
  border-radius: 3px;
  margin: 10px 0;
}

.tp-btn {
  width: 70px;
  height: 20px;
  border-radius: 10px;
  margin-top: 12px;
}

.tp-section {
  padding: 16px 12px;
}

.tp-cards {
  display: flex;
  gap: 6px;
}

.tp-card {
  flex: 1;
  height: 40px;
  border-radius: 4px;
}

/* ============================================
   CTA BANNER
   ============================================ */

.arch-cta {
  padding: 80px 0;
  background: var(--ink);
  text-align: center;
}

.arch-cta h2 {
  font-size: clamp(28px, 4vw, 42px);
  color: var(--white);
  margin-bottom: 16px;
}

.arch-cta p {
  font-size: 17px;
  color: rgba(255,255,255,0.6);
  margin-bottom: 32px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.arch-cta .btn-primary {
  background: var(--accent);
}
.arch-cta .btn-primary:hover { background: var(--accent-light); }

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 900px) {
  .template-showcase,
  .template-showcase.reverse {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .template-showcase.reverse .template-info { order: 0; }
  .template-showcase.reverse .template-devices { order: 0; }
  .device-frame-laptop { width: 320px; }
  .device-frame-phone { width: 80px; }
  .template-devices { justify-content: center; }
  .arch-meta { flex-direction: column; gap: 8px; }
}

@media (max-width: 600px) {
  .device-frame-laptop { width: 260px; }
  .device-frame-phone { width: 64px; }
  .template-actions { flex-direction: column; }
  .template-actions .btn { width: 100%; }
}
