/* =======================================================
   MagiMagi — Modern Warm UI (2026)
   Clean, bold, responsive
   ======================================================= */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&family=Fraunces:opsz,wght@9..144,600;9..144,700&display=swap');

:root {
  --brand-primary: #f4b400; /* amber */
  --brand-primary-600: #e2a000;
  --brand-ink: #1f1f1f;
  --brand-ink-2: #2b2b2b;
  --text-main: #1f1f1f;
  --text-muted: #5f6368;
  --text-light: #ffffff;
  --surface: #ffffff;
  --surface-alt: #fff8ed;
  --surface-2: #f7f4ef;
  --stroke: #e6e2db;
  --shadow-sm: 0 6px 16px rgba(0,0,0,0.06);
  --shadow-md: 0 14px 30px rgba(0,0,0,0.12);
  --shadow-lg: 0 24px 48px rgba(0,0,0,0.18);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --speed-fast: 160ms;
  --speed-med: 260ms;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  font-family: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  color: var(--text-main);
  background: linear-gradient(180deg, #fbfaf7 0%, #f6f1e9 100%);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 {
  font-family: "Fraunces", "Manrope", serif;
  letter-spacing: 0.2px;
}

body { display: flex; flex-direction: column; }

/* ---------- Header ---------- */
#header {
  background: radial-gradient(1200px 300px at 50% -30%, #2f2f2f 0%, #141414 60%);
  color: #fff;
  padding: 40px 0 28px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

#header::after {
  content: "";
  position: absolute;
  inset: -60px -40px auto;
  height: 140px;
  background: radial-gradient(600px 120px at 50% 0%, rgba(244,180,0,0.25), transparent 70%);
  pointer-events: none;
}

#header .brand { display: inline-block; margin: 0 auto; }
#header .brand .logo {
  width: clamp(200px, 40vw, 320px);
  height: auto;
  display: block;
  margin: 0 auto;
  filter: brightness(0) invert(1);
  animation: fadeUp var(--speed-med) ease-out;
}

/* ---------- Navigation ---------- */
#nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 14px 12px;
  margin: 0 auto;
  background: rgba(255,255,255,0.9);
  border: 1px solid var(--stroke);
  border-left: 0;
  border-right: 0;
  backdrop-filter: blur(6px);
}

#nav a {
  padding: 10px 16px;
  color: var(--brand-ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 999px;
  transition: transform var(--speed-fast) ease, background var(--speed-fast) ease, color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}

#nav a:hover {
  background: var(--surface-alt);
  color: var(--brand-ink-2);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

#nav a.active {
  background: var(--brand-primary);
  color: var(--brand-ink-2);
  box-shadow: var(--shadow-sm);
}

@media (max-width: 768px) {
  #nav { gap: 6px; padding: 10px 6px; }
  #nav a { padding: 8px 12px; font-size: 0.85rem; }
}

@media (max-width: 480px) {
  #nav { gap: 4px; padding: 8px 4px; }
  #nav a { padding: 6px 10px; font-size: 0.78rem; }
}

/* Social links */
#nav .social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 34px;
  width: 34px;
  border-radius: 50%;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--stroke);
  transition: transform var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
  margin: 0 2px;
}
#nav .social-link img { height: 18px; width: 18px; display: block; }
#nav .social-link:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
@media (max-width: 768px) {
  #nav .social-links { flex-basis: 100%; display: flex; justify-content: center; margin-top: 6px; gap: 6px; }
}

/* ---------- Container & Footer ---------- */
#container {
  flex: 1;
  max-width: 1040px;
  width: 92%;
  margin: 24px auto;
  padding: 28px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

@media (max-width: 768px) {
  #container { margin: 14px auto; padding: 18px; width: 96%; }
}

#container h2 { margin-bottom: 24px; margin-top: 10px; font-weight: 600; color: var(--brand-ink-2); }

#footer {
  background: var(--surface-2);
  color: var(--text-muted);
  text-align: center;
  padding: 28px 0 36px;
  margin-top: auto;
  border-top: 1px solid var(--stroke);
}

#footer a { color: var(--text-muted); margin: 0 10px; font-size: 0.9rem; }
#footer a:hover { text-decoration: underline; }
.copyright { margin-top: 20px; font-size: 0.78rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  height: 44px;
  font-size: 0.98rem;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  border-radius: 999px;
  cursor: pointer;
  transition: transform var(--speed-fast) ease, box-shadow var(--speed-fast) ease, background var(--speed-fast) ease;
  border: none;
  font-family: inherit;
  gap: 8px;
}

