/* assets/css/style.css
   Minimalist Luxury Neutral Theme (applied everywhere)
   Palette:
   --page-bg: #F2F2F2
   --surface-soft: #EAE4D5
   --surface-muted: #B6B09F
   --accent (primary): #000000
   --text: #000000
*/

/* THEME VARIABLES */
:root{
  --page-bg: #F2F2F2;      /* soft light neutral */
  --bg: #FFFFFF;           /* pure white for cards */

  --surface-soft: #EAE4D5; /* warm beige-tan soft surface */
  --surface-muted: #B6B09F;/* muted warm accent surface */

  --accent: #272727;       /* bold black for buttons & highlights */
  --accent-2: #1A1A1A;     /* subtle hover black */

  --text: #272727;         /* strong contrast black */
  --muted: #6C6C6C;        /* gentle soft grey muted text */

  --radius: 12px;
  --gap: 18px;
  --container: 1200px;
  --header-h: 72px;
  --glass: rgba(0, 0, 0, 0.08);

  --shadow-1: 0 8px 24px rgba(0,0,0,0.04);
  --shadow-2: 0 16px 36px rgba(0,0,0,0.08);

  --ease: cubic-bezier(.25,.78,.25,1);
}

/* RESET + BASE */
*{ box-sizing:border-box; }
html,body{ height:100%; }
body{
  margin:0;
  padding-top: calc(var(--header-h));
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  background: var(--page-bg);
  color: var(--text);
  font-size:16px;
  line-height:1.5;
}
.container{ width:92%; max-width:var(--container); margin:0 auto; padding:18px 0; }
a{ color:inherit; text-decoration:none; }
img{ max-width:100%; height:auto; display:block; }

/* HEADER & NAV */
.site-header{
  position:fixed;
  top:0; left:0; right:0;
  height:var(--header-h);
  display:flex; align-items:center; z-index:9999;
  background: rgba(255,255,255,0.96);
  border-bottom:1px solid rgba(0,0,0,0.04);
  backdrop-filter: blur(6px);
  transition: background .18s var(--ease), box-shadow .18s var(--ease);
}
.site-header.scrolled-header{ box-shadow: var(--shadow-1); }
.header-inner{ width:100%; display:flex; align-items:center; justify-content:flex-end; gap:var(--gap); padding:0 20px; }

.nav{ display:flex; gap:14px; align-items:center; }
.nav-link{ color:var(--muted); font-weight:600; font-size:14px; padding:8px 10px; border-radius:8px; transition: all .14s var(--ease); }
.nav-link:hover{ color:var(--text); background: rgba(0,0,0,0.02); }
.nav-link.active{ color:var(--accent); background: rgba(182,176,159,0.06); }

/* Resume CTA in nav */
.resume-link{
  padding:8px 14px; border-radius:10px; font-weight:700;
  background: var(--accent); color:#fff; box-shadow:var(--shadow-1); border:1px solid rgba(0,0,0,0.04);
}

/* Mobile drawer */
.nav-toggle{ display:none; background:transparent; border:none; cursor:pointer; padding:6px; color:var(--text); z-index:10002; }
@media(max-width:900px){
  .header-inner{ justify-content:space-between; }
  .nav-toggle{ display:block; }
  .nav{
    position:fixed; top:var(--header-h); right:-320px; width:280px; height:calc(100vh - var(--header-h));
    flex-direction:column; align-items:flex-start; gap:12px; padding:22px;
    background: linear-gradient(180deg, var(--bg), var(--surface-soft));
    box-shadow:-10px 0 40px rgba(0,0,0,0.08);
    transition: right .28s var(--ease); z-index:10001;
  }
  .nav.nav-open{ right:0; }
  .resume-link{ width:100%; text-align:center; padding:12px 18px; }
  .nav-link{ width:100%; padding:12px 10px; border-radius:8px; }
}
body.nav-open-lock{ overflow:hidden; }

/* ensure anchors land under header */
section{ scroll-margin-top: calc(var(--header-h) + 24px); }

/* HERO */
.hero-hero{
  position:relative; display:flex; align-items:center;
  min-height:86vh; overflow:hidden; padding: 28px 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(255,255,255,0.94));
}

/* hero background image (attached image) */
.hero-hero::before{
  content: "";
  position:absolute; inset:0;
  background-image: url('assets/img/home-bg.jpg');
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  opacity:0.18; filter: contrast(0.98) saturate(0.95);
  z-index:0;
}

/* Transparent dark/white overlay to control background-opactiy ONLY */
.hero-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.60); /* adjust opacity here */
  z-index: 0;
}


/* inner hero content */
.hero-inner{
  position:relative; z-index:2; width:92%; max-width:1200px; margin:0 auto;
  display:flex; gap:36px; align-items:center; padding:36px;
  background: linear-gradient(180deg, rgba(255,255,255,0.88), rgba(255,255,255,0.85));
  border-radius:18px; border:1px solid rgba(0,0,0,0.03); box-shadow: var(--shadow-2);
}
.hero-left{ max-width:760px; }

