:root{
  --bg:#071a2b;
  --text:#eaf2ff;
  --muted:#b8c7dd;
  --accent:#20e3a2;
  --accent2:#4aa3ff;
  --line:rgba(255,255,255,.10);
  --shadow: 0 12px 30px rgba(0,0,0,.35);
  --radius:18px;
  --max:1100px;
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:"Cairo",system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
  color:var(--text);
  background:
    radial-gradient(1200px 600px at 20% 0%, rgba(74,163,255,.20), transparent 55%),
    radial-gradient(900px 500px at 90% 20%, rgba(32,227,162,.14), transparent 60%),
    linear-gradient(180deg, var(--bg), #04111d 70%);
}
a{color:inherit; text-decoration:none}
.container{max-width:var(--max); margin:0 auto; padding:0 18px}

/* Header */
.header{
  position:sticky; top:0; z-index:50;
  backdrop-filter: blur(10px);
  background: rgba(7,26,43,.72);
  border-bottom:1px solid var(--line);
}
.header .bar{
  display:flex; align-items:center; justify-content:space-between;
  padding:14px 0; gap:16px;
}
.brand{
  display:flex; align-items:center; gap:10px;
  font-weight:700; letter-spacing:.3px;
}
.brand .logo{
  width:38px; height:38px; border-radius:12px;
  background: linear-gradient(135deg, rgba(32,227,162,.22), rgba(74,163,255,.18));
  display:grid; place-items:center;
  border:1px solid var(--line);
  box-shadow: 0 10px 20px rgba(0,0,0,.25);
  overflow:hidden;
}
.brand .logo img{width:100%; height:100%; object-fit:cover; display:block}

.nav{
  display:flex; gap:10px; align-items:center; flex-wrap:wrap;
}
.nav a{
  padding:8px 12px;
  border-radius:12px;
  color:var(--muted);
  border:1px solid transparent;
  transition:.2s ease;
  font-weight:600;
}
.nav a:hover{
  color:var(--text);
  border-color:var(--line);
  background:rgba(255,255,255,.03);
}
/* Contact button (default – NOT green) */
.nav .cta{
  border:1px solid var(--line);
  background: rgba(255,255,255,.03);
  color:var(--text);
  font-weight:800;
}

/* Active nav link (including Contact when active) */
.nav a.active{
  color:#052014;
  background: linear-gradient(135deg, var(--accent), #66f0c1);
  border:0;
  box-shadow: 0 10px 22px rgba(32,227,162,.18);
}

/* Buttons */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:10px;
  padding:12px 16px;
  border-radius:14px;
  border:1px solid var(--line);
  background: rgba(255,255,255,.03);
  color:var(--text);
  font-weight:800;
  transition:.2s ease;
  cursor:pointer;
}
.btn:hover{transform: translateY(-1px); background: rgba(255,255,255,.05)}
.btn.primary{
  border:0;
  background: linear-gradient(135deg, var(--accent), #66f0c1);
  color:#052014;
  box-shadow: 0 12px 26px rgba(32,227,162,.18);
}

/* Hero */
.hero{padding:78px 0 26px; text-align:center;}
.pill{
  display:inline-flex; align-items:center; gap:8px;
  padding:7px 12px; border-radius:999px;
  border:1px solid var(--line);
  background: rgba(255,255,255,.03);
  color:var(--muted); font-weight:700;
  margin-bottom:14px;
}
.pill .dot{
  width:8px; height:8px; border-radius:50%;
  background:var(--accent);
  box-shadow: 0 0 0 4px rgba(32,227,162,.15);
}
.hero h1{margin:0 0 10px; font-size: clamp(30px, 3.4vw, 52px); line-height:1.08;}
.hero p{margin:0 auto 18px; color:var(--muted); font-size:16px; max-width: 68ch;}
.hero-actions{display:flex; gap:12px; flex-wrap:wrap; justify-content:center; margin-top:14px;}

/* Sections */
.section{padding: 28px 0 10px}
.section-head{
  display:flex; align-items:flex-end; justify-content:space-between;
  gap:14px; margin-bottom:14px; flex-wrap:wrap;
}
.section-head .title{margin:0; font-size:22px}
.section-head .sub{margin:0; color:var(--muted); font-weight:600}

.panel{
  border:1px solid var(--line);
  background: rgba(255,255,255,.02);
  border-radius: var(--radius);
  padding:18px;
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
}
.panel h3{margin:0 0 8px}
.panel p{margin:0 0 12px; color:var(--muted); line-height:1.6}

/* Portfolio cards (overview + full page) */
.portfolio-grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:14px;
}
.work{
  border:1px solid var(--line);
  background: rgba(255,255,255,.02);
  border-radius: var(--radius);
  overflow:hidden;
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
  transition:.2s ease;
}
.work:hover{transform:translateY(-2px); background: rgba(255,255,255,.03)}
.work .thumb{
  aspect-ratio: 16 / 9;
  background:
    radial-gradient(500px 200px at 20% 0%, rgba(74,163,255,.22), transparent 60%),
    radial-gradient(500px 200px at 80% 60%, rgba(32,227,162,.18), transparent 60%),
    rgba(255,255,255,.02);
  border-bottom:1px solid rgba(255,255,255,.08);
}
.work .body{padding:14px}
.work h4{margin:0 0 6px}
.work p{margin:0; color:var(--muted); font-size:14px; line-height:1.45}
.tags{display:flex; gap:8px; flex-wrap:wrap; margin-top:10px}
.tag{
  font-size:12px; font-weight:800;
  color: rgba(234,242,255,.85);
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
  padding:6px 10px;
  border-radius:999px;
}

/* Services cards */
.cards{
  display:grid;
  grid-template-columns: repeat(4, 1fr);
  gap:14px;
  padding: 22px 0 10px;
}
.card{
  border:1px solid var(--line);
  background: rgba(255,255,255,.02);
  border-radius: var(--radius);
  padding:16px;
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
}
.card .icon{
  width:42px; height:42px; border-radius:14px;
  display:grid; place-items:center;
  background: rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.10);
  color:var(--accent2);
  margin-bottom:10px;
}
.card h3{margin:0 0 6px; font-size:16px}
.card p{margin:0; color:var(--muted); font-size:14px; line-height:1.45}

