/* === Global / Grundinställningar === */
:root {
  --bg: #000;
  --text: #fff;
  --muted: #bdbdbd;
  --box-gradient: linear-gradient(135deg, #c15cff, #ff6ad1);
  --accent: #ff007a;
  scroll-behavior: smooth;
  font-family: 'Montserrat', system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body { display: flex; flex-direction: column; background: var(--bg); color: var(--text); overflow-x: hidden; }
header, footer { width: 100%; }
main { flex: 1; }

/* === GPU Hero Animation === */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

/* Rosa lådan */
.gpu-box {
  position: absolute;
  margin-left: 300px;
  top: 300px; /* Start längre ner */
  width: 400px;
  height: 400px;
  background: var(--accent);
  border-radius: 25px;
  transform-origin: center;
  transition: transform 0.25s ease-out;
  z-index: 5;
  opacity: 0.9;
  box-shadow: 0 0 40px rgba(255, 0, 122, 0.3);
}

/* Grafikkortet */
.gpu-image {
  position: absolute;
  margin-left: 300px;
  top: 350px; /* Flyttad längre ner så bara toppen syns */
  transform: translateX(-50%) rotate(95deg); /* Startar lutad */
  width: 450px;
  height: auto;
  max-width: 90vw;
  object-fit: contain;
  z-index: 10;
  transition: transform 0.25s ease-out, opacity 0.4s ease-out;
  opacity: 1;
}

/* === Parallax Text (quote) === */
.parallax {
  position: absolute;
  width: 100%;
  text-align: center;
  top: 40%;
  left: 0;
  color: var(--text);
  opacity: 0.9;
  transform: translateY(0);
  transition: transform 0.25s ease-out;
  font-size: 1.2rem; /* Normal textstorlek */
  line-height: 1.5;
  padding: 0 20px;
}

/* === DATOR2 === */
.dator2-section {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 5%;
}

.dator2-wrapper {
  display: flex;
  align-items: center;
  gap: 40px;
  max-width: 1200px;
  width: 100%;
}

.computer-target {
  width: 400px;
  max-width: 45%;
  z-index: 20;
}

.dator2-text {
  color: #fff;
  flex: 1;
}

.dator2-text h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.dator2-text p {
  color: var(--muted);
  line-height: 1.5;
  font-size: 1rem;
}

/* === CPU-sektion === */
.cpu-section {
  background: #111;
  padding: 80px 5%;
}

.cpu-wrapper {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
  justify-content: center;
}

.cpu-item {
  position: relative;
  width: 45%;
  min-width: 280px;
  overflow: hidden;
  border-radius: 14px;
  background: #222;
  color: #fff;
  transition: transform .5s ease, opacity .5s ease;
}

.cpu-item img { width: 100%; display: block; }
.cpu-item figcaption { padding: 20px; }
.cpu-item h3 { margin-bottom: 0.5rem; font-size: 1.5rem; }
.cpu-item p { font-size: 1rem; color: var(--muted); }

/* === Exempelkort === */
.content-section {
  padding: 80px 6%;
  display: grid;
  gap: 28px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  background: #000;
}

.info-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  padding: 28px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.03);
  color: var(--text);
  transition: transform .4s ease, box-shadow .4s ease;
}

.info-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 12px 28px rgba(0,0,0,0.5);
}

.youtube-card {
  color: white;
  background: #ff0000;
  position: relative;
  overflow: hidden;
}

.youtube-card:hover {
  background: #cc0000;
}

.youtube-card:hover::after {
  content: url('../bilder/youtube-logo.png');
  position: absolute;
  right: 10px;
  top: 10px;
  width: 40px;
  height: 40px;
  animation: pop 0.5s ease forwards;
}

@keyframes pop {
  0% { transform: scale(0); }
  100% { transform: scale(1); }
}

/* === Footer === */
footer {
  background: #111;
  color: var(--muted);
  padding: 40px 5%;
  text-align: center;
  font-size: 14px;
}

footer .socials {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 10px;
}

footer .socials a {
  color: var(--muted);
  transition: color .3s;
}

footer .socials a:hover {
  color: var(--accent);
}

footer .footer-logo {
  width: 120px;
  display: block;
  margin: 0 auto 12px auto;
}

/* === Reveal-animation === */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
