:root {
  --accent: #08b5ff;
  --bg-primary: #111;
  --bg-secondary: #000;
  --text-primary: #fff;
  --text-secondary: #aaa;
  --transition-duration: 0.3s;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Splash Screen */
#splash {
  position: fixed;
  inset: 0;
  background-color: var(--bg-secondary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 1s ease-in-out;
}
#splash.hide {
  opacity: 0;
  pointer-events: none;
}
#splash #logo {
  width: 500px;
  margin-bottom: 1rem;
  opacity: 0;
  transition: opacity 1s ease 0.5s;
}
#splash:not(.hide) #logo {
  opacity: 1;
}
#welcome-text {
  font-family: 'Courier New', monospace;
  font-size: 4rem;
  border-right: 0.15em solid var(--accent);
  white-space: nowrap;
  overflow: hidden;
}

/* Hero Section */
#hero {
  position: relative;
  min-height: 60vh;
  background:
    var(--bg-secondary) url('hero-bg.jpg') center/cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 600px;
  padding: 0 1rem;
}
.hero-logo {
  width: 350px;
  margin-bottom: 1rem;
  opacity: 0;
  animation: fadeIn 1s ease-out forwards 0.5s;
}
.hero-title {
  font-family: 'Courier New', monospace;
  font-size: 3rem;
  margin-bottom: 0.5rem;
  opacity: 0;
  animation: fadeIn 1s ease-out forwards 1s;
}
.hero-subtitle {
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  color: #aab;
  opacity: 0;
  animation: fadeIn 1s ease-out forwards 1.5s;
}
.btn-primary {
  display: inline-block;
  padding: 1rem 2rem;
  background: var(--accent);
  color: var(--text-primary);
  border-radius: 2rem;
  font-weight: bold;
  transition: background var(--transition-duration), transform var(--transition-duration);
  opacity: 0;
  animation: fadeIn 1s ease-out forwards 2s;
}
.btn-primary:hover {
  background: #0057c2;
  transform: translateY(-3px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
}

/* About Section */
#about {
  padding: 4rem 1rem;
  background: var(--bg-secondary);
}
.about-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  max-width: 1000px;
  margin: 0 auto;
  gap: 2rem;
}
.about-avatar {
  flex: 0 0 200px;
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid var(--accent);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  opacity: 0;
  animation: fadeIn 1s ease-out forwards 0.5s;
}
.about-text {
  flex: 1;
  opacity: 0;
  animation: fadeIn 1s ease-out forwards 1s;
}
.about-text h2 {
  font-family: 'Courier New', monospace;
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--accent);
}
.about-text p {
  margin: 0;
}
.social-links a {
  margin-right: 1rem;
  font-size: 1.5rem;
  color: var(--text-primary);
  transition: color var(--transition-duration);
}
.social-links a:hover {
  color: var(--accent);
}

/* Services Section */
#services {
  padding: 3rem 1rem;
  background: var(--bg-primary);
  text-align: center;
}
#services h2 {
  font-family: 'Courier New', monospace;
  font-size: 2.5rem;
  color: var(--accent);
  margin-bottom: 2rem;
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  max-width: 1000px;
  margin: 0 auto;
}
.service-card {
  background: var(--bg-secondary);
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transform: translateY(10px);
  animation: fadeIn 1s ease-out forwards;
  transition: transform var(--transition-duration), box-shadow var(--transition-duration);
}
.service-card:nth-child(1) { animation-delay: 0.5s; }
.service-card:nth-child(2) { animation-delay: 0.8s; }
.service-card:nth-child(3) { animation-delay: 1.1s; }
.service-card:nth-child(4) { animation-delay: 1.4s; }
.service-icon {
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.service-card h3 {
  margin-bottom: 0.5rem;
}
.service-card p {
  margin: 0;
  font-size: 0.95rem;
}

/* Contact Section */
#contact {
  padding: 2rem 1rem;
  background: var(--bg-secondary);
  text-align: center;
}
#contact h2 {
  font-family: 'Courier New', monospace;
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 1.5rem;
}
.contact-form {
  max-width: 400px;
  margin: 0 auto;
  text-align: left;
}
.form-row {
  margin-bottom: 1rem;
}
.form-row label {
  display: block;
  margin-bottom: 0.25rem;
  font-weight: bold;
}
.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #333;
  border-radius: 0.5rem;
  background: var(--bg-primary);
  color: var(--text-primary);
}
.contact-form .btn-primary {
  display: block;
  margin: 1rem auto 0;
}

/* Chat Widget */
#chat-button {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  background: var(--accent);
  color: var(--text-primary);
  border: none;
  border-radius: 50%;
  width: 3.5rem;
  height: 3.5rem;
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 10000;
}
#chat-modal {
  position: fixed;
  bottom: 5.5rem;
  right: 1.5rem;
  width: 300px;
  max-width: 90%;
  background: var(--bg-secondary);
  border: 1px solid #222;
  border-radius: 0.5rem;
  display: flex;
  flex-direction: column;
  transform: scale(0);
  transform-origin: bottom right;
  transition: transform var(--transition-duration);
  overflow: hidden;
  z-index: 9999;
}
#chat-modal.open { transform: scale(1); }
.chat-header {
  background: var(--accent);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1rem;
}
.chat-header span,
#chat-close {
  color: var(--text-primary);
}
#chat-close {
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
}
#chat-messages {
  flex: 1;
  padding: 0.5rem;
  overflow-y: auto;
  font-size: 0.9rem;
}
#chat-messages .message.user { text-align:right; color:var(--accent); }
#chat-messages .message.bot { text-align:left; color:var(--text-secondary); }
#chat-form {
  display: flex;
  border-top: 1px solid #333;
}
#chat-input {
  flex: 1;
  padding: 0.5rem;
  border: none;
  background: #222;
  color: var(--text-primary);
  font-size: 0.9rem;
}
#chat-form button {
  background: var(--accent);
  border: none;
  color: var(--text-primary);
  padding: 0 1rem;
  cursor: pointer;
}
#chat-form button:hover {
  filter: brightness(0.9);
}

/* Footer */
footer {
  text-align: center;
  padding: 1rem;
  background: var(--bg-secondary);
  color: var(--text-secondary);
  font-size: 0.9rem;
}
.norvak-icon {
  width: 60px;
  height: 60px;
  transition: transform var(--transition-duration), filter var(--transition-duration);
  filter: drop-shadow(0 0 5px rgba(0,255,204,0.3));
}
.norvak-icon:hover {
  transform: scale(1.1);
  filter: drop-shadow(0 0 10px rgba(0,255,204,0.6));
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Responsive */
@media (max-width: 600px) {
  .about-container {
    flex-direction: column;
    text-align: center;
  }
  .hero-title {
    font-size: 2.5rem;
  }
}
