/* Rally Media Group - Static Site Styles */

/* CSS Variables */
:root {
  --color-dark: #1a1a2e;
  --color-darker: #0f0f1a;
  --color-green: #43BA46;
  --color-green-hover: #3aa33d;
  --color-green-dark: rgb(3, 125, 32);
  --color-lime: rgba(154, 204, 51, 0.9);
  --color-lime-solid: rgb(154, 204, 51);
  --color-white: #ffffff;
  --color-gray: #b0b0b0;
  --color-light-gray: #f5f5f5;
  --font-primary: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-secondary: 'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --max-width: 1200px;
  --header-height: 80px;
}

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

html {
  scroll-behavior: smooth;
}

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

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

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

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

body {
  font-family: var(--font-secondary);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-dark);
  background-color: var(--color-white);
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}

ul {
  list-style: none;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: 700;
  line-height: 1.2;
}

h1 { font-size: 3rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

@media (max-width: 768px) {
  h1 { font-size: 2.25rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.25rem; }
}

/* Container */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 32px;
  font-family: var(--font-primary);
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: var(--color-green);
  color: var(--color-white);
}

.btn-primary:hover {
  background-color: var(--color-green-hover);
  transform: translateY(-2px);
}

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

.btn-outline:hover {
  background-color: var(--color-white);
  color: var(--color-dark);
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background-color: var(--color-darker);
  z-index: 1000;
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo img {
  height: 50px;
  width: auto;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

.nav {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a,
.nav-links span {
  color: var(--color-white);
  font-family: var(--font-primary);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active,
.nav-links span.active {
  color: var(--color-green);
}

.nav .btn {
  padding: 10px 24px;
  font-size: 0.9rem;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
}

.menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--color-white);
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }

  .nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--color-darker);
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 40px;
    gap: 20px;
    transform: translateX(100%);
    transition: transform 0.3s ease;
  }

  .nav.active {
    transform: translateX(0);
  }

  .nav-links {
    flex-direction: column;
    align-items: center;
    gap: 24px;
  }

  .nav-links a,
  .nav-links span {
    font-size: 1.1rem;
  }
}

/* Green Line Below Header */
.header-border {
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  height: 3px;
  background-color: var(--color-green-dark);
  z-index: 999;
}

/* Hero Section */
.hero {
  min-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
              url('/images/hero-shot-rally-media.png') center/cover no-repeat;
  padding-top: calc(var(--header-height) + 60px);
  padding-bottom: 60px;
  padding-left: 20px;
  padding-right: 20px;
  color: var(--color-white);
}

@media (max-width: 1023px) {
  .hero {
    min-height: 500px;
  }
}

@media (max-width: 767px) {
  .hero {
    min-height: 400px;
  }
}

.hero-content {
  max-width: 800px;
  animation: fadeInUp 1s ease-out;
}

.hero h1 {
  margin-bottom: 24px;
  animation: fadeInUp 0.8s ease-out;
}

.hero p {
  font-size: 1.25rem;
  color: var(--color-white);
  margin-bottom: 40px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

/* Services Section */
.services {
  background-color: var(--color-white);
}

/* White space above banner */
.services-spacer {
  height: 20px;
  background-color: var(--color-white);
}

/* Green Banner Header */
.section-banner {
  background-color: rgba(154, 204, 51, 0.8);
  padding: 20px 20px 21px;
  text-align: center;
  animation: fadeIn 0.6s ease-out;
}

/* Mobile-only line break */
.mobile-break {
  display: none;
}

@media (max-width: 600px) {
  .mobile-break {
    display: block;
  }
}

.section-banner h2 {
  color: var(--color-dark);
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.3);
}

.section-header {
  margin-bottom: 60px;
}

.section-header h2 {
  margin-bottom: 16px;
}

.section-header p {
  color: var(--color-gray);
  max-width: 600px;
  margin: 0 auto;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  padding: 50px 20px 80px;
  max-width: var(--max-width);
  margin: 0 auto;
}

