/* Hangsix Energia Solar - Estilos */
:root {
  --primary: #f59e0b;
  --primary-dark: #d97706;
  --dark: #1e293b;
  --dark-light: #334155;
  --light: #f8fafc;
  --white: #ffffff;
  --text: #475569;
  --success: #10b981;
  --error: #ef4444;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Outfit', sans-serif; color: var(--dark); line-height: 1.6; background: var(--white); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }

/* Header */
.header { background: var(--white); box-shadow: 0 2px 15px rgba(0,0,0,.1); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.5rem; }
.logo { font-weight: 700; font-size: 1.25rem; }
.logo span { color: var(--primary); }
.nav { display: flex; gap: 2rem; }
.nav a { font-weight: 500; color: var(--dark-light); transition: color .2s; }
.nav a:hover { color: var(--primary); }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: .5rem; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--dark); margin: 5px 0; }

/* Buttons */
.btn { display: inline-block; padding: .75rem 1.5rem; font-weight: 600; border-radius: 8px; transition: all .2s; cursor: pointer; border: 2px solid transparent; font-family: inherit; }
.btn-primary { background: var(--primary); color: var(--white); border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: var(--white); }
.btn-block { width: 100%; text-align: center; }
.btn-link { background: none; border: none; cursor: pointer; font-size: inherit; color: inherit; text-decoration: underline; }
.btn-link.danger { color: var(--error); }

/* Main */
.main-content { min-height: calc(100vh - 200px); }

/* Hero */
.hero { background: linear-gradient(135deg, var(--dark) 0%, var(--dark-light) 100%); color: var(--white); padding: 4rem 0; text-align: center; }
.hero-logo { height: 100px; width: auto; margin: 0 auto 1.5rem; display: block; filter: drop-shadow(0 4px 20px rgba(0,0,0,.3)); }
.hero h1 { font-size: 2.5rem; margin-bottom: 1rem; }
.hero h1 span { color: var(--primary); }
.hero p { font-size: 1.2rem; opacity: .9; margin-bottom: 2rem; }
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* Sections */
section { padding: 3rem 0; }
h2 { margin-bottom: 2rem; font-size: 1.75rem; }
.beneficios { background: var(--light); }
.beneficios-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 2rem; }
.beneficio-card { background: var(--white); padding: 2rem; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,.06); transition: transform .2s; }
.beneficio-card:hover { transform: translateY(-4px); }
.beneficio-icon { font-size: 2.5rem; margin-bottom: 1rem; }
.beneficio-card h3 { margin-bottom: .5rem; color: var(--dark); }
.beneficio-card p { color: var(--text); font-size: .95rem; }

/* Projetos */
.projetos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 2rem; }
.projeto-card { background: var(--white); border-radius: 12px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,.06); transition: transform .2s; display: block; }
.projeto-card:hover { transform: translateY(-4px); }
.projeto-img { aspect-ratio: 16/10; background: var(--light); }
.projeto-img img { width: 100%; height: 100%; object-fit: cover; }
.projeto-placeholder { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 4rem; }
.projeto-info { padding: 1.25rem; }
.projeto-info h3 { margin-bottom: .25rem; }
.projeto-info p { color: var(--text); font-size: .9rem; }
.projeto-info .economia { color: var(--success); font-weight: 600; }
.projetos-destaque, .projetos-lista { background: var(--white); }
.projetos-destaque .container { text-align: center; }
.projetos-destaque .btn { margin-top: 2rem; }

/* CTA */
.cta { background: var(--primary); color: var(--white); text-align: center; padding: 4rem 0; }
.cta h2 { color: var(--white); margin-bottom: .5rem; }
.cta p { opacity: .95; margin-bottom: 1.5rem; }
.cta .btn { background: var(--white); color: var(--primary); border-color: var(--white); }
.cta .btn:hover { background: var(--light); }

/* Page header */
.page-header { background: var(--dark); color: var(--white); padding: 2.5rem 0; text-align: center; }
.page-header h1 { margin-bottom: .5rem; }
.page-header p { opacity: .85; }

/* Calculadora */
.calculadora-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
@media (max-width: 768px) { .calculadora-grid { grid-template-columns: 1fr; } }
.calculadora-form form, .contato-section form { display: flex; flex-direction: column; gap: 1rem; }
.calculadora-form label, .contato-section label { font-weight: 500; }
.calculadora-form input, .calculadora-form select, .contato-section input, .contato-section textarea {
  padding: .75rem; border: 1px solid #e2e8f0; border-radius: 8px; font-family: inherit;
}
.resultado-card { background: var(--light); padding: 2rem; border-radius: 12px; }
.resultado-valor { font-size: 2rem; font-weight: 700; color: var(--primary); }
.resultado-valor span { font-size: 1rem; font-weight: 400; }
.resultado-detalhes { margin: 1.5rem 0; }
.resultado-detalhes p { margin: .5rem 0; }
.resultado-obs { font-size: .85rem; color: var(--text); margin: 1rem 0; }
.resultado-placeholder { padding: 2rem; background: var(--light); border-radius: 12px; text-align: center; color: var(--text); }

