/* --- GENEL AYARLAR --- */
:root {
  --primary: #0f172a;
  /* Lacivert */
  --secondary: #475569;
  /* Gri - Darkened for better contrast (was #64748b) */
  --accent: #ea580c;
  /* Turuncu */
  --bg-light: #f1f5f9;
  --white: #ffffff;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", sans-serif;
  line-height: 1.6;
  color: #333;
  background: var(--bg-light);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

a {
  text-decoration: none;
  color: inherit;
  transition: 0.3s;
}

/* Focus styles for accessibility */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

a:focus:not(:focus-visible),
button:focus:not(:focus-visible) {
  outline: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

/* --- HEADER --- */
header {
  background: var(--white);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 1000;
}

nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  font-weight: 600;
  color: var(--secondary);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
}

/* Hamburger Menu (Mobil İçin) */
.hamburger {
  display: none;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0.5rem;
}

.hamburger:focus {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.bar {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px auto;
  background-color: var(--primary);
  transition: 0.3s;
}

/* --- ANA İÇERİK ALANI --- */
main {
  flex: 1;
}

/* Sayfa Başlıkları (Hero harici sayfalar için) */
.page-header {
  background: var(--primary);
  color: var(--white);
  text-align: center;
  padding: 3rem 1rem;
}

.container {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 20px;
}

/* --- HERO SECTION (Anasayfa) --- */
.hero {
  height: 85vh;
  background: linear-gradient(
      135deg,
      rgba(15, 23, 42, 0.85),
      rgba(234, 88, 12, 0.3)
    ),
    url("images/hero-bg.jpg");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--white);
  padding: 2rem;
  position: relative;
  overflow: hidden;
}

/* Animated background glow */
.hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(
      circle at 20% 80%,
      rgba(234, 88, 12, 0.3) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 20%,
      rgba(255, 255, 255, 0.1) 0%,
      transparent 40%
    );
  animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.5;
    transform: scale(1);
  }

  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin: 0 auto;
  animation: fadeInUp 1s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero h1 {
  font-size: 2.8rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
  animation: fadeInUp 1s ease-out 0.2s both;
}

.hero p {
  font-size: 1.3rem;
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  opacity: 0.95;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.2);
  animation: fadeInUp 1s ease-out 0.4s both;
}

.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--white);
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: bold;
  font-size: 1.1rem;
  box-shadow: 0 4px 15px rgba(234, 88, 12, 0.4);
  transition: all 0.3s ease;
  animation: fadeInUp 1s ease-out 0.6s both;
}

.btn:hover {
  background: #c2410c;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(234, 88, 12, 0.5);
}

/* Floating badge */
.hero-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  animation: fadeInUp 1s ease-out, float 3s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  animation: bounce 2s infinite;
}

.scroll-indicator span {
  display: block;
  width: 30px;
  height: 50px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  position: relative;
}

.scroll-indicator span::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 50%;
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  transform: translateX(-50%);
  animation: scroll 2s infinite;
}

@keyframes bounce {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  50% {
    transform: translateX(-50%) translateY(10px);
  }
}

@keyframes scroll {
  0% {
    opacity: 1;
    top: 8px;
  }

  100% {
    opacity: 0;
    top: 30px;
  }
}

/* --- GRID SİSTEMİ (Hizmetler ve Projeler) --- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.card {
  background: var(--white);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: var(--shadow);
  transition: 0.3s;
}

.card:hover {
  transform: translateY(-5px);
}

.card h3 {
  color: var(--primary);
  margin-bottom: 1rem;
}

/* --- İLETİŞİM FORMU --- */
.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

form input,
form textarea {
  width: 100%;
  padding: 10px;
  margin-bottom: 1rem;
  border: 1px solid #ccc;
  border-radius: 5px;
}

form button {
  width: 100%;
  padding: 10px;
  background: var(--primary);
  color: white;
  border: none;
  cursor: pointer;
  font-weight: bold;
}

/* --- FOOTER --- */
footer {
  background: var(--primary);
  color: #cbd5e1;
  text-align: center;
  padding: 2rem;
  margin-top: auto;
}

/* --- MOBİL UYUMLULUK --- */
@media (max-width: 768px) {
  .hamburger {
    display: block;
  }

  .hamburger.active .bar:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .nav-links {
    position: fixed;
    left: -100%;
    top: 70px;
    gap: 0;
    flex-direction: column;
    background-color: var(--white);
    width: 100%;
    text-align: center;
    transition: 0.3s;
    box-shadow: 0 10px 10px rgba(0, 0, 0, 0.1);
  }

  .nav-links.active {
    left: 0;
  }

  .nav-links li {
    padding: 1.5rem 0;
    border-bottom: 1px solid #eee;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero {
    height: 90vh;
    background-attachment: scroll;
  }

  .contact-wrapper {
    grid-template-columns: 1fr;
  }
}

/* --- BLOG STYLES --- */
.blog-card {
  position: relative;
}

.blog-date {
  font-size: 0.95rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.blog-link {
  display: inline-block;
  margin-top: 1rem;
  color: var(--accent);
  font-weight: 600;
  transition: 0.3s;
}

.blog-link:hover {
  color: #c2410c;
  transform: translateX(5px);
}

.blog-post {
  padding: 2rem 0;
}

.blog-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e2e8f0;
}

.back-link {
  color: var(--secondary);
  font-weight: 600;
  transition: 0.3s;
}

.back-link:hover {
  color: var(--accent);
}

.blog-post h1 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 2rem;
  line-height: 1.3;
}

.blog-content {
  background: var(--white);
  padding: 3rem;
  border-radius: 8px;
  box-shadow: var(--shadow);
  line-height: 1.8;
}

.blog-content h2 {
  color: var(--primary);
  margin: 2rem 0 1rem;
  font-size: 1.5rem;
}

.blog-content h3 {
  color: var(--accent);
  margin: 1.5rem 0 0.5rem;
  font-size: 1.2rem;
}

.blog-content p {
  margin-bottom: 1rem;
  color: #333;
}

.blog-content ul,
.blog-content ol {
  margin: 1rem 0 1.5rem 1.5rem;
}

.blog-content li {
  margin-bottom: 0.5rem;
  list-style: disc;
}

.blog-content ol li {
  list-style: decimal;
}

.blog-cta {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  padding: 2rem;
  border-radius: 8px;
  text-align: center;
  color: white;
  margin-top: 3rem;
}

.blog-cta h3 {
  color: white;
  margin-bottom: 0.5rem;
}

.blog-cta p {
  color: #cbd5e1;
  margin-bottom: 1.5rem;
}

/* --- PROJECT CARD STYLES --- */
.project-card {
  overflow: hidden;
}

.project-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 8px 8px 0 0;
  margin: -2rem -2rem 1rem -2rem;
  width: calc(100% + 4rem);
  transition: transform 0.3s ease;
}

.project-card:hover .project-image {
  transform: scale(1.05);
}
