/**
 * styles.css - Custom Styling Utilities
 * Project: CompliancesNext
 */

:root {
  --font-family-base:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;

  /* Global Font Sizes */
  --font-size-base: 16px;
  --font-size-small: 14px;
  --font-size-large: 18px;

  --font-size-h1: 2.25rem;
  --font-size-h2: 1.85rem;
  --font-size-h3: 1.5rem;
  --font-size-h4: 1.25rem;
  --font-size-h5: 1.1rem;
  --font-size-h6: 1rem;

  --line-height-base: 1.6;
  --line-height-heading: 1.25;
}

/* Apply same font everywhere */
html {
  font-size: 16px;
  overflow-x: hidden;
}

body {
  font-family: var(--font-family-base);
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  font-weight: 400;
  color: #0f172a;

  padding-top: 80px;

  display: flex;
  flex-direction: column;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Headings - Same across every page */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-family-base);
  line-height: var(--line-height-heading);
  margin-top: 0;
}

h1 {
  font-size: var(--font-size-h1);
  font-weight: 700;
}

h2 {
  font-size: var(--font-size-h2);
  font-weight: 700;
}

h3 {
  font-size: var(--font-size-h3);
  font-weight: 600;
}

h4 {
  font-size: var(--font-size-h4);
  font-weight: 600;
}

h5 {
  font-size: var(--font-size-h5);
  font-weight: 600;
}

h6 {
  font-size: var(--font-size-h6);
  font-weight: 600;
}

p {
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  margin-top: 0;
}

a {
  font-family: inherit;
  font-size: inherit;
}

button,
input,
select,
textarea {
  font-family: inherit;
}

button,
.btn {
  font-size: var(--font-size-base);
}

small,
.small {
  font-size: var(--font-size-small) !important;
}

.lead {
  font-size: var(--font-size-large);
  line-height: 1.6;
}

.transition-hover {
  transition:
    transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.transition-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px -10px rgba(15, 23, 42, 0.12) !important;
}

