/* 
 * SmartContext by Damibu - One Pager Styles - Optimized Version
 * 
 * A clean, professional stylesheet for the Contextor landing page.
 * Improved for accessibility and simplified for better maintainability.
 */

/* ===== CSS Variables ===== */
:root {
  /* Base font size - all rem values will scale from this */
  font-size: 16px;

  /* Responsive spacing that adapts to viewport */
  --space-unit: clamp(0.75rem, 2vw, 1.5rem);
  --space-xs: calc(var(--space-unit) * 0.5);
  --space-s: calc(var(--space-unit));
  --space-m: calc(var(--space-unit) * 2);
  --space-l: calc(var(--space-unit) * 3);
  --space-xl: calc(var(--space-unit) * 4);

  /* Damibu Brand Colors */

  --brand-gradient: linear-gradient(135deg, #6C63FF, #FF6584);
  --primary: #031756;
  --header-gradient: linear-gradient(315deg, #8B00CC, #172E74);
  --tooltip-gradient: linear-gradient(135deg, rgb(227, 226, 255), rgb(255, 224, 231));


  --gradient-light: linear-gradient(135deg, #e3e2ff, #ffe0e7);
  --gradient-brand: linear-gradient(135deg, #6c63ff, #ff6584);
  --gradient-alt: linear-gradient(315deg, #8B00CC, #172E74);
  --gradient-dark: linear-gradient(135deg, rgb(3, 0, 63), rgb(65, 0, 16));
  --gradient-feedback: linear-gradient(64deg, #FFCC40 0%, #FFFCA1 100%);
  --gradient-green: linear-gradient(-128deg, #0C9900 0%, #074e00 100%);

  /* Color Palette */
  --primary-color: #6C63FF;
  --secondary-color: #FF6584;
  --accent-color: #0C9900;
  --dark-blue: #172E74;
  --light-blue: #E3E2FF;
  --light-pink: #FFE0E7;
  --dark-text: #070811;
  --light-text: #777777;
  --white: #FFFFFF;
  --off-white: #F8F9FA;
  --light-gray: #E9ECEF;
  --medium-gray: #DEE2E6;

  /* Typography - Fluid font sizes using clamp */
  --font-size-xxs: clamp(0.625rem, 0.75vw, 0.75rem);
  --font-size-xs: clamp(0.75rem, 1vw, 0.875rem);
  --font-size-s: clamp(0.875rem, 1.5vw, 1rem);
  --font-size-m: clamp(1rem, 2vw, 1.125rem);
  --font-size-l: clamp(1.25rem, 2.5vw, 1.5rem);
  --font-size-xl: clamp(1.5rem, 3vw, 2rem);
  --font-size-xxl: clamp(2rem, 4vw, 2.5rem);

  /* Typography - font families */
  --heading-font: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  --body-font: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;

  /* Effects */
  --box-shadow: 0 0 1rem rgba(0, 0, 0, 0.25);
  --transition: all 0.3s ease;

  /* Container */
  --container-width: min(90%, 75rem);
}

/* ===== Base Styles ===== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--body-font);
  font-size: var(--font-size-m);
  line-height: 1.6;
  color: var(--dark-text);
  background-color: var(--white);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--heading-font);
  margin-bottom: var(--space-s);
  color: var(--dark-blue);
  line-height: 1.3;
}

h1 {
  font-size: var(--font-size-xxl);
}

h2 {
  font-size: var(--font-size-xl);
}

h3 {
  font-size: var(--font-size-l);
}

p {
  margin-bottom: var(--space-s);
}

a {
  color: var(--dark-blue);
  text-decoration: none;
  transition: var(--transition);
}

a:hover,
a:focus {
  color: var(--dark-blue);
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ===== Core classes ===== */
.btn {
  display: inline-block;
  font-family: var(--body-font);
  font-weight: 600;
  font-size: var(--font-size-m);
  cursor: pointer;
  border-radius: 0.25rem;
  transition: var(--transition);
  padding: 0.75rem 1.5rem;
  text-align: center;
  border: none;
  margin: 0.5rem;
}

.btn:hover,
.btn:focus {
  transform: translateY(-2px);
  box-shadow: 0 0.3rem 0.9rem rgba(0, 0, 0, 0.1);
  text-decoration: none;
}

.box {
  display: flex;
  padding: 1rem 1.5rem;
  border-radius: 0.5rem;
  box-shadow: var(--box-shadow);
  font-weight: 600;
}

.primary {
  background-color: var(--accent-color);
  color: var(--white);
}

.primary:hover {
  color: var(--white);
  opacity: 0.9;
}

.secondary {
  background-color: var(--light-gray);
  color: var(--dark-text);
}

.secondary:hover {
  color: var(--dark-text);
  opacity: 0.9;
}

.brand {
  background: var(--gradient-brand);
  color: var(--white);
}

.brand:hover {
  /* color: var(--dark-text); */
  opacity: 0.9;
}

.brand-light {
  background: var(--gradient-light);
  color: var(--dark-text);
}

.brand-light:hover {
  color: var(--dark-text);
  opacity: 0.9;
}

.offwhite {
  background: var(--off-white);
  color: var(--dark-text);
}

.offwhite:hover {
  color: var(--dark-text);
  opacity: 0.9;
}

.feedback {
  background: var(--gradient-feedback);
  color: var(--dark-text);
}

.warning {
  background: #740000;
  color: var(--white);
}

.green {
  background: var(--gradient-green);
  color: var(--white);
}

.gradient-text {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}



/* ===== Layout Components ===== */
.container {
  width: var(--container-width);
  margin: 0 auto;
}

.section {
  padding: var(--space-xl) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--space-m);
  position: relative;
  font-weight: 700;
}

.section-title::after {
  content: '';
  display: block;
  width: 3.75rem;
  height: 0.25rem;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  margin: 0.9rem auto 0;
  border-radius: 0.125rem;
}

.section-description {
  text-align: center;
  max-width: 50rem;
  margin: 0 auto var(--space-m);
  font-size: var(--font-size-m);
}

.content-columns {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-m);
}

.column {
  flex: 1 1 min(100%, 25rem);
}

/* ===== Grid Layouts ===== */
.grid {
  display: grid;
  gap: clamp(1rem, 3vw, 1.9rem);
}

.grid--2col {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18.75rem), 1fr));
}

.grid--3col {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15.625rem), 1fr));
}