@media (max-width: 900px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

.service-card {
  position: relative;
  background-color: var(--color-white);
  border: 1px solid #ddd;
  padding: 0 20px 20px;
  text-align: center;
  overflow: visible;
  animation: fadeInUp 0.6s ease-out both;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* SVG fancy divider at top of card - exact match from rallymedia.co */
.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 58px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 64' preserveAspectRatio='none'%3E%3Cdefs%3E%3Cstyle%3E.p1{opacity:0.2;}.p2{opacity:0.4;}%3C/style%3E%3C/defs%3E%3Cpolygon class='p1' fill='rgba(154,204,51,0.1)' points='0 0 1000 64 0 64 0 0'/%3E%3Cpolygon class='p2' fill='rgba(154,204,51,0.1)' points='0 64 1000 0 1000 64 0 64'/%3E%3Cpolygon fill='rgba(154,204,51,0.1)' points='0 32 0 64 1000 64 0 32'/%3E%3C/svg%3E");
  background-size: 100% 100%;
  background-repeat: no-repeat;
  transform: rotate(180deg);
}

.service-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-image: linear-gradient(rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.7)), linear-gradient(rgb(154, 204, 51), rgb(154, 204, 51));
  color: var(--color-dark);
  font-family: var(--font-primary);
  font-weight: 700;
  font-size: 16px;
  line-height: 2.5em;
  border-radius: 0;
  box-shadow: rgba(0, 0, 0, 0.18) 0px 12px 13px -2px;
  margin: 0 auto 30px;
  position: relative;
  z-index: 1;
}

.service-card h3 {
  color: rgb(17, 17, 17);
  font-family: -apple-system, "system-ui", "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 24px;
  letter-spacing: -0.4px;
  text-align: center;
  margin: 0;
  padding: 0;
  margin-bottom: 15px;
}

.service-card p {
  color: #444;
  font-size: 1rem;
  line-height: 2em;
  margin: 0;
}

/* CTA Section */
.cta {
  padding: 80px 0;
  background-color: var(--color-dark);
  color: var(--color-white);
  animation: fadeIn 0.8s ease-out;
  text-align: center;
}

.cta h2 {
  margin-bottom: 16px;
}

.cta p {
  color: var(--color-gray);
  margin-bottom: 32px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* About Page Styles */
.page-hero {
  padding: 160px 0 80px;
  background-color: var(--color-dark);
  color: var(--color-white);
  text-align: center;
}

.page-hero h1 {
  margin-bottom: 16px;
}

.page-hero p {
  color: var(--color-gray);
  max-width: 600px;
  margin: 0 auto;
}

.about-section {
  padding: 60px 0;
}

/* Section Title - Green accent */
.section-title {
  color: rgb(154, 204, 51);
  font-size: 2rem;
  margin-bottom: 30px;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 60px;
  height: 3px;
  background: rgb(154, 204, 51);
}

.about-differentiators .section-title::after {
  left: 50%;
  transform: translateX(-50%);
}

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

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

.about-intro-content,
.mission-block,
.differentiator-item {
  animation: fadeInUp 0.6s ease-out forwards;
}

.differentiator-item:nth-child(1) { animation-delay: 0.1s; }
.differentiator-item:nth-child(2) { animation-delay: 0.2s; }
.differentiator-item:nth-child(3) { animation-delay: 0.3s; }
.differentiator-item:nth-child(4) { animation-delay: 0.4s; }

/* Who We Are - Intro Section */
.about-intro {
  background-color: var(--color-white);
}

.about-intro-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.about-intro-content .lead-text {
  font-size: 1.25rem;
  color: #444;
  line-height: 1.8;
  margin-bottom: 20px;
}

.about-intro-content p {
  color: #666;
  line-height: 1.8;
}

/* Intro Quote - green left border blockquote style */
.intro-quote {
  font-size: 1.25rem;
  color: #444;
  line-height: 1.8;
  margin-top: 30px;
  padding-left: 20px;
  border-left: 4px solid rgb(154, 204, 51);
}

.quote-highlight {
  display: block;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-dark);
  margin-top: 12px;
}

/* Mission Section - white background */
.about-mission {
  background-color: var(--color-white);
}

/* Who We Are - grey background */
.about-intro {
  background-color: var(--color-light-gray);
}

