:root{
  --bg:#080808;
  --bg-soft:#101010;
  --panel:#141414;
  --panel-2:#1a1a1a;
  --line:#2a2a2a;
  --text:#f2f2f2;
  --muted:#a0a0a0;
  --gold:#c8a96b;
  --gold-2:#e0c28a;
  --danger:#c95a5a;
  --success:#4fa36c;
  --warning:#b98b2f;
  --radius:20px;
  --shadow:0 20px 50px rgba(0,0,0,.35);
}

*{
  box-sizing:border-box;
}

html,body{
  margin:0;
  padding:0;
  font-family:Arial, sans-serif;
  background:var(--bg);
  color:var(--text);
}

body{
  min-height:100vh;
}

a{
  color:inherit;
  text-decoration:none;
}

input, textarea, button{
  font:inherit;
}

/* LOGIN PAGE */
.login-page{
  background:
    radial-gradient(circle at top left, rgba(200,169,107,.10), transparent 26%),
    radial-gradient(circle at bottom right, rgba(255,255,255,.03), transparent 20%),
    linear-gradient(135deg, #050505, #0a0a0a 45%, #111111);
}

.split-layout{
  min-height:100vh;
  display:grid;
  grid-template-columns:1.15fr .85fr;
}

.marketing-panel{
  display:flex;
  flex-direction:column;
  justify-content:center;
  padding:72px;
}

.brand-wrap{
  display:flex;
  align-items:center;
  gap:16px;
  margin-bottom:48px;
}

.brand-badge{
  width:54px;
  height:54px;
  border-radius:16px;
  border:1px solid rgba(200,169,107,.35);
  display:flex;
  align-items:center;
  justify-content:center;
  color:var(--gold);
  font-weight:700;
  letter-spacing:.08em;
  background:rgba(255,255,255,.02);
}

.brand-badge.small{
  width:42px;
  height:42px;
  border-radius:12px;
  font-size:14px;
}

.brand-title{
  font-size:22px;
  font-weight:700;
  letter-spacing:.18em;
  text-transform:uppercase;
}

.brand-title.small-title{
  font-size:16px;
}

.brand-subtitle{
  font-size:12px;
  color:var(--muted);
  letter-spacing:.14em;
  text-transform:uppercase;
  margin-top:4px;
}

.marketing-content h1{
  max-width:640px;
  font-size:56px;
  line-height:1.05;
  letter-spacing:-.03em;
  margin:0 0 16px;
}

.rotating-text{
  color:var(--gold);
  font-size:24px;
  min-height:34px;
  transition:opacity .35s ease;
}

.login-panel{
  display:flex;
  align-items:center;
  justify-content:center;
  padding:32px;
  border-left:1px solid rgba(255,255,255,.04);
  background:linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.00));
}

.login-card{
  width:100%;
  max-width:400px;
  background:rgba(18,18,18,.92);
  border:1px solid rgba(200,169,107,.18);
  border-radius:24px;
  padding:30px;
  box-shadow:var(--shadow);
}

.access-chip{
  display:inline-flex;
  align-items:center;
  padding:8px 12px;
  border-radius:999px;
  border:1px solid rgba(200,169,107,.28);
  color:var(--gold);
  background:rgba(200,169,107,.06);
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.10em;
  margin-bottom:18px;
}

.login-card h2{
  margin:0 0 10px;
  font-size:32px;
}

.login-desc{
  margin:0 0 22px;
  color:var(--muted);
  line-height:1.6;
}

.form-group{
  margin-bottom:16px;
}

.form-group label{
  display:block;
  margin-bottom:8px;
  color:#d6d6d6;
  font-size:13px;
}

input, textarea{
  width:100%;
  border:1px solid #303030;
  background:#111;
  color:#fff;
  padding:14px 15px;
  border-radius:14px;
  outline:none;
  transition:.2s ease;
}

input:focus, textarea:focus{
  border-color:rgba(200,169,107,.55);
  box-shadow:0 0 0 4px rgba(200,169,107,.09);
}

textarea{
  resize:vertical;
  min-height:110px;
}

.btn{
  border:none;
  border-radius:14px;
  padding:14px 18px;
  cursor:pointer;
  font-weight:700;
  transition:.2s ease;
}

.btn:hover{
  transform:translateY(-1px);
}

