/* css/style.css — cleaned, consolidated, and annotated */

/* ========================
   Variables (light + dark)
   ======================== */
:root{
  --bg-start: #f4f7fb;
  --bg-end: #eef4fb;
  --card: #ffffff;
  --muted: #6b7280;
  --text: #0f1724;
  --accent: #10b981;
  --accent-strong: #34d399;
  --danger: #ef4444;
  --radius: 12px;
  --shadow: 0 8px 30px rgba(2,6,23,0.06);
  --glass-border: rgba(15,23,42,0.06);
  --font-default: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
}
/* Base */
* { box-sizing: border-box; }
html,body { height:100%; }
body {
  margin: 0;
  font-family: var(--font-default);
  color: var(--text);
  background: linear-gradient(180deg, var(--bg-start), var(--bg-end));
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background .25s ease, color .25s ease;
}

/* Dark mode */
html.dark, body.dark {
  --bg-start: #071428 ; 
  --bg-end: #071928;
  --card: #0d1720;
  --muted: #9aa3b2;
  --text: #e6eef5;
  --accent: var(--accent-strong);
  --shadow: 0 10px 40px rgba(2,6,23,0.5);
  --glass-border: rgba(255,255,255,0.03);
}

/* ========================
   Common components
   ======================== */
/* Common components */
.logo {
  width: 44px; height: 44px; border-radius: 10px;
  background: linear-gradient(135deg,var(--accent),#3b82f6);
  color: #fff; display:inline-flex; align-items:center; justify-content:center; font-weight:700;
}
h3{
    color: black;
}

/* Card glass effect */
.card {
 
  border-radius: var(--radius);
  padding: 20px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: 0 12px 32px rgba(52,211,153,0.12); }


/* Inputs/buttons */
.input {
  border: 1px solid rgba(15,23,42,0.06);
  border-radius: 10px;
  padding: 8px 10px;
  background: transparent;
  width: 100%;
  color: var(--text);
  transition: box-shadow .15s ease, border-color .15s ease;
}
.input:focus { outline:none; box-shadow: 0 6px 18px rgba(16,185,129,0.06); border-color:var(--accent); }

.btn {
  display:inline-flex; align-items:center; justify-content:center;
  padding: 8px 12px; border-radius: 10px; border: 1px solid rgba(15,23,42,0.06);
  background: transparent; cursor:pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.btn.primary {
  background-color: var(--accent); color:#fff; border:none;
  padding:.75rem 1.25rem; font-weight:600; box-shadow: 0 6px 18px rgba(16,185,129,0.12);
}
.btn.primary:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 10px 26px rgba(16,185,129,0.14); }

.btn-icon { background:transparent; border:none; cursor:pointer; font-size:1.2rem; }


/* Links & nav */
.nav-link { color: var(--muted); text-decoration: none; }
.nav-link.active { color: var(--text); font-weight: 600; }

/* ========================
   Planner & tasks
   ======================== */
.unscheduled { display:flex; flex-direction:column; gap:10px; min-height:100px; }
.task-item {
  padding: 10px; border-radius: 10px; display:flex; justify-content:space-between; align-items:center;
  background: linear-gradient(180deg, rgba(255,255,255,0.85), rgba(248,250,252,0.85));
  box-shadow: 0 6px 18px rgba(2,6,23,0.03); cursor:grab;
  transition: transform .18s ease, box-shadow .18s ease, background .2s ease;
}
.task-item:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(2,6,23,0.06); }
html.dark .task-item { background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01)); }

/* Planner grid */
.planner-wrap {
  background: linear-gradient(180deg, rgba(255,255,255,0.6), rgba(248,250,252,0.6));
  border-radius: 10px;
  padding: 8px;
  overflow: auto;
}
body.dark .planner-wrap { background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01)); }

.planner-grid { min-width: 1000px; position: relative; }
.grid-header {
  display: grid;
  grid-template-columns: 80px repeat(7,1fr);
  gap: 0;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(15,23,42,0.04);
}
.grid-header .col-name { text-align:center; font-weight:600; color:var(--muted); }

