/* Estilos do Painel Administrativo Tiba-X */

:root {
  --admin-bg-sidebar: #0b0d11;
  --admin-bg-body: #101319;
  --admin-bg-card: #171b24;
  --admin-border: rgba(255, 255, 255, 0.06);
  --admin-border-focus: #00f0ff;
  --admin-accent: #00f0ff;
  --admin-danger: #ff4757;
  --admin-success: #2ed573;
}

body.admin-body {
  background-color: var(--admin-bg-body);
  margin: 0;
  padding: 0;
  display: flex;
  min-height: 100vh;
  font-family: 'Inter', sans-serif;
  color: #f1f2f6;
}

/* Container de Login */
.login-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100vw;
  height: 100vh;
  background-color: #08090b;
  position: relative;
  overflow: hidden;
}

.login-wrapper::before {
  content: '';
  position: absolute;
  width: 300px;
  height: 300px;
  background-color: rgba(0, 240, 255, 0.05);
  border-radius: 50%;
  filter: blur(80px);
  top: 10%;
  left: 10%;
}

.login-card {
  width: 100%;
  max-width: 420px;
  background: rgba(23, 27, 36, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--admin-border);
  border-radius: 16px;
  padding: 3rem;
  box-shadow: 0 15px 35px rgba(0,0,0,0.5);
  text-align: center;
  z-index: 1;
}

.login-logo {
  height: 40px;
  margin-bottom: 2.5rem;
}

.login-card h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
  color: #fff;
}

.login-card p {
  color: #a4b0be;
  font-size: 0.9rem;
  margin-bottom: 2rem;
}

/* Layout do Painel */
.admin-sidebar {
  width: 260px;
  background-color: var(--admin-bg-sidebar);
  border-right: 1px solid var(--admin-border);
  display: flex;
  flex-direction: column;
  padding: 2rem 1.5rem;
  position: fixed;
  height: 100vh;
  left: 0;
  top: 0;
  z-index: 10;
}

.admin-sidebar-logo {
  height: 32px;
  margin-bottom: 3rem;
  padding-left: 0.5rem;
}

.admin-nav {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-grow: 1;
}

.admin-nav-item a {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  color: #a4b0be;
  border-radius: 8px;
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  cursor: pointer;
}

.admin-nav-item a:hover, .admin-nav-item.active a {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.03);
}

.admin-nav-item.active a {
  background-color: rgba(0, 240, 255, 0.08);
  border-left: 3px solid var(--admin-accent);
  border-radius: 0 8px 8px 0;
  padding-left: 0.85rem;
}

.admin-logout {
  margin-top: auto;
  border-top: 1px solid var(--admin-border);
  padding-top: 1.5rem;
}

.admin-logout-btn {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--admin-danger);
  padding: 0.85rem 1rem;
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.admin-logout-btn:hover {
  background-color: rgba(255, 71, 87, 0.05);
  border-radius: 8px;
}

.admin-main {
  flex-grow: 1;
  padding: 3rem 4rem;
  margin-left: 260px;
  min-height: 100vh;
  background-color: var(--admin-bg-body);
}

@media (max-width: 992px) {
  body.admin-body {
    flex-direction: column;
  }
  
  .admin-sidebar {
    width: 100%;
    height: auto;
    position: relative;
    padding: 1.5rem;
    border-right: none;
    border-bottom: 1px solid var(--admin-border);
  }
  
  .admin-sidebar-logo {
    margin-bottom: 1.5rem;
  }
  
  .admin-nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  
  .admin-logout {
    margin-top: 0;
    border-top: none;
    padding-top: 0;
  }
  
  .admin-main {
    margin-left: 0;
    padding: 2rem 1.5rem;
  }
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3rem;
  border-bottom: 1px solid var(--admin-border);
  padding-bottom: 1.5rem;
}

.admin-header h1 {
  font-size: 2rem;
  font-family: 'Outfit', sans-serif;
}

.admin-header p {
  color: #a4b0be;
  font-size: 0.95rem;
}

/* Painel de Abas */
.admin-tab-content {
  display: none;
}

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

