* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Inter', 'Calibri', sans-serif;
  background: #010514;
  color: #f0f5ff;
  overflow-x: hidden;
  font-weight: 400;
}
h1, h2, h3, .logo, .sec-label { font-family: 'Space Grotesk', monospace; font-weight: 600; letter-spacing: -0.02em; }

.cursor-follower {
  position: fixed;
  width: 8px;
  height: 8px;
  background: #00D9FF;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transition: transform 0.12s ease;
  box-shadow: 0 0 15px #00D9FF;
}
html { scroll-behavior: smooth; }
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: #030617; }
::-webkit-scrollbar-thumb { background: #00D9FF; border-radius: 10px; }
::selection { background: #00D9FF; color: #010514; }

/* Mobile Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  right: -100%;
  width: 280px;
  height: 100%;
  background: rgba(1, 5, 20, 0.98);
  backdrop-filter: blur(20px);
  border-left: 1px solid rgba(0,217,255,0.4);
  z-index: 2000;
  transition: right 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.sidebar.open { right: 0; }
.sidebar a {
  color: #eef5ff;
  text-decoration: none;
  font-size: 1.2rem;
  font-weight: 500;
  font-family: 'Space Grotesk';
  transition: 0.2s;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(0,217,255,0.2);
}
.sidebar a:hover { color: #00D9FF; padding-left: 8px; }
.close-sidebar { font-size: 2rem; color: #00D9FF; cursor: pointer; text-align: right; margin-bottom: 1rem; }
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  z-index: 1999;
  display: none;
}
.overlay.active { display: block; }
.hamburger { display: block; font-size: 1.8rem; background: transparent; border: none; color: #00D9FF; cursor: pointer; }
.desktop-nav { display: none; }

@media (min-width: 768px) {
  .hamburger { display: none; }
  .desktop-nav { display: flex; gap: 2rem; align-items: center; }
  .desktop-nav a { color: #eef5ff; text-decoration: none; font-weight: 500; transition: 0.2s; }
  .desktop-nav a:hover { color: #00D9FF; }
}

.project-preview-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform 0.5s ease;
  background: #0a1225;
}
.project-3d-card:hover .project-preview-img { transform: scale(1.03); }
.preview-overlay { overflow: hidden; border-radius: 24px 24px 0 0; }
.resume-btn {
  background: rgba(0,217,255,0.12);
  border: 1.5px solid #00D9FF;
  padding: 0.7rem 1.5rem;
  border-radius: 99px;
  font-weight: 600;
  transition: all 0.3s;
  cursor: pointer;
  color: #f0f5ff;
  font-size: 0.95rem;
}
.resume-btn:hover { background: #00D9FF; color: #010514; box-shadow: 0 0 20px #00D9FF; }
.service-card, .project-3d-card { transition: all 0.35s cubic-bezier(0.2, 0.9, 0.4, 1.1); background: rgba(6,14,28,0.75); backdrop-filter: blur(8px); cursor: pointer; }
@keyframes pulse { 0% { opacity: 0.4; transform: scale(0.8); } 100% { opacity: 1; transform: scale(1.2); } }

.services-grid, .projects-grid, .design-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; }
@media (min-width: 640px) { .services-grid, .projects-grid, .design-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .services-grid { grid-template-columns: repeat(3, 1fr); } .projects-grid { grid-template-columns: repeat(2, 1fr); } .design-grid { grid-template-columns: repeat(4, 1fr); } }
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; }
@media (min-width: 768px) { .contact-grid { grid-template-columns: 1fr 1fr; } }

p, .testimonial-text { font-size: 0.9rem; line-height: 1.5; color: #d0e2ff; }
h2 { font-size: 1.8rem; }
@media (min-width: 768px) { h2 { font-size: 2.2rem; } }

a { text-decoration: none; }
button { font-family: inherit; }
input, textarea, select { font-family: inherit; }

/* ── Chatbot typing indicator ── */
.typing-indicator { display: flex; gap: 5px; padding: 0.6rem 1rem; align-items: center; }
.typing-indicator span {
  width: 7px; height: 7px; background: #00D9FF; border-radius: 50%;
  animation: bounce 1.2s infinite;
}
.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }
@keyframes bounce { 0%, 60%, 100% { transform: translateY(0); } 30% { transform: translateY(-8px); } }

/* ════════════════════════════════════════════════════
   PAGE LOADER — spinning gear
   ════════════════════════════════════════════════════ */
#page-loader {
  position: fixed;
  inset: 0;
  background: #010514;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
#page-loader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
#page-loader .loader-label {
  font-family: 'Space Grotesk', monospace;
  font-size: 0.85rem;
  color: #00D9FF;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.8;
}
.gear-wrap {
  position: relative;
  width: 72px;
  height: 72px;
}
.gear {
  width: 72px;
  height: 72px;
  animation: spin-gear 1.8s linear infinite;
  filter: drop-shadow(0 0 10px #00D9FF);
}
.gear-inner {
  width: 40px;
  height: 40px;
  animation: spin-gear 1.8s linear infinite reverse;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 0 6px #2563eb);
}
@keyframes spin-gear {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.gear-inner-wrap {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  animation: spin-gear 1.8s linear infinite reverse;
}

/* ════════════════════════════════════════════════════
   NEW: Star ratings (read-only display + interactive input)
   ════════════════════════════════════════════════════ */
.star-display { display: inline-flex; gap: 2px; color: #00D9FF; font-size: 1rem; letter-spacing: 1px; }
.star-display .star-empty { color: rgba(0,217,255,0.25); }

.star-input { display: flex; gap: 0.4rem; font-size: 1.8rem; }
.star-input button {
  background: none; border: none; cursor: pointer; padding: 0;
  color: rgba(0,217,255,0.25); transition: color 0.15s, transform 0.15s;
  line-height: 1;
}
.star-input button.active,
.star-input button:hover,
.star-input button:hover ~ button { color: #00D9FF; }
.star-input button:hover { transform: scale(1.15); }

.rating-summary { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; justify-content: center; margin-bottom: 0.5rem; }
.rating-summary .big-number { font-family: 'Space Grotesk'; font-size: 2rem; font-weight: 700; color: #00D9FF; }

/* ════════════════════════════════════════════════════
   NEW: Project detail / clickable cards
   ════════════════════════════════════════════════════ */
.project-3d-card { display: flex; flex-direction: column; }
.project-card-link { color: inherit; display: block; }
.project-meta-tag {
  display: inline-block; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.05em;
  text-transform: uppercase; color: #00D9FF; background: rgba(0,217,255,0.1);
  border: 1px solid rgba(0,217,255,0.3); padding: 0.2rem 0.6rem; border-radius: 99px; margin-bottom: 0.6rem;
}
.view-more-link {
  color: #00D9FF; font-weight: 600; font-size: 0.85rem; display: inline-flex;
  align-items: center; gap: 0.3rem; margin-top: 0.5rem;
}

.detail-hero-img { width: 100%; max-height: 420px; object-fit: cover; border-radius: 24px; border: 1px solid rgba(0,217,255,0.3); }
.gallery-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.8rem; margin-top: 1.5rem; }
@media (min-width: 768px) { .gallery-grid { grid-template-columns: repeat(3, 1fr); } }
.gallery-grid img { width: 100%; height: 160px; object-fit: cover; border-radius: 16px; border: 1px solid rgba(0,217,255,0.2); cursor: pointer; transition: transform 0.3s, border-color 0.3s; }
.gallery-grid img:hover { transform: scale(1.02); border-color: #00D9FF; }

.back-link { color: #00D9FF; font-weight: 500; display: inline-flex; align-items: center; gap: 0.4rem; margin-bottom: 1.5rem; }

.detail-meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 1.5rem 0; }
.detail-meta-grid .meta-item { background: rgba(6,14,28,0.75); border: 1px solid rgba(0,217,255,0.2); border-radius: 16px; padding: 0.8rem 1rem; }
.detail-meta-grid .meta-item .label { font-size: 0.7rem; color: #00D9FF; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.2rem; }
.detail-meta-grid .meta-item .value { font-weight: 600; font-size: 0.95rem; }

/* Lightbox for gallery */
.lightbox-overlay {
  position: fixed; inset: 0; background: rgba(1,5,20,0.95); z-index: 3000;
  display: none; align-items: center; justify-content: center; padding: 1.5rem;
}
.lightbox-overlay.active { display: flex; }
.lightbox-overlay img { max-width: 100%; max-height: 90vh; border-radius: 12px; }
.lightbox-close { position: absolute; top: 1.5rem; right: 1.5rem; font-size: 2rem; color: #00D9FF; cursor: pointer; background: none; border: none; }

/* ════════════════════════════════════════════════════
   NEW: Testimonial submission form
   ════════════════════════════════════════════════════ */
.testimonial-form-card {
  background: rgba(5,15,35,0.6); backdrop-filter: blur(16px); border-radius: 32px;
  padding: 1.5rem; border: 1px solid rgba(0,217,255,0.3); margin-top: 2rem;
}
.form-input {
  width: 100%; margin: 0.5rem 0; padding: 0.8rem; background: #010c1c;
  border: 1px solid rgba(0,217,255,0.25); border-radius: 16px; color: white; font-size: 0.9rem;
}
.form-input:focus { outline: none; border-color: #00D9FF; }
.form-label { font-size: 0.8rem; color: #aaccff; margin-top: 0.8rem; display: block; }
.submit-btn {
  background: #00D9FF; border: none; padding: 0.8rem; width: 100%; border-radius: 40px;
  font-weight: bold; cursor: pointer; margin-top: 1rem; color: #010514; font-size: 0.95rem;
}
.submit-btn:hover { box-shadow: 0 0 20px #00D9FF66; }
.submit-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.form-feedback { margin-top: 0.7rem; font-size: 0.8rem; }
.form-feedback.success { color: #4ade80; }
.form-feedback.error { color: #f87171; }

.testimonial-card-rated {
  background: rgba(255,255,255,0.02); border: 1px solid #00D9FF30; border-radius: 24px; padding: 1.2rem;
}
.testimonial-card-rated .testimonial-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 0.6rem; flex-wrap: wrap; gap: 0.4rem; }
.testimonial-card-rated .name { color: #00D9FF; font-weight: 600; font-size: 0.9rem; }
.testimonials-scroll { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 768px) { .testimonials-scroll { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .testimonials-scroll { grid-template-columns: repeat(3, 1fr); } }

/* ════════════════════════════════════════════════════
   404 page
   ════════════════════════════════════════════════════ */
.error-page { min-height: 80vh; display: flex; align-items: center; justify-content: center; text-align: center; padding: 2rem; }
.error-page h1 { font-size: clamp(3rem, 12vw, 6rem); color: #00D9FF; }

/* ════════════════════════════════════════════════════
   NEW: Admin dashboard
   ════════════════════════════════════════════════════ */
.admin-body { font-family: 'Inter', sans-serif; background: #010514; color: #f0f5ff; min-height: 100vh; }
.admin-shell { display: flex; flex-direction: column; min-height: 100vh; }
@media (min-width: 900px) { .admin-shell { flex-direction: row; } }

.admin-sidebar {
  background: rgba(5,12,28,0.9); border-right: 1px solid rgba(0,217,255,0.2);
  padding: 1.2rem; display: flex; flex-direction: column; gap: 0.4rem;
}
@media (min-width: 900px) { .admin-sidebar { width: 240px; min-height: 100vh; position: sticky; top: 0; } }

.admin-sidebar .brand { font-family: 'Space Grotesk'; font-weight: 700; font-size: 1.1rem; color: #00D9FF; margin-bottom: 1rem; display: block; }
.admin-nav-link {
  color: #d0e2ff; padding: 0.7rem 0.9rem; border-radius: 12px; font-size: 0.9rem; font-weight: 500;
  display: flex; align-items: center; gap: 0.6rem; transition: 0.2s;
}
.admin-nav-link:hover, .admin-nav-link.active { background: rgba(0,217,255,0.1); color: #00D9FF; }
.admin-nav-link .badge { margin-left: auto; background: #00D9FF; color: #010514; font-size: 0.7rem; font-weight: 700; padding: 0.1rem 0.5rem; border-radius: 99px; }

.admin-main { flex: 1; padding: 1.2rem; max-width: 1200px; }
@media (min-width: 768px) { .admin-main { padding: 2rem; } }

.admin-topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 0.8rem; }
.admin-topbar h1 { font-size: 1.4rem; }

.stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 2rem; }
@media (min-width: 700px) { .stat-grid { grid-template-columns: repeat(4, 1fr); } }
.stat-card {
  background: rgba(6,14,28,0.75); border: 1px solid rgba(0,217,255,0.2); border-radius: 18px; padding: 1.1rem;
}
.stat-card .num { font-family: 'Space Grotesk'; font-size: 1.8rem; font-weight: 700; color: #00D9FF; }
.stat-card .label { font-size: 0.75rem; color: #aaccff; margin-top: 0.2rem; }

.admin-card { background: rgba(6,14,28,0.75); border: 1px solid rgba(0,217,255,0.2); border-radius: 20px; padding: 1.2rem; margin-bottom: 1.2rem; }
.admin-card h2 { font-size: 1.1rem; margin-bottom: 1rem; }

.admin-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.admin-table th { text-align: left; padding: 0.6rem 0.5rem; color: #00D9FF; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; border-bottom: 1px solid rgba(0,217,255,0.2); }
.admin-table td { padding: 0.7rem 0.5rem; border-bottom: 1px solid rgba(255,255,255,0.05); vertical-align: middle; }
.admin-table tr:hover td { background: rgba(0,217,255,0.04); }
.table-scroll { overflow-x: auto; }

.btn { display: inline-flex; align-items: center; gap: 0.3rem; padding: 0.45rem 0.9rem; border-radius: 10px; font-size: 0.8rem; font-weight: 600; cursor: pointer; border: 1px solid transparent; }
.btn-primary { background: #00D9FF; color: #010514; }
.btn-primary:hover { box-shadow: 0 0 14px #00D9FF66; }
.btn-outline { background: transparent; border-color: rgba(0,217,255,0.4); color: #00D9FF; }
.btn-outline:hover { background: rgba(0,217,255,0.1); }
.btn-danger { background: rgba(248,113,113,0.12); border-color: rgba(248,113,113,0.4); color: #f87171; }
.btn-danger:hover { background: rgba(248,113,113,0.2); }
.btn-success { background: rgba(74,222,128,0.12); border-color: rgba(74,222,128,0.4); color: #4ade80; }
.btn-success:hover { background: rgba(74,222,128,0.2); }
.btn-sm { padding: 0.3rem 0.6rem; font-size: 0.72rem; }
.btn-row { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.status-pill { font-size: 0.7rem; font-weight: 700; padding: 0.2rem 0.6rem; border-radius: 99px; text-transform: uppercase; letter-spacing: 0.03em; }
.status-pending { background: rgba(250,204,21,0.15); color: #facc15; }
.status-approved { background: rgba(74,222,128,0.15); color: #4ade80; }
.status-rejected { background: rgba(248,113,113,0.15); color: #f87171; }
.status-published { background: rgba(74,222,128,0.15); color: #4ade80; }
.status-draft { background: rgba(148,163,184,0.15); color: #94a3b8; }

.admin-form-group { margin-bottom: 1.1rem; }
.admin-form-group label { display: block; font-size: 0.82rem; color: #aaccff; margin-bottom: 0.4rem; font-weight: 500; }
.admin-form-group input[type=text],
.admin-form-group input[type=number],
.admin-form-group input[type=url],
.admin-form-group textarea,
.admin-form-group select {
  width: 100%; padding: 0.7rem 0.9rem; background: #010c1c; border: 1px solid rgba(0,217,255,0.25);
  border-radius: 12px; color: white; font-size: 0.9rem;
}
.admin-form-group input:focus, .admin-form-group textarea:focus, .admin-form-group select:focus { outline: none; border-color: #00D9FF; }
.admin-form-group textarea { min-height: 100px; resize: vertical; }
.admin-form-row { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 700px) { .admin-form-row { grid-template-columns: 1fr 1fr; } }
.checkbox-row { display: flex; align-items: center; gap: 0.5rem; }
.checkbox-row input { width: auto; }

.thumb-preview { width: 100%; max-width: 240px; border-radius: 12px; border: 1px solid rgba(0,217,255,0.25); margin-top: 0.5rem; }
.gallery-admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 0.7rem; margin-top: 0.8rem; }
.gallery-admin-item { position: relative; }
.gallery-admin-item img { width: 100%; height: 90px; object-fit: cover; border-radius: 10px; border: 1px solid rgba(0,217,255,0.2); }
.gallery-admin-item form { position: absolute; top: 4px; right: 4px; }
.gallery-admin-item button { background: rgba(0,0,0,0.6); border: none; color: #f87171; width: 22px; height: 22px; border-radius: 50%; cursor: pointer; font-size: 0.75rem; line-height: 1; }

.alert-banner { padding: 0.8rem 1rem; border-radius: 12px; font-size: 0.85rem; margin-bottom: 1.2rem; }
.alert-success { background: rgba(74,222,128,0.12); border: 1px solid rgba(74,222,128,0.3); color: #4ade80; }
.alert-error { background: rgba(248,113,113,0.12); border: 1px solid rgba(248,113,113,0.3); color: #f87171; }

.login-shell { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: #010514; padding: 1.5rem; }
.login-card { background: rgba(6,14,28,0.9); border: 1px solid rgba(0,217,255,0.3); border-radius: 24px; padding: 2rem; width: 100%; max-width: 380px; }
.login-card h1 { font-size: 1.4rem; margin-bottom: 0.4rem; }
.login-card p.sub { color: #aaccff; font-size: 0.85rem; margin-bottom: 1.5rem; }

.empty-state { text-align: center; padding: 2.5rem 1rem; color: #94a3b8; }
.empty-state .icon { font-size: 2.5rem; margin-bottom: 0.6rem; }

.filter-tabs { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 1.2rem; }
.filter-tab {
  padding: 0.4rem 0.9rem; border-radius: 99px; font-size: 0.78rem; font-weight: 600;
  border: 1px solid rgba(0,217,255,0.25); color: #d0e2ff;
}
.filter-tab.active { background: #00D9FF; color: #010514; border-color: #00D9FF; }