/* big name */
.big-name{ margin:0; font-weight:900; font-size:clamp(2.4rem,6vw,4.8rem); line-height:0.92; color:#B6B09F; letter-spacing:-1px; }
.big-name .last{ color:var(--accent); }

/* tagline and stats */
.hero-tagline{ margin-top:12px; color:var(--muted); font-size:1.05rem; }
.stats{ display:flex; gap:18px; margin-top:18px; flex-wrap:wrap; }
.stat strong{ font-size:1.4rem; font-weight:800; color:var(--text); }
.stat span{ color:var(--muted); }

/* CTAs */
.hero-ctas{ margin-top:20px; display:flex; gap:12px; }
.btn{ padding:12px 16px; border-radius:10px; font-weight:800; cursor:pointer; transition: all .18s var(--ease); }
.btn-primary{ background: var(--accent); color:#fff; border:none; box-shadow:var(--shadow-1); }
.btn-primary:hover{ background:var(--accent-2); transform: translateY(-2px); }
.btn-ghost{
  background: transparent;
  color: #272727;
  border: 1.6px solid #272727;
  transition: all .18s ease;
}

.btn-ghost:hover{
  background: rgba(0,0,0,0.05);
  color: #272727;
  border-color: #272727;
}


/* scroll arrow */
.scroll-down{ position:absolute; left:50%; bottom:46px; transform:translateX(-50%); color:#fff; z-index:3; font-size:20px; }

/* responsive hero */
@media(max-width:900px){
  .hero-inner{ padding:22px; flex-direction:column; align-items:flex-start; }
  .big-name{ font-size:2.4rem; }
}

/* ABOUT */
.about-section{ padding:86px 0; }
.about-inner{ display:flex; gap:32px; align-items:flex-start; flex-wrap:wrap; }
.about-img-wrapper{ flex:0 0 420px; max-width:460px; }
.about-img{ width:100%; height:auto; border-radius:14px; object-fit:cover; box-shadow:var(--shadow-1); border:1px solid rgba(0,0,0,0.03); }
.about-text{ flex:1; display:flex; flex-direction:column; gap:12px; }
.about-text h2{ font-size:1.6rem; margin:0; color:var(--text); }
.about-text p{ margin:0; color:var(--muted); line-height:1.6; }
.about-text .btn{ margin-top:10px; align-self:flex-start; }

/* EXPERIENCE */
.experience-section{ padding:72px 0; }
.section-title{ font-size:1.4rem; margin:0 0 12px; font-weight:800; color:var(--text); }
.exp-grid{ display:grid; gap:18px; grid-template-columns:1fr; }
@media(min-width:720px){ .exp-grid{ grid-template-columns:repeat(2,1fr); } }
@media(min-width:1100px){ .exp-grid{ grid-template-columns:repeat(3,1fr); } }

.exp-card{
  background: var(--bg); border-radius:12px; padding:18px; border:1px solid rgba(0,0,0,0.04);
  box-shadow: var(--shadow-1); transition: transform .14s var(--ease), box-shadow .14s var(--ease);
}
.exp-card:hover{ transform: translateY(-6px); box-shadow: var(--shadow-2); }

.exp-role{ margin:0 0 6px; font-weight:800; color:var(--accent); }
.exp-company{ margin:0 0 6px; color:var(--muted); }
.exp-duration{ margin:0 0 12px; color:var(--muted); font-weight:600; }
.exp-list{ margin-left:18px; color:var(--muted); line-height:1.6; }

/* PROJECTS */
.projects-section{ padding:80px 0; }
.section-lead{ color:var(--muted); margin:6px 0 18px; max-width:70ch; }
.projects-grid{ display:grid; gap:20px; grid-template-columns:repeat(auto-fit,minmax(300px,1fr)); }

.project-card{
  display:flex; flex-direction:column; background: var(--bg); border-radius:12px;
  border:1px solid rgba(0,0,0,0.04); box-shadow:var(--shadow-1); overflow:hidden;
  transition: transform .18s var(--ease), box-shadow .18s var(--ease);
}
.project-card:hover{ transform: translateY(-6px); box-shadow:var(--shadow-2); }
.proj-media{ flex:0 0 auto; height:220px; overflow:hidden; background:var(--surface-soft); }
.proj-img{ width:100%; height:100%; object-fit:cover; display:block; }
.proj-body{ display:flex; flex-direction:column; gap:12px; padding:16px; flex:1 1 auto; }
.proj-title{ margin:0; font-weight:800; color:var(--accent); }
.proj-desc{ margin:0; color:var(--muted); line-height:1.45; }
.proj-meta{ margin-top:auto; display:flex; gap:8px; align-items:center; }

/* tags */
.tag{ padding:6px 10px; background: rgba(182,176,159,0.06); border-radius:8px; color:var(--accent); border:1px solid rgba(143,134,125,0.10); font-weight:600; font-size:0.85rem; }
.btn-view{ padding:8px 10px; font-weight:700; border-radius:8px; }

/* PROJECT MODAL */
.modal{ position:fixed; inset:0; display:none; align-items:center; justify-content:center; z-index:2000; }
.modal[aria-hidden="false"]{ display:flex; }
.modal-backdrop{ position:absolute; inset:0; background:rgba(0,0,0,0.45); }
.modal-panel{ position:relative; width:92%; max-width:1000px; border-radius:12px; overflow:hidden; padding:18px; background:var(--bg); border:1px solid rgba(0,0,0,0.04); box-shadow:var(--shadow-2); }
.modal-img{ width:46%; float:left; margin-right:18px; object-fit:cover; border-radius:10px; }
.modal-text h3{ margin-top:0; color:var(--text); }
.modal-text p{ color:var(--muted); }

/* CONTACT */
.contact-section{ padding:80px 0; }
.contact-grid{ display:flex; gap:28px; flex-wrap:wrap; align-items:flex-start; }
.contact-card{ flex:1; min-width:300px; max-width:640px; background:var(--bg); border-radius:12px; padding:20px; border:1px solid rgba(0,0,0,0.04); box-shadow:var(--shadow-1); }
.contact-card .lead{ color:var(--muted); line-height:1.6; margin:6px 0 16px; }
.contact-actions{ display:flex; gap:12px; margin-bottom:16px; }
.btn.large{ padding:12px 18px; font-size:1rem; }

/* contact meta */
.contact-meta{ margin-top:6px; display:flex; flex-direction:column; gap:12px; }
.meta-line{ display:flex; gap:10px; align-items:center; color:var(--muted); }
.meta-line a{ color:var(--accent); font-weight:700; text-decoration:none; }

/* right mini card */
.contact-form-card{ flex:0.9; min-width:240px; max-width:420px; display:flex; align-items:center; }
.contact-card-mini{ width:100%; background:var(--surface-soft); padding:14px; border-radius:10px; border:1px solid rgba(0,0,0,0.03); }

/* FOOTER */
.site-footer{ padding:28px 0; text-align:center; color:var(--muted); }

/* SMALL SCREENS */
@media(max-width:900px){
  .container{ width:94%; }
  .projects-grid{ grid-template-columns:1fr; }
  .modal-img{ width:100%; float:none; margin:0 0 12px 0; }
  .contact-grid{ flex-direction:column; align-items:stretch; }
}

/* small accessibility focus */
a:focus, button:focus{ outline: 3px solid rgba(0,0,0,0.06); outline-offset:2px; border-radius:6px; }

.modal-subtitle {
  font-weight: 700;
  color: var(--muted);      /* same muted grey as experience duration */
  font-size: 0.95rem;
  margin: 0 0 6px;
}


/* ===== Project 1 custom modal ===== */

.modal-image-row{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.modal-image-row img{
  width: 100%;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
}

/* keep 3 images even on mobile */
@media(max-width: 600px){
  .modal-image-row{
    grid-template-columns: repeat(3, 1fr);
  }
}

.modal-title{
  margin: 8px 0 2px;
  font-weight: 800;
}

.modal-meta{
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.modal-section{
  margin-top: 18px;
  font-weight: 700;
  font-size: 1rem;
}

.modal-table{
  width: 100%;
  border-collapse: collapse;
  margin-top: 6px;
}

.modal-table td{
  padding: 6px 4px;
  font-size: 0.9rem;
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

.modal-table td:first-child{
  color: var(--muted);
  width: 40%;
}


/* =========================
   PROJECT MODAL – FINAL
   ========================= */

.modal{
  position: fixed;
  inset: 0;
  display: none;
  z-index: 3000;
}

.modal[aria-hidden="false"]{
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-backdrop{
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
}

.modal-panel{
  position: relative;
  width: 94%;
  max-width: 1100px;
  max-height: 90vh;
  background: var(--bg);
  border-radius: 14px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-content{
  padding: 22px;
  overflow-y: auto;
}

.modal-close{
  position: absolute;
  top: 12px;
  right: 16px;
  border: none;
  background: transparent;
  font-size: 22px;
  cursor: pointer;
}

.modal-footer{
  padding: 14px;
  text-align: center;
  border-top: 1px solid rgba(0,0,0,0.06);
}

.modal-image-row{
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
}

.modal-image-row.cols-3{
  grid-template-columns: repeat(3, 1fr);
}

.modal-image-row.cols-2{
  grid-template-columns: repeat(2, 1fr);
}

.modal-image-row img{
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 10px;
}

body.modal-open{
  overflow: hidden;
}

@media(max-width:700px){
  .modal-panel{
    max-height: 94vh;
  }
  .modal-image-row img{
    height: 130px;
  }
}


/* === FIX: Keep modal away from fixed navbar === */

.modal[aria-hidden="false"]{
  align-items: flex-start;              /* instead of center */
  padding-top: calc(var(--header-h) + 16px);
  padding-bottom: 16px;
}


/* === FIX: Proper spacing from navbar AND bottom === */

.modal[aria-hidden="false"]{
  align-items: flex-start;
  padding-top: calc(var(--header-h) + 16px);
  padding-bottom: 24px;   /* 👈 bottom gap */
}

/* ensure modal box never touches edges */
.modal-panel{
  max-height: calc(100vh - var(--header-h) - 40px);
}




