/* ========================= */
/* 🔧 BASE + RESET */
/* ========================= */

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  font-family: 'Segoe UI', sans-serif;
  color: #e8ecf1;
  min-height: 100vh;
  position: relative;
  z-index: 0;
  font-size: 16px;
  min-width: 320px;
}

/* ========================= */
/* 🎨 BACKGROUND */
/* ========================= */

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background: url("https://images.unsplash.com/photo-1576487248805-cf45f6bcc67f?auto=format&fit=crop&w=1920&q=80") no-repeat center center/cover;
  filter: blur(1px) brightness(0.5);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(135deg, rgba(10,15,28,0.9), rgba(14,22,40,0.95));
}

/* ========================= */
/* 🧱 LAYOUT */
/* ========================= */

.layout {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 240px;
  background: rgba(12, 20, 36, 0.85);
  backdrop-filter: blur(10px);
  padding: 25px;
  border-right: 1px solid rgba(255,255,255,0.05);
}

.main {
  flex: 1;
  padding: 25px;
}

/* ========================= */
/* 🔤 TYPOGRAPHY */
/* ========================= */

h1 {
  font-size: clamp(24px, 4vw, 32px);
}

h2 {
  font-size: clamp(20px, 3vw, 26px);
}

h3 {
  font-size: clamp(17px, 2.5vw, 22px);
}

h1, h2, h3 {
  color: #ffffff;
  font-weight: 600;
}

/* ========================= */
/* 🧩 SIDEBAR */
/* ========================= */

.sidebar h2 {
  color: #7ab8ff;
  margin-bottom: 30px;
}

.sidebar p {
  padding: 10px;
  margin-bottom: 8px;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.25s ease;
}

.sidebar p:hover {
  background: rgba(122,184,255,0.08);
}

/* ========================= */
/* 📦 CARDS */
/* ========================= */

.card {
  background: rgba(18, 26, 43, 0.75);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.05);
  padding: 20px;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.6);
  transition: 0.25s ease;
}

.card:hover {
  transform: translateY(-2px);
}

/* ========================= */
/* 📊 STATS + GRID */
/* ========================= */

.stats {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 15px;
}

/* ========================= */
/* 💼 JOB + APP CARDS */
/* ========================= */

.job-card, .app-card {
  background: rgba(20, 29, 48, 0.75);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.05);
  padding: 15px;
}

.job-card:hover {
  transform: scale(1.02);
}

/* ========================= */
/* 🔘 BUTTONS */
/* ========================= */

button {
  background: linear-gradient(145deg, #2f6fed, #1f56c2);
  color: white;
  border: none;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.25s ease;
  font-weight: 500;
  min-height: 42px;
}

button:hover {
  transform: translateY(-1px);
}

button.danger {
  background: linear-gradient(145deg, #d64545, #a93232);
}

button.secondary {
  background: linear-gradient(145deg, #3a3f4b, #2a2f3a);
}

/* ========================= */
/* ✏️ INPUTS */
/* ========================= */

input, textarea {
  width: 100%;
  padding: 10px;
  margin-top: 8px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(12, 21, 38, 0.85);
  color: white;
  font-size: 16px;
}

/* ========================= */
/* 📱 MOBILE FIX (MAIN FIX) */
/* ========================= */

@media (max-width: 768px) {

  body {
    font-size: 17px;
    line-height: 1.5;
  }

  .layout {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    padding: 15px;
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.05);
  }

  .main {
    padding: 15px;
  }

  .stats {
    flex-direction: column;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  /* 🔥 KEY FIXES */
  h1 { font-size: 26px; }
  h2 { font-size: 22px; }
  h3 { font-size: 18px; }

  button {
    width: 100%;
    padding: 14px;
    font-size: 16px;
  }

  input, textarea {
    padding: 14px;
    font-size: 16px;
  }

  .sidebar p {
    font-size: 16px;
    padding: 12px;
  }

  .card {
    padding: 16px;
  }
}

/* ========================= */
/* 💻 LARGE SCREEN POLISH */
/* ========================= */

@media (min-width: 1200px) {
  .main {
    padding: 40px;
  }

  .grid {
    gap: 20px;
  }
}