/* Elementos do Form */
.admin-card {
  background-color: var(--admin-bg-card);
  border: 1px solid var(--admin-border);
  border-radius: 12px;
  padding: 2.5rem;
  margin-bottom: 2rem;
}

.admin-card-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.35rem;
  margin-bottom: 1.75rem;
  color: #fff;
  border-bottom: 1px solid var(--admin-border);
  padding-bottom: 0.75rem;
}

.admin-form-group {
  margin-bottom: 1.5rem;
}

.admin-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 768px) {
  .admin-form-row {
    grid-template-columns: 1fr;
  }
}

.admin-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: #a4b0be;
  margin-bottom: 0.5rem;
  font-family: 'Outfit', sans-serif;
}

.admin-input, .admin-textarea, .admin-select {
  width: 100%;
  background-color: #0b0d11;
  border: 1px solid var(--admin-border);
  border-radius: 6px;
  padding: 0.8rem 1rem;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.admin-input:focus, .admin-textarea:focus, .admin-select:focus {
  outline: none;
  border-color: var(--admin-accent);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.15);
}

.admin-textarea {
  min-height: 100px;
  resize: vertical;
}

.admin-btn {
  background-color: var(--admin-accent);
  color: #000;
  border: none;
  padding: 0.8rem 1.75rem;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
}

.admin-btn:hover {
  background-color: #fff;
  box-shadow: 0 0 20px rgba(255,255,255,0.25);
  transform: translateY(-1px);
}

.admin-btn-secondary {
  background-color: rgba(255,255,255,0.05);
  color: #fff;
  border: 1px solid var(--admin-border);
}

.admin-btn-secondary:hover {
  background-color: rgba(255,255,255,0.1);
  border-color: #fff;
}

.admin-btn-danger {
  background-color: var(--admin-danger);
  color: #fff;
}

.admin-btn-danger:hover {
  background-color: #ff6b81;
  box-shadow: 0 0 20px rgba(255, 71, 87, 0.25);
}

/* Alertas e Mensagens */
.alert {
  padding: 1rem 1.25rem;
  border-radius: 8px;
  margin-bottom: 2rem;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.alert-success {
  background-color: rgba(46, 213, 115, 0.1);
  border: 1px solid rgba(46, 213, 115, 0.25);
  color: var(--admin-success);
}

.alert-error {
  background-color: rgba(255, 71, 87, 0.1);
  border: 1px solid rgba(255, 71, 87, 0.25);
  color: var(--admin-danger);
}

/* Área de Upload de Imagem */
.upload-zone {
  border: 2px dashed var(--admin-border);
  border-radius: 8px;
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-bottom: 1.5rem;
  position: relative;
}

.upload-zone:hover, .upload-zone.dragover {
  border-color: var(--admin-accent);
  background-color: rgba(0, 240, 255, 0.02);
}

.upload-zone svg {
  width: 48px;
  height: 48px;
  color: #a4b0be;
  margin-bottom: 1rem;
}

.upload-zone input[type="file"] {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

/* Gerenciamento de Imagens da Galeria */
.admin-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.admin-gallery-card {
  background-color: #0b0d11;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.admin-gallery-thumb {
  width: 100%;
  aspect-ratio: 4/3;
  overflow: hidden;
  position: relative;
}

.admin-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.admin-gallery-actions {
  position: absolute;
  top: 8px;
  right: 8px;
}

.admin-delete-img-btn {
  background-color: rgba(255, 71, 87, 0.85);
  color: #fff;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.admin-delete-img-btn:hover {
  background-color: var(--admin-danger);
  transform: scale(1.05);
}

.admin-gallery-info {
  padding: 0.85rem;
}

.admin-gallery-info h4 {
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-gallery-info span {
  font-size: 0.75rem;
  color: var(--admin-accent);
  text-transform: uppercase;
  font-weight: 600;
}

/* Lista de Serviços Administrável */
.admin-services-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.admin-service-item {
  background-color: #0b0d11;
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  padding: 1.25rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

@media (max-width: 576px) {
  .admin-service-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
}

.admin-service-meta h3 {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.admin-service-meta p {
  font-size: 0.85rem;
  color: #a4b0be;
}