.btn-gold{
  width:100%;
  background:linear-gradient(135deg, #b89254, #e0c28a);
  color:#111;
}

.btn-dark{
  background:#1b1b1b;
  color:#fff;
  border:1px solid #2d2d2d;
}

.message-box{
  min-height:20px;
  margin-top:14px;
  font-size:14px;
}

.message-box.success{
  color:#8fdaa7;
}

.message-box.error{
  color:#f1a2a2;
}

/* DASHBOARD */
.dashboard-page{
  background:
    radial-gradient(circle at top left, rgba(200,169,107,.05), transparent 20%),
    linear-gradient(180deg, #090909, #0d0d0d);
}

.topbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  padding:18px 28px;
  border-bottom:1px solid #1f1f1f;
  position:sticky;
  top:0;
  background:rgba(10,10,10,.92);
  backdrop-filter:blur(10px);
  z-index:20;
}

.topbar-left,
.topbar-right{
  display:flex;
  align-items:center;
  gap:14px;
}

.top-user{
  color:var(--muted);
  font-size:14px;
}

.dashboard-shell{
  padding:28px;
  max-width:1280px;
  margin:0 auto;
}

.card{
  background:linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.01));
  border:1px solid #222;
  border-radius:22px;
  padding:24px;
  box-shadow:var(--shadow);
}

.dashboard-hero{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:20px;
  margin-bottom:24px;
}

.dashboard-hero h1{
  margin:8px 0 10px;
  font-size:38px;
}

.section-label{
  color:var(--gold);
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.14em;
}

.muted{
  color:var(--muted);
  line-height:1.6;
}

.quota-box{
  min-width:190px;
  background:#111;
  border:1px solid #2d2d2d;
  border-radius:18px;
  padding:18px;
}

.quota-label{
  color:var(--muted);
  font-size:13px;
  margin-bottom:8px;
}

.quota-value{
  display:flex;
  align-items:flex-end;
  gap:8px;
}

.quota-value span{
  font-size:42px;
  color:var(--gold);
  line-height:1;
  font-weight:700;
}

.quota-value small{
  color:var(--muted);
  font-size:13px;
  padding-bottom:7px;
}

.dashboard-grid{
  display:grid;
  grid-template-columns:1.1fr .9fr;
  gap:24px;
  margin-bottom:24px;
}

.card h3{
  margin:10px 0 10px;
  font-size:24px;
}

.profile-list{
  margin-top:12px;
}

.profile-row{
  display:flex;
  justify-content:space-between;
  gap:14px;
  padding:13px 0;
  border-bottom:1px solid #222;
}

.profile-row:last-child{
  border-bottom:none;
}

.profile-row span{
  color:var(--muted);
}

.list-header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:16px;
}

.empty-state{
  padding:26px;
  border:1px dashed #313131;
  border-radius:18px;
  color:var(--muted);
  text-align:center;
  background:#101010;
}

/* Invite cards */
.invite-list{
  display:flex;
  flex-direction:column;
  gap:14px;
}

.invite-item{
  display:grid;
  grid-template-columns:1.4fr .7fr .8fr .7fr;
  gap:16px;
  align-items:center;
  padding:18px;
  border:1px solid #262626;
  border-radius:18px;
  background:#111;
}

.invite-item-extended{
  grid-template-columns:1.4fr .6fr 1fr .9fr;
}

.invite-main strong{
  display:block;
  margin-bottom:6px;
  font-size:15px;
}

.invite-main small,
.invite-meta,
.invite-date{
  color:var(--muted);
  font-size:13px;
  line-height:1.5;
}

.invite-link-box{
  margin-top:12px;
}

.invite-link-input{
  width:100%;
  font-size:12px;
  color:#cfcfcf;
  background:#0d0d0d;
  border:1px solid #2d2d2d;
  padding:12px;
  border-radius:12px;
}

.invite-actions{
  display:flex;
  justify-content:flex-end;
}

.invite-actions-column{
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:8px;
  justify-content:center;
}

.invite-action-row{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}

.status-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:0;
  height:42px;
  padding:0 14px;
  border-radius:999px;
  font-size:12px;
  text-transform:uppercase;
  letter-spacing:.08em;
  border:1px solid #333;
  line-height:1;
}

.status-sent{
  color:#e7c98d;
  border-color:rgba(200,169,107,.35);
  background:rgba(200,169,107,.08);
}

.status-opened,
.status-started,
.status-submitted{
  color:#d7bb84;
  border-color:#5a4723;
  background:#2a2213;
}

