/* ===== VARIÁVEIS ===== */
:root {
  --blue-light: #00c6ff;
  --blue-mid: #0072ff;
  --navy: #111827;
  --slate: #1f2937;
  --gray: #6b7280;
  --white: #ffffff;
  --accent: #00e5ff;
  --green: #10b981;
  --red: #ef4444;
  --sidebar-w: 240px;
}

*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { font-size:16px; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--navy);
  color: var(--white);
  -webkit-font-smoothing: antialiased;
}

/* ===== LOGIN ===== */
.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.login-bg {
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse 80% 80% at 50% 0%, rgba(0,114,255,0.25), transparent 70%), #0a0f1e;
  z-index: 0;
}

.login-orb {
  position: absolute;
  width: 600px; height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,198,255,0.12), transparent 70%);
  top: -150px; left: 50%; transform: translateX(-50%);
}

.login-box {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 24px;
  padding: 3rem 2.5rem;
  backdrop-filter: blur(20px);
  box-shadow: 0 30px 80px rgba(0,0,0,0.4);
  animation: fadeUp 0.6s ease both;
}

.login-logo {
  text-align: center;
  margin-bottom: 2.5rem;
}

.logo-text-admin {
  display: block;
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 2rem;
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.login-sub {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-top: 0.3rem;
  display: block;
}

.form-group {
  margin-bottom: 1.2rem;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255,255,255,0.6);
  margin-bottom: 0.45rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  color: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,229,255,0.08);
}

.form-group select option { background: #1f2937; }
.form-group textarea { resize: vertical; line-height: 1.5; }

.login-error {
  display: none;
  color: var(--red);
  font-size: 0.83rem;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.25);
  border-radius: 8px;
  padding: 0.6rem 0.9rem;
  margin-bottom: 1rem;
  text-align: center;
}

.btn-login {
  width: 100%;
  padding: 0.9rem;
  background: linear-gradient(135deg, var(--blue-mid), var(--blue-light));
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 4px 20px rgba(0,114,255,0.35);
}

.btn-login:hover { transform: translateY(-1px); box-shadow: 0 8px 30px rgba(0,114,255,0.5); }

.login-footer {
  text-align: center;
  margin-top: 1.5rem;
}

.login-footer a {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  transition: color 0.2s;
}

.login-footer a:hover { color: var(--accent); }

/* ===== DASHBOARD ===== */
.dashboard-page {
  display: flex;
  min-height: 100vh;
}

/* SIDEBAR */
.sidebar {
  width: var(--sidebar-w);
  min-height: 100vh;
  background: #0a0f1e;
  border-right: 1px solid rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  padding: 2rem 1.2rem;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 10;
}

.sidebar-logo {
  text-align: center;
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.sidebar-logo span {
  display: block;
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 1.5rem;
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sidebar-logo small {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.sidebar-nav { flex: 1; display: flex; flex-direction: column; gap: 0.4rem; }

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.75rem 1rem;
  border-radius: 10px;
  color: rgba(255,255,255,0.5);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  transition: all 0.2s;
}

.sidebar-link:hover, .sidebar-link.active {
  background: rgba(0,114,255,0.15);
  color: var(--accent);
}

.btn-logout {
  width: 100%;
  padding: 0.7rem;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 10px;
  color: #ef4444;
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 1rem;
}

.btn-logout:hover { background: rgba(239,68,68,0.2); }

/* MAIN */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 2.5rem 3rem;
  min-height: 100vh;
}

.page-header {
  margin-bottom: 2rem;
}

.page-header h1 {
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 1.9rem;
  margin-bottom: 0.3rem;
}

.page-header p {
  color: rgba(255,255,255,0.45);
  font-size: 0.92rem;
}

/* FORM CARD */
.form-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: 2.5rem;
}

