/* ═══════════════════════════════════════════════════════════════════
   Blue Penguin Digital v3 — Component Classes
   Extends theme-v4.css component layer. Project-specific components.
   ═══════════════════════════════════════════════════════════════════ */

/* ── Container ─────────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, 2.5rem);
}

/* ── Sections ───────────────────────────────────────── */
.section {
  padding: clamp(3rem, 6vw, 5rem) 0;
}

.section-label {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-heading {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 700;
  color: var(--color-permafrost);
  line-height: 1.2;
  margin-bottom: 0.5rem;
}

/* ── Page Hero (inner pages) ───────────────────────── */
.page-hero {
  padding: clamp(3rem, 8vw, 6rem) 0 clamp(2rem, 6vw, 4rem);
  text-align: center;
}

.page-hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
  color: var(--text);
}

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

.lede {
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  line-height: 1.6;
  color: var(--text-soft);
  max-width: 620px;
}

.lede-center {
  margin-left: auto;
  margin-right: auto;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  justify-content: center;
  margin-top: 2rem;
}

/* ── Homepage Hero ──────────────────────────────────── */
.hero-home {
  padding: clamp(4rem, 10vw, 8rem) 0 clamp(3rem, 8vw, 6rem);
  text-align: center;
}

.hero-home h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  color: var(--text);
  max-width: 840px;
  margin: 0 auto 1.25rem;
}

.hero-home .lede {
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 2.5rem;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  justify-content: center;
  margin-top: 3rem;
  font-size: 14px;
  color: var(--muted);
}

.hero-trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-trust-item .icon {
  font-size: 18px;
}

/* ── Buttons ────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 100px;
  font-weight: 600;
  font-size: 15px;
  font-family: var(--font-body);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
  text-decoration: none;
  cursor: pointer;
  border: 1.5px solid transparent;
  min-height: 44px;
}

.btn:active {
  transform: scale(0.97);
}

.btn-accent {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-accent:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-ghost {
  background: transparent;
  color: var(--text-soft);
}

.btn-ghost:hover {
  background: var(--bg-pane);
  color: var(--text);
}

.btn-white {
  background: #fff;
  color: var(--color-navy);
  border-color: #fff;
}

.btn-white:hover {
  background: var(--color-permafrost);
  border-color: var(--color-permafrost);
}

.btn-lg {
  padding: 14px 36px;
  font-size: 16px;
}

/* ── Cards ──────────────────────────────────────────── */
.card {
  background: var(--color-card);
  border-radius: 16px;
  border: 1px solid var(--line);
  padding: clamp(1.5rem, 3vw, 2rem);
}

.card-interactive {
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.card-interactive:hover {
  box-shadow: var(--shadow-level-2);
  transform: translateY(-2px);
}

/* ── Case Study Cards ──────────────────────────────── */
.cs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

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

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

.cs-card {
  padding: 0;
  overflow: hidden;
}

.cs-card-image {
  aspect-ratio: 3 / 2;
  overflow: hidden;
}

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

.cs-card h3 {
  padding: 16px 20px 0;
  margin: 0;
  font-size: 1.1rem;
}

.cs-card .cs-card-outcome {
  padding: 4px 20px 0;
  font-size: 14px;
  color: var(--text-soft);
  margin: 0;
}

.cs-card .card-link {
  display: block;
  padding: 12px 20px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.cs-card .card-link:hover {
  color: var(--accent-hover);
}

/* ── Service Cards ──────────────────────────────────── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

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

.service-card h3 {
  margin-bottom: 8px;
}

.service-card p {
  font-size: 14px;
  color: var(--text-soft);
  margin-bottom: 16px;
}

/* ── Testimonials ───────────────────────────────────── */
.testimonial-card {
  text-align: center;
  max-width: 680px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.testimonial-card blockquote {
  font-size: clamp(1.125rem, 2vw, 1.35rem);
  line-height: 1.6;
  font-style: italic;
  color: var(--text);
  margin: 0 0 1rem;
}

.testimonial-card .stars {
  color: var(--accent);
  font-size: 14px;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.testimonial-card cite {
  font-style: normal;
  font-weight: 600;
  font-size: 14px;
  color: var(--text-soft);
}

/* ── Process Steps ──────────────────────────────────── */
.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

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

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

.process-step {
  text-align: center;
}

.process-step .step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-pane);
  color: var(--accent);
  font-weight: 700;
  font-size: 18px;
  font-family: var(--font-mono);
  margin-bottom: 16px;
}

.process-step h4 {
  font-size: 1rem;
  margin-bottom: 8px;
}

.process-step p {
  font-size: 14px;
  color: var(--text-soft);
}

/* ── CTA Bar ────────────────────────────────────────── */
.section-navy {
  background: var(--color-navy);
}

.cta-bar {
  text-align: center;
  padding: clamp(3rem, 6vw, 5rem) 0;
}

.cta-bar h2 {
  color: var(--color-permafrost);
}

.cta-bar .cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 1.5rem;
}

.cta-bar .btn-secondary {
  color: var(--color-permafrost);
  border-color: rgba(255, 255, 255, 0.2);
}

.cta-bar .btn-secondary:hover {
  border-color: var(--color-permafrost);
  color: #fff;
}

/* ── Two-Column Page Layout ────────────────────────── */
.page-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 48px;
  align-items: start;
}

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

