:root{
  --bg:#0a0f1f;
  --bg-2:#070b16;
  --text:#dfe6ff;
  --muted:#c6d4ff;
  --accent:#6ab9ff;
  --accent-2:#90cdff;

  --card:#11182d;
  --card-2:#141b33;
  --border:rgba(120,170,255,0.14);
  --shadow:0 12px 30px rgba(0,0,0,0.35);

  --nav-bg:rgba(10,10,30,0.7);
  --nav-height:78px;
}

*,
*::before,
*::after{ box-sizing:border-box; }

html,body{ height:100%; }

body{
  margin:0;
  font-family:"Segoe UI",sans-serif;
  background:
    radial-gradient(1200px 700px at 15% 10%, rgba(106,185,255,0.10), transparent 60%),
    radial-gradient(900px 500px at 85% 20%, rgba(138,198,255,0.08), transparent 60%),
    linear-gradient(180deg,var(--bg),var(--bg-2));
  color:var(--text);
  scroll-behavior:smooth;
  overflow-x:hidden;
}

a{ text-decoration:none; color:var(--accent); }
a:hover{ color:var(--accent-2); }

a:focus-visible,
.button:focus-visible{
  outline:2px solid rgba(106,185,255,0.75);
  outline-offset:3px;
  border-radius:10px;
}

.skip-link{
  position:absolute;
  left:12px;
  top:12px;
  padding:10px 12px;
  background:rgba(20,27,51,0.95);
  border:1px solid var(--border);
  color:var(--text);
  border-radius:10px;
  transform:translateY(-140%);
  transition:transform 0.2s ease;
  z-index:9999;
}
.skip-link:focus{ transform:translateY(0); }

section{ scroll-margin-top:calc(var(--nav-height) + 18px); }

.hero,.section,footer{ position:relative; z-index:1; }

/* NAVBAR */
.navbar{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:18px 50px;
  background:var(--nav-bg);
  backdrop-filter:blur(10px);
  position:fixed;
  left:0; right:0; top:0;
  z-index:10;
  border-bottom:1px solid rgba(120,170,255,0.08);
}
.navbar .logo{
  color:var(--accent);
  font-size:26px;
  font-weight:700;
  letter-spacing:1px;
}
.navbar nav{
  display:flex;
  align-items:center;
  gap:10px;
}
.navbar nav a{
  color:var(--text);
  padding:10px 12px;
  border-radius:10px;
  transition:0.25s ease;
}
.navbar nav a:hover{
  color:var(--accent-2);
  background:rgba(120,170,255,0.08);
}

/* HERO */
.hero{
  min-height:100vh;
  padding:calc(var(--nav-height) + 40px) 20px 50px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  text-align:center;
}
.title{
  font-size:clamp(34px,5.6vw,58px);
  font-weight:800;
  color:#8ac6ff;
  margin:18px 0 0;
}
.subtitle{
  margin-top:14px;
  font-size:clamp(16px,2.2vw,20px);
  max-width:720px;
  opacity:0.92;
  line-height:1.6;
}
.button{
  margin-top:22px;
  padding:12px 28px;
  background:var(--accent);
  color:#000;
  font-weight:800;
  border-radius:12px;
  transition:0.25s ease;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 10px 22px rgba(106,185,255,0.18);
  border:none;
  cursor:pointer;
}
.button:hover{
  background:var(--accent-2);
  transform:translateY(-1px);
}
#typing-text{
  border-right:3px solid #8ac6ff;
  padding-right:8px;
  animation:blinkCursor 0.8s infinite;
}
@keyframes blinkCursor{
  0%{border-color:#8ac6ff;}
  50%{border-color:transparent;}
  100%{border-color:#8ac6ff;}
}

/* SECTIONS */
.section {
    padding: clamp(45px, 6vw, 80px) clamp(18px, 5vw, 60px);
    text-align: center;
}

.section-title{
  font-size:clamp(28px,4.6vw,42px);
  color:#7fb8ff;
  margin:0 0 45px;
}

/* SERVICE CARDS */
.card-container{
  display:flex;
  justify-content:center;
  gap:22px;
  flex-wrap:wrap;
}
.card{
  background:linear-gradient(180deg, rgba(17,24,45,0.95), rgba(17,24,45,0.72));
  border:1px solid var(--border);
  padding:28px;
  border-radius:16px;
  width:310px;
  transition:0.25s ease;
  box-shadow:var(--shadow);
}
.card:hover{
  transform:translateY(-6px);
  background:linear-gradient(180deg, rgba(26,33,64,0.95), rgba(26,33,64,0.75));
}

/* PROJECTS GRID (this prevents the giant image issue) */
.project-grid{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(280px, 1fr));
  gap:26px;
  max-width:1200px;
  margin:0 auto;
  align-items:start;
}
.project-card{
  background:linear-gradient(180deg, rgba(20,27,51,0.95), rgba(20,27,51,0.72));
  border:1px solid var(--border);
  border-radius:16px;
  padding:24px;
  box-shadow:var(--shadow);
  transition:0.25s ease;
  overflow:hidden;                /* KEY: prevents spill */
  display:flex;
  flex-direction:column;
  gap:12px;
}
.project-card:hover{
  transform:translateY(-6px);
  background:linear-gradient(180deg, rgba(29,38,70,0.95), rgba(29,38,70,0.75));
}
.project-card img{
  width:100%;
  height:190px;                   /* KEY: fixed thumbnail height */
  object-fit:cover;               /* KEY: crops cleanly */
  border-radius:12px;
  display:block;
}
.project-card .tools{
  margin:0;
}
.project-card .button{
  margin-top:auto;                /* aligns buttons to bottom */
}

/* ABOUT */
.about-text{
  max-width:780px;
  margin:0 auto;
  color:var(--muted);
  line-height:1.75;
  font-size:18px;
}

/* FOOTER */
footer{
  text-align:center;
  padding:28px 16px;
  background:rgba(13,18,36,0.9);
  border-top:1px solid rgba(120,170,255,0.08);
  color:#6f7da7;
}

/* MODALS (real overlay) */
.modal{
  display:none;
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.85);
  z-index:9999;
  padding:90px 20px 30px;
  overflow:auto;
  pointer-events: auto;
}
.modal.open{ display:block; }

