:root {
  --bg-dark: #0A0B10;
  --bg-card: rgba(255, 255, 255, 0.03);
  --bg-card-hover: rgba(255, 255, 255, 0.08);
  --text-main: #FFFFFF;
  --text-muted: #A0A0B0;
  --accent-orange: #FF7A59;
  --accent-orange-hover: #E86A4C;
  --accent-cyan: #00F2FE;
  
  --font-body: 'Inter', sans-serif;
  --font-heading: 'Outfit', sans-serif;
  
  --transition-smooth: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6, .logo {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

.h2 { font-size: 2.5rem; margin-bottom: 1rem; }
.h3 { font-size: 1.8rem; margin-bottom: 1rem; }
.gradient-text {
  background: linear-gradient(90deg, var(--accent-orange), var(--accent-cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

a {
  text-decoration: none;
  color: var(--text-main);
  transition: var(--transition-smooth);
}

ul {
  list-style: none;
}

/* Layout */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.section-padding {
  padding: 100px 0;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 60px;
}
.section-header p {
  color: var(--text-muted);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 30px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  border: none;
}
.btn-small {
  padding: 8px 20px;
  font-size: 0.9rem;
}

.btn-primary {
  background-color: var(--accent-orange);
  color: #fff;
  box-shadow: 0 4px 15px rgba(255, 122, 89, 0.3);
}
.btn-primary:hover {
  background-color: var(--accent-orange-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 122, 89, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--text-main);
  border: 1px solid var(--text-muted);
}
.btn-outline:hover {
  border-color: var(--accent-orange);
  color: var(--accent-orange);
}

.btn-modern {
  position: relative;
  background: var(--bg-card);
  color: var(--text-main);
  border: 1px solid rgba(255, 122, 89, 0.5);
  overflow: hidden;
  z-index: 1;
  transition: all 0.4s ease;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.btn-modern::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(90deg, var(--accent-orange), var(--accent-cyan));
  z-index: -1;
  transition: opacity 0.4s ease;
  opacity: 0;
}
.btn-modern:hover {
  border-color: transparent;
  color: #fff;
  box-shadow: 0 10px 30px rgba(0, 242, 254, 0.3);
  transform: translateY(-3px);
}
.btn-modern:hover::before {
  opacity: 1;
}
.btn-modern i {
  transition: transform 0.4s ease;
}
.btn-modern:hover i {
  transform: translateX(5px);
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 5px 0;
  z-index: 1000;
  transition: var(--transition-smooth);
}
.navbar.scrolled {
  background: rgba(10, 10, 16, 0.9);
  backdrop-filter: blur(10px);
  padding: 5px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

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

.logo {
  font-size: 1.8rem;
  letter-spacing: 1px;
}
.logo span {
  color: var(--accent-orange);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
}
.nav-links a:not(.btn) {
  font-size: 0.95rem;
  font-weight: 500;
}
.nav-links a:not(.btn):hover {
  color: var(--accent-orange);
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg-glow {
  position: absolute;
  top: -20%;
  left: -10%;
  width: 60vw;
  height: 60vw;
  background: radial-gradient(circle, rgba(255,122,89,0.15) 0%, rgba(10,11,16,0) 70%);
  z-index: 1;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -20%;
  right: -10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, rgba(0,242,254,0.1) 0%, rgba(10,11,16,0) 70%);
  z-index: 1;
}
.hero-grid {
  position: relative;
  z-index: 2;
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 60px;
  direction: ltr !important; /* Force Left-to-Right layout */
}
.hero-content {
  flex: 1 1 50%;
  max-width: 600px;
  text-align: left;
}
.pt-20 { padding-top: 80px; }

.hero h1 {
  font-size: 4rem;
  margin-bottom: 20px;
}
.hero .subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  max-width: 600px;
}

.hero-cta {
  display: flex;
  justify-content: flex-start;
  gap: 20px;
}

.hero-image-wrapper {
  flex: 1 1 50%;
  position: relative;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}
.hero-image-glow {
  position: absolute;
  width: 80%;
  height: 80%;
  background: var(--accent-cyan);
  filter: blur(80px);
  opacity: 0.15;
  border-radius: 50%;
  z-index: -1;
  animation: pulse-glow 4s infinite alternate;
}
@keyframes pulse-glow {
  0% { transform: scale(0.9); opacity: 0.1; }
  100% { transform: scale(1.1); opacity: 0.2; }
}
.hero-image {
  width: 100%;
  max-width: 500px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-20px); }
  100% { transform: translateY(0px); }
}

/* Core Values / Features */
.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 50px;
  text-align: center;
}
.value-card {
  padding: 20px 10px;
  transition: var(--transition-smooth);
}
.value-card:hover {
  transform: translateY(-8px);
}
.value-icon {
  width: 70px;
  height: 70px;
  background: var(--accent-orange);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  margin: 0 auto 25px;
  box-shadow: 0 10px 20px rgba(255,122,89,0.3);
  transition: var(--transition-smooth);
}
.value-card:hover .value-icon {
  transform: scale(1.1) rotate(5deg);
}
.value-card .h3 {
  font-size: 1.6rem;
  margin-bottom: 15px;
  letter-spacing: -0.5px;
}
.value-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* Services */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}
.service-card {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px;
  padding: 40px 30px;
  transition: var(--transition-smooth);
}
.service-card:hover {
  background: var(--bg-card-hover);
  transform: translateY(-10px);
  border-color: rgba(255,122,89,0.2);
}
.icon-box {
  width: 60px;
  height: 60px;
  background: rgba(255,122,89,0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--accent-orange);
  margin-bottom: 20px;
}
.service-card h3 {
  font-size: 1.3rem;
  margin-bottom: 15px;
}
.service-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 20px;
}
.learn-more {
  color: var(--accent-orange);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 5px;
}
.learn-more:hover { gap: 10px; }