/* ── Contact Form ───────────────────────────────────── */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  font-size: 16px; /* Prevents iOS zoom */
  font-family: var(--font-body);
  background: var(--color-card);
  color: var(--text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  min-height: 44px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.15);
}

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

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none' stroke='%23475569' stroke-width='2'%3E%3Cpath d='M3 5l3 3 3-3'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

/* ── Blog Grid ──────────────────────────────────────── */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

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

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

.blog-card {
  background: var(--color-card);
  border-radius: 16px;
  border: 1px solid var(--line);
  overflow: hidden;
  transition: box-shadow 0.3s ease;
}

.blog-card:hover {
  box-shadow: var(--shadow-level-2);
}

.blog-card-image {
  aspect-ratio: 3 / 2;
  overflow: hidden;
}

.blog-card-body {
  padding: 20px;
}

.blog-card-date {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 8px;
}

.blog-card-body h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.blog-card-body h3 a {
  color: var(--text);
  text-decoration: none;
}

.blog-card-body h3 a:hover {
  color: var(--accent);
}

.blog-card-body p {
  font-size: 14px;
  color: var(--text-soft);
}

/* ── Page Content (blog posts, case studies) ────────── */
.page-content {
  padding-bottom: clamp(3rem, 6vw, 5rem);
}

.page-content h2 {
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  margin-top: 2.5rem;
  margin-bottom: 0.75rem;
}

.page-content h3 {
  font-size: 1.25rem;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

.page-content p,
.page-content li {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-soft);
  margin-bottom: 1rem;
}

.page-content ul,
.page-content ol {
  padding-left: 1.25rem;
  margin-bottom: 1.5rem;
}

/* ── 404 ────────────────────────────────────────────── */
.page-404 {
  padding: clamp(5rem, 12vw, 10rem) 0;
  text-align: center;
}

.page-404 .code {
  font-size: clamp(5rem, 12vw, 8rem);
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--line);
  line-height: 1;
  margin-bottom: 1rem;
}

.page-404 h1 {
  margin-bottom: 1rem;
}

/* ── Inline link ────────────────────────────────────── */
.inline-link {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 500;
}

.inline-link:hover {
  color: var(--accent-hover);
}

/* ── Scroll Reveal ──────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ── Pricing Cards ───────────────────────────────────── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}

@media (max-width: 768px) {
  .pricing-grid { grid-template-columns: 1fr; max-width: 440px; margin: 0 auto; }
}

.pricing-card {
  background: var(--color-card);
  border-radius: 16px;
  border: 1px solid var(--line);
  padding: 32px 28px;
  text-align: center;
}

.pricing-card.featured {
  border-color: var(--accent);
  box-shadow: var(--shadow-level-2);
  position: relative;
}

.pricing-card .pricing-name {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 12px;
}

.pricing-card .price {
  font-family: var(--font-mono);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.pricing-card .price-period {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 24px;
}

.pricing-card .pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 24px;
}

.pricing-card .pricing-features li {
  padding: 8px 0;
  font-size: 14px;
  color: var(--text-soft);
  border-bottom: 1px solid var(--line);
}

.pricing-card .pricing-features li:last-child {
  border-bottom: none;
}
.footer-company-name {
  color: #FFFFFF;
  font-size: 16px;
}

/* ── Mobile Accordion ───────────────────────────────────────── */