.modal-content{
  max-width:950px;
  margin:0 auto;
  background:#0f172a;
  border-radius:14px;
  padding:20px;
  position:relative;
  color:var(--text);
  pointer-events: auto;
}
.modal-close{
  position:absolute;
  top:10px;
  right:15px;
  background:none;
  border:none;
  color:#fff;
  font-size:30px;
  cursor:pointer;
  z-index: 10001; /* IMPORTANT */
  pointer-events: auto;
}
.modal-scroll{
  max-height:70vh;
  overflow-y:auto;
  margin-top:15px;
  padding-right:6px;
  text-align:left;
}
.modal-scroll img{
  width:100%;
  height:auto;
  object-fit:contain;
  border-radius:12px;
  display:block;
  margin-bottom:18px;
}
.modal-video{
  margin-top:18px;
}
.modal-subtitle{
  margin:0 0 10px;
  font-size:18px;
  color:#cfe4ff;
}
.modal-scroll iframe{
  width:100%;
  height:450px;
  border:0;
  border-radius:12px;
  display:block;
}

/* GLOW ORB */
#glow-orb{
  position:fixed;
  width:220px;
  height:220px;
  background:radial-gradient(circle, rgba(80,150,255,0.28), rgba(0,0,0,0));
  pointer-events:none;
  border-radius:50%;
  z-index:0;
  filter:blur(44px);
  will-change:transform;
}

/* PARTICLES */
#particles{
  position:fixed;
  top:0; left:0;
  width:100%;
  height:100%;
  z-index:-2;
  background:transparent;
  pointer-events:none;
}

/* 3D CAROUSEL */
/* =========================
   CAROUSEL – CLEAN BASELINE
========================= */

.carousel-container {
  width: 100%;
  height: 260px;
  margin-top: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1200px;
}

.carousel-3d {
  position: relative;
  width: 360px;
  height: 240px;
  transform-style: preserve-3d;
  animation: spin 22s linear infinite;
}

.carousel-3d img {
  position: absolute;
  width: 120px;
  height: 120px;
  object-fit: contain;
  padding: 10px;
  border-radius: 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(120,170,255,0.25);
  box-shadow: 0 0 20px rgba(120,170,255,0.35);
}

@keyframes spin {
  from { transform: rotateY(0deg); }
  to   { transform: rotateY(-360deg); }
}


/* RESPONSIVE */
@media (max-width:820px){
  .navbar{
    padding:14px 18px;
    flex-direction:column;
    gap:10px;
  }
  .navbar nav{
    flex-wrap:wrap;
    justify-content:center;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  *{ transition:none !important; animation:none !important; scroll-behavior:auto !important; }
  #glow-orb{ display:none; }
}
/* ===============================
   PROJECT LAYOUT HARD FIX
   =============================== */

#projects {
  overflow-x: hidden;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
  max-width: 1100px;
  margin: 0 auto;
  align-items: stretch;
}

.project-card {
  width: 100%;
  max-width: 340px;
  overflow: hidden;
  position: relative;
}

.project-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  border-radius: 10px;
}

.project-card:hover {
  transform: translateY(-4px);
}

/* ===============================
   MODAL – TRUE OVERLAY
   =============================== */

.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 10000;
  padding: 80px 20px;
  overflow-y: auto;
}

.modal-content {
  max-width: 900px;
  margin: auto;
  background: #0f172a;
  border-radius: 14px;
  padding: 24px;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  font-size: 30px;
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
}

.modal img,
.modal iframe {
  width: 100%;
  max-width: 100%;
  display: block;
  margin-bottom: 20px;
  border-radius: 10px;
}


/* CHANGED: tighten ABOUT section spacing */
#about.section{
  padding-top: 50px;      /* was too tall */
  padding-bottom: 110px;  /* gives room so bullets don’t touch footer */
}