.form-section-title {
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: 1.2rem;
  color: rgba(255,255,255,0.85);
  padding-bottom: 0.6rem;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

/* ITEM DO ORÇAMENTO */
.quote-item {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr auto;
  gap: 0.8rem;
  align-items: center;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 0.8rem;
  animation: fadeUp 0.3s ease both;
}

.quote-item input {
  width: 100%;
  padding: 0.65rem 0.9rem;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  color: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s;
}

.quote-item input:focus { border-color: var(--accent); }

.btn-remove-item {
  width: 36px; height: 36px;
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
  border-radius: 8px;
  color: #ef4444;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: background 0.2s;
  flex-shrink: 0;
}

.btn-remove-item:hover { background: rgba(239,68,68,0.25); }

.btn-add-item {
  margin-top: 0.5rem;
  padding: 0.65rem 1.5rem;
  background: rgba(0,229,255,0.08);
  border: 1px dashed rgba(0,229,255,0.3);
  border-radius: 10px;
  color: var(--accent);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-add-item:hover { background: rgba(0,229,255,0.15); }

/* ACTIONS */
.form-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.btn-preview {
  padding: 0.85rem 2rem;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 50px;
  color: var(--white);
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-preview:hover { background: rgba(255,255,255,0.12); }

.btn-pdf {
  padding: 0.85rem 2rem;
  background: linear-gradient(135deg, var(--blue-mid), var(--blue-light));
  border: none;
  border-radius: 50px;
  color: #fff;
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0,114,255,0.35);
  transition: all 0.25s ease;
}

.btn-pdf:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0,114,255,0.5); }

/* PREVIEW AREA */
.preview-area {
  margin-top: 2rem;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  overflow: hidden;
}

.preview-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.5rem;
  background: rgba(255,255,255,0.05);
  border-bottom: 1px solid rgba(255,255,255,0.07);
  font-size: 0.88rem;
  font-weight: 600;
}

.preview-header-bar button {
  background: none;
  border: none;
  color: rgba(255,255,255,0.5);
  cursor: pointer;
  font-size: 0.85rem;
  transition: color 0.2s;
}

.preview-header-bar button:hover { color: var(--red); }

/* ===== PDF CONTENT ===== */
.pdf-content {
  background: #ffffff;
  color: #1a1a2e;
  font-family: 'Inter', sans-serif;
  width: 100%;
  padding: 0;
}

.pdf-cover {
  background: linear-gradient(135deg, #0d1b4b 0%, #0a0f1e 60%, #001a3a 100%);
  color: #fff;
  padding: 60px 60px 50px;
  position: relative;
  overflow: hidden;
}

.pdf-cover::before {
  content: '';
  position: absolute;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,198,255,0.15), transparent 70%);
  top: -150px; right: -100px;
}

.pdf-cover-logo {
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 2.2rem;
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.3rem;
}

.pdf-cover-tagline {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 60px;
}

.pdf-cover h1 {
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 2.4rem;
  line-height: 1.15;
  margin-bottom: 0.5rem;
  position: relative;
}

