/* Reset and Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #2c509a;
  --primary-dark: #4865a0;
  --color-brand: #2c509a;
  --color-brand-dark: #2c509a;
  --secondary: #00D26A;
  --accent: #FF6B00;
  --background: #FFFFFF;
  --surface: #F5F7FA;
  --surface-dark: #E8ECF0;
  --border: #D8DDE4;
  --text-primary: #0D0D0D;
  --text-secondary: #5C6470;
  --text-muted: #8A929D;
  --error: #FF3D3D;
  --success: #00C853;
  --warning: #FFB800;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-primary);
  background: var(--background);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

img {
  max-width: 100%;
  height: auto;
}

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

@media (min-width: 640px) {
  .container {
    padding: 0 24px;
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 32px;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  white-space: nowrap;
}

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

.btn-primary:hover {
  background: var(--primary-dark);
}

.btn-secondary {
  background: #ffd540 !important;
  color: #000 !important;
  border: 1px solid #ffd540 !important;
  font-weight: 600;
}

.btn-secondary:hover {
  background: #ffd540;
}

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

.btn-white:hover {
  background: rgba(255, 255, 255, 0.9);
}

.btn-outline-white {
  background: transparent;
  color: white;
  border: 1px solid white;
}

.btn-outline-white:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: white;
  border-bottom: 1px solid var(--border);
}

.top-bar {
  background: var(--surface);
  padding: 8px 0;
  font-size: 12px;
  color: var(--text-secondary);
  display: none;
}

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

.top-bar-links {
  display: flex;
  gap: 24px;
}

.top-bar-links a:hover {
  color: var(--primary);
}

.top-bar-phone {
  display: none;
}

@media (min-width: 640px) {
  .top-bar-phone {
    display: block;
  }
}

.main-header {
  padding: 16px 0;
}

.header-content {
  display: flex;
  align-items: center;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: var(--primary);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.logo-text {
  display: none;
}

@media (min-width: 640px) {
  .logo-text {
    display: block;
  }
}

.logo-main {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
}

.logo-suffix {
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
}

.catalog-btn {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--primary);
  color: white;
  border-radius: 8px;
  font-weight: 500;
}

.catalog-btn:hover {
  background: var(--primary-dark);
}

@media (min-width: 768px) {
  .catalog-btn {
    display: flex;
  }
}

.search-box {
  flex: 1;
  max-width: 600px;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 10px 44px 10px 16px;
  background: var(--surface);
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
}

.search-box input:focus {
  background: white;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 91, 255, 0.1);
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.search-btn {
position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  padding: 7px 40px !important;
}

.search-btn:hover {
  color: #d2d2d2;
}

.header-actions {
  display: none;
  align-items: center;
  gap: 8px;
}

@media (min-width: 1024px) {
  .header-actions {
    display: flex;
  }
}

.icon-btn {
  padding: 10px;
  color: var(--text-secondary);
  border-radius: 8px;
  transition: all 0.2s;
}

.icon-btn:hover {
  background: var(--surface);
  color: var(--primary);
}

.auth-buttons {
  display: flex;
  gap: 8px;
}

.mobile-menu-btn {
  padding: 8px;
  color: var(--text-secondary);
  margin-left: auto;
}

@media (min-width: 1024px) {
  .mobile-menu-btn {
    display: none;
  }
}

/* Catalog Dropdown */
.catalog-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border-bottom: 1px solid var(--border);
  padding: 24px 0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.catalog-dropdown.active {
  display: block;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (min-width: 640px) {
  .catalog-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.catalog-item {
  padding: 12px 16px;
  border-radius: 8px;
  transition: all 0.2s;
}

.catalog-item:hover {
  background: var(--surface);
  color: var(--primary);
}

/* Mobile Menu */
.mobile-menu {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: white;
  z-index: 200;
  padding: 16px;
  flex-direction: column;
}

.mobile-menu.active {
  display: flex;
}

.mobile-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.mobile-menu-title {
  font-size: 18px;
  font-weight: 600;
}

.mobile-menu-close {
  padding: 8px;
  color: var(--text-secondary);
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.mobile-nav a {
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 16px;
}

.mobile-nav a:hover {
  background: var(--surface);
  color: var(--primary);
}

.mobile-auth {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* Hero Section */
.hero {
  position: relative;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 64px 0;
  overflow: hidden;
}

@media (min-width: 1024px) {
  .hero {
    padding: 96px 0;
  }
}

.hero-bg {
  position: absolute;
  inset: 0;
  opacity: 0.1;
  background-image: url('../images/hero-banner.jpg');
  background-size: cover;
  background-position: center;
}

.hero-content {
  position: relative;
  max-width: 640px;
}

.hero-title {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  color: #fff;
}

@media (min-width: 640px) {
  .hero-title {
    font-size: 40px;
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 48px;
  }
}

.hero-subtitle {
  font-size: 16px;
  line-height: 1.6;
  opacity: 0.9;
  margin-bottom: 32px;
  color: #fff;
}

@media (min-width: 640px) {
  .hero-subtitle {
    font-size: 18px;
  }
}

.hero-search {
  margin-bottom: 32px;
}

.hero-search-box {
  display: flex;
  background: white;
  border-radius: 12px;
  padding: 8px;
  gap: 8px;
}

.hero-search-box .search-icon {
  position: absolute;
  left: 24px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.hero-search-box input {
  flex: 1;
  padding: 12px 16px;
  border: none;
  outline: none;
  font-size: 16px;
  color: var(--text-primary);
}

.hero-search-box input::placeholder {
  color: var(--text-muted);
}

.hero-search-box .btn {
  padding: 12px 32px;
}

.hero-features {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.hero-feature {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

/* Section */
.section {
  padding: 48px 0;
}

@media (min-width: 1024px) {
  .section {
    padding: 64px 0;
  }
}

.section-gray {
  background: var(--surface);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.section-title {
  font-size: 24px;
  font-weight: 600;
}

@media (min-width: 640px) {
  .section-title {
    font-size: 28px;
  }
}

.section-link {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--primary);
  font-weight: 500;
}

.section-link:hover {
  text-decoration: underline;
}

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

/* Categories Grid */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (min-width: 640px) {
  .categories-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .categories-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.category-card {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  display: block;
}

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.category-card:hover img {
  transform: scale(1.1);
}

.category-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.2) 50%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
  color: white;
}

.category-overlay h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}

.category-overlay span {
  font-size: 12px;
  opacity: 0.8;
}

/* Products Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (min-width: 640px) {
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .products-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
  }
}

.product-card {
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
  transition: all 0.2s;
}

.product-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  transform: translateY(-4px);
}

.product-image {
  position: relative;
  aspect-ratio: 1;
  background: var(--surface);
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.favorite-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all 0.2s;
}

.favorite-btn:hover {
  color: var(--error);
}

.product-brand {
  position: absolute;
  bottom: 12px;
  left: 12px;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
}

.product-info {
  padding: 16px;
}

.product-name {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 40px;
}

.product-price {
  margin-bottom: 8px;
}

.price-main {
  font-size: 18px;
  font-weight: 700;
}

.price-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: 4px;
}

.product-meta {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--text-secondary);
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 48px;
}

@media (min-width: 640px) {
  .features-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

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

.feature-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.feature-item h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-item p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* CTA Box */
.cta-box {
  background: linear-gradient(135deg, #0D0D0D 0%, #1a1a1a 100%);
  border-radius: 16px;
  padding: 48px 32px;
  text-align: center;
  color: white;
}

.cta-box h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 12px;
}

@media (min-width: 640px) {
  .cta-box h2 {
    font-size: 28px;
  }
}

.cta-box p {
  opacity: 0.8;
  max-width: 600px;
  margin: 0 auto 24px;
  line-height: 1.6;
}

.cta-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: center;
}

@media (min-width: 640px) {
  .cta-buttons {
    flex-direction: row;
  }
}

/* Footer */
.footer {
  background: #0D0D0D;
  color: white;
  padding: 48px 0 24px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

@media (min-width: 640px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.footer-logo .logo-icon {
  background: var(--primary);
}

.footer-logo .logo-main {
  color: white;
}

.footer-desc {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 16px;
}

.footer-contacts {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-contacts a,
.footer-address {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 14px;
}

.footer-contacts a:hover {
  color: white;
}

.footer-col h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col ul a {
  color: var(--text-muted);
  font-size: 14px;
}

.footer-col ul a:hover {
  color: white;
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 640px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
  }
}

.footer-bottom p {
  color: var(--text-muted);
  font-size: 14px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.social-link:hover {
  background: var(--primary);
}

/* Breadcrumbs */
.breadcrumbs {
  background: white;
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}

.breadcrumbs-list {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.breadcrumbs-list a {
  color: var(--text-secondary);
}

.breadcrumbs-list a:hover {
  color: var(--primary);
}

.breadcrumbs-list span {
  color: var(--text-primary);
}

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

/* Page Content */
.page-content {
  padding: 24px 0;
}

/* Card */
.card {
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
}

.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.card-title {
  font-size: 16px;
  font-weight: 600;
}

.card-body {
  padding: 20px;
}

/* Form Elements */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 91, 255, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

/* Tabs */
.tabs {
  display: flex;
  gap: 4px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 4px;
  margin-bottom: 20px;
  overflow-x: auto;
}

.tab {
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  transition: all 0.2s;
}

.tab.active {
  background: var(--primary);
  color: white;
}

.tab:not(.active):hover {
  background: var(--surface);
}

/* Table */
.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.table th {
  background: var(--surface);
  font-weight: 500;
  font-size: 12px;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.table tr:hover td {
  background: var(--surface);
}

/* Badge */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 500;
}

.badge-blue {
  background: rgba(0, 91, 255, 0.1);
  color: var(--primary);
}

.badge-green {
  background: rgba(0, 210, 106, 0.1);
  color: var(--secondary);
}

.badge-orange {
  background: rgba(255, 107, 0, 0.1);
  color: var(--accent);
}

.badge-gray {
  background: var(--surface);
  color: var(--text-secondary);
}

/* Chat */
.chat-container {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 200px);
  min-height: 500px;
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: white;
}

.chat-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.chat-avatar {
  width: 40px;
  height: 40px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 500;
}

.chat-user-info h4 {
  font-size: 14px;
  font-weight: 600;
}

.chat-user-info span {
  font-size: 12px;
  color: var(--secondary);
}

.chat-actions {
  display: flex;
  gap: 8px;
}

.chat-product {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.chat-product img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 8px;
}

.chat-product-info {
  flex: 1;
}

.chat-product-info h5 {
  font-size: 14px;
  font-weight: 500;
}

.chat-product-info span {
  font-size: 14px;
  color: var(--primary);
  font-weight: 600;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  background: var(--surface);
}

.message {
  display: flex;
  margin-bottom: 16px;
}

.message.sent {
  justify-content: flex-end;
}

.message-bubble {
  max-width: 70%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.5;
}

.message.received .message-bubble {
  background: white;
  color: var(--text-primary);
  border-bottom-left-radius: 4px;
}

.message.sent .message-bubble {
  background: var(--primary);
  color: white;
  border-bottom-right-radius: 4px;
}

.message-time {
  font-size: 11px;
  opacity: 0.7;
  margin-top: 4px;
  text-align: right;
}

.chat-input {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 16px 20px;
  background: white;
  border-top: 1px solid var(--border);
}

.chat-input button {
  padding: 10px;
  color: var(--text-secondary);
  border-radius: 8px;
}

.chat-input button:hover {
  background: var(--surface);
  color: var(--primary);
}

.chat-input input {
  flex: 1;
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: none;
}

.chat-input input:focus {
  border-color: var(--primary);
}

.chat-input .btn-primary {
  padding: 10px;
}

/* Chat List */
.chat-list {
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  overflow: hidden;
}

.chat-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}

.chat-list-item:hover {
  background: var(--surface);
}

.chat-list-item:last-child {
  border-bottom: none;
}

.chat-list-content {
  flex: 1;
  min-width: 0;
}

.chat-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.chat-list-header h4 {
  font-size: 14px;
  font-weight: 500;
}

.chat-list-header span {
  font-size: 12px;
  color: var(--text-muted);
}

.chat-list-preview {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-list-preview.unread {
  color: var(--text-primary);
  font-weight: 500;
}

.chat-list-badge {
  width: 20px;
  height: 20px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 11px;
  font-weight: 500;
}

/* Dashboard */
.dashboard-layout {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 1024px) {
  .dashboard-layout {
    flex-direction: row;
  }
}

.dashboard-sidebar {
  width: 100%;
}

@media (min-width: 1024px) {
  .dashboard-sidebar {
    width: 260px;
    flex-shrink: 0;
  }
}

.dashboard-nav {
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 16px;
}

.dashboard-user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.dashboard-user-avatar {
  width: 48px;
  height: 48px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.dashboard-user-info h4 {
  font-size: 14px;
  font-weight: 600;
}

.dashboard-user-info span {
  font-size: 12px;
  color: var(--text-muted);
}

.dashboard-menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dashboard-menu a,
.dashboard-menu button {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  text-align: left;
  width: 100%;
}

.dashboard-menu a:hover,
.dashboard-menu button:hover {
  background: var(--surface);
  color: var(--primary);
}

.dashboard-menu a.active,
.dashboard-menu button.active {
  background: var(--surface);
  color: var(--primary);
  font-weight: 500;
}

.dashboard-content {
  flex: 1;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

@media (min-width: 640px) {
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.stat-card {
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 16px;
}

.stat-card-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}

.stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 10px;
}

.stat-value {
  font-size: 21px;
  font-weight: 700;
}

.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 15px;
}


.welcome-card {
    position: relative;
    overflow: hidden;

    background: linear-gradient(
        135deg,
        #2c509a 0%,
        #006be7 50%,
        #2c509a 100%
    );

    background-size: 200% 200%;
    animation: gradientMove 6s ease infinite;

    border-radius: 12px;
    padding: 24px;
    color: #fff;
    margin-bottom: 24px;
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}
.welcome-card::after {
    content: "";
    position: absolute;

    top: -30%;
    left: -40%;

    width: 220px;
    height: 220%;

    background: radial-gradient(
        ellipse at center,
        rgba(255,255,255,0.28) 0%,
        rgba(255,255,255,0.18) 25%,
        rgba(255,255,255,0.08) 45%,
        transparent 75%
    );

    filter: blur(22px);

    transform: rotate(18deg);

    animation: shineMove 9s ease-in-out infinite;

    pointer-events: none;
}

@keyframes shineMove {
    0% {
        left: -45%;
        opacity: 0;
    }

    15% {
        opacity: 1;
    }

    50% {
        left: 45%;
        opacity: 0.9;
    }

    85% {
        opacity: 1;
    }

    100% {
        left: 120%;
        opacity: 0;
    }
}
.welcome-card h2 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
  color: #fff;
}

.welcome-card p {
  opacity: 0.8;
  color: #fff;
}

/* Filter Sidebar */
.filter-sidebar {
  background: white;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 20px;
}

.filter-group {
  margin-bottom: 24px;
}

.filter-group:last-child {
  margin-bottom: 0;
}

.filter-group h4 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
}

.filter-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.filter-option {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  cursor: pointer;
}

.filter-option input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 32px;
}

.page-btn {
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.page-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

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

.page-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Accordion */
.accordion {
  border-radius: 12px;
  overflow: hidden;
}

.accordion-item {
  background: white;
  border: 1px solid var(--border);
  margin-bottom: 8px;
  border-radius: 12px;
  overflow: hidden;
}

.accordion-header {
  width: 100%;
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  font-weight: 500;
  text-align: left;
}

.accordion-header:hover {
  background: var(--surface);
}

.accordion-content {
  padding: 0 20px 16px;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
}

/* Steps */
.steps {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 32px;
}

.step {
  display: flex;
  align-items: center;
  gap: 8px;
}

.step-number {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 600;
}

.step.active .step-number {
  background: var(--primary);
  color: white;
}

.step:not(.active) .step-number {
  background: var(--border);
  color: var(--text-muted);
}

.step-label {
  display: none;
  font-size: 14px;
  font-weight: 500;
}

@media (min-width: 640px) {
  .step-label {
    display: block;
  }
}

.step.active .step-label {
  color: var(--primary);
}

.step:not(.active) .step-label {
  color: var(--text-muted);
}

.step-line {
  flex: 1;
  height: 2px;
  background: var(--border);
}

.step-line.active {
  background: var(--primary);
}

/* Info Box */
.info-box {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  border-radius: 8px;
  font-size: 14px;
}

.info-box.blue {
  background: rgba(0, 91, 255, 0.05);
}

.info-box.orange {
  background: rgba(255, 184, 0, 0.1);
}

.info-box svg {
  flex-shrink: 0;
  margin-top: 2px;
}

/* Success State */
.success-state {
  text-align: center;
  padding: 48px 24px;
}

.success-icon {
  width: 80px;
  height: 80px;
  background: rgba(0, 210, 106, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}

.success-state h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 12px;
}

.success-state p {
  color: var(--text-secondary);
  max-width: 400px;
  margin: 0 auto 24px;
}

/* Utility Classes */
.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.gap-2 {
  gap: 8px;
}

.gap-4 {
  gap: 16px;
}

.mt-4 {
  margin-top: 16px;
}

.mt-6 {
  margin-top: 24px;
}

.mb-4 {
  margin-bottom: 16px;
}

.mb-6 {
  margin-bottom: 24px;
}

.flex {
  display: flex;
}

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

.justify-between {
  justify-content: space-between;
}

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

.grid {
  display: grid;
}

.w-full {
  width: 100%;
}

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

/* ============================================
   NEW PAGES STYLES
   Manufacturers, Suppliers, Supplier Profile
   ============================================ */

/* Page Header */
.page-header {
  margin-bottom: 32px;
}

.page-title {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
}

@media (min-width: 640px) {
  .page-title {
    font-size: 32px;
  }
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 16px;
}

/* Alphabet Filter */
.alphabet-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 24px;
  padding: 12px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.alphabet-letter {
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.alphabet-letter:hover {
  background: var(--surface);
  color: var(--primary);
}

.alphabet-letter.active {
  background: var(--primary);
  color: white;
}

/* Category Pills */
.category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-pill {
  padding: 8px 16px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 9999px;
  font-size: 14px;
  color: var(--text-secondary);
  transition: all 0.2s;
  cursor: pointer;
}

.category-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.category-pill.active {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

/* Letter Group */
.letter-group {
  margin-bottom: 40px;
}

.letter-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
}

/* Manufacturers Grid */
.manufacturers-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 16px;
}

@media (min-width: 640px) {
  .manufacturers-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .manufacturers-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.manufacturer-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: all 0.2s;
}

.manufacturer-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
  border-color: var(--primary);
}

.manufacturer-logo {
  width: 64px;
  height: 64px;
  background: var(--surface);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.manufacturer-info {
  flex: 1;
  min-width: 0;
}

.manufacturer-name {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.manufacturer-country {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.manufacturer-products {
  font-size: 13px;
  color: var(--primary);
  font-weight: 500;
}

/* Suppliers List */
.suppliers-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.supplier-card-large {
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s;
}

.supplier-card-large:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.supplier-card-header {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 20px;
  border-bottom: 1px solid var(--border);
}

.supplier-card-logo {
  width: 64px;
  height: 64px;
  background: var(--surface);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.supplier-card-info {
  flex: 1;
  min-width: 200px;
}

.supplier-card-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.supplier-card-title h3 {
  font-size: 18px;
  font-weight: 600;
}

.supplier-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
  color: var(--text-secondary);
}

.supplier-location,
.supplier-rating,
.supplier-products {
  display: flex;
  align-items: center;
  gap: 4px;
}

.supplier-rating svg {
  color: var(--warning);
}

.supplier-card-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

@media (min-width: 640px) {
  .supplier-card-actions {
    flex-direction: row;
  }
}

.supplier-card-body {
  padding: 20px;
}

.supplier-description {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

.supplier-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.category-tag {
  padding: 4px 12px;
  background: var(--surface);
  border-radius: 9999px;
  font-size: 12px;
  color: var(--text-secondary);
}

.supplier-stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.supplier-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.supplier-stat-value {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.supplier-stat-label {
  font-size: 12px;
  color: var(--text-muted);
}

/* Filter More Link */
.filter-more {
  display: inline-block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--primary);
}

.filter-more:hover {
  text-decoration: underline;
}

/* Catalog Toolbar */
.catalog-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding: 16px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.results-count {
  font-size: 14px;
  color: var(--text-secondary);
}

.sort-dropdown {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.sort-dropdown span {
  color: var(--text-secondary);
}

/* Pagination (Extended) */
.pagination-ellipsis {
  padding: 8px;
  color: var(--text-muted);
}

/* ============================================
   SUPPLIER PROFILE PAGE
   ============================================ */

.supplier-profile-header {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
  padding: 24px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.supplier-profile-main {
  display: flex;
  gap: 20px;
  flex: 1;
}

.supplier-profile-logo {
  width: 80px;
  height: 80px;
  background: var(--surface);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.supplier-profile-info {
  flex: 1;
  min-width: 200px;
}

.supplier-profile-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.supplier-profile-title h1 {
  font-size: 24px;
  font-weight: 700;
}

@media (min-width: 640px) {
  .supplier-profile-title h1 {
    font-size: 28px;
  }
}

.supplier-profile-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 12px;
}

.supplier-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: var(--text-secondary);
}

.supplier-profile-rating {
  display: flex;
  align-items: center;
  gap: 8px;
}

.rating-stars {
  display: flex;
  gap: 2px;
  color: var(--warning);
}

.rating-value {
  font-size: 18px;
  font-weight: 700;
}

.rating-count {
  font-size: 14px;
  color: var(--text-secondary);
}

.supplier-profile-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

@media (min-width: 640px) {
  .supplier-profile-actions {
    flex-direction: row;
  }
}

.btn-large {
  padding: 14px 28px;
  font-size: 15px;
}

/* Contact Reveal */
.contact-reveal {
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  background: var(--surface);
  border-radius: 8px;
}

.contact-item svg {
  color: var(--primary);
  flex-shrink: 0;
}

.contact-label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.contact-value {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Supplier Stats Cards */
.supplier-stats-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (min-width: 640px) {
  .supplier-stats-cards {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .supplier-stats-cards {
    grid-template-columns: repeat(5, 1fr);
  }
}

.stat-card {
  text-align: left;
  padding: 12px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  line-height: 25px;
}

.stat-card-value {
  display: block;
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.stat-card-label {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Tabs Container */
.tabs-container {
  margin-top: 32px;
}

.tabs-nav {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
  overflow-x: auto;
}

.tab-btn {
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
  transition: all 0.2s;
}

.tab-btn:hover {
  color: var(--primary);
}

.tab-btn.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* Company Details */
.company-details {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.detail-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.detail-label {
  min-width: 150px;
  font-size: 14px;
  color: var(--text-secondary);
}

.detail-value {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Reviews */
.reviews-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 32px;
  padding: 24px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.reviews-rating {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.reviews-rating-value {
  font-size: 48px;
  font-weight: 700;
  color: var(--text-primary);
}

.reviews-count {
  font-size: 14px;
  color: var(--text-secondary);
}

.reviews-bars {
  flex: 1;
  min-width: 250px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.review-bar {
  display: flex;
  align-items: center;
  gap: 12px;
}

.review-bar span:first-child {
  width: 16px;
  font-size: 14px;
  color: var(--text-secondary);
}

.review-bar-track {
  flex: 1;
  height: 8px;
  background: var(--surface);
  border-radius: 4px;
  overflow: hidden;
}

.review-bar-fill {
  height: 100%;
  background: var(--warning);
  border-radius: 4px;
}

.review-bar span:last-child {
  width: 30px;
  font-size: 13px;
  color: var(--text-secondary);
  text-align: right;
}

/* Review Card */
.reviews-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.review-card {
  padding: 20px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.review-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.review-avatar {
  width: 40px;
  height: 40px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 14px;
  font-weight: 500;
}

.review-name {
  font-size: 14px;
  font-weight: 600;
}

.review-date {
  font-size: 12px;
  color: var(--text-muted);
}

.review-rating {
  display: flex;
  gap: 2px;
  color: var(--warning);
}

.review-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Documents */
.documents-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.document-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: var(--surface);
  border-radius: 8px;
}

.document-info {
  flex: 1;
  min-width: 0;
}

.document-name {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.document-meta {
  font-size: 12px;
  color: var(--text-muted);
}

/* Badges Extended */
.badge-success {
  background: rgba(0, 200, 83, 0.1);
  color: var(--success);
}

.badge-primary {
  background: rgba(0, 91, 255, 0.1);
  color: var(--primary);
}

.badge-warning {
  background: rgba(255, 184, 0, 0.1);
  color: var(--warning);
}

/* Product Content (for supplier profile) */
.product-content {
  padding: 16px;
}

.product-title {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 40px;
}

.product-price {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.product-supplier {
  font-size: 12px;
  color: var(--text-muted);
}
.supplier-offers-list {
  width: 100%;
}

.supplier-offer-row {
  display: grid;
  grid-template-columns: 1.6fr 2.2fr 1fr 1fr 140px;
  gap: 20px;
  align-items: center;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

.supplier-offer-row:last-child {
  border-bottom: 0;
}

.supplier-offer-name {
  display: block;
  color: var(--primary);
  font-weight: 500;
  margin-bottom: 4px;
}

.supplier-offer-rating {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #008000;
  line-height: 1;
}

.supplier-offer-rating a {
  color: var(--primary);
}

.supplier-offer-delivery strong,
.supplier-offer-delivery span {
  display: block;
  color: var(--text-primary);
}

.supplier-offer-price,
.supplier-offer-min {
  font-weight: 500;
}

.supplier-offer-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 130px;
  height: 42px;
  border-radius: 4px;
  background: #008bd2;
  color: #fff;
  font-weight: 600;
}

.supplier-offer-btn:hover {
  color: #fff;
  background: #0079b8;
}

@media (max-width: 768px) {
  .supplier-offer-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .supplier-offer-btn {
    width: 100%;
  }
}