.status-approved{
  color:#8fdaa7;
  border-color:#28543a;
  background:#12241a;
}

.status-rejected,
.status-revoked{
  color:#efacac;
  border-color:#613030;
  background:#2b1717;
}

.btn-revoke{
  background:#221414;
  color:#efacac;
  border:1px solid #5a2c2c;
  width:auto;
  padding:10px 14px;
}

/* Compact copy / action button */
.btn-copy,
.invite-action-row .btn-copy,
.invite-actions-column .btn-copy{
  width:auto;
  min-width:0;
  height:42px;
  padding:0 14px;
  border-radius:999px;
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.10);
  color:#ececec;
  font-size:12px;
  font-weight:600;
  letter-spacing:.02em;
  line-height:1;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  box-shadow:none;
}

.btn-copy:hover,
.invite-action-row .btn-copy:hover,
.invite-actions-column .btn-copy:hover{
  transform:translateY(-1px);
  border-color:rgba(200,169,107,0.28);
  color:var(--gold-2);
  background:rgba(200,169,107,0.06);
}

.btn-copy:active,
.invite-action-row .btn-copy:active,
.invite-actions-column .btn-copy:active{
  transform:translateY(0);
}

/* Form helpers */
.field-help{
  display:block;
  margin-top:8px;
  color:var(--muted);
  font-size:12px;
}

.expertise-picker{
  position:relative;
}

.expertise-suggestions{
  position:absolute;
  top:calc(100% + 8px);
  left:0;
  right:0;
  background:#121212;
  border:1px solid #2e2e2e;
  border-radius:14px;
  box-shadow:var(--shadow);
  z-index:25;
  display:none;
  overflow:hidden;
}

.expertise-suggestion-item{
  width:100%;
  text-align:left;
  background:transparent;
  color:#f1f1f1;
  border:none;
  padding:12px 14px;
  cursor:pointer;
  border-bottom:1px solid #232323;
}

.expertise-suggestion-item:last-child{
  border-bottom:none;
}

.expertise-suggestion-item:hover{
  background:#1a1a1a;
  color:var(--gold);
}

.selected-expertise-list{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin:14px 0 20px;
}

.empty-expertise-box{
  padding:14px;
  border:1px dashed #333;
  border-radius:14px;
  color:var(--muted);
  background:#101010;
}

.selected-expertise-item{
  display:grid;
  grid-template-columns:1.2fr 140px 110px;
  gap:12px;
  align-items:end;
  padding:14px;
  border:1px solid #262626;
  border-radius:16px;
  background:#111;
}

.selected-expertise-chip{
  display:inline-flex;
  align-items:center;
  padding:12px 14px;
  border-radius:999px;
  background:rgba(200,169,107,.10);
  border:1px solid rgba(200,169,107,.25);
  color:var(--gold);
  font-size:14px;
  font-weight:600;
}

.selected-expertise-years label{
  display:block;
  margin-bottom:8px;
  color:var(--muted);
  font-size:12px;
}

.remove-expertise-btn{
  height:48px;
  border:none;
  border-radius:12px;
  background:#221414;
  color:#efacac;
  cursor:pointer;
  border:1px solid #5a2c2c;
}

.mini-skill-list{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:10px;
}

.mini-skill-chip{
  display:inline-flex;
  align-items:center;
  padding:8px 10px;
  border-radius:999px;
  background:#171717;
  border:1px solid #2d2d2d;
  color:#d8d8d8;
  font-size:12px;
}

.skill-list{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:12px;
}

.skill-chip{
  padding:8px 12px;
  border-radius:12px;
  background:#111;
  border:1px solid #2a2a2a;
  font-size:13px;
  color:#ddd;
}

/* Invite page extras */
.endorsed-box{
  margin:18px 0 22px;
  padding:18px;
  border-radius:18px;
  background:#111;
  border:1px solid #2c2c2c;
}

.endorsed-box-title{
  color:var(--gold);
  font-size:13px;
  letter-spacing:.10em;
  text-transform:uppercase;
  margin-bottom:10px;
}

.endorsed-box-text{
  margin-bottom:14px;
}

