/* ===== DM ROOFING TEXAS — PREMIUM CSS ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Montserrat:wght@700;800;900&display=swap');

:root {
  --primary: #991b1b;
  --primary-light: #ef4444;
  --primary-dark: #7f1d1d;
  --accent: #dc2626;
  --gold: #d97706;
  --gold-light: #f59e0b;
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.4);
  --shadow-red: rgba(153, 27, 27, 0.25);
  --shadow-xl: 0 25px 50px -12px rgba(0,0,0,0.18);
}

/* ===== BASE TYPOGRAPHY ===== */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
  scroll-behavior: smooth;
}

h1, h2, h3 {
  font-family: 'Montserrat', 'Inter', sans-serif;
}

/* ===== GLASS HEADER — PREMIUM ===== */
.glass-header {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(220, 38, 38, 0.1);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
  transition: all 0.3s ease;
}

/* ===== HERO PATTERN — RICH DARK RED ===== */
.hero-pattern {
  position: relative;
  background: linear-gradient(135deg, #7f1d1d 0%, #991b1b 35%, #b91c1c 70%, #7f1d1d 100%);
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6zM36 4V0h-2v4h-4v2h4v4h2V6h4V4h-4z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(135deg, #7f1d1d 0%, #991b1b 35%, #b91c1c 70%, #7f1d1d 100%);
  overflow: hidden;
}

.hero-pattern::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 60%;
  height: 200%;
  background: radial-gradient(ellipse at center, rgba(239,68,68,0.15) 0%, transparent 70%);
  pointer-events: none;
}

/* ===== PREMIUM BUTTON ===== */
.btn-premium {
  background: linear-gradient(135deg, #991b1b 0%, #dc2626 50%, #ef4444 100%);
  color: white;
  padding: 1rem 2rem;
  border-radius: 1rem;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: 0.025em;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 25px -5px var(--shadow-red), 0 4px 10px -5px var(--shadow-red);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.btn-premium::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, transparent, rgba(255,255,255,0.15), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}

.btn-premium:hover::after {
  transform: translateX(100%);
}

.btn-premium:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 35px -5px var(--shadow-red), 0 8px 15px -5px var(--shadow-red);
  filter: brightness(1.08);
}

/* ===== PREMIUM CARD ===== */
.card-premium {
  background: white;
  border-radius: 1.5rem;
  padding: 2rem;
  box-shadow: 0 4px 20px -2px rgba(0,0,0,0.08), 0 2px 8px -2px rgba(0,0,0,0.04);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(0, 0, 0, 0.05);
  position: relative;
  overflow: hidden;
}

.card-premium::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #991b1b, #ef4444, #991b1b);
  transform: scaleX(0);
  transition: transform 0.35s ease;
  transform-origin: left;
}

.card-premium:hover::before {
  transform: scaleX(1);
}

.card-premium:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px -8px rgba(153, 27, 27, 0.12), 0 8px 20px -4px rgba(0,0,0,0.08);
  border-color: rgba(220, 38, 38, 0.15);
}

/* ===== PROSE / CONTENT STYLES ===== */
.prose {
  color: #374151;
  font-size: 1.05rem;
  line-height: 1.85;
  font-family: 'Inter', sans-serif;
}

.prose h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 1.5rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.prose h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: #1f2937;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  padding-left: 1rem;
  border-left: 4px solid var(--accent);
  line-height: 1.3;
}

.prose h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: #374151;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.prose p {
  margin-bottom: 1.4rem;
  color: #4b5563;
}

/* ===== RED ACCENT LINK ===== */
.prose a {
  color: var(--accent);
  text-decoration: underline;
  font-weight: 500;
  transition: color 0.2s;
}
.prose a:hover { color: var(--primary-dark); }

/* ===== PREMIUM LIST ===== */
.prose ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: 1.5rem;
}

.prose ul li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 0.85rem;
  color: #4b5563;
  line-height: 1.7;
}

.prose ul li::before {
  content: '\f058';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.95rem;
  top: 0.1rem;
}

.prose ol {
  padding-left: 1.75rem;
  margin-bottom: 1.5rem;
}

.prose ol li {
  margin-bottom: 0.85rem;
  color: #4b5563;
  line-height: 1.7;
  padding-left: 0.5rem;
}