/* Contact page */
.grid-2{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
  padding: 22px 0 10px;
}
.row{
  display:flex; gap:10px; align-items:center;
  padding:12px; border-radius:14px;
  border:1px solid rgba(255,255,255,.08);
  background: rgba(7,26,43,.35);
  margin-bottom:10px;
}
.row i{
  width:36px; height:36px; border-radius:12px;
  display:grid; place-items:center;
  background: rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.10);
  color: var(--accent);
}
.row span{color:var(--muted); font-weight:700}
.row a{font-weight:800}

.form{display:grid; gap:10px}
input, textarea{
  width:100%;
  padding:12px 12px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.03);
  color: var(--text);
  outline:none;
  font-family:inherit;
}
textarea{min-height:120px; resize:vertical}

/* Footer */
.footer{
  margin-top:38px;
  border-top:1px solid var(--line);
  background: rgba(7,26,43,.65);
}
.footer-top{
  padding:24px 0;
  display:grid;
  grid-template-columns: 1.2fr .8fr .8fr;
  gap:16px;
}
.footer h4{margin:0 0 10px}
.footer p, .footer li{color:var(--muted); margin:0; line-height:1.6}
.footer ul{list-style:none; padding:0; margin:0; display:grid; gap:8px}
.footer a{color:var(--muted); font-weight:700}
.footer a:hover{color:var(--text)}
.footer-under{
  border-top:1px solid var(--line);
  padding:14px 0;
  display:flex; align-items:center; justify-content:space-between;
  gap:12px; flex-wrap:wrap;
}
.social{display:flex; gap:10px; align-items:center}
.social a{
  width:40px; height:40px; border-radius:14px;
  border:1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.03);
  display:grid; place-items:center;
  transition:.2s ease;
  color: rgba(234,242,255,.9);
}
.social a:hover{transform:translateY(-1px); border-color:rgba(255,255,255,.18)}

/* Responsive */
@media (max-width: 980px){
  .footer-top{grid-template-columns: 1fr}
  .portfolio-grid{grid-template-columns: repeat(2, 1fr)}
  .cards{grid-template-columns: repeat(2, 1fr)}
  .grid-2{grid-template-columns:1fr}
}
@media (max-width: 560px){
  .portfolio-grid{grid-template-columns: 1fr}
  .cards{grid-template-columns: 1fr}
  .nav{gap:6px}
  .nav a{padding:8px 10px}
}

/* ==============================
   HOME PAGE – FULL IMAGE HERO
================================ */
.home-hero{
  min-height: calc(100vh - 68px);
  display:flex;
  align-items:center;
}

.hero-layout{
  display:grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap:32px;
  align-items:center;
}

.hero-copy{
  max-width: 560px;
}

.hero-image{
  position:relative;
  height: 70vh;
  min-height: 420px;
  border-radius: var(--radius);
  overflow:hidden;
  box-shadow: var(--shadow);
}

.hero-image img{
  width:100%;
  height:100%;
  object-fit:cover;
}

/* ==============================
   HOME ABOUT SECTION (WITH PHOTO)
================================ */
.about-layout{
  display:grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap:32px;
  align-items:start;
}

.about-photo{
  border-radius: var(--radius);
  overflow:hidden;
  box-shadow: var(--shadow);
}

.about-photo img{
  width:100%;
  display:block;
  object-fit:cover;
}

@media (max-width: 900px){
  .hero-layout,
  .about-layout{
    grid-template-columns: 1fr;
  }

  .hero-image{
    height: 45vh;
  }
}

.thumb{
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: rgba(255,255,255,.02);
  border-radius: 12px;
}

.thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
  transition: transform .35s ease;
}

.work:hover .thumb img{
  transform: scale(1.05);
}

/* Portfolio hover overlay */
.thumb{
  position: relative;
}

.thumb::after{
  content: "View website →";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(7,26,43,0.72);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  letter-spacing: .2px;
  opacity: 0;
  transition: opacity .25s ease;
}

.work:hover .thumb::after{
  opacity: 1;
}

/* HEADER NAV: keep links on one line (no ugly wrap) */
.header .bar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
}

.header .brand{
  display:flex;
  align-items:center;
  gap:10px;
  min-width: 0;          /* allows brand text to shrink */
  flex: 0 1 auto;
}

.header .nav{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap: nowrap;     /* stops wrapping */
  white-space: nowrap;   /* keeps links on one line */
  overflow-x: auto;      /* if tight, scroll instead of wrapping */
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox hide scrollbar */
}

.header .nav::-webkit-scrollbar{
  display:none;          /* Chrome/Safari hide scrollbar */
}

/* Optional: slightly tighter links so they fit easier */
.header .nav a{
  padding: 8px 10px;
  font-size: 14px;
}