@keyframes skeleton-glow {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

.skeleton-loading {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: skeleton-glow 1.5s infinite linear;
}

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

header {
  width: 100%;
}

footer {
  width: 100%;
  margin-top: auto;
  background: #151515;
}

img {
  max-width: 80%;
}

a,
button,
input,
select,
textarea {
  min-width: 0;
}

.card,
.accordion-button,
.form-control,
.form-select,
.btn {
  overflow-wrap: anywhere;
}

.navbar {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 9999;
  margin: 0;
}

.navbar-brand {
  min-width: 0;
}

.navbar-with-separator {
  border-bottom: 2px solid #ffffff;
}

.navbar-logo-container {
  position: relative;
  width: 280px;
  height: 50px;
  overflow: hidden;
  flex-shrink: 0;
}

.navbar-logo {
  position: absolute;
  width: 280px;
  height: 280px;
  max-width: none;
  object-fit: contain;
  left: 0;
  top: 50%;
  transform: translateY(-50%) scale(1.32);
  transform-origin: center center;
}

@media (max-width: 768px) {
  .navbar-logo-container {
    width: 240px;
    height: 50px;
  }

  .navbar-logo {
    width: 240px;
    height: 240px;
  }
}
.brand-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-gradient {
  color: #ffffff;
  min-height: 520px;
  background-image: url("https://speakers-team.s3.us-east-1.amazonaws.com/Banner+CS.jpeg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hover-opacity:hover {
  opacity: 0.8 !important;
}

.hover-underline-theme {
  transition: color 0.2s ease;
}

.hover-underline-theme:hover {
  color: var(--secondary-color) !important;
  text-decoration: underline !important;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.card-theme {
  border-top: 4px solid var(--secondary-color);
  background: var(--card-bg);
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.webinar-card {
  position: relative;
}

.webinar-live-dot {
  position: absolute;
  top: 1rem;
  right: 1rem;

  width: 0.75rem;
  height: 0.75rem;

  border-radius: 999px;
  background: #dc2626;

  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12);
}

.webinar-live-dot.is-live {
  background: #22c55e;

  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.16);

  animation: live-pulse 1.35s ease-in-out infinite;
}

@keyframes live-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.45);
  }

  70% {
    box-shadow: 0 0 0 9px rgba(34, 197, 94, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
}

.session-description-scroll {
  max-height: 360px;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.recent-webinars-carousel {
  --carousel-control-size: 2.75rem;
  padding: 0 3.5rem;
}

.recent-webinars-carousel .carousel-control-prev,
.recent-webinars-carousel .carousel-control-next {
  width: var(--carousel-control-size);
  height: var(--carousel-control-size);

  top: 50%;
  transform: translateY(-50%);

  border-radius: 999px;
  background: var(--primary-color);

  opacity: 1;
}

.recent-webinars-carousel .carousel-control-prev {
  left: 0;
}

.recent-webinars-carousel .carousel-control-next {
  right: 0;
}

.recent-webinar-slide {
  min-height: 190px;
  justify-content: center;

  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);

  border-left: 4px solid var(--secondary-color) !important;
}

.footer-logo-container {
  position: relative;
  width: 280px;
  height: 50px;
  overflow: hidden;
  flex-shrink: 0;
}

.footer-logo {
  position: absolute;
  width: 280px;
  height: 280px;
  max-width: none;
  object-fit: contain;
  left: 0;
  top: calc(50% - 12px);
  transform: translateY(-50%) scale(1.32);
  transform-origin: center center;
}

@media (max-width: 768px) {
  .footer-logo-container {
    width: 240px;
    height: 50px;
  }

  .footer-logo {
    width: 240px;
    height: 240px;
  }
}

@media (min-width: 992px) {
  .buy-box {
    position: sticky;
    top: 24px;
  }
}

@media (max-width: 991.98px) {
  .buy-box {
    position: static !important;
    margin-top: 1.5rem;
  }
}

@media (max-width: 768px) {
  /* Keep typography consistent */
  html {
    font-size: 16px;
  }

  body {
    font-size: 16px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.7rem;
  }

  h3 {
    font-size: 1.4rem;
  }

  h4 {
    font-size: 1.2rem;
  }

  h5 {
    font-size: 1.05rem;
  }

  h6 {
    font-size: 1rem;
  }

  p {
    font-size: 16px;
  }

  .lead {
    font-size: 17px;
  }

  .display-3 {
    font-size: 2.35rem !important;
    line-height: 1.2;
  }

  .display-4 {
    font-size: 2rem !important;
  }

  .card {
    padding: 1.5rem !important;
  }

  .text-md-end {
    text-align: left !important;
    margin-top: 1rem;
  }

  .navbar-collapse {
    padding-top: 1rem;
  }

  .navbar-nav .nav-link {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .hero-gradient {
    min-height: auto;
  }

  .view-toggle {
    display: flex;
    width: 100%;
  }

  .view-toggle .btn {
    flex: 1 1 0;
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
    white-space: nowrap;
  }

  .webinar-card-actions {
    width: 100%;
  }

  .webinar-card-actions .btn {
    width: 100%;
  }

  .webinar-live-dot {
    top: 0.9rem;
    right: 0.9rem;
  }

  .session-description-scroll {
    max-height: 300px;
  }

  .recent-webinars-carousel {
    padding: 0;
  }

  .recent-webinars-carousel .carousel-control-prev,
  .recent-webinars-carousel .carousel-control-next {
    display: none;
  }

  .speaker-summary {
    align-items: flex-start !important;
  }

  .checkout-coupon {
    flex-direction: column;
  }

  .checkout-coupon .btn {
    width: 100%;
  }
}

@media (max-width: 575.98px) {
  html {
    font-size: 16px;
  }

  body {
    font-size: 16px;
  }

  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .card {
    padding: 1.15rem !important;
    border-radius: 0.85rem !important;
  }

  main.container,
  .container.py-5 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }

  .display-3 {
    font-size: 2rem !important;
  }

  .lead {
    font-size: 16px;
  }

  .hero-gradient .btn {
    width: 100%;
  }

  .hero-gradient .container {
    text-align: left !important;
  }

  .hero-gradient .d-flex {
    justify-content: stretch !important;
  }

  .accordion-button {
    padding-left: 0;
    padding-right: 0;
    line-height: 1.35;
  }

  .footer-payments {
    flex-wrap: wrap;
  }

  .footer-payments img {
    object-fit: contain;
    display: inline-block;
  }

  footer .input-group {
    display: block;
    border: 0 !important;
    overflow: visible !important;
  }

  footer .input-group .form-control,
  footer .input-group .btn {
    width: 100%;
    border-radius: 0.5rem !important;
  }

  footer .input-group .btn {
    margin-top: 0.5rem;
  }

  .btn-proceed {
    padding-top: 0.85rem !important;
    padding-bottom: 0.85rem !important;
    font-size: 0.95rem;
  }

  #processing-view,
  #success-view,
  #error-view {
    box-shadow: 0 0.5rem 1.5rem rgba(15, 23, 42, 0.08) !important;
  }

  #success-view .justify-content-between {
    align-items: flex-start !important;
    gap: 0.35rem;
  }
}
/* =========================================
   UNIVERSAL BUTTON CLICK FIX
   ========================================= */

