/*
Theme Name: PTM Srl - Elementor Compatible
Theme URI: https://ptmsrl.com
Author: PTM Srl
Author URI: https://ptmsrl.com
Description: Tema WordPress customizado para PTM Srl, totalmente compatível com Elementor. Mantém a identidade visual original com estrutura moderna e editável.
Version: 1.0.0
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ptm-srl-theme
Domain Path: /languages
Requires at least: 5.9
Requires PHP: 7.4
Elementor Tested up to: 3.18

This theme is designed to work seamlessly with Elementor Page Builder.
*/

/* ============================================
   RESET E VARIÁVEIS CSS
   ============================================ */

:root {
  /* Cores Primárias */
  --color-primary: #0066cc;
  --color-primary-dark: #0052a3;
  --color-primary-light: #3385e5;
  
  /* Cores Secundárias */
  --color-secondary: #333333;
  --color-secondary-light: #666666;
  --color-secondary-lighter: #999999;
  
  /* Cores de Fundo */
  --color-bg-light: #ffffff;
  --color-bg-gray: #f5f5f5;
  --color-bg-dark: #1a1a1a;
  
  /* Cores de Acentos */
  --color-accent: #ff6b35;
  --color-success: #28a745;
  --color-warning: #ffc107;
  --color-danger: #dc3545;
  
  /* Tipografia */
  --font-family-primary: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-family-secondary: 'Georgia', serif;
  --font-size-base: 16px;
  --font-size-small: 14px;
  --font-size-large: 18px;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-bold: 700;
  
  /* Espaçamento */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  --spacing-xxl: 4rem;
  
  /* Bordas e Sombras */
  --border-radius: 4px;
  --border-radius-lg: 8px;
  --box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --box-shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.15);
  
  /* Transições */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;
}

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

html {
  font-size: var(--font-size-base);
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family-primary);
  font-size: var(--font-size-base);
  line-height: 1.6;
  color: var(--color-secondary);
  background-color: var(--color-bg-light);
}

/* ============================================
   TIPOGRAFIA
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-primary);
  font-weight: var(--font-weight-bold);
  line-height: 1.2;
  margin-bottom: var(--spacing-md);
  color: var(--color-secondary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.75rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: var(--spacing-md);
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-normal);
}

a:hover {
  color: var(--color-primary-dark);
  text-decoration: underline;
}

/* ============================================
   CONTAINER E LAYOUT
   ============================================ */

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

.container-fluid {
  width: 100%;
  padding: 0 var(--spacing-lg);
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 calc(var(--spacing-md) * -1);
}

.col {
  flex: 1 1 100%;
  padding: var(--spacing-md);
}

.col-md-6 {
  flex: 0 0 50%;
}

.col-md-4 {
  flex: 0 0 33.333%;
}

.col-md-3 {
  flex: 0 0 25%;
}

/* ============================================
   COMPONENTES GLOBAIS
   ============================================ */

.button,
button,
input[type="button"],
input[type="submit"] {
  display: inline-block;
  padding: var(--spacing-sm) var(--spacing-lg);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-medium);
  text-align: center;
  text-decoration: none;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: all var(--transition-normal);
}

.button-primary,
.button.primary {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: white;
}

.button-primary:hover,
.button.primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--box-shadow-lg);
}

.button-secondary,
.button.secondary {
  background-color: var(--color-secondary-light);
  color: white;
}

.button-secondary:hover,
.button.secondary:hover {
  background-color: var(--color-secondary);
}

.button-outline {
  background-color: transparent;
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}

.button-outline:hover {
  background-color: var(--color-primary);
  color: white;
}

/* ============================================
   HEADER
   ============================================ */

.site-header {
  background-color: var(--color-bg-light);
  box-shadow: var(--box-shadow);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md) 0;
}

.logo {
  max-width: 200px;
  height: auto;
}

.logo img {
  max-width: 100%;
  height: auto;
  display: block;
}

.main-nav {
  display: flex;
  list-style: none;
  gap: var(--spacing-lg);
}