.mission-block {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.mission-block .section-title {
  display: block;
  text-align: center;
}

.mission-block .section-title::after {
  left: 50%;
  transform: translateX(-50%);
}

.mission-statement {
  color: var(--color-dark);
  font-size: 2rem;
  font-weight: 500;
  line-height: 1.6;
}

@media (max-width: 768px) {
  .mission-statement {
    font-size: 1.5rem;
  }
}

/* What Sets Us Apart - Differentiators */
.about-differentiators {
  background-color: var(--color-white);
}

.about-differentiators .section-title {
  text-align: center;
  margin-bottom: 50px;
}

.differentiator-list {
  max-width: 900px;
  margin: 0 auto;
}

.differentiator-item {
  display: flex;
  gap: 30px;
  padding: 30px 0;
  border-bottom: 1px solid #eee;
}

.differentiator-item:last-child {
  border-bottom: none;
}

.diff-number {
  font-family: var(--font-primary);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-lime-solid);
  line-height: 1;
  min-width: 60px;
}

.diff-content h3 {
  color: var(--color-dark);
  font-size: 1.25rem;
  margin-bottom: 10px;
}

.diff-content p {
  color: #666;
  line-height: 1.7;
  margin: 0;
}

@media (max-width: 600px) {
  .differentiator-item {
    flex-direction: column;
    gap: 15px;
  }

  .diff-number {
    font-size: 2rem;
  }
}

/* Contact Page Styles */
.contact-section {
  padding: 80px 0;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
}

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

.contact-info h2 {
  margin-bottom: 20px;
}

.contact-info p {
  color: #666;
  margin-bottom: 30px;
}

.contact-details {
  margin-top: 40px;
}

.contact-details h4 {
  margin-bottom: 16px;
}

.contact-details p {
  margin-bottom: 8px;
}

/* Contact Form */
.contact-form {
  background-color: var(--color-light-gray);
  padding: 40px;
  border-radius: 8px;
}

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

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  font-family: var(--font-primary);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: var(--font-secondary);
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-green);
}

.form-group textarea {
  min-height: 150px;
  resize: vertical;
}

.contact-form .btn {
  width: 100%;
}

/* TidyCal Embed */
.tidycal-section {
  padding: 80px 0;
  background-color: var(--color-light-gray);
}

.tidycal-section .container {
  text-align: center;
}

.tidycal-section h2 {
  margin-bottom: 16px;
}

.tidycal-section p {
  color: #666;
  margin-bottom: 40px;
}

.tidycal-embed {
  max-width: 600px;
  margin: 0 auto;
}

/* Legal Pages */
.legal-content {
  padding: 80px 0;
}

.legal-content h1 {
  margin-bottom: 40px;
}

.legal-content h2 {
  margin-top: 60px;
  margin-bottom: 20px;
  font-size: 1.5rem;
}

.legal-content h3 {
  margin-top: 40px;
  margin-bottom: 20px;
  font-size: 1.25rem;
}

.legal-content p {
  font-family: "Hoefler Text", Garamond, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 400;
  line-height: 1.8;
  color: #444;
  margin-bottom: 16px;
}

.legal-content ul {
  font-family: "Hoefler Text", Garamond, "Times New Roman", serif;
  font-size: 22px;
  line-height: 1.8;
  list-style: disc;
  padding-left: 24px;
  margin-bottom: 16px;
}

.legal-content li {
  margin-bottom: 8px;
  color: #444;
}

/* Footer */
.footer {
  background-color: var(--color-darker);
  color: var(--color-white);
  padding: 60px 0 30px;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

.footer-brand p {
  color: var(--color-gray);
  margin-top: 16px;
  max-width: 300px;
}

.footer-links h4,
.footer-contact h4 {
  margin-bottom: 20px;
  font-size: 1rem;
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: var(--color-gray);
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--color-green);
}

.footer-contact p {
  color: var(--color-gray);
  margin-bottom: 8px;
}

.footer-bottom {
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: var(--color-gray);
  font-size: 0.9rem;
}

/* Utility Classes */
.text-center { text-align: center; }
.text-green { color: var(--color-green); }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
.mt-40 { margin-top: 40px; }
.mb-40 { margin-bottom: 40px; }

/* 404 page: fill the viewport so the footer sits at the bottom */
.page-404 {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-404 .page-hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
