/* ===========================================================
   TrastoWallet CRM — Professional Dark-Neon Theme
   Designer: Ayaz (UX-Level: 1st Class)
   =========================================================== */

/* ---------- BASE ---------- */
:root {
  --bg1: #0a0612;
  --bg2: #290040;
  --bg3: #7500ff;
  --neon: #c08fff;
  --white: #fff;
  --error: #ff4c7d;
}

* {
  box-sizing: border-box;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body.login-body {
  background: radial-gradient(circle at 80% 20%, var(--bg3), var(--bg2) 50%, var(--bg1) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  overflow: hidden;
}

.login-card {
  width: 360px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 40px 30px;
  text-align: center;
  box-shadow: 0 0 40px rgba(140,0,255,0.35);
  backdrop-filter: blur(14px);
  animation: fadeIn 0.8s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

.login-card h1 {
  font-size: 24px;
  font-weight: 800;
  color: var(--neon);
  text-shadow: 0 0 20px var(--neon);
  margin-bottom: 30px;
}

.input {
  width: 100%;
  margin-bottom: 16px;
}

.input input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(0,0,0,0.35);
  color: var(--white);
  font-size: 14px;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}

.input input:focus {
  border-color: var(--neon);
  box-shadow: 0 0 8px var(--neon);
}

.btn {
  width: 100%;
  background: linear-gradient(90deg, #5300ff, #b46dff);
  border: none;
  padding: 12px;
  color: var(--white);
  font-weight: 700;
  border-radius: 10px;
  cursor: pointer;
  box-shadow: 0 0 16px rgba(181,123,255,0.5);
  transition: transform .15s, box-shadow .25s;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 22px rgba(181,123,255,0.8);
}

.error {
  color: var(--error);
  font-size: 13px;
  margin-top: 14px;
  font-weight: 600;
  text-shadow: 0 0 4px rgba(255,0,0,0.4);
}

/* ---------- SIDEBAR ---------- */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 230px;
  height: 100vh;
  background: rgba(18, 0, 30, 0.95);
  border-right: 1px solid var(--border);
  box-shadow: inset -1px 0 0 rgba(255,255,255,0.04);
  padding: 22px 18px;
  backdrop-filter: blur(10px) saturate(160%);
  -webkit-backdrop-filter: blur(10px) saturate(160%);
}

.sidebar .logo {
  font-weight: 900;
  font-size: 18px;
  color: var(--accent);
  margin-bottom: 36px;
  text-shadow: 0 0 10px rgba(181,123,255,0.7);
}

.sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar li {
  margin-bottom: 14px;
}

.sidebar a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  display: block;
  padding: 10px 14px;
  border-radius: 10px;
  transition: all .25s;
}

.sidebar a:hover {
  background: rgba(255,255,255,0.08);
  color: var(--white);
}

.sidebar a.active {
  color: var(--accent);
  background: rgba(181,123,255,0.1);
  box-shadow: 0 0 8px rgba(181,123,255,0.4);
}

/* ---------- MAIN CONTENT ---------- */
.main {
  margin-left: 250px;
  padding: 36px;
  min-height: 100vh;
  background: radial-gradient(circle at 20% 20%, #1b0030 0%, #090010 100%);
  color: var(--text);
}

.main h2 {
  font-size: 22px;
  color: var(--accent);
  text-shadow: 0 0 8px rgba(181,123,255,0.6);
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px) saturate(150%);
}


/* GLOBAL LAYOUT THEME */
body.crm-body {
    min-height:100vh;
    margin:0;
    font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
    color:#fff;
    background:
      radial-gradient(circle at 20% 20%, rgba(147,51,234,0.5) 0%, rgba(0,0,0,0) 60%),
      radial-gradient(circle at 80% 10%, rgba(88,28,135,0.5) 0%, rgba(0,0,0,0) 60%),
      radial-gradient(circle at 50% 50%, #0a0012 0%, #000 70%);
    display:flex;
    flex-direction:column;
}

/* ==== TOPBAR ==== */
.crm-topbar{
    position:fixed;
    top:0;
    left:220px; /* sidebar genişliği */
    right:0;
    height:56px;

    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:0 16px;

    background:rgba(0,0,0,.4);
    border-bottom:1px solid rgba(255,255,255,.08);
    box-shadow:0 12px 32px rgba(0,0,0,.8);
    backdrop-filter:blur(12px);
    z-index:1000;
}
.crm-topbar-title{
    font-size:14px;
    font-weight:700;
    color:#cba8ff;
    text-shadow:0 0 8px #cba8ff;
}
.crm-topbar-right{
    display:flex;
    align-items:center;
    gap:12px;
}
.crm-user-pill{
    padding:8px 12px;
    border-radius:10px;
    background:rgba(255,255,255,.05);
    border:1px solid rgba(255,255,255,.1);
    box-shadow:0 0 20px rgba(203,168,255,.4);
    font-size:12px;
    font-weight:600;
    color:#fff;
}
.crm-user-role{
    font-weight:700;
    color:#fff;
}
.crm-logout-btn{
    font-size:12px;
    font-weight:700;
    color:#fff;
    text-decoration:none;
    background:linear-gradient(90deg,#ff004c,#ff6a00);
    border-radius:10px;
    padding:8px 12px;
    box-shadow:0 10px 24px rgba(255,0,76,.4);
}

/* ==== SIDEBAR ==== */
.crm-sidebar{
    position:fixed;
    top:0;
    left:0;
    bottom:0;
    width:220px;

    background:rgba(0,0,0,.5);
    border-right:1px solid rgba(255,255,255,.08);
    box-shadow:8px 0 30px rgba(0,0,0,.8);

    padding:20px 16px 16px;
    backdrop-filter:blur(14px);
    z-index:999;
    display:flex;
    flex-direction:column;
}

.crm-logo-block{
    margin-bottom:24px;
}
.crm-logo-title{
    font-size:15px;
    font-weight:800;
    color:#fff;
    text-shadow:0 0 10px rgba(181,123,255,.9);
}
.crm-logo-sub{
    font-size:12px;
    font-weight:600;
    color:#cba8ff;
    margin-top:2px;
}

.crm-nav{
    display:flex;
    flex-direction:column;
    gap:8px;
    margin-top:16px;
}
.crm-nav-item{
    display:flex;
    align-items:center;
    gap:10px;
    text-decoration:none;
    font-size:13px;
    font-weight:600;
    line-height:1.2;
    color:#fff;

    background:rgba(255,255,255,.03);
    border:1px solid rgba(255,255,255,.07);
    border-radius:10px;
    padding:10px 12px;
    box-shadow:0 0 20px rgba(0,0,0,.6);
    transition:all .15s;
}
.crm-nav-item .ico{
    width:20px;
    text-align:center;
}
.crm-nav-item.active,
.crm-nav-item:hover{
    background:linear-gradient(90deg,#5a00ff,#9a5dff);
    border-color:transparent;
    box-shadow:0 10px 30px rgba(181,123,255,.6);
}

/* ==== MAIN AREA ==== */
.crm-main{
    margin-left:220px;
    padding-top:56px; /* topbar yüksekliği */
    padding:24px;
    min-height:100vh;
    color:#fff;
}

/* ROW of cards */
.crm-cards-row{
    display:flex;
    flex-wrap:wrap;
    gap:24px;
}

/* CARD */
.crm-card{
    background:rgba(255,255,255,.03);
    border:1px solid rgba(255,255,255,.07);
    border-radius:16px;
    box-shadow:0 0 40px rgba(181,123,255,.3);
    padding:20px;
    min-width:240px;
    flex:0 0 auto;
}
.crm-card.big{
    flex:1 1 320px;
    min-width:320px;
    max-width:420px;
}
.crm-card-head{
    margin-bottom:12px;
}
.crm-card-title{
    font-size:14px;
    font-weight:700;
    color:#fff;
    text-shadow:0 0 10px rgba(181,123,255,.8);
}
.crm-card-sub{
    font-size:12px;
    color:#cba8ff;
    font-weight:500;
    line-height:1.4;
}
.crm-card-body{
    display:flex;
    flex-wrap:wrap;
    gap:16px;
}

/* Metrics */
.metric{
    min-width:120px;
}
.metric-label{
    font-size:11px;
    color:#cba8ff;
    font-weight:600;
    margin-bottom:4px;
}
.metric-value{
    font-size:20px;
    font-weight:800;
    color:#fff;
    text-shadow:0 0 12px rgba(181,123,255,.8);
}

.metric-lg{
    text-align:left;
}
.metric-value-lg{
    font-size:28px;
    font-weight:800;
    color:#fff;
    text-shadow:0 0 15px rgba(181,123,255,.9);
}

/* Section below */
.crm-section{
    margin-top:24px;
    max-width:480px;
}
.crm-card-body.actions{
    flex-direction:column;
}
.crm-action-btn{
    display:block;
    text-decoration:none;
    font-size:13px;
    font-weight:700;
    color:#fff;
    background:rgba(255,255,255,.05);
    border:1px solid rgba(255,255,255,.1);
    border-radius:10px;
    padding:12px 14px;
    box-shadow:0 10px 24px rgba(0,0,0,.7);
    transition:all .15s;
}
.crm-action-btn:hover{
    background:linear-gradient(90deg,#5a00ff,#9a5dff);
    border-color:transparent;
    box-shadow:0 10px 30px rgba(181,123,255,.6);
}
.crm-action-btn.danger{
    background:linear-gradient(90deg,#ff004c,#ff6a00);
    border:none;
    box-shadow:0 10px 30px rgba(255,0,76,.4);
}