.endorsed-expertise-list{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

.endorsed-chip{
  display:inline-flex;
  align-items:center;
  padding:10px 12px;
  border-radius:999px;
  background:rgba(200,169,107,.10);
  border:1px solid rgba(200,169,107,.24);
  color:var(--gold);
  font-size:13px;
}

/* Application / admin */
.application-list{
  display:flex;
  flex-direction:column;
  gap:18px;
}

.application-card{
  border:1px solid #262626;
  background:#111;
  border-radius:20px;
  padding:22px;
}

.application-header{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:14px;
  margin-bottom:18px;
}

.application-header h3{
  margin:8px 0 6px;
  font-size:24px;
}

.application-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
  margin-bottom:18px;
}

.application-block{
  border:1px solid #232323;
  background:#0f0f0f;
  border-radius:16px;
  padding:16px;
  margin-bottom:14px;
}

.application-block h4{
  margin:0 0 14px;
  color:var(--gold);
  font-size:15px;
  letter-spacing:.04em;
}

.profile-list.compact .profile-row{
  padding:10px 0;
}

.wrap-anywhere{
  word-break:break-word;
}

.summary-box{
  line-height:1.7;
  color:#ddd;
  white-space:pre-wrap;
}

.review-note-input{
  margin-bottom:14px;
}

