/* ==========================================================================
   ServisMatch - Professional Light Theme with Extra Large Glowing Logo Icon
   ========================================================================== */

:root {
  --font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  /* Color Palette - Clean Light Theme */
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-subtle: #f1f5f9;
  --bg-green-soft: #f0fdf4;
  --border-color: #e2e8f0;
  --border-focus: #1b4332;
  
  /* Forest / Dark Green Palette */
  --green-dark: #1b4332;
  --green-dark-hover: #2d6a4f;
  --green-muted: #40916c;
  --green-chip-bg: #e8f5e9;
  --green-chip-text: #1b4332;
  
  --amber-rating: #d97706;
  --amber-bg: #fffbeb;
  
  --text-main: #0f172a;
  --text-muted: #475569;
  --text-dim: #94a3b8;
  
  --shadow-subtle: 0 1px 3px 0 rgba(0, 0, 0, 0.05), 0 1px 2px -1px rgba(0, 0, 0, 0.05);
  --shadow-card: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-float: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  
  --radius-lg: 12px;
  --radius-md: 8px;
  --radius-sm: 6px;
  --transition-fast: all 0.15s ease-in-out;
  --transition-smooth: all 0.25s ease-in-out;
}

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

body {
  font-family: var(--font-family);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}

/* Header & Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-color);
  padding: 0.85rem 2rem;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Premium Enriched Brand Logo with Huge Glowing S Icon */
.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-size: 1.65rem;
  font-weight: 900;
  letter-spacing: -0.6px;
  color: var(--text-main);
  transition: var(--transition-fast);
}

.brand:hover {
  transform: translateY(-1px);
}

.brand-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-dark-hover) 100%);
  color: #ffffff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 900;
  box-shadow: 0 6px 16px rgba(27, 67, 50, 0.35);
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.brand-text {
  font-size: 1.65rem;
  font-weight: 800;
}