.grid-row {
  display: grid;
  grid-template-columns: 80px repeat(7,1fr);
  border-bottom: 1px dashed rgba(15,23,42,0.04);
}
.hour-label {
  padding: 10px;
  text-align: right;
  color: var(--muted);
  border-right: 1px solid rgba(15,23,42,0.04);
  font-size: 12px;
}
.hour-cell {
  min-height: 64px;
  padding: 8px;
  border-left: 1px solid rgba(15,23,42,0.04);
  overflow: auto;
  transition: background .12s ease, box-shadow .12s ease;
}
.hour-cell:hover { background: rgba(241,245,249,0.95); box-shadow: inset 0 0 6px rgba(0,0,0,0.04); }
.scheduled {
  padding: 6px 8px;
  margin-bottom: 8px;
  border-radius: 10px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  cursor: grab;
}

/* ========================
   Trash bin
   ======================== */
.trash {
  background: rgba(239,68,68,0.08);
  border: 1px solid rgba(239,68,68,0.18);
  color: var(--danger);
  width: 56px;
  height: 56px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius: 10px;
  transition: transform .28s ease, box-shadow .28s ease;
}
.trash:hover { transform: scale(1.08) rotate(-6deg); box-shadow: 0 12px 28px rgba(239,68,68,0.15); }

/* ========================
   Modal (single definition)
   ======================== */
#taskModal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  background: rgba(0,0,0,0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}
#taskModal .modal-card {
  background: var(--card);
  border-radius: 12px;
  padding: 18px;
  width: 92%;
  max-width: 420px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  transform: translateY(6px) scale(.995);
}
#taskModal:not(.hidden) {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}
#taskModal .close-btn {
  position: absolute;
  top: 10px;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 1rem;
  color: var(--muted);
}

/* Modal content typography */
#modalTitle { font-size: 1.125rem; font-weight: 700; margin-bottom: 6px; color: var(--text); }
#modalDeadline, #modalPriority { font-size: .9rem; color: var(--muted); margin-bottom: 6px; }
#modalDesc { font-size: .95rem; color: var(--text); line-height: 1.35; }

/* ========================
   Gauge (SVG) styling
   ======================== */
.gauge-bg { fill: none; stroke: #d1d5db; stroke-width: 2.5; transition: stroke .2s ease; }
body.dark .gauge-bg { stroke: #1f2937; }
.gauge-value { fill:none; stroke: var(--accent); stroke-width: 2.5; stroke-linecap: round; transition: stroke-dasharray .5s ease, stroke .2s ease; }
body.dark .gauge-value { stroke: var(--accent-strong); }
.gauge-text { font-size: .35rem; fill: var(--text); font-weight:bold; }

/* ========================
   Tabs and nav micro-interactions
   ======================== */
.tab {
  position: relative;
  padding: 6px 12px;
  border-radius: 8px;
  color: var(--muted);
  transition: color .28s ease;
  text-decoration: none;
}
.tab::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0%;
  height: 2px;
  background: var(--accent);
  transition: width .28s ease, left .28s ease;
}
.tab:hover { color: var(--text); }
.tab:hover::after { width: 100%; left: 0; }
.tab.active { color: #000; font-weight: 700; }

/* ========================
   Small utility & responsive
   ======================== */
.hidden { display: none !important; }
.mobileonly { display: none; }
@media (max-width: 980px) {
  .mobileonly { display: flex; }
  .planner-grid { min-width: 760px; }
}

/* ========================
   Polished UI touches
   ======================== */
/* subtle pulsing fab */
.fab { animation: pulse 2.2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(16,185,129,0.26); } 70% { box-shadow: 0 0 0 10px rgba(16,185,129,0); } 100% { box-shadow: 0 0 0 0 rgba(16,185,129,0); } }

/* small helpers */
.today {  border: 1px solid rgba(0,123,255,0.16); color: #007bff; padding:6px 10px; border-radius:6px; font-weight:500; }
/* === Landing Page Animation Enhancements === */

/* Scroll fade/slide animation base */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease;
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}


/* Feature cards hover + entry animation */
.feature-card {
  background: #ffffff !important;
  border: 1px solid rgba(0,0,0,0.05);
  border-radius: 1rem;
  box-shadow: 0 8px 30px rgba(0,0,0,0.05);
  transition: all 0.35s ease;
  transform: translateY(0);
}
.feature-card:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: 0 16px 40px rgba(16,185,129,0.15);
}

