/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Lato', 'HelveticaNeue', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: #fff;
  background: #0b1e43;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

/* === Typography === */
h1, h2, h3, h4 { line-height: 1.2; font-weight: 300; }
h1 { font-size: 34px; }
h2 { font-size: 28px; }
h3 { font-size: 20px; }
h4 { font-size: 16px; }

.gold { color: #f8cb5f; }
.white { color: #fff; }

/* === Layout === */
.container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.section { padding: 60px 0; }
.section--dark { background: #0b1e43; }
.section--navy { background: #07193c; }
.section--blue { background: #a5bce8; color: #0b1e43; }
.section--pattern {
  background-color: #07193c;
  background-image: url('../images/cubic_pattern1-min.png');
  background-repeat: repeat;
}

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

/* Grid */
.grid { display: grid; gap: 8px; }
.grid--2 { grid-template-columns: 1fr 1fr; }
.grid--3 { grid-template-columns: 1fr 1fr 1fr; }
.grid--4 { grid-template-columns: 1fr 1fr 1fr 1fr; }

/* === Decorative line === */
.deco-line {
  display: block;
  margin: 15px auto 25px;
  height: 4px;
  max-width: 200px;
}

.deco-line--left {
  margin-left: 0;
}

/* === Header === */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 20px 0;
  transition: all 0.3s ease;
  background: transparent;
}

.header.scrolled {
  background: rgba(11, 30, 67, 0.95);
  padding: 10px 0;
  backdrop-filter: blur(10px);
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header__logo img {
  height: 50px;
  transition: height 0.3s ease;
}

.header.scrolled .header__logo img {
  height: 38px;
}

.header__nav {
  display: flex;
  gap: 30px;
}

.header__nav a {
  font-size: 14px;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #fff;
  transition: color 0.2s;
  position: relative;
}

.header__nav a:hover,
.header__nav a.active {
  color: #f8cb5f;
}

.header__nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #f8cb5f;
  transition: width 0.2s;
}

.header__nav a:hover::after,
.header__nav a.active::after {
  width: 100%;
}

/* Mobile menu */
.header__toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 28px;
  cursor: pointer;
  padding: 5px;
}

/* === Hero === */
.hero {
  position: relative;
  min-height: 75vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(11, 30, 67, 0.5);
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  padding: 0 20px;
}

.hero__content h1 {
  font-size: 26px;
  font-weight: 300;
  line-height: 1.5;
  color: #fff;
}

.hero--short {
  min-height: 50vh;
}

.hero--project {
  min-height: 45vh;
}

/* === Portfolio Grid === */
.portfolio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.portfolio-grid__item {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  cursor: pointer;
}

.portfolio-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.portfolio-grid__item:hover img {
  transform: scale(1.05);
}

.portfolio-grid__item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(11, 30, 67, 0);
  transition: background 0.3s ease;
}

.portfolio-grid__item:hover::after {
  background: rgba(11, 30, 67, 0.3);
}

/* === What We Do === */
.services {
  background-color: #0b1e43;
  background-image: url('../images/shelf.png');
  background-repeat: no-repeat;
  background-position: center bottom;
  background-size: contain;
}

.service-card {
  text-align: center;
  padding: 20px 15px;
}

.service-card h3 {
  color: #f8cb5f;
  margin-bottom: 10px;
  font-weight: 400;
}

.service-card .deco-line {
  max-width: 100px;
  margin-bottom: 15px;
}

.service-card p {
  font-size: 13px;
  line-height: 1.7;
  color: #ccc;
}

/* === Use Cases / Slider === */
.slider {
  position: relative;
  overflow: hidden;
}

.slider__track {
  display: flex;
  transition: transform 0.5s ease;
}

.slider__slide {
  min-width: 100%;
  display: flex;
  align-items: center;
  gap: 40px;
  padding: 20px;
}

.slider__image {
  flex: 0 0 45%;
  border-radius: 4px;
  overflow: hidden;
}

.slider__image img {
  width: 100%;
  border-radius: 4px;
}

.slider__text h3 {
  font-size: 22px;
  font-weight: 400;
  margin-bottom: 10px;
}

.slider__text p {
  font-size: 14px;
  opacity: 0.8;
}

.slider__dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}

.slider__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid #0b1e43;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s;
}

.slider__dot.active {
  background: #0b1e43;
}

/* === Team / About === */
.team-member {
  text-align: center;
  padding: 20px;
}

.team-member__photo {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 15px;
}

.team-member h3 {
  font-weight: 400;
  margin-bottom: 5px;
}

.team-member h4 {
  color: #f8cb5f;
  font-weight: 300;
  margin-bottom: 10px;
}

.team-member p {
  font-size: 14px;
  color: #ccc;
  max-width: 300px;
  margin: 0 auto;
}

/* === Testimonials === */
.testimonials {
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  min-height: 200px;
}

