/* ========================================
   Cherry Solutions Website - Stylesheet
   ======================================== */

/* ---- Root & Variables ---- */
:root {
  --primary-color: #1a365d;
  --accent-color: #0066cc;
  --secondary-color: #00a8cc;
  --text-dark: #333;
  --text-light: #666;
  --bg-light: #f8f9fa;
  --bg-white: #ffffff;
  --border-color: #e0e0e0;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.15);
}

/* ---- Reset & Global Styles ---- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--bg-white);
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--secondary-color);
}

/* ---- Container ---- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---- Header & Navigation ---- */
header {
  background-color: var(--primary-color);
  color: white;
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

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

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  color: white;
}

.logo span {
  color: var(--secondary-color);
}

nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
}

nav a {
  color: white;
  font-weight: 500;
  transition: color 0.3s ease;
}

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

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
}

@media (max-width: 768px) {
  nav ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background-color: var(--primary-color);
    padding: 1rem;
  }

  nav ul.active {
    display: flex;
  }

  nav li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.5rem 0;
  }

  .menu-toggle {
    display: block;
  }

  .header-content {
    flex-wrap: wrap;
  }
}

/* ---- Sections & Layout ---- */
section {
  padding: 4rem 0;
}

section:nth-child(even) {
  background-color: var(--bg-light);
}

.section-title {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 1rem;
  text-align: center;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-light);
  text-align: center;
  margin-bottom: 3rem;
}

/* ---- Hero Section ---- */
.hero {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
  color: white;
  padding: 6rem 0;
  text-align: center;
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  font-weight: bold;
}

.hero p {
  font-size: 1.3rem;
  margin-bottom: 2rem;
  opacity: 0.95;
}

.hero .subtitle {
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  opacity: 0.9;
}

/* ---- Buttons ---- */
.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 0.4rem;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid;
  font-size: 1rem;
}

.btn-primary {
  background-color: var(--accent-color);
  color: white;
  border-color: var(--accent-color);
}

.btn-primary:hover {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background-color: transparent;
  color: white;
  border-color: white;
}

.btn-secondary:hover {
  background-color: white;
  color: var(--primary-color);
}

.btn-outline {
  background-color: transparent;
  color: var(--accent-color);
  border-color: var(--accent-color);
}

.btn-outline:hover {
  background-color: var(--accent-color);
  color: white;
}

/* ---- Cards & Grid ---- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.card {
  background-color: var(--bg-white);
  border-radius: 0.5rem;
  padding: 2rem;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.card-title {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-weight: bold;
}

.card-description {
  color: var(--text-light);
  margin-bottom: 1rem;
  line-height: 1.8;
}

.card-list {
  list-style: none;
  margin-top: 1rem;
}

.card-list li {
  padding: 0.3rem 0;
  color: var(--text-light);
}

.card-list li:before {
  content: "✓ ";
  color: var(--secondary-color);
  font-weight: bold;
  margin-right: 0.5rem;
}

/* ---- Why Section ---- */
.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.why-item {
  padding: 1.5rem;
  background-color: var(--bg-white);
  border-left: 4px solid var(--accent-color);
  border-radius: 0.3rem;
}

.why-item h4 {
  color: var(--primary-color);
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.why-item p {
  color: var(--text-light);
  font-size: 0.95rem;
}

/* ---- Case Studies ---- */
.case-study {
  background-color: var(--bg-white);
  border-radius: 0.5rem;
  padding: 2.5rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--accent-color);
}

.case-study h3 {
  color: var(--primary-color);
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
}

.case-study-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.9rem;
  color: var(--text-light);
}

.case-study-meta span {
  font-weight: 600;
  color: var(--primary-color);
}

.case-study h4 {
  color: var(--accent-color);
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.case-study p {
  color: var(--text-light);
  margin-bottom: 1rem;
  line-height: 1.8;
}

.case-study ul {
  list-style-position: inside;
  color: var(--text-light);
  margin-bottom: 1rem;
}

.case-study ul li {
  margin-bottom: 0.3rem;
}

.tech-stack {
  background-color: var(--bg-light);
  padding: 1rem;
  border-radius: 0.3rem;
  margin: 1rem 0;
}

.tech-stack strong {
  color: var(--primary-color);
}

/* ---- About Section ---- */
.about-intro {
  font-size: 1.1rem;
  line-height: 1.9;
  color: var(--text-light);
  margin-bottom: 2rem;
}

.about-intro p {
  margin-bottom: 1rem;
}

.competencies-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.competency-section h4 {
  color: var(--accent-color);
  font-size: 1.2rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid var(--accent-color);
  padding-bottom: 0.5rem;
}

.competency-section ul {
  list-style-position: inside;
  color: var(--text-light);
}

.competency-section li {
  margin-bottom: 0.5rem;
}

/* ---- Contact Form ---- */
.contact-form {
  max-width: 600px;
  margin: 2rem auto;
  background-color: var(--bg-white);
  padding: 2rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--primary-color);
}

input,
textarea,
select {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid var(--border-color);
  border-radius: 0.3rem;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text-dark);
  transition: border-color 0.3s ease;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

textarea {
  resize: vertical;
  min-height: 120px;
}

.form-error {
  color: #d32f2f;
  font-size: 0.85rem;
  margin-top: 0.3rem;
  display: none;
}

.form-group.error input,
.form-group.error textarea,
.form-group.error select {
  border-color: #d32f2f;
}

.form-group.error .form-error {
  display: block;
}

.form-success {
  background-color: #4caf50;
  color: white;
  padding: 1rem;
  border-radius: 0.3rem;
  margin-bottom: 1rem;
  display: none;
}

.form-success.show {
  display: block;
}

/* ---- Footer ---- */
footer {
  background-color: var(--primary-color);
  color: white;
  padding: 3rem 0 1rem;
  margin-top: 4rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  color: var(--secondary-color);
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section a {
  color: rgba(255, 255, 255, 0.8);
  transition: color 0.3s ease;
}

.footer-section a:hover {
  color: var(--secondary-color);
}

.footer-contact {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 0.5rem;
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
}

/* ---- Responsive Design ---- */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .hero p {
    font-size: 1.1rem;
  }

  section {
    padding: 2rem 0;
  }

  .section-title {
    font-size: 2rem;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .case-study {
    padding: 1.5rem;
  }

  .contact-form {
    padding: 1.5rem;
  }

  nav ul {
    gap: 0;
  }

  nav li {
    padding: 0.8rem 0;
  }
}

@media (max-width: 480px) {
  .logo {
    font-size: 1.3rem;
  }

  .hero h1 {
    font-size: 1.8rem;
  }

  .hero p {
    font-size: 1rem;
  }

  .section-title {
    font-size: 1.5rem;
  }

  .btn {
    padding: 0.7rem 1.5rem;
    font-size: 0.9rem;
  }
}

/* ---- Utilities ---- */
.text-center {
  text-align: center;
}

.mt-2 {
  margin-top: 1rem;
}

.mt-4 {
  margin-top: 2rem;
}

.mb-2 {
  margin-bottom: 1rem;
}

.mb-4 {
  margin-bottom: 2rem;
}

.text-muted {
  color: var(--text-light);
}
