/* assets/style.css */
:root {
  --deep-teal: #2F4F4F;
  --soft-ivory: #F8F9FA;
  --steel-blue: #B0C4DE;
  --sunshine-yellow: #FFD166;
  --warm-gray: #EDEDED;
  --transition: 500ms cubic-bezier(0.25, 0.8, 0.5, 1);
  --font-heading: 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;
  /* scale factor for live-demo iframe previews */
  --preview-scale: 0.6;
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--soft-ivory);
  color: var(--deep-teal);
  line-height: 1.6;
  scroll-behavior: smooth;
}

/* Header / Navigation */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1rem;
  background: var(--deep-teal);
  color: var(--soft-ivory);
  max-height: 60px;
}

.brand {
  font-size: 1.25rem;
  font-weight: 600;
}

.brand img {
  height: 100px;
  width: auto;
  background: ghostwhite;
  border-radius: 15px;
  margin-top: 50px;
}

nav {
  display: flex;
  align-items: center;
}

nav a {
  margin-left: 0.75rem;
  text-decoration: none;
  color: var(--soft-ivory);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color var(--transition);
}

nav a:hover {
  color: var(--sunshine-yellow);
}

.theme-toggle {
  margin-left: 0.75rem;
  background: none;
  border: none;
  color: inherit;
  cursor: pointer;
  font: inherit;
  font-size: 1rem;
}

/* Hero */
#hero {
  display: flex;
  align-items: center;
  justify-content: center;
  height: auto;
  text-align: center;
  padding: 0 1rem;
  background: linear-gradient(135deg, var(--steel-blue) 0%, var(--warm-gray) 100%);
  position: relative;
  overflow: hidden;
}

#hero .inner {
  max-width: 800px;
  z-index: 1;
  margin-bottom: 15px;
}

#hero h1 {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 4rem;
  line-height: 1.1;
  margin-bottom: 1rem;
}

#hero .hero-title {
  background: repeating-linear-gradient(
    to right,
    var(--deep-teal) 0%, var(--deep-teal) 25%,
    var(--soft-ivory) 25%, var(--soft-ivory) 50%
  ) repeat-y;
  background-size: 200% auto;
  margin-top: 10px;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  text-shadow: 0 0 80px rgba(255,255,255,0.5);
  animation:
    heroTitleFill 10s ease-in-out infinite alternate,
    heroTitlePulse 4s ease-in-out infinite alternate;
  transform-origin: center center;
}

#hero p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
}

#hero .btn {
  display: inline-block;
  margin: 0 0.5rem;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 0.5rem;
  transition: transform var(--transition), box-shadow var(--transition);
}

.btn-primary {
  background: var(--deep-teal);
  color: var(--soft-ivory);
}

.btn-secondary {
  border: 2px solid var(--deep-teal);
  color: var(--deep-teal);
  background: transparent;
}

#hero .btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ----------------------------------------------------------
   Projects inside hero (carousel), revised for optimal UX
   ---------------------------------------------------------- */
#hero-work {
  max-width: 600px;
  margin: 1rem auto;
  height: auto;
  position: relative;
}

/* wrap your track + nav in this for relative positioning */
#hero-work .slider-container {
  position: relative;
  overflow: hidden;                          /* mask overflowing track */
}

/* flex-based slider moved with transforms */
#hero-work .slider-track {
  display: flex;
  gap: 1rem;                                 /* space between cards */
  transition: transform 0.6s ease-in-out;    /* smooth slide movement */
}

/* individual slide card */
#hero-work .certificate-card {
  flex: 0 0 auto;                            /* no shrinking or growing */
  width: min(90vw, 600px);                   /* responsive up to 600px */
  height: 65vh;
  position: relative;
  border-radius: 0.5rem;                     /* your rounded corners */
  overflow: hidden;                          /* clip iframe content */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  margin-top: 20px;
}

/* new wrapper around the iframe—this masks anything inside */
#hero-work .certificate-card .iframe-wrapper {
  position: absolute;
  inset: 0;                                   /* fill the card */
  overflow: hidden;                           /* clip scaled or oversized children */
  border-radius: inherit;                     /* clip to the parent’s radius */
}

/* iframe now just fills its wrapper—no scaling transform needed */
#hero-work .certificate-card .iframe-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}
/* at the bottom of assets/style.css */

/* Hide iframe scrollbars in all modern browsers */
iframe {
  overflow: hidden;
  scrollbar-width: none;    /* Firefox */
}

iframe::-webkit-scrollbar {
  display: none;            /* Chrome, Safari, Edge */
}


