/* ==========================================================================
   JuusyWare - Homepage
   ========================================================================== */

:root {
  /* Purple & Cyan color scheme */
  --bg: #0a0b0f;
  --bg-alt: #14161d;
  --card: rgba(20, 22, 29, 0.72);
  --card-solid: #14161d;
  --card-border: rgba(255, 255, 255, 0.065);
  --card-border-strong: rgba(255, 255, 255, 0.11);
  --hover: rgba(255, 255, 255, 0.05);
  --hover-strong: rgba(255, 255, 255, 0.10);

  --text: #edeef2;
  --text-2: #a4a8b4;
  --text-3: #6b707d;

  --accent: #00d9ff;        /* Cyan */
  --accent-2: #8f7cff;      /* Purple */
  --accent-soft: rgba(0, 217, 255, 0.12);
  --accent-line: rgba(0, 217, 255, 0.32);

  --radius: 18px;
  --radius-sm: 11px;
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.03) inset, 0 20px 50px -20px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 20px 60px -20px rgba(0, 0, 0, 0.8);

  --font: "Inter", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", sans-serif;
  --font-display: "Inter Display", "Segoe UI Variable Display", "SF Pro Display", "Segoe UI", system-ui, sans-serif;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 { margin: 0; font-family: var(--font-display); }
p { margin: 0; line-height: 1.6; }
a { color: var(--text); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent); }

button { font: inherit; color: inherit; cursor: pointer; }
ul { list-style: none; margin: 0; padding: 0; }

.icon {
  width: 20px;
  height: 20px;
  flex: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Scrollbar */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-thumb {
  background: rgba(0, 217, 255, 0.3);
  border-radius: 10px;
  border: 3px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 217, 255, 0.5);
  border: 3px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-track { background: transparent; }

/* Background gradient backdrop */
.backdrop {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(900px 560px at 8% -12%, rgba(0, 217, 255, 0.11), transparent 62%),
    radial-gradient(760px 620px at 108% 112%, rgba(143, 124, 255, 0.10), transparent 60%),
    radial-gradient(600px 400px at 60% 40%, rgba(255, 255, 255, 0.015), transparent 70%);
  z-index: 0;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
  position: relative;
  z-index: 1;
}

@media (max-width: 768px) {
  .container { padding: 0 20px; }
}

/* ========================================================================== 
   Navigation Bar
   ========================================================================== */

.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 11, 15, 0.7);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--card-border);
  padding: 16px 0;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-section {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 650;
  font-size: 16px;
}

.logo-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 24px;
  flex: none;
}

.logo-text {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-link {
  font-size: 13px;
  font-weight: 550;
  color: var(--text-2);
  transition: color 0.2s;
}

.nav-link:hover {
  color: var(--accent);
}

@media (max-width: 768px) {
  .nav-links { gap: 20px; }
  .logo-text { display: none; }
}

/* ========================================================================== 
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--card-border-strong);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s var(--ease);
  white-space: nowrap;
  text-align: center;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border: none;
  color: #000;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(0, 217, 255, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 12px 36px rgba(0, 217, 255, 0.4);
}

/* ========================================================================== 
   Hero Section
   ========================================================================== */

.hero {
  position: relative;
  z-index: 1;
  padding: 140px 0 100px;
  text-align: center;
}

.hero-content {
  max-width: 700px;
  margin: 0 auto;
}

.hero-title {
  font-size: 64px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 20px;
  background: linear-gradient(135deg, var(--text), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 18px;
  color: var(--text-2);
  margin-bottom: 40px;
  line-height: 1.7;
}

@media (max-width: 768px) {
  .hero {
    padding: 80px 0 60px;
  }
  
  .hero-title {
    font-size: 42px;
  }
  
  .hero-subtitle {
    font-size: 16px;
  }
}

/* ========================================================================== 
   Section Styling
   ========================================================================== */

section {
  position: relative;
  z-index: 1;
  padding: 80px 0;
}

.section-title {
  font-size: 42px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 60px;
  color: var(--text);
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  margin: 20px auto 0;
  border-radius: 2px;
}

/* ========================================================================== 
   Projects Grid
   ========================================================================== */

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 32px;
}

.project-card {
  position: relative;
  padding: 40px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition: all 0.3s var(--ease);
  display: flex;
  flex-direction: column;
  gap: 20px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.project-card:hover {
  border-color: var(--accent-line);
  background: rgba(0, 217, 255, 0.07);
  transform: translateY(-6px);
  box-shadow: 0 20px 60px rgba(0, 217, 255, 0.2);
}

.project-card-coming {
  cursor: default;
  opacity: 0.7;
}

.project-card-coming:hover {
  border-color: var(--card-border);
  background: var(--card);
  transform: translateY(0);
  box-shadow: var(--shadow);
}

.coming-soon-badge {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 6px 12px;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 6px;
}

.project-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(0, 217, 255, 0.2), rgba(143, 124, 255, 0.2));
  border-radius: 14px;
  color: var(--accent);
  font-size: 28px;
}