.grid--4col {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 12.5rem), 1fr));
}

/* ===== Card Components ===== */
.card {
  border-radius: 0.5rem;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
}

.card:hover,
.card:focus-within {
  transform: translateY(-0.3rem);
  box-shadow: 0 0.9rem 1.9rem rgba(0, 0, 0, 0.1);
}

.card-header {
  padding: var(--space-s);
  display: flex;
  align-items: center;
  gap: var(--space-s);
  flex-wrap: wrap;
}

.card-body {
  padding: var(--space-s);
}

.image {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--box-shadow);
  max-width: 100%;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.image:hover {
  transform: scale(1.02);
  box-shadow: 0 0.9rem 1.9rem rgba(0, 0, 0, 0.15);
}

/* ===== Header Styles ===== */
.site-header {
  padding: var(--space-s) 0;
  background-color: var(--dark-blue);
  position: relative;
  z-index: 100;
  container-type: inline-size;
}

.logo-container {
  display: flex;
  align-items: center;
}

.logo {
  width: 3.125rem;
  height: 3.125rem;
  margin-right: 0.9rem;
}

.site-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin: 0;
  color: white;
  font-weight: 700;
}

@container (max-width: 480px) {
  .header-cta {
    display: none;
  }
}


/* ===== Hero Section ===== */
.hero {
  padding: var(--space-xl) 0;
  position: relative;
  overflow: hidden;
}

.hero .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3.75rem);
}

.hero-content {
  flex: 1 1 min(100%, 25rem);
}

.hero-image {
  flex: 1 1 min(100%, 25rem);
}

/* Hero Video Styles */
.hero-video-container {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--box-shadow);
  max-width: 100%;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-video-container:hover {
  transform: scale(1.02);
  box-shadow: 0 0.9rem 1.9rem rgba(0, 0, 0, 0.15);
}

.hero-video {
  width: 100%;
  display: block;
  border-radius: 1rem;
}

/* ===== Stat Cards Styling ===== */

.stat-percentage {
  flex-shrink: 0;
}

.stat-circle {
  width: 5rem;
  height: 5rem;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0.3rem 0.9rem rgba(0, 0, 0, 0.1);
}

.stat-number {
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--dark-blue);
}

.stat-title {
  color: var(--white);
  margin: 0;
  font-size: var(--font-size-l);
  line-height: 1.3;
  flex: 1;
  min-width: 10rem;
}

.stat-source {
  font-size: var(--font-size-xxs);
  border-top: 1px solid var(--light-gray);
  padding-top: 0.625rem;
  text-align: right;
}

/* ===== Feature Cards ===== */
.feature-icon {
  margin-bottom: var(--space-s);
}