.review-action-row{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.btn-approve{
  width:auto;
  padding:12px 16px;
  background:#16301f;
  color:#9ee2b2;
  border:1px solid #29553a;
}

.btn-warning{
  width:auto;
  padding:12px 16px;
  background:#2b2213;
  color:#e4c885;
  border:1px solid #5a4723;
}

.btn-reject{
  width:auto;
  padding:12px 16px;
  background:#2b1717;
  color:#efacac;
  border:1px solid #613030;
}

.btn-nav-link{
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

.btn-inline-link{
  width:auto;
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
}

.reset-link-box{
  display:block;
}

/* Analytics */
.analytics-summary-grid{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  gap:18px;
  margin-bottom:24px;
}

.summary-card h3{
  margin:10px 0 8px;
  font-size:36px;
}

.analytics-grid{
  grid-template-columns:1.4fr .8fr;
}

.table-wrap{
  overflow:auto;
}

.analytics-table{
  width:100%;
  border-collapse:collapse;
  min-width:900px;
}

.analytics-table th,
.analytics-table td{
  padding:14px 12px;
  border-bottom:1px solid #232323;
  text-align:left;
  vertical-align:middle;
}

.analytics-table th{
  color:var(--gold);
  font-size:13px;
  letter-spacing:.05em;
  text-transform:uppercase;
}

.analytics-table td{
  color:#ddd;
}

.expertise-stats-list{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.expertise-stat-row{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding:14px 16px;
  border:1px solid #242424;
  border-radius:14px;
  background:#111;
}

.lineage-list{
  display:flex;
  flex-direction:column;
  gap:12px;
}

.lineage-item{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:16px;
  padding:16px 18px;
  border:1px solid #242424;
  border-radius:16px;
  background:#111;
}

.lineage-main{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:center;
}

.lineage-meta{
  display:flex;
  gap:12px;
  align-items:center;
  color:var(--muted);
}

/* Member extras */
.member-bullets{
  margin:16px 0 0;
  padding-left:18px;
}

.member-bullets li{
  margin-bottom:8px;
}

/* Responsive */
@media (max-width: 1100px){
  .analytics-summary-grid{
    grid-template-columns:repeat(2, 1fr);
  }

  .analytics-grid{
    grid-template-columns:1fr;
  }
}

@media (max-width: 980px){
  .split-layout{
    grid-template-columns:1fr;
  }

  .marketing-panel{
    padding:40px 24px 24px;
  }

  .marketing-content h1{
    font-size:38px;
  }

  .login-panel{
    border-left:none;
    border-top:1px solid rgba(255,255,255,.04);
    padding:20px 20px 32px;
  }

  .dashboard-grid{
    grid-template-columns:1fr;
  }

  .dashboard-hero{
    flex-direction:column;
  }

  .invite-item,
  .invite-item-extended,
  .selected-expertise-item,
  .application-grid{
    grid-template-columns:1fr;
  }

  .invite-actions{
    justify-content:flex-start;
  }

  .application-header{
    flex-direction:column;
  }
}

@media (max-width: 640px){
  .topbar{
    padding:16px 18px;
  }

  .dashboard-shell{
    padding:18px;
  }

  .marketing-panel{
    padding:28px 20px 20px;
  }

  .brand-title{
    font-size:18px;
  }

  .marketing-content h1{
    font-size:32px;
  }

  .rotating-text{
    font-size:20px;
  }

  .login-card{
    padding:22px;
  }

  .dashboard-hero h1{
    font-size:28px;
  }

  .analytics-summary-grid{
    grid-template-columns:1fr;
  }

  .lineage-item{
    flex-direction:column;
    align-items:flex-start;
  }

  .lineage-meta{
    flex-wrap:wrap;
  }
}

.reaction-bar{
  display:flex;
  gap:8px;
  margin-top:14px;
}

.reaction-btn{
  padding:6px 12px;
  border-radius:999px;
  border:1px solid #2a2a2a;
  background:#111;
  color:#aaa;
  font-size:12px;
  cursor:pointer;
  transition:.2s ease;
}

.reaction-btn:hover{
  border-color:var(--gold);
  color:var(--gold);
}

.reaction-btn.active{
  background:rgba(200,169,107,.12);
  border-color:rgba(200,169,107,.4);
  color:var(--gold);
}

/* HOME FEED */
.home-grid{
  display:grid;
  grid-template-columns:1.35fr .65fr;
  gap:24px;
}

.feed-main,
.feed-side{
  display:flex;
  flex-direction:column;
  gap:24px;
}

.composer-card textarea{
  min-height:140px;
}

.nj-select{
  width:100%;
  border:1px solid #303030;
  background:#111;
  color:#fff;
  padding:14px 15px;
  border-radius:14px;
  outline:none;
  transition:.2s ease;
}

.nj-select:focus{
  border-color:rgba(200,169,107,.55);
  box-shadow:0 0 0 4px rgba(200,169,107,.09);
}

.feed-list{
  display:flex;
  flex-direction:column;
  gap:16px;
}

.feed-card{
  border:1px solid #262626;
  background:#111;
  border-radius:20px;
  padding:20px;
}

.feed-card-top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
  margin-bottom:14px;
}

.feed-author{
  font-size:16px;
  font-weight:700;
  color:#f3f3f3;
  margin-bottom:4px;
}

.feed-meta{
  color:var(--muted);
  font-size:13px;
  line-height:1.5;
}

.feed-type-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:34px;
  padding:0 12px;
  border-radius:999px;
  background:rgba(200,169,107,.08);
  border:1px solid rgba(200,169,107,.24);
  color:var(--gold);
  font-size:12px;
  font-weight:600;
  letter-spacing:.05em;
  white-space:nowrap;
}

.feed-content{
  color:#ececec;
  line-height:1.75;
  white-space:pre-wrap;
  margin-bottom:14px;
}

.feed-footer{
  display:flex;
  justify-content:flex-end;
  margin-top:8px;
}

.feed-date{
  color:var(--muted);
  font-size:12px;
}

.post-tag-list{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:10px;
}

.post-tag{
  display:inline-flex;
  align-items:center;
  padding:7px 10px;
  border-radius:999px;
  background:#171717;
  border:1px solid #2c2c2c;
  color:#d8d8d8;
  font-size:12px;
}

.side-card{
  min-height:unset;
}

.side-chip-list{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:10px;
}

.side-chip{
  display:inline-flex;
  align-items:center;
  padding:8px 12px;
  border-radius:999px;
  background:#171717;
  border:1px solid #2c2c2c;
  color:#d9d9d9;
  font-size:12px;
}

.reaction-preview{
  display:inline-flex;
  align-items:center;
  padding:8px 12px;
  border-radius:999px;
  background:rgba(200,169,107,.08);
  border:1px solid rgba(200,169,107,.24);
  color:var(--gold);
  font-size:12px;
  font-weight:600;
}

.reaction-bar{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:16px;
}

.reaction-btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 12px;
  border-radius:999px;
  border:1px solid #2a2a2a;
  background:#111;
  color:#aaa;
  font-size:12px;
  font-weight:600;
  cursor:pointer;
  transition:.2s ease;
}

.reaction-btn:hover{
  border-color:var(--gold);
  color:var(--gold);
  background:rgba(200,169,107,.05);
}

.reaction-btn.active{
  background:rgba(200,169,107,.12);
  border-color:rgba(200,169,107,.4);
  color:var(--gold);
}

.reaction-count{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:20px;
  height:20px;
  border-radius:999px;
  background:rgba(255,255,255,.05);
  color:#ddd;
  font-size:11px;
  padding:0 6px;
}

@media (max-width: 1100px){
  .home-grid{
    grid-template-columns:1fr;
  }
}

@media (max-width: 640px){
  .feed-card-top{
    flex-direction:column;
    align-items:flex-start;
  }
}