button,
.btn,
button:hover,
.btn:hover,
button:focus,
.btn:focus,
button:focus-visible,
.btn:focus-visible,
button:active,
.btn:active,
button.active,
.btn.active {
  outline: none !important;
}

/* Prevent Bootstrap from changing button appearance on click */
button:active,
.btn:active {
  color: inherit;
}

/* Keep custom button background on click */
.btn-primary:active,
.btn-primary:focus,
.btn-primary:focus-visible {
  background-color: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
  color: #fff !important;
}

.btn-secondary:active,
.btn-secondary:focus,
.btn-secondary:focus-visible {
  background-color: var(--secondary-color) !important;
  border-color: var(--secondary-color) !important;
  color: #fff !important;
}

.btn-success:active,
.btn-success:focus,
.btn-success:focus-visible {
  background-color: #198754 !important;
  border-color: #198754 !important;
  color: #fff !important;
}

.btn-danger:active,
.btn-danger:focus,
.btn-danger:focus-visible {
  background-color: #dc3545 !important;
  border-color: #dc3545 !important;
  color: #fff !important;
}

.btn-dark:active,
.btn-dark:focus,
.btn-dark:focus-visible {
  background-color: #212529 !important;
  border-color: #212529 !important;
  color: #fff !important;
}

/* Remove Bootstrap focus glow if unwanted */
.btn:focus,
.btn:focus-visible {
  box-shadow: none !important;
}

/* Webinar card hover */
.webinar-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 18px;
  bottom: 18px;
  width: 3px;
  border-radius: 0 5px 5px 0;
  background: var(--secondary-hover);
  transform: scaleY(0);
  transform-origin: center;
  transition: transform 0.3s ease;
}

.webinar-card:hover {
  transform: translateY(-4px);
  border-color: rgba(200, 0, 0, 0.14) !important;
  box-shadow:
    0 15px 35px rgba(15, 23, 42, 0.09),
    0 3px 10px rgba(200, 0, 0, 0.04) !important;
}

.webinar-card:hover::before {
  transform: scaleY(1);
}

/* Testimonials Slide */
.testimonial-slider {
  overflow: hidden;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}

.testimonial-track {
  display: flex;
  transition: transform 0.7s ease-in-out;
}

.testimonial-slide {
  flex: 0 0 50%;
  width: 50%;
  padding: 0 2px;
  box-sizing: border-box;
}

/* Image Size */
.testimonial-image {
  width: 100%;
  max-width: 360px;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 14px;
  object-fit: contain;
}

/* =========================
   DOTS
========================= */

.testimonial-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 25px;
}

.testimonial-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: #cbd5e1;
  cursor: pointer;
  transition: all 0.3s ease;
}

.testimonial-dots button.active {
  width: 24px;
  border-radius: 10px;
  background: #0b99e0;
}

/* =========================
   MOBILE
========================= */

@media (max-width: 767.98px) {
  .testimonial-slider {
    max-width: 100%;
  }

  .testimonial-slide {
    flex: 0 0 100%;
    width: 100%;
    padding: 0 20px;
  }

  .testimonial-image {
    width: 100%;
    max-width: 380px;
  }

  .testimonial-dots {
    margin-top: 20px;
  }
}