.pdf-cover h1 span {
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pdf-cover-sub {
  font-size: 1rem;
  color: rgba(255,255,255,0.55);
  margin-bottom: 50px;
  position: relative;
}

.pdf-cover-meta {
  display: flex;
  gap: 3rem;
  flex-wrap: wrap;
  position: relative;
}

.pdf-meta-item label {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  margin-bottom: 0.2rem;
}

.pdf-meta-item span {
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
}

.pdf-divider {
  height: 4px;
  background: linear-gradient(90deg, #0072ff, #00c6ff, transparent);
}

/* PDF BODY */
.pdf-body {
  padding: 50px 60px;
  background: #f8faff;
}

.pdf-intro {
  background: #fff;
  border-radius: 16px;
  padding: 35px 40px;
  margin-bottom: 35px;
  border-left: 4px solid #0072ff;
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
}

.pdf-intro h2 {
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 1.3rem;
  color: #0a0f1e;
  margin-bottom: 0.8rem;
}

.pdf-intro p {
  font-size: 0.92rem;
  color: #4b5563;
  line-height: 1.75;
}

.pdf-section-title {
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 1.15rem;
  color: #0a0f1e;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #e5e7eb;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* TABELA DE ITENS */
.pdf-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 20px rgba(0,0,0,0.06);
}

.pdf-table thead tr {
  background: linear-gradient(135deg, #0d1b4b, #0072ff);
  color: #fff;
}

.pdf-table thead th {
  padding: 14px 20px;
  text-align: left;
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pdf-table tbody tr {
  border-bottom: 1px solid #f1f5f9;
  transition: background 0.15s;
}

.pdf-table tbody tr:nth-child(even) { background: #f8faff; }

.pdf-table tbody td {
  padding: 14px 20px;
  font-size: 0.9rem;
  color: #374151;
}

.pdf-table tfoot tr {
  background: #0a0f1e;
  color: #fff;
}

.pdf-table tfoot td {
  padding: 16px 20px;
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  color: #fff;
}

.pdf-table tfoot .total-label { color: rgba(255,255,255,0.7); font-size: 0.85rem; }

/* PROJETOS */
.pdf-projects-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
  margin-bottom: 2rem;
}

.pdf-project-card {
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 20px rgba(0,0,0,0.07);
  border: 1px solid #e5e7eb;
}

.pdf-project-thumb {
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  font-weight: 900;
  letter-spacing: 0.05em;
}

.pdf-project-info {
  padding: 16px 20px;
}

.pdf-project-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0072ff;
  background: rgba(0,114,255,0.08);
  border-radius: 50px;
  padding: 0.2rem 0.7rem;
  margin-bottom: 0.5rem;
}

.pdf-project-info h4 {
  font-family: 'Exo 2', sans-serif;
  font-weight: 800;
  font-size: 0.98rem;
  color: #0a0f1e;
  margin-bottom: 0.3rem;
}

.pdf-project-info p {
  font-size: 0.8rem;
  color: #6b7280;
  line-height: 1.5;
}

.pdf-project-result {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.7rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: #10b981;
}

/* DIFERENCIAIS */
.pdf-diferenciais {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.pdf-dif-item {
  background: #fff;
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
  border: 1px solid #e5e7eb;
}

.pdf-dif-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(0,114,255,0.15), rgba(0,198,255,0.08));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.pdf-dif-item h4 {
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  color: #0a0f1e;
  margin-bottom: 0.2rem;
}

.pdf-dif-item p {
  font-size: 0.78rem;
  color: #6b7280;
  line-height: 1.5;
}

/* DEPOIMENTOS */
.pdf-testimonials {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.pdf-testimonial {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
  border: 1px solid #e5e7eb;
  border-top: 3px solid #0072ff;
}

.pdf-testimonial-stars {
  color: #f59e0b;
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
}

.pdf-testimonial p {
  font-size: 0.8rem;
  color: #4b5563;
  line-height: 1.55;
  font-style: italic;
  margin-bottom: 0.8rem;
}

.pdf-testimonial-author {
  font-size: 0.78rem;
  font-weight: 700;
  color: #0a0f1e;
}

.pdf-testimonial-role {
  font-size: 0.72rem;
  color: #9ca3af;
}

/* FOOTER DO PDF */
.pdf-footer {
  background: #0a0f1e;
  color: #fff;
  padding: 40px 60px;
}

.pdf-footer-obs {
  background: rgba(255,255,255,0.06);
  border-left: 3px solid #0072ff;
  border-radius: 8px;
  padding: 18px 22px;
  margin-bottom: 30px;
}

.pdf-footer-obs h4 {
  font-family: 'Exo 2', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.7);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.pdf-footer-obs p {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
  line-height: 1.65;
}

.pdf-footer-contacts {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 25px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.pdf-footer-brand {
  font-family: 'Exo 2', sans-serif;
  font-weight: 900;
  font-size: 1.4rem;
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.pdf-footer-info {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
  line-height: 1.7;
  text-align: right;
}

/* ===== UTILS ===== */
@keyframes fadeUp {
  from { opacity:0; transform:translateY(20px); }
  to   { opacity:1; transform:translateY(0); }
}

@media (max-width: 768px) {
  .sidebar { display: none; }
  .main-content { margin-left: 0; padding: 1.5rem; }
  .quote-item { grid-template-columns: 1fr 1fr; }
  .quote-item input:first-child { grid-column: 1 / -1; }
  .pdf-projects-grid,
  .pdf-diferenciais,
  .pdf-testimonials { grid-template-columns: 1fr; }
}