/* Serviços e Sobre */
.servico-intro { margin-bottom: 2.5rem; max-width: 800px; }
.servico-intro p { margin-bottom: 0; }
.servicos-titulo { font-size: 1.5rem; margin-bottom: 1.5rem; color: var(--dark); }
.servicos-subtitulo { font-size: 1.25rem; margin-bottom: 1rem; color: var(--dark-light); }
.servico-item, .sobre-item { margin-bottom: 2rem; }
.servico-item ul { margin-top: .5rem; }
.servico-cta { margin-top: 2.5rem; }
.sobre-card { width: 100%; background: var(--white); padding: 2.5rem; border-radius: 12px; box-shadow: 0 4px 20px rgba(0,0,0,.08); }
.sobre-texto { margin-bottom: 2rem; }
.sobre-texto p { margin-bottom: 1rem; }
.servico-item h2, .sobre-item h2 { font-size: 1.25rem; margin-bottom: .75rem; }
.sobre-item ul { margin-left: 1.5rem; }
.sobre-item li { margin: .5rem 0; }

/* Contato */
.contato-section .container { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: start; }
@media (max-width: 768px) { .contato-section .container { grid-template-columns: 1fr; } }
.contato-info-card { background: var(--light); padding: 1.5rem 2rem; border-radius: 12px; }
.contato-info-card h2 { font-size: 1.25rem; margin-bottom: 1rem; }
.contato-info-card p { margin-bottom: .75rem; }
.contato-info-card a { color: var(--primary); font-weight: 500; }
.contato-info-card a:hover { text-decoration: underline; }
.contato-largura { max-width: 100%; }
.contato-section form { max-width: 100%; }

/* Alerts */
.alert { padding: 1rem; border-radius: 8px; margin-bottom: 1rem; }
.alert-error { background: #fee2e2; color: var(--error); }
.alert-success { background: #d1fae5; color: var(--success); }

/* Footer */
.footer { background: var(--dark); color: var(--white); padding: 3rem 0 1.5rem; margin-top: 4rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; margin-bottom: 2rem; }
.footer-logo { height: 72px; width: auto; margin-bottom: 1.25rem; object-fit: contain; opacity: .95; }
.footer h3, .footer h4 { margin-bottom: .75rem; }
.footer a { opacity: .9; }
.footer a:hover { opacity: 1; color: var(--primary); }
.footer-endereco { font-size: .9rem; opacity: .9; margin-bottom: 1rem; line-height: 1.4; max-width: 220px; }
.footer-copy { text-align: center; opacity: .7; font-size: .9rem; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,.2); }

/* Empty state */
.empty-state { text-align: center; padding: 3rem; color: var(--text); }

/* Projeto detalhe */
.projeto-galeria { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.projeto-galeria img { border-radius: 8px; width: 100%; object-fit: cover; }
.projeto-conteudo h2 { margin-top: 1rem; margin-bottom: .5rem; }
.projeto-stats { margin-top: 1.5rem; }
.projeto-stats p { margin: .5rem 0; }

/* Admin */
.admin-body { background: var(--light); }
.admin-header { background: var(--dark); color: var(--white); padding: 1rem 0; }
.admin-header-inner { display: flex; justify-content: space-between; align-items: center; }
.admin-logo-img { height: 48px; width: auto; display: block; object-fit: contain; }
.admin-header nav { display: flex; gap: 1.5rem; }
.admin-header a { color: rgba(255,255,255,.9); }
.admin-header a:hover { color: var(--primary); }
.admin-main { padding: 2rem 0; }
.admin-dashboard h1 { margin-bottom: 2rem; }
.admin-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1.5rem; margin-bottom: 3rem; }
.admin-card { background: var(--white); padding: 2rem; border-radius: 12px; box-shadow: 0 2px 10px rgba(0,0,0,.06); transition: transform .2s; display: block; text-align: center; }
.admin-card:hover { transform: translateY(-2px); }
.admin-card h3 { font-size: 2rem; color: var(--primary); }
.admin-tables { display: grid; gap: 2rem; }
.admin-tables table { width: 100%; background: var(--white); border-radius: 8px; overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.admin-tables th, .admin-tables td { padding: .75rem 1rem; text-align: left; }
.admin-tables thead { background: var(--dark); color: var(--white); }
.admin-tables tr:nth-child(even) { background: var(--light); }
.admin-section table { width: 100%; background: var(--white); border-radius: 8px; overflow: hidden; box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.admin-section th, .admin-section td { padding: .75rem 1rem; text-align: left; }
.admin-section thead { background: var(--dark); color: var(--white); }
.admin-section tr:nth-child(even) { background: var(--light); }
.admin-section h1 { margin-bottom: 1.5rem; display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.thumb { width: 60px; height: 60px; object-fit: cover; border-radius: 6px; }
.form-width { max-width: 600px; }
.form-width form { display: flex; flex-direction: column; gap: 1rem; }
.form-width label { font-weight: 500; }
.form-width input, .form-width textarea, .form-width select { padding: .75rem; border: 1px solid #e2e8f0; border-radius: 8px; font-family: inherit; }

/* Login */
.login-body { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--dark) 0%, var(--dark-light) 100%); }
.login-box { background: var(--white); padding: 2.5rem; border-radius: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.3); max-width: 400px; width: 100%; text-align: center; }
.login-logo { height: 100px; width: auto; margin: 0 auto 1.5rem; display: block; object-fit: contain; }
.login-box h1 { margin-bottom: .5rem; }
.login-box p { color: var(--text); margin-bottom: 1.5rem; }
.login-box form { display: flex; flex-direction: column; gap: 1rem; }

/* Responsive */
@media (max-width: 768px) {
  .nav { display: none; }
  .nav-toggle { display: block; }
  .hero h1 { font-size: 1.75rem; }
}
