/* ============================================================
   Money Culture CRM — Premium Login Page
   Scoped entirely to .mc-login-* classes so it never touches
   any other page style.
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600;9..144,700&display=swap');

:root{
  --mc-primary:#8A6D1F;
  --mc-primary-dark:#6B5518;
  --mc-primary-light:#C6A15B;
  --mc-bg-left:#F6F1E4;
  --mc-card-bg:#ffffff;
  --mc-text:#16202E;
  --mc-text-muted:#6B655A;
  --mc-border:#E8E1D2;
  --mc-shadow:0 20px 60px -15px rgba(138, 109, 31,.25);
}

.mc-login-body[data-theme="dark"]{
  --mc-bg-left:#0B1524;
  --mc-card-bg:#122036;
  --mc-text:#F1EEE3;
  --mc-text-muted:#9CA6BA;
  --mc-border:#223349;
  --mc-shadow:0 20px 60px -15px rgba(0,0,0,.55);
}

.mc-login-body{
  font-family:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;
  color:var(--mc-text);
}

.mc-login-wrap{
  min-height:100vh;
  width:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:32px;
  background:var(--mc-bg-left);
  position:relative;
  overflow:hidden;
  transition:background .35s ease;
}

/* animated ambient blobs */
.mc-blob{
  position:absolute;
  border-radius:50%;
  filter:blur(60px);
  opacity:.55;
  z-index:0;
  animation:mcFloat 14s ease-in-out infinite;
}
.mc-blob-1{
  width:420px;height:420px;
  top:-120px;left:-120px;
  background:radial-gradient(circle,#E9D9AC,transparent 70%);
}
.mc-blob-2{
  width:380px;height:380px;
  bottom:-140px;left:10%;
  background:radial-gradient(circle,#D9C08A,transparent 70%);
  animation-delay:-6s;
}
.mc-blob-3{
  width:320px;height:320px;
  top:20%;right:-100px;
  background:radial-gradient(circle,#C9E0D6,transparent 70%);
  animation-delay:-3s;
}
@keyframes mcFloat{
  0%,100%{ transform:translate(0,0) scale(1); }
  50%{ transform:translate(30px,-30px) scale(1.08); }
}

.mc-dots{
  position:absolute;
  top:60px; left:60px;
  width:100px; height:70px;
  background-image:radial-gradient(var(--mc-primary) 1.5px, transparent 1.5px);
  background-size:14px 14px;
  opacity:.25;
  z-index:0;
}

.mc-theme-toggle{
  position:absolute;
  top:28px; right:36px;
  z-index:5;
  display:flex; align-items:center; gap:8px;
  background:var(--mc-card-bg);
  border:1px solid var(--mc-border);
  color:var(--mc-text);
  padding:10px 18px;
  border-radius:999px;
  font-size:14px;
  font-weight:600;
  cursor:pointer;
  box-shadow:0 4px 14px rgba(0,0,0,.06);
  transition:all .2s ease;
}
.mc-theme-toggle:hover{ transform:translateY(-1px); box-shadow:0 8px 20px rgba(0,0,0,.1); }
.mc-theme-toggle svg{ width:16px; height:16px; }

.mc-shell{
  position:relative;
  z-index:1;
  width:100%;
  max-width:1120px;
  min-height:640px;
  display:flex;
  border-radius:32px;
  overflow:hidden;
  box-shadow:var(--mc-shadow);
  background:var(--mc-card-bg);
}

/* ---------- LEFT BRAND PANEL ---------- */
.mc-brand-panel{
  flex:1 1 46%;
  padding:64px 56px 40px;
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  position:relative;
  background:linear-gradient(160deg,#FBF7EE 0%, #F5EBD4 55%, #EFDFBA 100%);
  overflow:hidden;
}
.mc-login-body[data-theme="dark"] .mc-brand-panel{
  background:linear-gradient(160deg,#152238 0%, #0E1A2E 100%);
}

.mc-brand-logo{
  width:220px;
  max-width:70%;
  height:auto;
  border-radius:50%;
  box-shadow:0 10px 30px rgba(138, 109, 31,.18);
  margin-bottom:28px;
  position:relative;
  z-index:2;
  animation:mcPulseIn .7s ease;
}
@keyframes mcPulseIn{
  from{ opacity:0; transform:scale(.85); }
  to{ opacity:1; transform:scale(1); }
}

.mc-brand-welcome{
  font-size:16px;
  color:var(--mc-text-muted);
  margin-bottom:4px;
  position:relative; z-index:2;
}
.mc-brand-title{
  font-family:'Fraunces',Georgia,serif;
  font-size:31px;
  font-weight:600;
  color:var(--mc-text);
  margin-bottom:14px;
  position:relative; z-index:2;
}
.mc-brand-title span{
  color:var(--mc-primary);
}
.mc-brand-rule{
  width:56px; height:4px;
  border-radius:4px;
  background:linear-gradient(90deg,var(--mc-primary),var(--mc-primary-light));
  margin-bottom:18px;
  position:relative; z-index:2;
}
.mc-brand-desc{
  font-size:14.5px;
  line-height:1.6;
  color:var(--mc-text-muted);
  max-width:320px;
  margin-bottom:34px;
  position:relative; z-index:2;
}

.mc-feature-list{
  width:100%;
  max-width:340px;
  display:flex;
  flex-direction:column;
  gap:14px;
  position:relative;
  z-index:2;
  margin-bottom:auto;
}
.mc-feature{
  display:flex;
  align-items:center;
  gap:14px;
  text-align:left;
  background:rgba(255,255,255,.55);
  border:1px solid rgba(255,255,255,.7);
  padding:12px 14px;
  border-radius:14px;
  backdrop-filter:blur(6px);
}
.mc-login-body[data-theme="dark"] .mc-feature{
  background:rgba(255,255,255,.04);
  border-color:rgba(255,255,255,.08);
}
.mc-feature-icon{
  flex:0 0 auto;
  width:38px; height:38px;
  border-radius:10px;
  display:flex; align-items:center; justify-content:center;
}
.mc-feature-icon svg{ width:19px; height:19px; }
.mc-feature-icon.mc-blue{ background:#E3EAF1; color:#2E5C8A; }
.mc-feature-icon.mc-green{ background:#DCFCE7; color:#15803D; }
.mc-feature-icon.mc-orange{ background:#FFEDD5; color:#C2410C; }
.mc-login-body[data-theme="dark"] .mc-feature-icon.mc-blue{ background:#1B2A42; color:#8FB2D8; }
.mc-login-body[data-theme="dark"] .mc-feature-icon.mc-green{ background:#0F3B25; color:#6EE7B7; }
.mc-login-body[data-theme="dark"] .mc-feature-icon.mc-orange{ background:#4A2A0C; color:#FDBA74; }

.mc-feature-title{ font-size:14px; font-weight:700; color:var(--mc-text); }
.mc-feature-sub{ font-size:12.5px; color:var(--mc-text-muted); }

.mc-wave{
  position:absolute;
  left:0; right:0; bottom:0;
  height:170px;
  z-index:1;
  opacity:.9;
  pointer-events:none;
}

/* ---------- RIGHT FORM PANEL ---------- */
.mc-form-panel{
  flex:1 1 54%;
  padding:56px 64px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  background:var(--mc-card-bg);
}

.mc-form-head{
  text-align:center;
  margin-bottom:30px;
}
.mc-shield{
  width:64px; height:64px;
  border-radius:50%;
  background:#F3E9D3;
  display:flex; align-items:center; justify-content:center;
  margin:0 auto 16px;
  color:var(--mc-primary);
}
.mc-login-body[data-theme="dark"] .mc-shield{ background:#1B2A42; }
.mc-shield svg{ width:28px; height:28px; }

.mc-form-title{
  font-family:'Fraunces',Georgia,serif;
  font-size:28px;
  font-weight:600;
  color:var(--mc-text);
  margin-bottom:6px;
}
.mc-form-sub{
  font-size:14.5px;
  color:var(--mc-text-muted);
}

.mc-alert{
  display:flex;
  align-items:center;
  gap:10px;
  background:#FEF2F2;
  color:#B91C1C;
  border:1px solid #FECACA;
  border-left:4px solid #EF4444;
  padding:12px 16px;
  border-radius:12px;
  font-size:13.5px;
  margin-bottom:20px;
}
.mc-login-body[data-theme="dark"] .mc-alert{
  background:#301418; border-color:#5B1F26; color:#FCA5A5;
}
.mc-alert svg{ flex:0 0 auto; width:18px; height:18px; }

.mc-field{ margin-bottom:20px; }
.mc-field label{
  display:block;
  font-size:13.5px;
  font-weight:600;
  color:var(--mc-text);
  margin-bottom:8px;
}
.mc-input-group{
  position:relative;
  display:flex;
  align-items:center;
}
.mc-input-icon{
  position:absolute;
  left:16px;
  color:var(--mc-text-muted);
  display:flex;
  pointer-events:none;
}
.mc-input-icon svg{ width:18px; height:18px; }

.mc-input-group input{
  width:100%;
  padding:14px 16px 14px 46px;
  border-radius:13px;
  border:1.5px solid var(--mc-border);
  background:var(--mc-card-bg);
  color:var(--mc-text);
  font-size:14.5px;
  font-family:inherit;
  outline:none;
  transition:border-color .18s ease, box-shadow .18s ease;
}
.mc-input-group input::placeholder{ color:#A6ABC2; }
.mc-input-group input:focus{
  border-color:var(--mc-primary);
  box-shadow:0 0 0 4px rgba(138, 109, 31,.14);
}
.mc-input-group.has-toggle input{ padding-right:46px; }

.mc-pw-toggle{
  position:absolute;
  right:14px;
  background:none;
  border:none;
  cursor:pointer;
  color:var(--mc-text-muted);
  display:flex;
  padding:4px;
}
.mc-pw-toggle svg{ width:18px; height:18px; }
.mc-pw-toggle:hover{ color:var(--mc-primary); }

.mc-row-between{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:24px;
}
.mc-remember{
  display:flex;
  align-items:center;
  gap:9px;
  font-size:13.5px;
  color:var(--mc-text);
  cursor:pointer;
  user-select:none;
}
.mc-remember input{
  width:17px; height:17px;
  accent-color:var(--mc-primary);
  cursor:pointer;
}
.mc-forgot{
  font-size:13.5px;
  font-weight:600;
  color:var(--mc-primary);
  text-decoration:none;
}
.mc-forgot:hover{ text-decoration:underline; }

.mc-submit{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  border:none;
  cursor:pointer;
  padding:15px 20px;
  border-radius:13px;
  font-size:15px;
  font-weight:700;
  font-family:inherit;
  color:#fff;
  background:linear-gradient(135deg,var(--mc-primary-light),var(--mc-primary) 55%, var(--mc-primary-dark));
  box-shadow:0 12px 26px -8px rgba(138, 109, 31,.55);
  transition:transform .15s ease, box-shadow .15s ease, filter .15s ease;
}
.mc-submit svg{ width:18px; height:18px; }
.mc-submit:hover{ transform:translateY(-2px); box-shadow:0 16px 30px -8px rgba(138, 109, 31,.6); filter:brightness(1.04); }
.mc-submit:active{ transform:translateY(0); }
.mc-submit.mc-loading{ opacity:.85; pointer-events:none; }

.mc-divider{
  display:flex;
  align-items:center;
  gap:14px;
  margin:26px 0 20px;
  color:var(--mc-text-muted);
  font-size:12.5px;
}
.mc-divider::before, .mc-divider::after{
  content:'';
  flex:1;
  height:1px;
  background:var(--mc-border);
}

.mc-social-row{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:14px;
  margin-bottom:22px;
}
.mc-social-btn{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  padding:12px 14px;
  border-radius:13px;
  border:1.5px solid var(--mc-border);
  background:var(--mc-card-bg);
  color:var(--mc-text);
  font-size:13.5px;
  font-weight:600;
  cursor:pointer;
  font-family:inherit;
  transition:all .18s ease;
}
.mc-social-btn:hover{
  border-color:var(--mc-primary-light);
  box-shadow:0 6px 16px rgba(138, 109, 31,.12);
  transform:translateY(-1px);
}
.mc-social-btn svg{ width:18px; height:18px; }

.mc-security-note{
  display:flex;
  align-items:center;
  gap:14px;
  background:#F7F3E9;
  border:1px solid var(--mc-border);
  border-radius:14px;
  padding:14px 16px;
}
.mc-login-body[data-theme="dark"] .mc-security-note{
  background:#152238;
}
.mc-security-note svg{ width:22px; height:22px; color:var(--mc-text-muted); flex:0 0 auto; }
.mc-security-note-title{ font-size:13.5px; font-weight:700; color:var(--mc-text); }
.mc-security-note-sub{ font-size:12px; color:var(--mc-text-muted); }

.mc-footer{
  text-align:center;
  margin-top:26px;
  font-size:12.5px;
  color:var(--mc-text-muted);
  position:relative; z-index:1;
}
.mc-footer a{
  color:var(--mc-text-muted);
  text-decoration:none;
  margin:0 4px;
}
.mc-footer a:hover{ color:var(--mc-primary); text-decoration:underline; }

/* toast for placeholder actions */
.mc-toast{
  position:fixed;
  bottom:26px; left:50%;
  transform:translate(-50%,20px);
  background:var(--mc-text);
  color:#fff;
  padding:12px 20px;
  border-radius:12px;
  font-size:13.5px;
  font-weight:500;
  box-shadow:0 10px 24px rgba(0,0,0,.25);
  opacity:0;
  pointer-events:none;
  transition:all .25s ease;
  z-index:50;
}
.mc-toast.show{
  opacity:1;
  transform:translate(-50%,0);
}

@media (max-width: 980px){
  .mc-shell{ flex-direction:column; max-width:520px; min-height:0; border-radius:24px; }
  .mc-brand-panel{ padding:44px 32px 36px; }
  .mc-feature-list{ display:none; }
  .mc-wave{ display:none; }
  .mc-form-panel{ padding:40px 32px 44px; }
  .mc-theme-toggle{ top:18px; right:18px; padding:8px 14px; font-size:13px; }
}
@media (max-width: 480px){
  .mc-login-wrap{ padding:16px; }
  .mc-form-panel{ padding:32px 22px 36px; }
  .mc-brand-panel{ padding:36px 22px 28px; }
  .mc-brand-title{ font-size:24px; }
  .mc-social-row{ grid-template-columns:1fr; }
}
/* ============================================================
   MOBILE LOGIN REBUILD
   Keeps authentication markup/logic unchanged.
   ============================================================ */
@media screen and (max-width:1200px){
  .mc-login-wrap{
    min-height:100dvh;
    width:100%;
    box-sizing:border-box;
    display:block;
    padding:76px 16px 24px;
    overflow-x:hidden;
    overflow-y:auto;
  }

  .mc-shell{
    width:100%;
    max-width:560px;
    min-height:0;
    margin:0 auto;
    display:flex;
    flex-direction:column;
    border-radius:24px;
    overflow:hidden;
  }

  .mc-brand-panel{
    flex:0 0 auto;
    width:100%;
    box-sizing:border-box;
    padding:30px 24px 28px;
    min-height:0;
  }

  .mc-brand-logo{
    width:110px;
    max-width:110px;
    margin:0 auto 16px;
  }

  .mc-brand-welcome{
    font-size:15px;
    margin-bottom:4px;
  }

  .mc-brand-title{
    font-size:29px;
    line-height:1.12;
    margin-bottom:10px;
  }

  .mc-brand-rule{
    margin-bottom:12px;
  }

  .mc-brand-desc{
    max-width:360px;
    font-size:14px;
    line-height:1.5;
    margin:0 auto;
  }

  .mc-feature-list,
  .mc-wave{
    display:none !important;
  }

  .mc-form-panel{
    flex:0 0 auto;
    width:100%;
    box-sizing:border-box;
    padding:30px 24px 32px;
    display:block;
  }

  .mc-form-head{
    margin-bottom:22px;
  }

  .mc-shield{
    width:58px;
    height:58px;
    margin-bottom:12px;
  }

  .mc-form-title{
    font-size:27px;
    line-height:1.15;
  }

  .mc-form-sub{
    font-size:14px;
  }

  .mc-field{
    margin-bottom:17px;
  }

  .mc-input-group input{
    min-height:52px;
    box-sizing:border-box;
    font-size:16px;
  }

  .mc-row-between{
    gap:14px;
    margin-bottom:20px;
  }

  .mc-remember,
  .mc-forgot{
    font-size:14px;
  }

  .mc-submit{
    min-height:54px;
    font-size:16px;
  }

  .mc-social-row{
    grid-template-columns:1fr 1fr;
    gap:10px;
  }

  .mc-social-btn{
    min-height:50px;
  }

  .mc-security-note{
    margin-top:4px;
  }

  .mc-footer{
    width:100%;
    max-width:560px;
    box-sizing:border-box;
    margin:14px auto 0;
    padding:0 8px 10px;
    line-height:1.7;
  }

  .mc-theme-toggle{
    position:fixed;
    top:16px;
    right:16px;
    padding:10px 14px;
    z-index:20;
  }

  .mc-dots{
    display:none;
  }

  .mc-blob{
    opacity:.3;
  }
}

@media screen and (max-width:600px){
  .mc-login-wrap{
    padding:72px 10px 18px;
  }

  .mc-shell{
    max-width:none;
    border-radius:20px;
  }

  .mc-brand-panel{
    padding:26px 20px 24px;
  }

  .mc-brand-logo{
    width:96px;
    max-width:96px;
    margin-bottom:14px;
  }

  .mc-brand-title{
    font-size:26px;
  }

  .mc-brand-desc{
    font-size:14px;
  }

  .mc-form-panel{
    padding:28px 20px 30px;
  }

  .mc-form-title{
    font-size:25px;
  }

  .mc-row-between{
    align-items:flex-start;
  }

  .mc-social-row{
    grid-template-columns:1fr;
  }

  .mc-social-btn{
    width:100%;
  }

  .mc-footer{
    font-size:12px;
  }
}

@media screen and (max-width:380px){
  .mc-login-wrap{
    padding-left:8px;
    padding-right:8px;
  }

  .mc-theme-toggle{
    right:10px;
    top:12px;
    font-size:12px;
    padding:8px 11px;
  }

  .mc-brand-panel{
    padding:22px 16px;
  }

  .mc-form-panel{
    padding:24px 16px 28px;
  }

  .mc-brand-title{
    font-size:24px;
  }

  .mc-row-between{
    flex-direction:column;
    gap:10px;
  }
}

/* ============================================================
   DESKTOP LOGIN LAYOUT FIX
   The footer is a sibling of .mc-shell. Keep the desktop wrapper
   in a vertical flow so the shell remains the full 1120px card
   and the footer sits underneath it.
   Mobile rules below remain unchanged.
   ============================================================ */
@media screen and (min-width:1201px){
  .mc-login-wrap{
    flex-direction:column;
    align-items:center;
    justify-content:center;
  }

  .mc-shell{
    flex:0 0 auto;
    width:100%;
    max-width:1120px;
  }

  .mc-footer{
    width:100%;
    max-width:1120px;
    flex:0 0 auto;
    box-sizing:border-box;
  }
}
