/* ==========================================================================
   BLLZ ADVOCACIA - ADMIN CMS STYLESHEET
   ========================================================================== */

:root {
  --bllz-gold: #DCA54A;
  --bllz-gold-dark: #D09A40;
  --bllz-navy: #0F172A;
  --bllz-navy-light: #1E293B;
  --bg-admin: #F4F6F9;
  --bg-card: #FFFFFF;
  --text-main: #1E293B;
  --text-muted: #64748B;
  --danger: #EF4444;
  --font-serif: 'Cinzel', Georgia, serif;
  --font-sans: 'Montserrat', system-ui, sans-serif;
  --radius: 8px;
  --transition: all 0.25s ease;
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-admin);
  color: var(--text-main);
  line-height: 1.5;
  font-size: 15px;
}

/* --------------------------------------------------------------------------
   LOGIN SCREEN
   -------------------------------------------------------------------------- */
.login-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: linear-gradient(135deg, var(--bllz-navy), #090d16);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
}

.login-card {
  background: #ffffff;
  width: 100%;
  max-width: 420px;
  padding: 40px 32px;
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
  text-align: center;
  border-top: 4px solid var(--bllz-gold);
}

.login-logo {
  max-height: 50px;
  margin: 0 auto 20px;
}

.login-card h2 {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  color: var(--bllz-navy);
  margin-bottom: 8px;
}

.login-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.login-error {
  display: none;
  margin-top: 16px;
  color: var(--danger);
  font-size: 0.85rem;
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   ADMIN LAYOUT
   -------------------------------------------------------------------------- */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: 280px;
  background: var(--bllz-navy);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 10;
  border-right: 1px solid rgba(220, 165, 74, 0.2);
}

.sidebar-header {
  padding: 28px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.sidebar-logo {
  max-height: 44px;
  filter: brightness(0) invert(1);
}

.sidebar-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--bllz-gold);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.sidebar-nav {
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-grow: 1;
}

.nav-tab {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 16px;
  border-radius: var(--radius);
  color: #cbd5e1;
  font-weight: 500;
  font-size: 0.9rem;
  text-align: left;
  transition: var(--transition);
}

.nav-tab i {
  font-size: 1rem;
  color: var(--bllz-gold);
}

.nav-tab:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
}

.nav-tab.active {
  background: var(--bllz-gold);
  color: #0F172A;
  font-weight: 700;
}

.nav-tab.active i {
  color: #0F172A;
}

.sidebar-footer {
  padding: 20px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* MAIN CONTENT */
.admin-main {
  margin-left: 280px;
  flex-grow: 1;
  padding: 32px 40px;
  max-width: 1200px;
}

.admin-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  background: #ffffff;
  padding: 24px 32px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--bllz-gold);
}

.admin-topbar h1 {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  color: var(--bllz-navy);
}

.topbar-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* CARDS & FORMS */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 28px;
  border: 1px solid rgba(0,0,0,0.06);
}

.card-title {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: var(--bllz-navy);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-title i {
  color: var(--bllz-gold-dark);
}

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

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.span-2 {
  grid-column: span 2;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--bllz-navy);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius);
  border: 1px solid #cbd5e1;
  font-family: var(--font-sans);
  font-size: 0.92rem;
  outline: none;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--bllz-gold-dark);
  box-shadow: 0 0 0 3px var(--bllz-gold-glow);
}

/* TABS */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* ITEM CARDS LIST (SERVICES & FAQ) */
.admin-items-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.admin-item-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius);
  padding: 24px;
  position: relative;
}

.admin-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e2e8f0;
}

.admin-item-header h4 {
  font-size: 1rem;
  color: var(--bllz-navy);
  font-weight: 700;
}

/* BUTTONS */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: var(--radius);
  transition: var(--transition);
}

.btn-gold {
  background: var(--bllz-gold);
  color: #0F172A;
}

.btn-gold:hover {
  background: var(--bllz-gold-dark);
  color: #ffffff;
}

.btn-primary {
  background: var(--bllz-navy);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--bllz-navy-light);
}

.btn-outline {
  border: 1px solid #cbd5e1;
  color: var(--text-main);
  background: transparent;
}

.btn-outline:hover {
  border-color: var(--bllz-navy);
  background: var(--bllz-navy);
  color: #ffffff;
}

.btn-danger {
  background: #fee2e2;
  color: var(--danger);
  border: 1px solid #fca5a5;
}

.btn-danger:hover {
  background: var(--danger);
  color: #ffffff;
}

.btn-dark {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.btn-dark:hover {
  background: rgba(255, 255, 255, 0.2);
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.78rem;
}

.btn-block {
  width: 100%;
}

.mt-2 { margin-top: 10px; }

/* BACKUP SECTION */
.backup-card {
  background: #f1f5f9;
  border-left: 4px solid var(--bllz-navy);
}

.backup-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.backup-card h4 {
  font-size: 1rem;
  color: var(--bllz-navy);
}

.backup-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.backup-btn-group {
  display: flex;
  gap: 12px;
}

/* TOAST NOTIFICATION */
.toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--bllz-navy);
  color: #ffffff;
  padding: 16px 28px;
  border-radius: var(--radius);
  border-left: 4px solid var(--bllz-gold);
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  font-size: 0.9rem;
  font-weight: 600;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9999;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* RESPONSIVE ADMIN */
@media (max-width: 900px) {
  .admin-sidebar {
    width: 100%;
    height: auto;
    position: relative;
  }
  .admin-main {
    margin-left: 0;
    padding: 20px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .span-2 {
    grid-column: span 1;
  }
  .admin-topbar, .backup-flex {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }
}

/* --------------------------------------------------------------------------
   PHOTO UPLOAD CMS STYLES
   -------------------------------------------------------------------------- */
.photo-upload-grid {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 14px;
}

.photo-preview-box {
  position: relative;
  width: 120px;
  height: 120px;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid var(--bllz-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
  flex-shrink: 0;
}

.photo-preview-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.preview-badge {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.85);
  color: var(--bllz-gold);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  pointer-events: none;
}

.photo-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.photo-btn-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.photo-info-text {
  font-size: 0.83rem;
  color: var(--text-muted);
  font-weight: 500;
  line-height: 1.4;
}

.photo-edit-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 20px;
  margin-top: 24px;
  border-left: 4px solid var(--bllz-gold);
}

.subcard-heading {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--bllz-navy);
  margin-bottom: 4px;
}

@media (max-width: 600px) {
  .photo-upload-grid {
    flex-direction: column;
    align-items: flex-start;
  }
}