#about .section-title{
  margin-bottom: 22px;    /* pulls content up */
}


.about-item {
  display: grid;
  grid-template-columns: 200px 1fr;
  column-gap: 16px;
  margin-bottom: 18px;
}

.about-item .label {
  color: #9ecbff;
  font-weight: 600;
  text-align: right;
  opacity: 0.95;
}

.about-item .desc {
  line-height: 1.7;
}


.about-closing {
  margin-top: 32px;
  font-style: italic;
  opacity: 0.85;
  text-align: center;
}




/* =========================
   FOOTER (ArkTech – rebuilt)
========================= */

.site-footer {
  background: linear-gradient(180deg, #0b1224, #070b16);
  border-top: 1px solid rgba(120,170,255,0.12);
  padding: 70px 40px;
  color: #dfe6ff;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr; /* left | right */
  gap: 60px;
  align-items: start;
}

/* ---------- LEFT SIDE ---------- */

.footer-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;   /* lock left alignment */
  justify-content: flex-start;
  gap: 20px;
}




  border-radius: 50%;
  object-fit: cover;
  display: block;
  border: 1px solid rgba(120,170,255,0.35);
}



.footer-identity {
  font-size: 18px;
  font-weight: 700;
  color: #8ac6ff;
}

.footer-contact-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-left: 2px; /* subtle alignment correction */
}


.footer-contact-list a {
  color: #dfe6ff;
  transition: color 0.25s ease;
}

.footer-contact-list a:hover {
  color: #90cdff;
}

/* ---------- RIGHT SIDE (FORM) ---------- */

.footer-right h3 {
  margin-bottom: 18px;
  font-size: 22px;
  color: #8ac6ff;
}

.footer-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-form input,
.footer-form textarea {
  background: #0f172a;
  border: 1px solid rgba(120,170,255,0.18);
  border-radius: 10px;
  padding: 12px 14px;
  color: #dfe6ff;
  font-size: 14px;
  font-family: inherit;
}

.footer-form input::placeholder,
.footer-form textarea::placeholder {
  color: #9aa8d6;
}

.footer-form textarea {
  resize: none;
  min-height: 120px;
}

.footer-form button {
  align-self: flex-start;
  margin-top: 6px;
  padding: 12px 26px;
  background: #6ab9ff;
  color: #000;
  font-weight: 800;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease;
}

.footer-form button:hover {
  background: #90cdff;
  transform: translateY(-1px);
}

/* ---------- RESPONSIVE ---------- */

@media (max-width: 900px) {
  .footer-container {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .footer-form button {
    width: 100%;
    text-align: center;
  }
}


/* =========================
   FOOTER (CONTACT SECTION)
========================= */

.site-footer {
  background: linear-gradient(180deg, rgba(10,15,35,0.95), rgba(8,12,28,0.95));
  padding: 80px 40px 30px;
  color: #dfe6ff;
}

/* Two-column layout */
.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 80px;
  align-items: flex-start;
}

/* LEFT: Contact info */
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.contact-item strong {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: #9ecbff;
  margin-bottom: 6px;
  letter-spacing: 0.3px;
}

.contact-item a {
  color: #6ab9ff;
  font-size: 16px;
  word-break: break-word;
}

.contact-item a:hover {
  color: #90cdff;
}

/* RIGHT: Contact form */
.footer-right h3 {
  font-size: 22px;
  margin-bottom: 24px;
  color: #8ac6ff;
}

.footer-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.footer-form input,
.footer-form textarea {
  width: 100%;
  padding: 14px 16px;
  background: rgba(20,27,51,0.85);
  border: 1px solid rgba(120,170,255,0.18);
  border-radius: 10px;
  color: #dfe6ff;
  font-size: 15px;
}

.footer-form input::placeholder,
.footer-form textarea::placeholder {
  color: #aab8e8;
}

.footer-form input:focus,
.footer-form textarea:focus {
  outline: none;
  border-color: rgba(106,185,255,0.6);
  box-shadow: 0 0 0 2px rgba(106,185,255,0.15);
}

.footer-form textarea {
  resize: vertical;
  min-height: 120px;
}

/* Button */
.footer-form button {
  align-self: flex-start;
  margin-top: 8px;
  padding: 12px 28px;
  background: #6ab9ff;
  color: #000;
  font-weight: 700;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: 0.25s ease;
}

.footer-form button:hover {
  background: #90cdff;
  transform: translateY(-1px);
}

/* Bottom copyright */
.footer-bottom {
  margin-top: 70px;
  padding-top: 20px;
  text-align: center;
  font-size: 14px;
  color: #7f8dbd;
  border-top: 1px solid rgba(120,170,255,0.12);
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 60px;
  }

  .footer-right h3 {
    text-align: left;
  }

  .footer-form button {
    align-self: stretch;
    text-align: center;
  }
}


.section-subtitle {
  font-size: 26px;
  color: #9ecbff;
  margin: 60px 0 12px;
}

.section-description {
  max-width: 760px;
  margin: 0 auto 40px;
  color: var(--muted);
  line-height: 1.6;
}