/* About & Tabs */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
}
.about-tabs {
  margin-top: 10px;
}
.tab-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}
.tab-btn.active {
  background: linear-gradient(90deg, var(--accent-orange), var(--accent-cyan));
  color: #fff;
  box-shadow: 0 4px 15px rgba(255, 122, 89, 0.3);
}
.tab-btn:hover:not(.active) {
  color: #fff;
  background: rgba(255,255,255,0.1);
}
.tab-pane {
  display: none;
  animation: fadeIn 0.4s ease forwards;
}
.tab-pane.active {
  display: block;
}
.tab-pane p {
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 20px;
  font-size: 1.05rem;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@keyframes spin-reverse {
  from { transform: rotate(360deg); }
  to { transform: rotate(0deg); }
}

/* Projects */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
}
.project-card {
  border-radius: 16px;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.05);
}
.project-img {
  height: 220px;
  transition: var(--transition-smooth);
}
.project-card:hover .project-img {
  transform: scale(1.05);
}
.bg-grad-1 { background: linear-gradient(135deg, #FF7A59, #FFB75E); }
.bg-grad-2 { background: linear-gradient(135deg, #00F2FE, #4FACFE); }
.bg-grad-3 { background: linear-gradient(135deg, #43E97B, #38F9D7); }

.project-info {
  padding: 25px;
  position: relative;
  z-index: 2;
  background: var(--bg-card);
}
.project-info h4 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}
.project-info p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
}
.contact-info p {
  color: var(--text-muted);
  margin-bottom: 40px;
}
.detail-item {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 30px;
}
.detail-item i {
  font-size: 1.5rem;
  color: var(--accent-orange);
  background: rgba(255,122,89,0.1);
  padding: 12px;
  border-radius: 50%;
}
.detail-item h5 {
  font-size: 1.1rem;
  margin-bottom: 5px;
}
.detail-item p {
  margin: 0;
  font-size: 0.95rem;
}

.contact-form-wrapper {
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.05);
  padding: 40px;
  border-radius: 20px;
  position: relative;
}
.form-title {
  margin-bottom: 30px;
  font-family: var(--font-heading);
  font-size: 1.5rem;
}
.form-group {
  position: relative;
  margin-bottom: 30px;
}
.form-group input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(255,255,255,0.2);
  padding: 10px 0;
  color: var(--text-main);
  font-size: 1rem;
  outline: none;
}
/* Focus / valid state for labels */
.form-group label {
  position: absolute;
  top: 10px;
  left: 0;
  color: var(--text-muted);
  transition: 0.3s;
  pointer-events: none;
}
.form-group input:focus ~ label,
.form-group input:valid ~ label {
  top: -15px;
  font-size: 0.8rem;
  color: var(--accent-orange);
}
.form-group .line {
  position: absolute;
  bottom: 0px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-orange);
  transition: 0.4s;
}
.form-group input:focus ~ .line,
.form-group input:valid ~ .line {
  width: 100%;
}
.submit-btn {
  width: 100%;
}

/* Footer */
.footer {
  background: #050508;
  padding: 80px 0 30px;
  border-top: 1px solid rgba(255,255,255,0.05);
}
.footer-content {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  justify-content: space-between !important;
  align-items: flex-start !important;
  gap: 40px;
  margin-bottom: 60px;
  direction: ltr !important;
}
.footer-brand {
  flex: 2;
  min-width: 300px;
  text-align: left;
}
.footer-brand p {
  color: var(--text-muted);
  margin-top: 20px;
  margin-bottom: 25px;
  max-width: 300px;
}
.social-links a {
  display: inline-flex;
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  margin-right: 10px;
}
.social-links a:hover {
  background: var(--accent-orange);
  transform: translateY(-3px);
}
.footer-links {
  flex: 1;
  min-width: 200px;
  text-align: left;
}
.footer-newsletter {
  flex: 1;
  min-width: 280px;
  text-align: left;
}
.footer-links h4, .footer-newsletter h4 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 20px;
}
.footer-links a {
  display: block;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.footer-links a:hover {
  color: var(--accent-orange);
  padding-left: 5px;
}
.footer-newsletter p {
  color: var(--text-muted);
  margin-bottom: 15px;
}
.newsletter-form {
  display: flex;
  gap: 10px;
}
.newsletter-form input {
  flex: 1;
  padding: 10px 15px;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05);
  color: #fff;
  outline: none;
}
.footer-bottom {
  text-align: center;
  color: rgba(255,255,255,0.3);
  font-size: 0.9rem;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.05);
}

