/* =====================================================
   BASE & RESET
   ===================================================== */

html {
  font-size: 16px;
  box-sizing: border-box;
}

*, *::before, *::after {
  box-sizing: inherit;
}

body {
  margin: 0;
  font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: #0b0f14;
  color: #e5e7eb;
  line-height: 1.6;
}

/* =====================================================
   GLOBAL HEADER
   ===================================================== */

#global-header {
  position: relative;
  top: 0;
  width: 100%;
  height: 96px;
  z-index: 1000;
  overflow: hidden;
  background-color: #0b0f14;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

@supports (position: sticky) {
  #global-header {
    position: sticky;
  }
}

/* =====================================================
   HEADER BACKGROUND ROTATION
   ===================================================== */

.header-background {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.header-background .bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
}

.bg1 { background-image: url("/assets/images/header/header-1.jpg"); animation: bg1 50s infinite; }
.bg2 { background-image: url("/assets/images/header/header-2.png"); animation: bg2 50s infinite; }
.bg3 { background-image: url("/assets/images/header/header-3.png"); animation: bg3 50s infinite; }
.bg4 { background-image: url("/assets/images/header/header-4.jpg"); animation: bg4 50s infinite; }
.bg5 { background-image: url("/assets/images/header/header-5.png"); animation: bg5 50s infinite; }

@keyframes bg1 { 0%,20%{opacity:.35;} 25%,100%{opacity:0;} }
@keyframes bg2 { 0%,20%{opacity:0;} 20%,40%{opacity:.35;} 45%,100%{opacity:0;} }
@keyframes bg3 { 0%,40%{opacity:0;} 40%,60%{opacity:.35;} 65%,100%{opacity:0;} }
@keyframes bg4 { 0%,60%{opacity:0;} 60%,80%{opacity:.35;} 85%,100%{opacity:0;} }
@keyframes bg5 { 0%,80%{opacity:0;} 80%,100%{opacity:.35;} }

.header-background::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(11,15,20,0.7);
  z-index: 1;
}

/* =====================================================
   HEADER CONTENT
   ===================================================== */

.header-content {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  height: 100%;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* =====================================================
   BRAND
   ===================================================== */

.header-brand {
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand-logo img {
  height: 64px;
  width: auto;
  display: block;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-size: 20px;
  font-weight: 600;
  color: #f9fafb;
}

.brand-tagline {
  font-size: 12px;
  color: #9ca3af;
}

/* =====================================================
   HEADER IDENTITY & NAV
   ===================================================== */

.header-identity {
  font-size: 13px;
  letter-spacing: 0.6px;
  color: #9ca3af;
  white-space: nowrap;
}

.header-nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  gap: 30px;
}

.header-nav a {
  position: relative;
  font-size: 14px;
  font-weight: 500;
  color: #e5e7eb;
  text-decoration: none;
}

.header-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 2px;
  background-color: #38bdf8;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.header-nav a:hover::after,
.header-nav a.active::after {
  opacity: 1;
}

.header-nav a.active {
  color: #38bdf8;
}

/* =====================================================
   SECTIONS & FLOW
   ===================================================== */

section {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 90px 24px;
}

section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 24px;
  right: 24px;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    rgba(255,255,255,0.06),
    transparent
  );
}

#hero::before {
  display: none;
}

section:nth-of-type(even) {
  background: rgba(255,255,255,0.015);
}

/* =====================================================
   HERO
   ===================================================== */

#hero {
  padding-top: 120px;
  padding-bottom: 120px;
}

.hero-inner {
  max-width: 900px;
}

#hero h1 {
  font-size: 46px;
  line-height: 1.15;
  font-weight: 600;
  color: #f9fafb;
}

#hero h1 span {
  display: block;
  font-size: 38px;
  font-weight: 500;
  color: #d1d5db;
  margin-top: 6px;
}

#hero p {
  margin-top: 28px;
  font-size: 18px;
  color: #cbd5f5;
  max-width: 820px;
}

/* =====================================================
   AUDIENCE CARDS
   ===================================================== */