.btn-primary {
  background: var(--brand-primary);
  color: var(--brand-ink-2) !important;
}
.btn-primary:hover {
  background: var(--brand-primary-600);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: #1f1f1f;
  color: #fff !important;
}
.btn-secondary:hover {
  background: #2a2a2a;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-accent { background: #188038; color: #fff !important; }
.btn-danger { background: #d93025; color: #fff !important; }

.btn-block { display: flex; width: 100%; }

/* Keep dashboard buttons from stretching edge-to-edge on desktop */
@media (min-width: 900px) {
  .dash-card .btn {
    align-self: center;
    width: auto;
    min-width: 200px;
    max-width: 280px;
    padding: 0 28px;
  }
}

/* ---------- Forms ---------- */
.form-container {
  max-width: 460px;
  margin: 44px auto;
  padding: 36px 32px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

@media (max-width: 600px) {
  .form-container { padding: 24px 16px; border: 1px solid var(--stroke); }
}

input[type="text"],
input[type="password"],
input[type="email"],
input[type="tel"],
input[type="date"],
select,
textarea {
  width: 100%;
  padding: 13px 15px;
  margin: 8px 0;
  border: 1px solid var(--stroke);
  border-radius: 10px;
  font-size: 1rem;
  font-family: inherit;
  background: #fff;
  transition: border-color var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
  color: var(--brand-ink);
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border: 1px solid var(--brand-primary);
  box-shadow: 0 0 0 4px rgba(244,180,0,0.18);
}

input[type="submit"] {
  width: auto;
  min-width: 88px;
  padding: 0 24px;
  height: 40px;
  background: var(--brand-primary);
  color: #2b2b2b;
  border: none;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--speed-fast) ease;
}
input[type="submit"]:hover { background: var(--brand-primary-600); }

/* ---------- Flash & Info ---------- */
.return-error {
  color: #b3261e;
  background: #fff1f0;
  border: 1px solid #ffd6d2;
  padding: 12px;
  border-radius: 10px;
  margin: 16px 0;
  font-size: 0.9rem;
}

.return-success {
  color: #0f7b37;
  background: #eefaf2;
  border: 1px solid #ccefd9;
  padding: 12px;
  border-radius: 10px;
  margin: 16px 0;
  font-size: 0.9rem;
}

/* ---------- Tables ---------- */
.table-stacked { width: 100%; border-collapse: collapse; margin-bottom: 24px; }
.table-stacked th,
.table-stacked td { border-bottom: 1px solid var(--stroke); padding: 12px 16px; text-align: left; }
.table-stacked thead th { background: #fff; font-weight: 600; color: var(--text-muted); font-size: 0.85rem; }

/* ---------- Hero & Search ---------- */
.hero {
  background: radial-gradient(1000px 280px at 50% -10%, rgba(244,180,0,0.22), transparent 70%),
              linear-gradient(180deg, #1f1f1f 0%, #141414 100%);
  color: #fff;
  padding: 90px 20px 70px;
  text-align: center;
  margin-bottom: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  animation: fadeUp var(--speed-med) ease-out;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
  margin-bottom: 18px;
  font-weight: 700;
  color: var(--brand-primary);
}

.hero p {
  font-size: 1.15rem;
  color: #f3f3f3;
  max-width: 720px;
  margin: 0 auto 32px;
}

.search-box {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  gap: 10px;
  background: #fff;
  border-radius: 999px;
  padding: 10px;
  box-shadow: var(--shadow-lg);
}

.search-box input {
  flex: 1;
  border: none;
  padding: 10px 16px;
  font-size: 1.05rem;
  color: var(--brand-ink);
  background: transparent;
}

.search-box input:focus { outline: none; }

/* ---------- Explore Categories Grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 22px;
  padding: 8px 4px 20px;
}

.grid .card {
  background: #fff;
  padding: 26px;
  border-radius: var(--radius-md);
  text-align: center;
  border: 1px solid var(--stroke);
  transition: transform var(--speed-fast) ease, box-shadow var(--speed-fast) ease, border-color var(--speed-fast) ease;
}

.grid .card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #f1d49a;
}

.card h3 { margin-bottom: 8px; font-size: 1.05rem; font-weight: 600; color: var(--brand-ink-2); }
.card p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 16px; }

/* ---------- Card / Dashboard ---------- */
.card {
  background: #fff;
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.card-header { padding: 16px 24px; background: #fff; border-bottom: 1px solid var(--stroke); }
.card-header h1 { font-size: 1.6rem; font-weight: 700; text-align: center; color: var(--brand-ink-2); }
.card-body { padding: 30px; }

.dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }

.dash-card {
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  padding: 28px;
  display: flex;
  flex-direction: column;
  background: #fff;
  transition: transform var(--speed-fast) ease, box-shadow var(--speed-fast) ease, border-color var(--speed-fast) ease;
}

.dash-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--brand-primary);
}

.dash-card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.dash-card h2 { font-size: 1.1rem; font-weight: 600; margin: 0; }

.content-wrapper {
  padding: 20px 0;
  max-width: 1040px;
  margin: 0 auto;
  width: 100%;
}
.mandatory { color: #d93025; margin-left: 2px; font-weight: 600; }
.info-box { margin-top: 12px; font-size: 0.9rem; line-height: 1.4; display: block; color: var(--text-muted); }

ul, ol { margin: 0 0 1em 1.5em; padding-left: 1.2em; }
ul li, ol li { margin-bottom: 6px; line-height: 1.5; }

.pagination {
  margin-top: 24px;
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.page-link,
.page-link.current,
.page-link.disabled {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  text-decoration: none;
  font-size: 0.85rem;
}
.page-link { background: #fff; color: #1a73e8; }
.page-link:hover { background: #f1f3f4; }
.page-link.current { background: #1a73e8; color: #fff; border-color: #1a73e8; }
.page-link.disabled { background: #fff; color: #c7c7c7; cursor: default; border-color: #eee; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 16px; }
@media (max-width: 600px) { .btn-row { flex-direction: column; align-items: stretch; } }

.dash-hero {
  background: #fff;
  border: 1px solid var(--stroke);
  border-radius: var(--radius-md);
  padding: 40px 24px;
  margin-bottom: 32px;
  text-align: center;
}

.dash-hero-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: #1a73e8;
  background: #e8f0fe;
  padding: 4px 12px;
  border-radius: 16px;
  margin-bottom: 16px;
}
.dash-hero-title { font-size: 2rem; margin: 0 0 8px; color: var(--brand-ink); font-weight: 600; }
.dash-hero-sub { color: var(--text-muted); font-size: 1rem; }

/* Landing Wrapper */
.landing-wrapper { text-align: center; padding: 40px 20px; max-width: 800px; margin: 0 auto; }
.landing-wrapper h1 { font-size: 2.4rem; font-weight: 600; margin-bottom: 16px; color: var(--brand-ink); }
.landing-wrapper .lead { font-size: 1.1rem; color: var(--text-muted); margin-bottom: 32px; }

.landing-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #1a73e8;
  color: #ffffff !important;
  font-weight: 600;
  border: none;
  border-radius: 999px;
  padding: 0 32px;
  height: 48px;
  font-size: 1rem;
  text-decoration: none;
  transition: background var(--speed-fast) ease, box-shadow var(--speed-fast) ease;
}
.landing-btn:hover { background: #1659c6; box-shadow: var(--shadow-sm); }

.features-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.features-row span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  font-size: 0.85rem;
  color: var(--text-muted);
}

@media (max-width: 600px) {
  .hero h1 { font-size: 2rem; }
  .landing-wrapper h1 { font-size: 1.8rem; }
  .search-box { flex-direction: column; border-radius: var(--radius-md); }
}

.state-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: capitalize;
}

.state-badge.pending { background: #f1f3f4; color: #5f6368; }
.state-badge.done { background: #e6f4ea; color: #1e8e3e; }
.state-badge.running { background: #fef7e0; color: #f9ab00; }

/* ---------- Motion ---------- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- Responsive refinements ---------- */
@media (max-width: 900px) {
  .hero { padding: 70px 16px 60px; }
  .hero p { font-size: 1.05rem; }
  .grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
}

@media (max-width: 600px) {
  #container { margin: 10px auto; padding: 14px; width: 98%; border-radius: var(--radius-md); }
  .hero { padding: 58px 14px 50px; border-radius: var(--radius-md); }
  .search-box { max-width: 100%; padding: 8px; }
  .search-box input { font-size: 1rem; }
  .card-body { padding: 22px; }
  .dash-grid { grid-template-columns: 1fr; }
}



/* ---------- User details form width ---------- */
@media (min-width: 900px) {
  .user-details-form {
    max-width: 360px;
    margin: 0 auto;
  }

  .user-details-form .form-group {
    margin-bottom: 12px;
  }

  .user-details-form .form-group label {
    font-size: 0.85rem;
    margin-bottom: 6px;
    display: block;
  }

  .user-details-form .form-control,
  .user-details-form input[type="text"],
  .user-details-form input[type="password"],
  .user-details-form input[type="email"],
  .user-details-form input[type="tel"],
  .user-details-form input[type="date"],
  .user-details-form select,
  .user-details-form textarea {
    font-size: 0.95rem;
    padding: 10px 12px;
  }
}

/* ---------- User details form actions ---------- */
.user-details-form .form-actions {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

/* ---------- User details phone row ---------- */
.user-details-form .phone-row {
  display: flex;
  gap: 12px;
  align-items: center;
}
.user-details-form .country-code {
  flex: 0 0 150px;
}
.user-details-form .mobile-number {
  flex: 1 1 auto;
}