.project-card h3 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  margin-top: 8px;
}

.project-card p {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.6;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.tag {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 6px 10px;
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 6px;
}

.project-arrow {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  opacity: 0;
  transform: translateX(-8px);
  transition: all 0.3s var(--ease);
}

.project-card:hover .project-arrow {
  opacity: 1;
  transform: translateX(0);
}

@media (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
  
  .project-arrow {
    opacity: 1;
  }
}

/* ========================================================================== 
   Footer
   ========================================================================== */

.footer {
  background: var(--card);
  border-top: 1px solid var(--card-border);
  padding: 60px 0 30px;
  margin-top: 80px;
  position: relative;
  z-index: 1;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 60px;
  margin-bottom: 40px;
}

.footer-content h4 {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-content p {
  font-size: 13px;
  color: var(--text-2);
  line-height: 1.6;
}

.footer-content ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-content a {
  font-size: 13px;
  color: var(--text-2);
  transition: color 0.2s;
}

.footer-content a:hover {
  color: var(--accent);
}

.footer-bottom {
  text-align: center;
  padding-top: 30px;
  border-top: 1px solid var(--card-border);
  color: var(--text-3);
  font-size: 12px;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .restricted-access-panel {
    width: calc(100% - 32px);
    max-width: 100%;
    min-width: unset;
    padding: 40px 24px;
    margin: 16px;
  }

  .restricted-access-panel h1 {
    font-size: 26px;
  }

  .passphrase-input,
  .passphrase-submit {
    font-size: 16px;
  }
}

/* ========================================================================== 
   Animations
   ========================================================================== */

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

section {
  animation: fade-in 0.6s var(--ease) backwards;
}

section:nth-child(2) { animation-delay: 0.1s; }
section:nth-child(3) { animation-delay: 0.2s; }
section:nth-child(4) { animation-delay: 0.3s; }

/* ========================================================================== 
   Under Construction Overlay
   ========================================================================== */

.construction-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 11, 15, 0.85);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  pointer-events: all;
}

body.construction-mode .construction-overlay {
  display: flex;
}

body.construction-mode {
  overflow: hidden;
  pointer-events: none;
}

body.construction-mode .construction-overlay {
  pointer-events: all;
}

.construction-panel {
  text-align: center;
  padding: 60px 40px;
  max-width: 500px;
  background: var(--card);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0, 217, 255, 0.3);
}

.construction-logo {
  font-size: 48px;
  color: var(--accent);
  margin-bottom: 20px;
}

.construction-panel h1 {
  font-size: 32px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 10px;
}

.construction-status {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 16px;
}

.construction-message {
  font-size: 15px;
  color: var(--text-2);
  line-height: 1.6;
}

/* ========================================================================== 
   Restricted Access Overlay
   ========================================================================== */

.restricted-access-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 11, 15, 0.85);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  pointer-events: all;
}

body.restricted-access-mode .restricted-access-overlay {
  display: flex;
}

body.restricted-access-mode {
  overflow: hidden;
  pointer-events: none;
}

body.restricted-access-mode .restricted-access-overlay {
  pointer-events: all;
}

.restricted-access-panel {
  text-align: center;
  padding: 60px 40px;
  width: 100%;
  max-width: 550px;
  min-width: 520px;
  background: var(--card);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0, 217, 255, 0.3);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.restricted-access-logo {
  font-size: 48px;
  color: var(--accent);
}

.restricted-access-panel h1 {
  font-size: 32px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 10px;
}

.restricted-access-status {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.restricted-access-message {
  font-size: 15px;
  color: var(--text-2);
  line-height: 1.6;
}

.passphrase-input {
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--card-border-strong);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  transition: border-color 0.2s, background 0.2s;
}

.passphrase-input::placeholder {
  color: var(--text-3);
}

.passphrase-input:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent-line);
}

.passphrase-input:focus {
  outline: none;
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--accent);
}

.passphrase-submit {
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border: none;
  border-radius: var(--radius-sm);
  color: #000;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s var(--ease);
  box-shadow: 0 8px 24px rgba(0, 217, 255, 0.3);
}

.passphrase-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 36px rgba(0, 217, 255, 0.4);
}

.passphrase-submit:active {
  transform: translateY(0);
}

.passphrase-error {
  font-size: 13px;
  color: #f2606b;
  min-height: 18px;
  margin: 0;
}