/* Animated icons */
.feature-card i {
  transition: transform 0.5s ease, color 0.3s ease;
}
.feature-card:hover i {
  transform: rotate(6deg) scale(1.15);
  color: var(--accent);
}

/* Glowing shadow pulse */
.feature-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 1rem;
  background: radial-gradient(circle at center, rgba(16,185,129,0.1), transparent 60%);
  opacity: 0;
  transition: opacity 0.5s ease;
}
.feature-card:hover::after { opacity: 1; }

/* Section title animation underline */
.section-title {
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -8px;
  width: 0;
  height: 3px;
  background: var(--accent);
  transition: all 0.4s ease;
}
.section-title.reveal.active::after {
  left: 0;
  width: 100%;
}

/* Pulse effect for “AI Features” cards */
.ai-card:hover {
  animation: pulseCard 1.5s ease-in-out;
}
@keyframes pulseCard {
  0% { transform: scale(1); box-shadow: 0 0 0 rgba(16,185,129,0.2); }
  50% { transform: scale(1.04); box-shadow: 0 0 30px rgba(16,185,129,0.15); }
  100% { transform: scale(1); }
}
/* ...existing code... */

/* responsive helpers */
.responsive-img { max-width: 100%; height: auto; display: block; }

/* Card & container tweaks */
.card { border-radius: .75rem;  box-shadow: 0 6px 18px rgba(0,0,0,0.04); }
@media (max-width: 640px) {
  .card { padding: 1rem !important; }
}

/* Inputs & buttons full width on small screens */
.input { width: 100%; padding: .6rem .75rem; border-radius: .5rem; border: 1px solid rgba(0,0,0,0.08); }
.btn { padding: .6rem 1rem; border-radius: .6rem; }
.btn.w-full, .btn.full { width: 100%; }

/* Mobile nav specific */
.mobile-menu { display: none; }
.mobile-menu.open { display: block; }
@media (min-width: 768px) {
  .mobile-toggle { display: none; }
}

/* Small spacing improvements */
@media (max-width: 640px) {
  .logo { width: 40px; height: 40px; font-size: 0.9rem; }
  .section-title { font-size: 1.4rem; }
  .feature-card { padding: 1rem; }
}
/* ...existing code... */

/* Ensure desktop nav is visible on medium+ screens in case Tailwind not loaded or .hidden overwritten */
@media (min-width: 768px) {
  .nav-desktop { display: flex !important; gap: 1.5rem; align-items: center; }
}
/* ...existing code... */
/* Planner grid and task block styles for extensions */
.planner-grid { width: 100%; }
.planner-grid .card { box-shadow: var(--shadow); }
.grid-slot { position: relative; padding: 6px; min-height: 0; }
.task-block {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  background: linear-gradient(180deg, rgba(16,185,129,0.08), rgba(16,185,129,0.03));
  color: #08332f;
  border-radius: 8px;
  margin: 4px;
  padding: 6px;
  cursor: pointer;
  font-weight: 600;
  overflow: hidden;
}
html.dark .task-block { background: linear-gradient(180deg, rgba(52,211,153,0.07), rgba(16,24,39,0.04)); color: var(--text); }
.task-block.card { border-radius:8px; }
/* Header "today" highlight */
.today { outline: 2px solid rgba(16,185,129,0.18); }
/* small helper for month badges */
.day-tasks .feature-card { padding:6px; font-size:0.9rem; }