:root{
  --admin-bg:#07170f;
  --admin-panel:rgba(11,32,22,.94);
  --admin-panel-2:rgba(16,47,31,.94);
  --admin-border:rgba(255,215,0,.34);
  --admin-border-2:rgba(255,215,0,.18);
  --admin-text:#f6f2dc;
  --admin-muted:#d6d0af;
  --admin-accent:#2e8b57;
  --admin-accent-2:#ffd700;
  --admin-shadow:0 18px 45px rgba(0,0,0,.38);
}
.link-reset{color:inherit;text-decoration:none}
.admin-shell{display:grid;grid-template-columns:280px minmax(0,1fr);gap:22px;align-items:start}
.admin-sidebar{position:sticky;top:90px;background:linear-gradient(180deg,var(--admin-panel),var(--admin-panel-2));border:1px solid var(--admin-border);border-radius:22px;box-shadow:var(--admin-shadow);padding:18px;overflow:hidden}
.admin-sidebar:before{content:"";position:absolute;inset:0;background:radial-gradient(circle at top right, rgba(255,221,138,.12), transparent 35%);pointer-events:none}
.admin-sidebar>*{position:relative}
.admin-brand{display:flex;gap:12px;align-items:center;margin-bottom:14px;padding-bottom:12px;border-bottom:1px solid var(--admin-border-2)}
.admin-brand-icon{width:52px;height:52px;display:grid;place-items:center;border-radius:16px;background:linear-gradient(135deg, rgba(217,164,76,.28), rgba(255,215,120,.12));border:1px solid var(--admin-border);font-size:1.35rem;box-shadow:inset 0 0 20px rgba(255,215,120,.05)}
.admin-brand h2{font-size:1.02rem;line-height:1.15;margin:0;color:var(--admin-text)}
.admin-brand small{display:block;color:var(--admin-muted);margin-top:4px}
.admin-search{margin:12px 0 16px}
.admin-search input{width:100%;padding:12px 14px;border-radius:14px;border:1px solid var(--admin-border);background:rgba(0,0,0,.28);color:var(--admin-text)}
.admin-sidebar-section{margin:16px 0}
.admin-sidebar-heading{font-size:.8rem;text-transform:uppercase;letter-spacing:.12em;color:var(--admin-muted);margin:0 0 8px}
.admin-sidebar-links{display:grid;gap:8px}
.admin-sidebar-link{display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:14px;color:var(--admin-text);text-decoration:none;border:1px solid transparent;transition:all .18s ease;background:rgba(255,255,255,.02)}
.admin-sidebar-link:hover,.admin-sidebar-link.is-active{border-color:var(--admin-border);background:rgba(46,139,87,.16);transform:translateX(2px)}
.admin-sidebar-link .ico{width:28px;height:28px;display:grid;place-items:center;border-radius:10px;background:rgba(255,215,0,.12);font-size:.95rem}
.admin-main{min-width:0}
.admin-v2-topbar{display:flex;gap:14px;align-items:center;justify-content:space-between;margin-bottom:18px;background:linear-gradient(180deg, rgba(26,15,9,.9), rgba(15,10,5,.9));border:1px solid var(--admin-border);padding:16px 18px;border-radius:20px;box-shadow:var(--admin-shadow)}
.admin-v2-topbar h1{font-size:1.35rem;margin:0;color:var(--admin-text)}
.admin-v2-topbar p{margin:4px 0 0;color:var(--admin-muted)}
.admin-chip-row{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.admin-chip{display:inline-flex;align-items:center;gap:8px;padding:8px 12px;border-radius:999px;background:rgba(46,139,87,.16);border:1px solid var(--admin-border);color:var(--admin-text);font-size:.92rem}
.admin-return{display:inline-flex;align-items:center;gap:8px;padding:11px 16px;border-radius:14px;background:linear-gradient(180deg, rgba(46,139,87,.95), rgba(34,99,63,.95));color:#f8f8f0!important;font-weight:700;text-decoration:none!important;border:1px solid rgba(255,221,138,.5);box-shadow:0 10px 24px rgba(0,0,0,.22)}
.admin-return:hover{filter:brightness(1.06);transform:translateY(-1px)}
.admin-hero-grid{display:grid;grid-template-columns:1.3fr .9fr;gap:18px}
.admin-stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-top:14px}
.admin-stat-card,.admin-card-panel{background:linear-gradient(180deg, rgba(29,16,10,.82), rgba(17,10,6,.86));border:1px solid var(--admin-border);border-radius:18px;padding:16px;box-shadow:var(--admin-shadow)}
.admin-stat-card h3,.admin-card-panel h3{margin:0 0 6px;color:var(--admin-text)}
.admin-stat-value{font-size:1.8rem;font-weight:800;color:var(--admin-accent-2);line-height:1.1}
.admin-stat-meta{color:var(--admin-muted);font-size:.95rem}
.admin-grid-v2{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
.admin-card-link{display:flex;flex-direction:column;justify-content:space-between;gap:10px;min-height:130px;padding:16px;border-radius:18px;background:linear-gradient(180deg, rgba(35,20,12,.82), rgba(20,12,8,.9));border:1px solid var(--admin-border);text-decoration:none;color:var(--admin-text)!important;box-shadow:var(--admin-shadow);transition:transform .18s ease, border-color .18s ease, box-shadow .18s ease}
.admin-card-link:hover{transform:translateY(-3px);border-color:rgba(255,221,138,.62);box-shadow:0 20px 32px rgba(0,0,0,.42)}
.admin-card-link .card-emoji{font-size:1.45rem}
.admin-card-link .card-title{font-weight:800;font-size:1rem}
.admin-card-link .card-desc{color:var(--admin-muted);font-size:.92rem;line-height:1.45}
.admin-card-link .card-foot{font-size:.85rem;color:var(--admin-accent-2)}
.page-builder-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(340px,.8fr);gap:18px;align-items:start}
.page-builder-help{display:grid;gap:18px}
.page-snippet-bar{display:flex;gap:8px;flex-wrap:wrap;padding:12px;border:1px dashed var(--admin-border);border-radius:14px;background:rgba(255,255,255,.02);margin-top:12px}
.page-snippet-title{font-weight:700;color:var(--admin-accent-2);margin-right:4px}
.page-snippet-btn{padding:8px 10px!important;font-size:.86rem}
.page-wireframe{border-radius:18px;border:1px solid var(--admin-border);overflow:hidden;background:rgba(0,0,0,.18)}
.page-wireframe-label{padding:10px 14px;background:rgba(46,139,87,.16);font-size:.85rem;color:var(--admin-muted);text-transform:uppercase;letter-spacing:.08em}
.page-wireframe-hero{min-height:160px;display:grid;place-items:center;background:rgba(255,255,255,.03);border-bottom:1px solid var(--admin-border-2)}
.page-wireframe-body{padding:16px}
.page-wireframe-chip{display:inline-flex;padding:6px 10px;border-radius:999px;background:rgba(46,139,87,.16);border:1px solid var(--admin-border);margin-bottom:12px}
.page-wireframe-content{padding:14px;border-radius:14px;background:rgba(255,255,255,.03);border:1px dashed var(--admin-border);margin-top:12px;min-height:120px;color:var(--admin-muted)}
.page-wireframe-empty{color:var(--admin-muted)}
.page-block-note{margin-top:8px;color:var(--admin-muted);font-size:.92rem}
.page-action-row{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px}
.upload-box{margin-top:8px;margin-bottom:14px;padding:14px;border:1px solid var(--admin-border);border-radius:14px;background:rgba(0,0,0,.2)}
.upload-box input[type=file]{display:block;width:100%;color:var(--admin-text);background:transparent;border:none;padding:0}
.upload-box input[type=file]::file-selector-button{background:linear-gradient(180deg, rgba(46,139,87,.95), rgba(34,99,63,.95));color:#f8f8f0;border:none;border-radius:10px;padding:10px 16px;margin-right:12px;font-weight:700;cursor:pointer}
.upload-help{display:block;margin-top:10px;color:var(--admin-muted)}
.users-list{display:grid;gap:12px}
.user-row-card{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;padding:14px;border-radius:16px;border:1px solid var(--admin-border);background:rgba(255,255,255,.03)}
.user-row-meta{color:var(--admin-muted);font-size:.93rem;margin-top:4px}
.user-row-actions{display:flex;gap:8px;align-items:start;flex-wrap:wrap}
.perm-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.perm-item{display:flex;gap:10px;align-items:flex-start;padding:10px 12px;border-radius:12px;border:1px solid var(--admin-border-2);background:rgba(255,255,255,.02)}
.perm-item input{margin-top:3px}
.admin-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.admin-note{padding:12px 14px;border-radius:14px;background:rgba(255,221,138,.08);border:1px solid var(--admin-border);color:var(--admin-muted)}
.nav-manager-list{display:grid;gap:10px}
.nav-link-row{display:grid;grid-template-columns:1.4fr 1.8fr auto auto;gap:10px;align-items:center;padding:12px;border:1px solid var(--admin-border);border-radius:14px;background:rgba(255,255,255,.03)}
.admin-table{width:100%;border-collapse:separate;border-spacing:0 10px}
.admin-table th{font-size:.85rem;color:var(--admin-muted);text-transform:uppercase;letter-spacing:.08em;padding:0 10px 4px;text-align:left}
.admin-table td{padding:12px 10px;background:rgba(255,255,255,.03);border-top:1px solid var(--admin-border-2);border-bottom:1px solid var(--admin-border-2)}
.admin-table td:first-child{border-left:1px solid var(--admin-border-2);border-radius:12px 0 0 12px}
.admin-table td:last-child{border-right:1px solid var(--admin-border-2);border-radius:0 12px 12px 0}
@media (max-width:1200px){.admin-grid-v2{grid-template-columns:repeat(3,minmax(0,1fr))}.admin-stat-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.perm-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:980px){.admin-shell{grid-template-columns:1fr}.admin-sidebar{position:static}.page-builder-grid,.admin-hero-grid,.admin-form-grid{grid-template-columns:1fr}.admin-grid-v2{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:640px){.admin-grid-v2,.admin-stat-grid,.perm-grid{grid-template-columns:1fr}.user-row-card{grid-template-columns:1fr}.nav-link-row{grid-template-columns:1fr}.admin-v2-topbar{flex-direction:column;align-items:flex-start}.admin-chip-row{justify-content:flex-start}}


/* Admin V2 readability + footer fixes */
body.page-admin{background:linear-gradient(rgba(5,16,11,.74), rgba(5,16,11,.8)), url('/assets/logo.png') no-repeat center 140px fixed, #07170f; background-size:cover, contain, auto; color:var(--admin-text);} 
body.page-admin .content-area{padding-bottom:calc(var(--footer-h) + 40px);} 
body.page-admin .content-wrapper{max-width:1280px;overflow:visible;} 
body.page-admin .admin-main{min-width:0;color:var(--admin-text);} 
body.page-admin .admin-main, 
body.page-admin .admin-main p,
body.page-admin .admin-main li,
body.page-admin .admin-main label,
body.page-admin .admin-main strong,
body.page-admin .admin-main span,
body.page-admin .admin-main td,
body.page-admin .admin-main th,
body.page-admin .admin-main code,
body.page-admin .admin-main small,
body.page-admin .admin-main h1,
body.page-admin .admin-main h2,
body.page-admin .admin-main h3,
body.page-admin .admin-main h4,
body.page-admin .admin-main h5,
body.page-admin .admin-main h6{color:var(--admin-text);} 
body.page-admin .admin-main .admin-stat-meta,
body.page-admin .admin-main .card-desc,
body.page-admin .admin-main .page-block-note,
body.page-admin .admin-main .upload-help,
body.page-admin .admin-main .user-row-meta,
body.page-admin .admin-main .admin-note,
body.page-admin .admin-main .page-wireframe-empty,
body.page-admin .admin-main .page-wireframe-label,
body.page-admin .admin-main .content-muted{color:var(--admin-muted)!important;} 
body.page-admin .admin-main .content-card,
body.page-admin .admin-main .admin-card,
body.page-admin .admin-main .schedule-box,
body.page-admin .admin-main .clock-box{color:var(--admin-text);} 
body.page-admin .admin-main a:not(.admin-btn):not(.admin-return):not(.admin-card-link):not(.btn):not(.admin-sidebar-link){color:var(--admin-accent-2);} 
body.page-admin .admin-main input,
body.page-admin .admin-main textarea,
body.page-admin .admin-main select{color:var(--admin-text);} 
body.page-admin .admin-main input::placeholder,
body.page-admin .admin-main textarea::placeholder{color:rgba(245,232,201,.6);} 
body.page-admin .admin-table td{color:var(--admin-text);} 
body.page-admin .site-footer{display:block!important;visibility:visible!important;opacity:1!important;position:fixed;left:0;bottom:0;z-index:9997;width:100%;margin-left:0;} 
@media (max-width:980px){body.page-admin .site-footer{margin-left:0;}}


.builder-toolbar{display:flex;gap:8px;flex-wrap:wrap}
.builder-blocks{display:grid;gap:14px;margin-top:16px}
.builder-block{padding:14px;border:1px solid var(--admin-border);border-radius:16px;background:rgba(255,255,255,.03)}
.builder-block-head{display:flex;justify-content:space-between;gap:10px;align-items:center;margin-bottom:10px}
.builder-block-actions{display:flex;gap:6px;flex-wrap:wrap}
.preview-block-card{padding:12px;border-radius:14px;background:rgba(255,255,255,.04);border:1px solid var(--admin-border-2);margin-bottom:10px}
.preview-block-card h4{margin:8px 0 6px}
.preview-badge{display:inline-flex;padding:4px 8px;border-radius:999px;background:rgba(217,164,76,.14);border:1px solid var(--admin-border);font-size:.8rem;text-transform:capitalize}
.preview-thumb{margin-top:8px;padding:8px 10px;border-radius:10px;background:rgba(255,255,255,.03);color:var(--admin-muted);font-size:.9rem}
.builder-hero .builder-copy,.builder-copy{line-height:1.7}
.builder-media{width:100%;height:auto;border-radius:14px;display:block}
.quote-source{opacity:.8;margin-top:8px}


/* Users page layout fix */
.admin-users-layout{
  display:grid;
  grid-template-columns:minmax(360px, 430px) minmax(0, 1fr);
  gap:18px;
  align-items:start;
}
.admin-users-layout > .content-card{min-width:0;}
.admin-users-layout .perm-grid{
  grid-template-columns:repeat(2, minmax(0, 1fr));
  gap:10px;
}
.admin-users-layout .perm-item{
  min-width:0;
  align-items:center;
}
.admin-users-layout .perm-item span{
  display:block;
  line-height:1.35;
  word-break:break-word;
}
@media (max-width: 980px){
  .admin-users-layout{grid-template-columns:1fr;}
  .admin-users-layout .perm-grid{grid-template-columns:1fr;}
}


/* Keep admin content behaving like the front site shell */
body.page-admin .footer-inner{padding-left:24px;padding-right:24px;}
body.page-admin .content-area{min-height:100vh;}

body.page-admin .main-container.admin-v2-shell{padding-top:24px;padding-bottom:120px;}



/* Larger Almost Heaven admin form controls */
body.page-admin .admin-main .admin-input,
body.page-admin .admin-main .admin-select,
body.page-admin .admin-main .input-field,
body.page-admin .admin-main .request-input,
body.page-admin .admin-main textarea,
body.page-admin .admin-main select,
body.page-admin .admin-main input[type="text"],
body.page-admin .admin-main input[type="password"],
body.page-admin .admin-main input[type="url"],
body.page-admin .admin-main input[type="email"],
body.page-admin .admin-main input[type="datetime-local"],
body.page-admin .admin-main input[type="number"]{
  width:100%;
  min-height:52px;
  padding:14px 16px;
  border-radius:14px;
  border:1px solid var(--admin-border);
  background:rgba(0,0,0,.28);
  box-sizing:border-box;
  font-size:1rem;
}
body.page-admin .admin-main textarea,
body.page-admin .admin-main textarea.admin-input,
body.page-admin .admin-main textarea.input-field{
  min-height:140px;
  resize:vertical;
  line-height:1.5;
}
body.page-admin .admin-main input[type="checkbox"],
body.page-admin .admin-main input[type="radio"]{
  transform:scale(1.15);
  margin-right:8px;
}
body.page-admin .admin-main label{
  display:block;
  margin-bottom:8px;
}
body.page-admin .admin-main .admin-form,
body.page-admin .admin-main .form,
body.page-admin .admin-main form{
  gap:12px;
}


/* Almost Heaven admin/login professional pass */
:root{
  --admin-bg:#07130f;
  --admin-panel:rgba(8,24,20,.92);
  --admin-panel-2:rgba(10,32,26,.96);
  --admin-border:rgba(241,208,75,.30);
  --admin-border-2:rgba(112,177,140,.18);
  --admin-text:#f5ecd0;
  --admin-muted:#d7cfb1;
  --admin-accent:#1f5a45;
  --admin-accent-2:#f1d04b;
}
body.page-admin{
  background:transparent;
}
body.page-admin .admin-main-shell{
  width:min(1440px, calc(100% - 40px));
  margin:0 auto;
}
body.page-admin .admin-topbar-pro{
  background:linear-gradient(180deg, rgba(15,44,33,.86), rgba(8,24,20,.88));
  border:1px solid rgba(241,208,75,.22);
  border-radius:24px;
  padding:16px 18px;
  box-shadow:0 18px 38px rgba(0,0,0,.24);
}
body.page-admin .admin-return{
  background:linear-gradient(135deg, rgba(241,208,75,.22), rgba(31,90,69,.22));
  border:1px solid rgba(241,208,75,.28);
  color:#fff3bf!important;
}
body.page-admin .admin-return:hover{background:linear-gradient(135deg, rgba(241,208,75,.30), rgba(31,90,69,.28));}
body.page-admin .admin-card-panel,
body.page-admin .admin-stat-card,
body.page-admin .admin-card-link,
body.page-admin .content-card{
  background:linear-gradient(180deg, rgba(6,16,24,.90), rgba(8,18,28,.84));
  border:1px solid rgba(241,208,75,.22);
  box-shadow:0 18px 40px rgba(0,0,0,.28), inset 0 0 18px rgba(255,255,255,.02);
  border-radius:24px;
}
body.page-admin .admin-card-link .card-title,
body.page-admin .admin-title{color:var(--admin-accent-2);}
body.page-admin .admin-card-link .card-foot{color:#fff3bf;}
body.page-admin .admin-table td{background:rgba(8,18,28,.72);}
body.page-admin .admin-stat-card h3, body.page-admin .admin-card-panel h2, body.page-admin .content-card h2{color:var(--admin-accent-2);}
body.page-admin .admin-chip, body.page-admin .page-wireframe-chip, body.page-admin .preview-badge{background:rgba(241,208,75,.12);}
body.page-admin .admin-sidebar-link:hover,.admin-sidebar-link.is-active{background:rgba(241,208,75,.10);}
body.page-admin .site-footer{position:static!important; margin-top:32px;}

.login-shell-pro{padding:42px 0 60px;}
.login-shell-wrap{max-width:1240px; margin:0 auto;}
.login-shell-grid{display:grid;grid-template-columns:1.1fr .9fr;gap:28px;align-items:stretch;}
.login-brand-pane,.pro-login-card{padding:34px;border-radius:24px;background:linear-gradient(180deg, rgba(6,16,24,.82), rgba(8,18,28,.78));border:1px solid rgba(241,208,75,.22);box-shadow:0 18px 40px rgba(0,0,0,.28);backdrop-filter:blur(10px);}
.login-brand-pane h2{margin:0 0 14px;color:#f1d04b;font-size:clamp(2rem,3vw,3rem);line-height:1.08;}
.login-brand-pane p{color:#d7cfb1;font-size:1.05rem;max-width:60ch;}
.login-feature-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:20px;}
.login-feature-pill{padding:14px 16px;border-radius:18px;background:rgba(255,255,255,.05);border:1px solid rgba(241,208,75,.16);color:#f5ecd0;font-weight:700;}
.pro-login-card h3{margin:0 0 8px;color:#f1d04b;font-size:1.8rem;}
.login-form-pro{display:grid;gap:12px;margin-top:14px;}
.login-form-pro label{font-weight:700;color:#f5ecd0;}
.login-form-pro .admin-input{width:100%;min-height:52px;padding:14px 16px;border-radius:16px;border:1px solid rgba(241,208,75,.22);background:rgba(4,10,18,.78)!important;color:#fff6d8!important;}
.btn-login-wow{width:100%;justify-content:center;margin-top:6px;}
.login-error-box{padding:12px 14px;border-radius:14px;background:rgba(135,0,0,.25);border:1px solid rgba(255,120,120,.35);color:#ffdada;font-weight:700;}
@media (max-width: 980px){.login-shell-grid{grid-template-columns:1fr;}.login-feature-grid{grid-template-columns:1fr;}}