/* ===== PREMIUM TABLE ===== */
.prose table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 2rem 0;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 16px -4px rgba(0,0,0,0.12);
  border: 1px solid rgba(0,0,0,0.06);
}

.prose th {
  background: linear-gradient(135deg, #991b1b 0%, #dc2626 100%);
  color: white;
  padding: 1rem 1.25rem;
  text-align: left;
  font-weight: 700;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.prose td {
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid #f3f4f6;
  color: #374151;
  font-weight: 500;
  transition: background 0.2s;
}

.prose tr:last-child td {
  border-bottom: none;
}

.prose tr:hover td {
  background-color: #fef2f2;
}

.prose tr:nth-child(even) td {
  background-color: #f9fafb;
}

.prose tr:nth-child(even):hover td {
  background-color: #fef2f2;
}

/* ===== STRONG ===== */
.prose strong {
  font-weight: 700;
  color: #1f2937;
}

/* ===== BLOCKQUOTE ===== */
.prose blockquote {
  background: linear-gradient(135deg, #fef2f2, #fff5f5);
  border-left: 4px solid var(--accent);
  border-radius: 0 0.75rem 0.75rem 0;
  padding: 1.25rem 1.5rem;
  margin: 1.75rem 0;
  font-style: italic;
  color: #6b7280;
  box-shadow: 0 2px 8px rgba(220,38,38,0.08);
}

/* ===== ENTRANCE ANIMATIONS ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes shimmer {
  0% { background-position: -1000px 0; }
  100% { background-position: 1000px 0; }
}

@keyframes pulse-red {
  0%, 100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.4); }
  50% { box-shadow: 0 0 0 8px rgba(220, 38, 38, 0); }
}

.animate-fade-up {
  animation: fadeInUp 0.65s cubic-bezier(0.4, 0, 0.2, 1) both;
}

.animate-fade {
  animation: fadeIn 0.5s ease-out forwards;
}

.animate-slide-left {
  animation: slideInLeft 0.6s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@media (prefers-reduced-motion: no-preference) {
  .content-section > p:nth-child(1) { animation: fadeInUp 0.6s 0.05s both; }
  .content-section > p:nth-child(2) { animation: fadeInUp 0.6s 0.15s both; }
  .content-section > h2 { animation: slideInLeft 0.55s 0.1s both; }
  .content-section > ul { animation: fadeInUp 0.6s 0.2s both; }
  .content-section > table { animation: fadeInUp 0.6s 0.25s both; }
}

/* ===== PHONE BUTTON PULSE ===== */
.phone-button {
  animation: pulse-red 2.5s infinite;
  position: relative;
}

/* ===== SECTION BADGE ===== */
.section-badge {
  display: inline-flex;
  align-items: center;
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  color: var(--accent);
  padding: 0.4rem 1rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid rgba(220, 38, 38, 0.2);
  margin-bottom: 0.75rem;
}

/* ===== STAT CARDS ===== */
.stat-card {
  text-align: center;
  padding: 1.5rem;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 1rem;
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
}

.stat-card:hover {
  background: rgba(255,255,255,0.18);
  transform: translateY(-3px);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .prose { font-size: 1rem; }
  .prose h1 { font-size: 1.875rem; }
  .prose h2 { font-size: 1.35rem; margin-top: 2rem; }
  .prose h3 { font-size: 1.15rem; }
  .prose table { font-size: 0.875rem; }
  .prose th, .prose td { padding: 0.75rem 0.875rem; }

  @media (max-width: 520px) {
    .prose thead { display: none; }
    .prose tr { display: block; margin-bottom: 1rem; border: 1px solid #e5e7eb; border-radius: 8px; overflow: hidden; }
    .prose td { display: block; text-align: right; padding: 0.75rem 1rem; border-bottom: 1px solid #f3f4f6; position: relative; padding-left: 45%; }
    .prose td:last-child { border-bottom: none; }
    .prose td::before { content: attr(data-label); position: absolute; left: 1rem; font-weight: 700; color: #1f2937; text-align: left; }
  }
}

/* ===== PRINT ===== */
@media print {
  .glass-header { position: relative; }
  .prose h1, .prose h2, .prose h3 { color: #000; }
  .prose table { box-shadow: none; border: 1px solid #ccc; }
  .prose th { background: #e5e7eb; color: #000; }
}