.testimonial {
  display: none;
  animation: fadeIn 0.5s ease;
}

.testimonial.active {
  display: block;
}

.testimonial blockquote {
  font-size: 16px;
  font-style: italic;
  line-height: 1.8;
  color: #ddd;
  margin-bottom: 15px;
}

.testimonial cite {
  color: #f8cb5f;
  font-style: normal;
  font-weight: 400;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* === Client Logos === */
.client-logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 30px;
  max-width: 900px;
  margin: 0 auto;
}

.client-logos img {
  height: 50px;
  width: auto;
  opacity: 0.7;
  transition: opacity 0.3s;
  filter: brightness(2);
}

.client-logos img:hover {
  opacity: 1;
}

/* === Contact Section === */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 15px;
  margin-bottom: 15px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 3px;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  transition: border-color 0.2s;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: #f8cb5f;
}

.contact-form textarea {
  height: 120px;
  resize: vertical;
}

.contact-form button {
  background: #f8cb5f;
  color: #0b1e43;
  border: none;
  padding: 12px 35px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 3px;
  transition: background 0.2s;
}

.contact-form button:hover {
  background: #e6b94d;
}

.contact-form .status-msg {
  margin-top: 10px;
  font-size: 14px;
}

.contact-info {
  padding-top: 10px;
}

.contact-info__item {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 25px;
}

.contact-info__item img {
  width: 24px;
  height: 24px;
  margin-top: 3px;
  filter: brightness(2);
}

.contact-info__item p {
  font-size: 14px;
  line-height: 1.8;
  color: #ccc;
}

.contact-info__item a {
  color: #f8cb5f;
  transition: opacity 0.2s;
}

.contact-info__item a:hover {
  opacity: 0.8;
}

.contact-side-image {
  max-width: 280px;
  margin-top: 30px;
}

/* === Footer === */
.footer {
  background: #050e22;
  padding: 40px 0;
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.footer__col h4 {
  color: #f8cb5f;
  margin-bottom: 12px;
  font-weight: 400;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer__col p,
.footer__col a {
  font-size: 13px;
  color: #999;
  line-height: 1.8;
}

.footer__col a:hover {
  color: #f8cb5f;
}

.footer__social {
  display: flex;
  gap: 12px;
}

.footer__social img {
  width: 32px;
  height: 32px;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.footer__social a:hover img {
  opacity: 1;
}

.footer__bottom {
  text-align: center;
  padding-top: 25px;
  margin-top: 25px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 12px;
  color: #666;
}

/* === Project Detail Page === */
.project-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
  align-items: start;
}

.project-description p {
  font-size: 15px;
  line-height: 1.8;
  color: #ccc;
  margin-bottom: 15px;
}

.project-meta {
  background: rgba(255, 255, 255, 0.05);
  padding: 25px;
  border-radius: 4px;
}

.project-meta dt {
  color: #f8cb5f;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.project-meta dd {
  color: #ccc;
  font-size: 14px;
  margin-bottom: 15px;
}

.project-meta dd:last-child {
  margin-bottom: 0;
}

.project-meta a {
  color: #f8cb5f;
  text-decoration: underline;
}

.project-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 15px;
  margin-top: 30px;
}

.project-gallery img {
  width: 100%;
  border-radius: 4px;
}

.video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  margin: 30px 0;
  border-radius: 4px;
}

.video-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* === Lightbox === */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.9);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox.active {
  display: flex;
}

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
}

.lightbox__close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 36px;
  cursor: pointer;
  background: none;
  border: none;
  line-height: 1;
}

/* === Back link === */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #f8cb5f;
  font-size: 14px;
  margin-bottom: 20px;
  transition: opacity 0.2s;
}

.back-link:hover {
  opacity: 0.8;
}

/* === Responsive === */
@media (max-width: 900px) {
  .grid--4 { grid-template-columns: 1fr 1fr; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .project-content { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .slider__slide { flex-direction: column; }
  .slider__image { flex: none; width: 100%; }
}

@media (max-width: 768px) {
  .header__nav { display: none; }
  .header__nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(11, 30, 67, 0.98);
    padding: 20px;
    gap: 15px;
  }
  .header__toggle { display: block; }
  .portfolio-grid { grid-template-columns: 1fr; }
  .grid--4 { grid-template-columns: 1fr; }
  .grid--3 { grid-template-columns: 1fr; }
  .grid--2 { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .hero { min-height: 50vh; }
  .hero__content h1 { font-size: 20px; }
  h1 { font-size: 26px; }
  h2 { font-size: 22px; }
}

/* === Preloader === */
.preloader {
  position: fixed;
  inset: 0;
  background: #0b1e43;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s ease;
}

.preloader.hide {
  opacity: 0;
  pointer-events: none;
}

.preloader__spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(248, 203, 95, 0.2);
  border-top-color: #f8cb5f;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}