/* Animations */
.fade-up {
  opacity: 0;
  transform: translateY(40px);
  transition: var(--transition-smooth);
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }

/* Projects Grid for Database/Filters */
.projects-matrix {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 40px;
  margin-top: 50px;
}
.portfolio-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  display: flex;
  flex-direction: column;
  height: 380px;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
}
.portfolio-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 242, 254, 0.15);
  border-color: rgba(0, 242, 254, 0.3);
}
.portfolio-img-container {
  height: 260px;
  width: 100%;
  background-color: #ffffff;
  padding: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.portfolio-img-container::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  box-shadow: inset 0 0 40px rgba(0,0,0,0.05);
  pointer-events: none;
  z-index: 1;
}
.portfolio-img-container img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.5s ease;
  z-index: 0;
}
.portfolio-card:hover .portfolio-img-container img {
  transform: scale(1.08);
}
.portfolio-info {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--bg-dark);
}
.portfolio-info h4 {
  margin: 0;
  font-size: 1.15rem;
  color: #fff;
  line-height: 1.4;
}

/* Responsive */
@media(max-width: 900px) {
  .hero-grid {
    flex-direction: column !important;
  }
  .about-grid, .contact-grid {
    grid-template-columns: 1fr;
  }
  .footer-content {
    flex-direction: column !important;
  }
  .hero-content {
    text-align: center;
    margin: 0 auto;
  }
  .hero-cta {
    justify-content: center;
  }
  .hero h1 { font-size: 3rem; }
  .nav-links { display: none; }
}

/* Mobile Button Architecture Upgrades */
.tab-buttons {
  display: flex;
  gap: 10px;
  margin-bottom: 30px;
  border: none;
  background: rgba(0,0,0,0.3);
  padding: 8px;
  border-radius: 50px;
}
.tab-buttons .tab-btn {
  flex: 1;
  border-radius: 40px;
  padding: 12px 15px;
  font-size: 1rem;
}

@media(max-width: 600px) {
  .hero-cta {
    flex-direction: column;
    width: 100%;
  }
  .hero-cta .btn {
    width: 100%;
    margin-bottom: 10px;
  }
  .tab-buttons {
    flex-direction: column;
    border-radius: 20px;
  }
  .container { width: 95%; }
  .about-grid { gap: 40px; }
}