.brand-text span {
  color: var(--green-dark);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.btn-nav-action {
  background: var(--green-dark);
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.6rem 1.1rem;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: var(--transition-fast);
}

.btn-nav-action:hover {
  background: var(--green-dark-hover);
  transform: translateY(-1px);
}

/* Multi-language Selector */
.lang-selector {
  display: flex;
  align-items: center;
  background: var(--bg-card-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.2rem;
  gap: 0.2rem;
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-weight: 600;
  padding: 0.3rem 0.55rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.8rem;
  transition: var(--transition-fast);
}

.lang-btn:hover {
  color: var(--text-main);
}

.lang-btn.active {
  background: #fff;
  color: var(--green-dark);
  box-shadow: var(--shadow-subtle);
}

/* Hero Section (Aligned to 1200px Grid Width) */
.hero {
  padding: 3.5rem 0 2.5rem;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.hero-badge {
  display: inline-block;
  background: var(--green-chip-bg);
  color: var(--green-dark);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.35rem 0.85rem;
  border-radius: 50px;
  margin-bottom: 1.25rem;
  border: 1px solid rgba(27, 67, 50, 0.15);
}

.hero-title {
  font-size: 2.45rem;
  font-weight: 800;
  line-height: 1.2;
  color: var(--text-main);
  margin-bottom: 1.25rem;
  letter-spacing: -0.3px;
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  white-space: nowrap;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 2.25rem;
  max-width: 950px;
  margin-left: auto;
  margin-right: auto;
}

/* Search Box Component (Stretched to 1200px Grid) */
.search-box-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 0.6rem;
  box-shadow: var(--shadow-float);
  display: grid;
  grid-template-columns: 2.5fr 1fr auto;
  gap: 0.6rem;
  margin-bottom: 2.5rem;
  width: 100%;
}

.search-input-wrap {
  display: flex;
  align-items: center;
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.9rem;
}

.search-input-wrap input, .search-input-wrap select {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  width: 100%;
  font-size: 0.95rem;
}

.btn-search-main {
  background: var(--green-dark);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.75rem 1.8rem;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.btn-search-main:hover {
  background: var(--green-dark-hover);
}

/* Stats Counter */
.stats-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto 2.5rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  width: 100%;
  gap: 1rem;
}

.stat-item {
  white-space: nowrap;
}

.stat-item strong {
  color: var(--text-main);
  font-weight: 700;
}

/* Main Container & Tabs (1200px Grid Width) */
.main-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 0 4rem;
}

.tabs-container {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 2rem;
  width: 100%;
}

.tab-btn {
  background: #fff;
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.95rem 1.25rem;
  border-radius: var(--radius-md);
  font-size: 0.98rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
  text-align: center;
  width: 100%;
}

.tab-btn:hover {
  border-color: var(--green-muted);
  color: var(--text-main);
}

.tab-btn.active {
  background: var(--green-dark);
  color: #fff;
  border-color: var(--green-dark);
  box-shadow: var(--shadow-subtle);
}

/* Filter Toolbar */
.filter-toolbar {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  margin-bottom: 1.75rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  box-shadow: var(--shadow-subtle);
  width: 100%;
}

.filter-group {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.filter-label {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 600;
}

.filter-select {
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.45rem 0.75rem;
  border-radius: var(--radius-sm);
  outline: none;
  font-size: 0.9rem;
}

.filter-select:focus {
  border-color: var(--border-focus);
}

/* Cards Grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 1.5rem;
  width: 100%;
}

.provider-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-card);
}

.provider-card:hover {
  border-color: var(--green-muted);
  box-shadow: var(--shadow-float);
  transform: translateY(-2px);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.75rem;
}

.provider-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.2rem;
}

.provider-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.rating-badge {
  background: var(--amber-bg);
  color: var(--amber-rating);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(217, 119, 6, 0.2);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.badges-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.85rem;
}

.chip-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
}

.chip-verified {
  background: var(--green-chip-bg);
  color: var(--green-dark);
  border: 1px solid rgba(27, 67, 50, 0.15);
}

.chip-fast {
  background: var(--bg-card-subtle);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.chip-lang {
  background: var(--bg-card-subtle);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.provider-bio {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-footer {
  border-top: 1px solid var(--border-color);
  padding-top: 0.85rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.price-tag {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--green-dark);
}

.price-tag span {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
}

.btn-card-action {
  background: var(--bg-card-subtle);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.btn-card-action:hover {
  background: var(--green-dark);
  color: #fff;
  border-color: var(--green-dark);
}

/* Calculator Section */
.calc-section {
  background: var(--bg-green-soft);
  border: 1px solid rgba(27, 67, 50, 0.15);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  margin: 3.5rem 0;
  width: 100%;
}

.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

.calc-info h2 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.75rem;
}

.calc-info p {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 1.25rem;
}

.price-display-box {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  text-align: center;
  box-shadow: var(--shadow-subtle);
}

.est-price-number {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--green-dark);
  margin-top: 0.25rem;
}

.calc-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  color: var(--text-main);
  outline: none;
  font-size: 0.9rem;
}

.form-group input:focus, .form-group select:focus {
  border-color: var(--border-focus);
}

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.modal-card {
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2rem;
  position: relative;
  box-shadow: var(--shadow-float);
  color: var(--text-main);
}

.btn-close-modal {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--bg-card-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-weight: 700;
}

.btn-close-modal:hover {
  color: var(--text-main);
  background: var(--border-color);
}

.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}

.gallery-grid img {
  width: 100%;
  height: 130px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.toast {
  background: var(--green-dark);
  color: #fff;
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-float);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Footer */
footer {
  border-top: 1px solid var(--border-color);
  background: #fff;
  padding: 2.5rem 1.5rem 1.5rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 1240px) {
  .hero, .main-content {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
  .hero-title {
    white-space: normal;
    font-size: 2rem;
  }
}

@media (max-width: 950px) {
  .search-box-card { grid-template-columns: 1fr; }
  .tabs-container { grid-template-columns: 1fr; }
  .calc-grid { grid-template-columns: 1fr; }
  .stats-bar { flex-direction: column; gap: 0.35rem; align-items: center; }
}