.feature-icon svg {
  width: 3.75rem;
  height: 3.75rem;
}

/* ===== List Styles ===== */
.custom-list {
  margin: var(--space-s) 0;
  padding-left: 1.25rem;
}

.custom-list li {
  margin-bottom: 0.75rem;
  position: relative;
  list-style-type: none;
  padding-left: 1.6rem;
}

.check-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-weight: bold;
}

.arrow-list li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
}

.dot-list li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-size: 1.25rem;
}

/* ===== Form Elements ===== */
.form-group {
  margin-bottom: var(--space-s);
}

.form-group label {
  display: block;
  margin-bottom: 0.3rem;
  font-weight: 500;
  color: var(--dark-text);
}

.form-control {
  width: 100%;
  padding: 0.625rem 0.9rem;
  border: 1px solid var(--medium-gray);
  border-radius: 0.25rem;
  font-family: var(--body-font);
  font-size: var(--font-size-m);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.125rem rgba(108, 99, 255, 0.2);
}

textarea.form-control {
  min-height: 7.5rem;
}

/* URL input form */
.url-input-container {
  display: flex;
  flex-wrap: wrap;
  max-width: 37.5rem;
  margin: 0 auto;
  gap: 0.625rem;
}

/* ===== Footer ===== */
.site-footer {
  padding: 3.75rem 0 1.9rem;
  background-color: var(--dark-blue);
  color: var(--white);
}

.footer-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15.625rem), 1fr));
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.footer-logo {
  width: 7.5rem;
  height: auto;
  margin-bottom: 0.3rem;
}

.footer-column h4 {
  color: var(--white);
  margin-bottom: var(--space-s);
  font-size: var(--font-size-l);
  position: relative;
  padding-bottom: 0.625rem;
}

.footer-column h4::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 1.9rem;
  height: 0.125rem;
  background-color: var(--secondary-color);
}

.footer-links {
  list-style-type: none;
}

.footer-links li {
  margin-bottom: 0.625rem;
}

.footer-links a {
  color: var(--light-gray);
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--white);
  text-decoration: underline;
}

address {
  font-style: normal;
  line-height: 1.6;
}

address p {
  margin-bottom: 0.3rem;
}

address a {
  color: var(--light-gray);
}

address a:hover {
  color: var(--white);
}

.copyright {
  text-align: center;
  padding-top: 1.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: var(--font-size-xs);
  color: var(--light-gray);
}

/* ===== Accessibility Improvements ===== */
:focus {
  outline: 0.125rem solid var(--primary-color);
  outline-offset: 0.125rem;
}

.screen-reader-text {
  position: absolute;
  width: 0.0625rem;
  height: 0.0625rem;
  padding: 0;
  margin: -0.0625rem;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Skip to content link */
.skip-link {
  position: absolute;
  top: -4.5rem;
  left: 0;
  background-color: var(--primary-color);
  color: white;
  padding: 0.5rem 1rem;
  z-index: 999;
  transition: top 0.3s ease;
}

.skip-link:focus {
  top: 0;
}

/* Focus styles for interactive elements */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus,
[tabindex]:focus {
  outline: 3px solid var(--primary-color);
  outline-offset: 3px;
}



.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.step {
  text-align: center;
  position: relative;
}

.step-number {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--secondary-color);
  color: var(--white);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
}

.step-icon {
  background-color: var(--white);
  width: 100px;
  height: 100px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  box-shadow: var(--box-shadow);
}

.step-svg {
  width: 60px;
  height: 60px;
}

.step h3 {
  margin-bottom: 15px;
}



.website-owner-note {
  background: var(--gradient-light);
  border-radius: 8px;
  padding: 25px 30px;
  margin: 50px auto 0;
  max-width: 800px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  border-left: 5px solid var(--primary-color);
}

.website-owner-note h3 {
  color: var(--dark-blue);
  margin-bottom: 15px;
  font-size: 1.3rem;
}

.website-owner-note p {
  margin-bottom: 15px;
  font-weight: 500;
}

.website-owner-note ul {
  margin-bottom: 20px;
  padding-left: 20px;
}

.website-owner-note ul li {
  margin-bottom: 10px;
  position: relative;
  list-style-type: none;
  padding-left: 25px;
}

.website-owner-note ul li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
}

/* Try Your Website Section */
.try-proxy {
  padding: var(--section-spacing) 0;
  background-color: var(--off-white);
}