.main-nav a {
  font-weight: var(--font-weight-medium);
  color: var(--color-secondary);
  text-transform: uppercase;
  font-size: 0.9rem;
}

.main-nav a:hover {
  color: var(--color-primary);
  text-decoration: none;
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero-section {
  position: relative;
  min-height: 500px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  color: white;
  text-align: center;
  max-width: 600px;
  animation: fadeInLeft 0.8s ease-out;
}

.hero-content h1 {
  color: white;
  margin-bottom: var(--spacing-lg);
  text-transform: uppercase;
}

.hero-content p {
  font-size: var(--font-size-large);
  margin-bottom: var(--spacing-lg);
}

/* Parallax Effect */
.parallax {
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

/* ============================================
   SLIDER/CAROUSEL
   ============================================ */

.slider-wrapper {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.slider {
  display: flex;
  position: relative;
}

.slide {
  flex: 0 0 100%;
  width: 100%;
}

.slide-nav {
  position: absolute;
  bottom: var(--spacing-lg);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: var(--spacing-sm);
  z-index: 10;
}

.slide-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all var(--transition-normal);
}

.slide-dot.active {
  background-color: white;
  transform: scale(1.3);
}

/* ============================================
   CARDS
   ============================================ */

.card {
  background-color: var(--color-bg-light);
  border-radius: var(--border-radius-lg);
  box-shadow: var(--box-shadow);
  overflow: hidden;
  transition: all var(--transition-normal);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--box-shadow-lg);
}

.card-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
}

.card-content {
  padding: var(--spacing-lg);
}

.card-title {
  font-size: 1.25rem;
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--spacing-md);
  color: var(--color-secondary);
}

.card-text {
  color: var(--color-secondary-light);
  margin-bottom: var(--spacing-md);
}

/* ============================================
   FOOTER
   ============================================ */

.site-footer {
  background-color: var(--color-secondary);
  color: white;
  padding: var(--spacing-xxl) 0;
  margin-top: var(--spacing-xxl);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
}

.footer-section h3 {
  color: white;
  margin-bottom: var(--spacing-md);
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: var(--spacing-sm);
}

.footer-section a {
  color: rgba(255, 255, 255, 0.8);
}

.footer-section a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: var(--spacing-lg);
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
}

/* ============================================
   ANIMAÇÕES
   ============================================ */

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.animate-fade-in-left {
  animation: fadeInLeft 0.8s ease-out;
}

.animate-fade-in-up {
  animation: fadeInUp 0.8s ease-out;
}

.animate-slide-in-right {
  animation: slideInRight 0.8s ease-out;
}

/* ============================================
   RESPONSIVIDADE
   ============================================ */

@media (max-width: 768px) {
  .container {
    padding: 0 var(--spacing-md);
  }

  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }

  .main-nav {
    gap: var(--spacing-md);
  }

  .col-md-6,
  .col-md-4,
  .col-md-3 {
    flex: 0 0 100%;
  }

  .hero-section {
    min-height: 300px;
  }

  .footer-content {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--spacing-sm);
  }

  h1 { font-size: 1.5rem; }
  h2 { font-size: 1.25rem; }
  h3 { font-size: 1rem; }

  .main-nav {
    flex-direction: column;
    gap: var(--spacing-sm);
  }

  .button {
    width: 100%;
  }
}

/* ============================================
   COMPATIBILIDADE COM ELEMENTOR
   ============================================ */

.elementor-container {
  max-width: 1200px;
}

.elementor-section {
  padding: var(--spacing-lg) 0;
}

.elementor-widget-wrap {
  display: flex;
  flex-wrap: wrap;
}

/* Remover espaçamento padrão de widgets */
.elementor-widget-wrap > .elementor-widget-wrap {
  margin: 0;
}

/* Estilos para widgets customizados */
.elementor-widget-ptm-hero {
  width: 100%;
}

.elementor-widget-ptm-card {
  margin-bottom: var(--spacing-lg);
}

.elementor-widget-ptm-slider {
  width: 100%;
}