.audience-grid {
  margin-top: 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.audience-card {
  padding: 26px 24px;
  background: rgba(255,255,255,0.04);
  border-radius: 6px;
  font-size: 15px;
  font-weight: 500;
}

/* =====================================================
   PLACARD ENGINE (TOOLS + PROJECTS)
   ===================================================== */

.tools-grid,
.projects-grid {
  margin-top: 50px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
}

.tool-card {
  position: relative;
  padding: 28px 26px;
  background: rgba(255,255,255,0.035);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.08);
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.tool-card:hover {
  transform: translateY(-4px);
  border-color: rgba(56,189,248,0.4);
}

.tool-card h3 {
  font-size: 18px;
  font-weight: 600;
  color: #f9fafb;
  margin-bottom: 14px;
}

.tool-card p {
  font-size: 15px;
  line-height: 1.6;
  color: #cbd5f5;
}

.tool-action {
  margin-top: 22px;
  font-size: 13px;
  font-weight: 600;
  color: #38bdf8;
  letter-spacing: 0.4px;
}

/* Light sweep */
.tool-card::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -120%;
  width: 120%;
  height: 200%;
  background: linear-gradient(
    120deg,
    rgba(255,255,255,0) 0%,
    rgba(255,255,255,0.06) 45%,
    rgba(255,255,255,0.14) 50%,
    rgba(255,255,255,0.06) 55%,
    rgba(255,255,255,0) 100%
  );
  transform: skewX(-20deg);
  opacity: 0;
  pointer-events: none;
  animation: toolSheen 18s infinite;
}

.tool-card:nth-child(2)::before { animation-delay: 3s; }
.tool-card:nth-child(3)::before { animation-delay: 6s; }
.tool-card:nth-child(4)::before { animation-delay: 9s; }
.tool-card:nth-child(5)::before { animation-delay: 12s; }
.tool-card:nth-child(6)::before { animation-delay: 15s; }

@keyframes toolSheen {
  0%   { left: -120%; opacity: 0; }
  6%   { opacity: 1; }
  16%  { left: 120%; opacity: 0; }
  100% { left: 120%; opacity: 0; }
}

/* =====================================================
   FOOTER
   ===================================================== */

#footer {
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 32px 24px;
  text-align: center;
  font-size: 13px;
  color: #9ca3af;
}

/* =====================================================
   RESPONSIVE
   ===================================================== */

@media (max-width: 1024px) {
  .brand-logo img { height: 56px; }
}

@media (max-width: 768px) {
  .header-identity { display: none; }
  #hero h1 { font-size: 36px; }
  #hero h1 span { font-size: 30px; }
}

@media (max-width: 480px) {
  .brand-logo img { height: 50px; }
  #hero h1 { font-size: 32px; }
}

/* =====================================================
   CONTACT FORM
   ===================================================== */

#contact-form {
  max-width: 700px;
}

#contact-form p {
  margin-bottom: 28px;
}

.form-row {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
}

.form-row label {
  font-size: 13px;
  margin-bottom: 6px;
  color: #9ca3af;
}

.form-row input,
.form-row select,
.form-row textarea {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  padding: 10px 12px;
  font-size: 14px;
  color: #e5e7eb;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: #38bdf8;
}

.form-row button {
  align-self: flex-start;
  background: #38bdf8;
  color: #0b0f14;
  border: none;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
}

.form-row button:hover {
  background: #60c8ff;
}

.form-note {
  margin-top: 14px;
  font-size: 12px;
  color: #9ca3af;
}
/* AI Tool Placard Layout Fix */
.tool-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

/* Ensure description takes flexible space */
.tool-card p {
  flex-grow: 1;
}

/* Call-to-action always at bottom */
.tool-card .tool-action,
.tool-card .coming-soon {
  margin-top: 20px;
}
/* Tool image strip */
.tool-image {
  height: 100px;
  border-radius: 8px;
  margin-bottom: 16px;
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
}

/* Dark overlay for consistency */
.tool-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0.35),
    rgba(0,0,0,0.65)
  );
}

/* Individual tool images */
.tool-image.plc-log {
  background-image: url("/assets/images/tools/plc-logs.jpg");
}

.tool-image.alarm {
  background-image: url("/assets/images/tools/alarms.jpg");
}

.tool-image.production {
  background-image: url("/assets/images/tools/production.jpg");
}

.tool-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

/* Tool image container */
.tool-image {
  position: relative;
}

/* Badge inside image */
.tool-image .tool-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
}

/* Optional: soften badge contrast over image */
.tool-image .tool-badge {
  backdrop-filter: blur(4px);
}


.badge-trial {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.35);
}

.badge-paid {
  background: rgba(234, 179, 8, 0.15);
  color: #eab308;
  border: 1px solid rgba(234, 179, 8, 0.35);
}

.badge-soon {
  background: rgba(156, 163, 175, 0.12);
  color: #9ca3af;
  border: 1px solid rgba(156, 163, 175, 0.3);
}

/* Tool image container must control badge positioning */
.tool-image {
  position: relative;
}

/* Badge now sits INSIDE the image safely */
.tool-image .tool-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
}
/* Fix dropdown visibility */
select {
  background-color: #0f172a;   /* same dark background */
  color: #e5e7eb;              /* readable text */
  border: 1px solid rgba(255,255,255,0.2);
}

/* Dropdown options */
select option {
  background-color: #0f172a;
  color: #e5e7eb;
}