.try-your-website {
  background-color: var(--white);
  /* border-radius: 8px; wont work with gradient */
  padding: 30px;
  margin: 0 auto 40px;
  max-width: 800px;
  box-shadow: var(--box-shadow);
  text-align: center;
  border: 5px solid transparent;
  /* Set a transparent border */
  border-image: var(--gradient-brand) 1;
  /* Apply the gradient */
}

.try-your-website h3 {
  margin-bottom: 15px;
  color: var(--primary-color);
}

.url-input-form {
  margin-top: 25px;
}

.url-input-container {
  display: flex;
  max-width: 600px;
  margin: 0 auto;
  flex-wrap: wrap;
  gap: 10px;
}

#website-url {
  flex: 1;
  min-width: 250px;
  padding: 12px 15px;
  border: 1px solid var(--medium-gray);
  border-radius: 4px;
  font-family: var(--body-font);
  font-size: 16px;
  transition: var(--transition);
}

#website-url:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(108, 99, 255, 0.2);
}

.url-submit-button {
  background-color: var(--primary-color);
  color: var(--white);
  border: none;
  padding: 12px 24px;
  font-family: var(--body-font);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  border-radius: 4px;
  transition: var(--transition);
  white-space: nowrap;
}

.url-submit-button:hover {
  background-color: var(--dark-blue);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.url-form-note {
  margin-top: 15px;
  font-size: 0.9rem;
  color: var(--light-text);
  font-style: italic;
}

.use-case-card {
  background-color: var(--off-white);
  padding: 30px;
  border-radius: 8px;
  box-shadow: var(--box-shadow);
}

.use-case-card h3 {
  color: var(--dark-blue);
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.use-case-card h3::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.use-case-card em {
  display: block;
  margin-top: 20px;
  color: var(--dark-blue);
  font-style: italic;
}


/* ===== Funders Section ===== */
.funders {
  padding: var(--section-spacing) 0;
  background-color: var(--white);
}

.funders-description {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px;
  font-size: 1.1rem;
}

.funders-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 50px;
  margin-bottom: 40px;
}

.funder-item {
  text-align: center;
  transition: var(--transition);
}

.funder-item:hover {
  transform: translateY(-5px);
}

.funder-item a {
  text-decoration: none;
  color: var(--dark-text);
}

.funder-logo-container {
  width: 200px;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  background-color: var(--off-white);
  border-radius: 8px;
  box-shadow: var(--box-shadow);
  padding: 15px;
  transition: var(--transition);
}

.funder-logo-container:hover {
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.funder-logo {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.funder-name {
  font-weight: 600;
  margin-top: 10px;
  color: var(--dark-blue);
}

.funders-note {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  color: var(--light-text);
  font-style: italic;
  font-size: 0.9rem;
}



/* Below here is the salesmate embedded form code, which is nasty */
/* ===== CTA Section ===== */
.cta {
  padding: var(--section-spacing) 0;
  color: var(--white);
  border-radius: 16px;
  box-shadow: 0px 5px 8px 0px rgba(0, 0, 0, 0.25);
}

.cta .section-title {
  color: var(--white);
}

.cta-description {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 40px;
  font-size: 1.1rem;
}

.cta-form {
  max-width: 600px;
  margin: 0 auto;
  background-color: var(--white);
  padding: 30px;
  border-radius: 8px;
  box-shadow: var(--box-shadow);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
  color: var(--dark-text);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px 15px;
  border: 1px solid var(--medium-gray);
  border-radius: 4px;
  font-family: var(--body-font);
  font-size: 16px;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(108, 99, 255, 0.2);
}

.form-group textarea {
  min-height: 120px;
}

.cta-form .cta-button {
  width: 100%;
  margin-top: 10px;
}

.form-note {
  text-align: center;
  margin-top: 20px;
  font-size: 0.9rem;
  color: var(--white);
  font-style: italic;
}

iframe {
  height: 809px;
}

/* Fullscreen video styles */
.clickable {
  cursor: pointer;
  position: relative;
}

.clickable::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 24px;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.clickable:hover::after {
  opacity: 1;
}

.fullscreen-video-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.fullscreen-video-container.active {
  opacity: 1;
  visibility: visible;
}

.fullscreen-video {
  max-width: 90%;
  max-height: 80%;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.close-fullscreen {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 20px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.close-fullscreen:hover {
  background-color: rgba(0, 0, 0, 0.8);
}

body.fullscreen-video-active {
  overflow: hidden;
}

.example-site h3, .example-site h4 {
  margin-bottom: 0;
}

.example-site p {
  margin-top: 0.5rem;
}

.example-site strong {
  font-weight: 700;
}