/* ── Mobile Nav Accordion (CSS Grid — no inline styles) ─── */

[data-mobile-accordion-panel] {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.3s ease;
}

[data-mobile-accordion-panel] > * {
  overflow: hidden;
}

[data-mobile-accordion-panel].accordion-open {
  grid-template-rows: 1fr;
}

[data-mobile-accordion-chevron] {
  transition: transform 0.2s ease;
}

.chevron-open {
  transform: rotate(180deg);
}

/* ── Desktop Nav Dropdown ──────────────────────────────────── */

[data-nav-dropdown-group] {
  position: relative;
}

[data-nav-dropdown-panel] {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translate(-50%, -8px);
  min-width: 200px;
  width: max-content;
  margin-top: 8px;
  background: #0F172A;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease,
    visibility 0s linear 0.2s;
}

[data-nav-dropdown-panel] a {
  display: block;
  padding: 10px 16px;
  font-size: 14px;
  color: rgba(240, 244, 248, 0.8);
  font-weight: 500;
  border-radius: 8px;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s, color 0.15s;
}

[data-nav-dropdown-panel] a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

[data-nav-dropdown-group].is-open [data-nav-dropdown-panel] {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translate(-50%, 0);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease,
    visibility 0s linear 0s;
}

[data-nav-dropdown-group].is-open [data-nav-dropdown-chevron] {
  transform: rotate(180deg);
}

@media (prefers-reduced-motion: reduce) {
  [data-nav-dropdown-panel] {
    transition: none;
  }
}

/* ═══════════════════════════════════════════════════════════════════
   Portfolio Case Study — Accudo Orb Animation
   ═══════════════════════════════════════════════════════════════════ */
@keyframes orb-breathe {
  0%, 100% {
    transform: scale(1);
    opacity: 0.85;
  }
  50% {
    transform: scale(1.08);
    opacity: 1;
  }
}

@keyframes spin-slow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes reverse-spin {
  0% { transform: rotate(360deg); }
  100% { transform: rotate(0deg); }
}

@keyframes orb-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.animate-orb-breathe {
  animation: orb-breathe 4s ease-in-out infinite;
}

.animate-spin-slow {
  animation: spin-slow 12s linear infinite;
}

.animate-reverse-spin {
  animation: reverse-spin 15s linear infinite;
}

.animate-orb-float {
  animation: orb-float 6s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .animate-orb-breathe,
  .animate-spin-slow,
  .animate-reverse-spin,
  .animate-orb-float {
    animation: none;
  }
}

/* ── Floating WhatsApp Button ──────────────────── */
.whatsapp-float {
  position: fixed;
  right: 1.25rem;
  bottom: 6rem; /* clears cookie banner on mobile */
  z-index: 45;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 24px rgba(37, 211, 102, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  color: white;
  font-size: 1.75rem;
  text-decoration: none;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 32px rgba(37, 211, 102, 0.5);
}

.whatsapp-float:focus-visible {
  outline: 2px solid #25D366;
  outline-offset: 2px;
}

/* Pulse ring */
.whatsapp-float::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #25D366;
  opacity: 0.25;
  animation: wa-pulse 2s cubic-bezier(0, 0, 0.2, 1) infinite;
  pointer-events: none;
}

@keyframes wa-pulse {
  0% { transform: scale(1); opacity: 0.35; }
  75%, 100% { transform: scale(1.8); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .whatsapp-float::before {
    animation: none;
  }
}

@media (min-width: 768px) {
  .whatsapp-float {
    bottom: 1.5rem;
  }
}
