﻿/* ========================================
   Email Signature Generator — Stylesheet
   ======================================== */

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

:root {
  --bg: #1a0e05;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.07);
  --glass: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.1);
  --text-primary: #f5f0eb;
  --text-secondary: #b8a090;
  --text-muted: #806b5c;
  --accent: #f97316;
  --accent-glow: rgba(249, 115, 22, 0.3);
  --accent-soft: rgba(249, 115, 22, 0.12);
  --success: #22c55e;
  --radius: 16px;
  --radius-sm: 10px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
  font-size: 15px;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
}

.bg-blobs {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.35;
}

.blob-1 {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #f97316 0%, transparent 70%);
  top: -120px;
  left: -100px;
  animation: float1 18s ease-in-out infinite;
}

.blob-2 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, #fb923c 0%, transparent 70%);
  bottom: -80px;
  right: -60px;
  animation: float2 22s ease-in-out infinite;
}

.blob-3 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, #ea580c 0%, transparent 70%);
  top: 50%;
  left: 60%;
  animation: float3 20s ease-in-out infinite;
}

@keyframes float1 {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  50% {
    transform: translate(60px, 40px) scale(1.1);
  }
}

@keyframes float2 {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  50% {
    transform: translate(-50px, -30px) scale(1.15);
  }
}

@keyframes float3 {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  50% {
    transform: translate(30px, -50px) scale(0.9);
  }
}

.container {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 24px 60px;
}

/* ---- Header ---- */
.header {
  text-align: center;
  margin-bottom: 40px;
}

.header-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 16px;
  box-shadow: 0 0 30px var(--accent-glow);
}

.header h1 {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #f5f0eb 30%, #f97316);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-top: 6px;
}

/* ---- Grid ---- */
.content-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 28px;
  margin-bottom: 28px;
}

@media (max-width: 820px) {
  .content-grid {
    grid-template-columns: 1fr;
  }
}

.panel {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 28px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: border-color var(--transition);
  min-width: 0;
}

.panel:hover {
  border-color: rgba(255, 255, 255, 0.16);
}

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

.panel-header h2 {
  font-size: 1.05rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.badge {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 20px;
  background: rgba(34, 197, 94, 0.12);
  color: var(--success);
  animation: pulse-badge 2s ease-in-out infinite;
}

@keyframes pulse-badge {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.input-wrapper {
  position: relative;
}

.input-wrapper input,
.input-wrapper select {
  width: 100%;
  padding: 12px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  color: var(--text-primary);
  background: var(--surface);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  outline: none;
  transition: all var(--transition);
}

.input-wrapper input::placeholder {
  color: var(--text-muted);
}

.input-wrapper input:focus,
.input-wrapper select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
  background: var(--surface-hover);
}

.input-wrapper select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23a0a0b8' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.input-wrapper select option {
  background: #1a1a2e;
  color: var(--text-primary);
}

.logo-upload {
  border: 2px dashed var(--glass-border);
  border-radius: var(--radius-sm);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
  position: relative;
}

.logo-upload:hover,
.logo-upload.drag-over {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.upload-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.upload-content small {
  font-size: 0.7rem;
  color: var(--text-muted);
  opacity: 0.7;
}

.upload-preview {
  position: relative;
  display: inline-block;
}

.upload-preview img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--glass-border);
}

.btn-remove-logo {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #ef4444;
  color: white;
  border: none;
  font-size: 0.7rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s;
}

.btn-remove-logo:hover {
  transform: scale(1.15);
}

.email-context {
  margin-bottom: 20px;
}

.email-mockup {
  background: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.email-header-mock {
  background: #f3f4f6;
  padding: 10px 14px;
  display: flex;
  gap: 6px;
}

.email-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d1d5db;
}

.email-dot:nth-child(1) {
  background: #ef4444;
}

.email-dot:nth-child(2) {
  background: #f59e0b;
}

.email-dot:nth-child(3) {
  background: #22c55e;
}

.email-body-mock {
  padding: 24px 20px;
  overflow-x: auto;
}

.email-line {
  height: 8px;
  background: #e5e7eb;
  border-radius: 4px;
  margin-bottom: 8px;
}

.email-line.short {
  height: 6px;
  background: #d1d5db;
}

.email-spacer {
  height: 14px;
}

.signature-box {
  padding: 4px 0 0 0;
  border-top: 1px solid #e5e7eb;
  max-width: 660px;
  width: 660px;
  height: 110px;
  overflow: hidden;
  box-sizing: border-box;
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-wrap: wrap;
}

.actions a {
  text-decoration: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition);
  flex: 1;
  justify-content: center;
}

.btn-primary {
  background: linear-gradient(135deg, #f97316, #fb923c);
  color: white;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-tutorial {
  background: linear-gradient(135deg, #374151, #4b5563);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 30px var(--accent-glow);
}

.btn-tutorial:hover:not(:disabled) {
  transform: translateY(-2px);
}

.btn-primary:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-secondary {
  background: var(--surface);
  color: var(--text-primary);
  border: 1px solid var(--glass-border);
}

.btn-secondary:hover {
  background: var(--surface-hover);
  border-color: rgba(255, 255, 255, 0.2);
}

.toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: var(--success);
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 999;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.recommendations-panel {
  margin-bottom: 28px;
}

.rec-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 820px) {
  .rec-grid {
    grid-template-columns: 1fr;
  }
}

.rec-card {
  background: var(--surface);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  padding: 20px;
  transition: all var(--transition);
}

.rec-card:hover {
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-2px);
}

.rec-icon {
  font-size: 1.6rem;
  margin-bottom: 10px;
}

.rec-card h3 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.rec-card ul {
  list-style: none;
  padding: 0;
}

.rec-card li {
  font-size: 0.78rem;
  color: var(--text-secondary);
  padding: 4px 0;
  line-height: 1.5;
}

.rec-card li strong {
  color: var(--text-primary);
}

.rec-card a {
  color: var(--accent);
  text-decoration: none;
}

.rec-card a:hover {
  text-decoration: underline;
}

.rec-card code {
  font-size: 0.72rem;
  background: rgba(249, 115, 22, 0.12);
  color: #fdba74;
  padding: 2px 5px;
  border-radius: 4px;
}

/* ---- Footer ---- */
.footer {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.78rem;
}

.footer code {
  background: var(--accent-soft);
  color: #a5b4fc;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.75rem;
}

/* Chrome, Edge e Safari */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: #1f2937;
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, #f97316, #fb923c);
  border-radius: 10px;
  border: 2px solid #1f2937;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(135deg, #ea580c, #f97316);
}

* {
  scrollbar-width: thin;
  scrollbar-color: #f97316 #1f2937;
}