/* Pagination dots */
#hero-work .slider-dots {
  text-align: center;
  margin-top: 0.75rem;
}
#hero-work .slider-dots button {
  width: 10px;
  height: 10px;
  margin: 0 4px;
  border-radius: 50%;
  border: none;
  background: var(--warm-gray);
  cursor: pointer;
  transition: transform var(--transition);
}
#hero-work .slider-dots button.active {
  background: var(--deep-teal);
  transform: scale(1.2);
}

#hero-work .modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

#hero-work .modal.open {
  display: flex;
}

#hero-work .modal-content {
  position: relative;
  background: #fff;
  padding: 1rem;
  border-radius: 0.5rem;
  max-width: 90%;
  max-height: 90%;
  overflow: auto;
}

#hero-work .modal-close {
  position: absolute;
  top: 0.25rem;
  right: 0.5rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
}

/* Case cards (if needed elsewhere) */
.case-card {
  background: #fff;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition: transform var(--transition);
  min-width: 100%;
  flex-shrink: 0;
}

.case-card:hover {
  transform: translateY(-5px);
}

.case-card h3 {
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.case-card p {
  margin-bottom: 1rem;
}

.case-card a {
  font-weight: 600;
  color: var(--steel-blue);
  text-decoration: none;
}

/* Services inside hero */
#hero-services {
  background: var(--soft-ivory);
  padding: 4rem 1rem;
  max-width: 1000px;
  margin: auto;
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  text-align: center;
}

.service {
  background: var(--warm-gray);
  padding: 2rem;
  border-radius: 0.5rem;
  transition: transform var(--transition);
}

.service:hover {
  transform: translateY(-4px);
}

.service h4 {
  margin-bottom: 0.75rem;
  font-weight: 600;
}

/* About */
#about {
  max-width: 1000px;
  margin: 4rem auto;
  padding: 0 1rem;
}

#about-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2rem;
}

#about-inner img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

#about-inner .cred-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  flex-shrink: 0;
}

#about-inner .cred-list .item {
  display: flex;
  align-items: center;
  font-weight: 600;
}

#about-inner .cred-list .item span {
  font-size: 1.5rem;
  margin-right: 0.5rem;
}

#about-inner .bio {
  flex: 1;
}

#about-inner h2 {
  font-weight: 600;
  margin-bottom: 0.5rem;
}

#about-inner p {
  font-size: 1.1rem;
}

/* Contact */
#contact {
  background: var(--warm-gray);
  text-align: center;
  padding: 4rem 1rem;
}

#contact h2 {
  font-weight: 600;
  margin-bottom: 1rem;
}

#contact a.email {
  display: inline-block;
  margin-bottom: 1rem;
  font-weight: 600;
  color: var(--deep-teal);
  text-decoration: none;
  border-bottom: 2px solid var(--deep-teal);
  transition: color var(--transition), border-color var(--transition);
}

#contact a.email:hover {
  color: var(--steel-blue);
  border-color: var(--steel-blue);
}

#contact .social {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

#contact .social img {
  width: 32px;
  height: 32px;
  filter: grayscale(100%);
  transition: filter var(--transition);
}

#contact .social img:hover {
  filter: none;
}

footer {
  text-align: center;
  padding: 2rem 1rem;
  background: var(--deep-teal);
  color: var(--soft-ivory);
  font-size: 0.9rem;
}

/* Responsive tweaks */
@media (max-width: 768px) {
  #hero h1 {
    font-size: 2.75rem;
  }
  #hero-work .certificate-card {
    flex: 0 0 90vw;
  }
  #about-inner {
    flex-direction: column;
    text-align: center;
  }
  #about-inner img {
    margin: auto;
  }
  #about-inner .cred-list {
    flex-direction: row;
    justify-content: center;
    gap: 1.5rem;
  }
}

/* Utility classes */
.hidden {
  display: none !important;
}

.fade {
  opacity: 0;
  transform: translateY(15px);
  transition: opacity var(--transition), transform var(--transition);
}

.fade.show {
  opacity: 1;
  transform: none;
}

.section {
  overflow: hidden;
}

.section-inner {
  will-change: transform, opacity;
}

.section-inner:focus {
  outline: none;
}

/* Keyframes */
@keyframes heroTitleFill {
  to { background-position: 100% 50%; }
}

@keyframes heroTitlePulse {
  0% { text-shadow: 0 0 80px rgba(255,255,255,0.5); }
  100% { text-shadow: 0 0 100px rgba(255,255,255,0.7); }
}
