/* OfficeEra - Premium Office Furniture */
:root {
  --primary: #1B3A6B;
  --primary-dark: #122850;
  --primary-light: #2a4a7c;
  --accent: #E8A020;
  --accent-hover: #d09018;
  --secondary: #1a1a1a;
  --text: #333333;
  --text-light: #666666;
  --text-muted: #888888;
  --bg: #ffffff;
  --bg-warm: #F8F6F2;
  --bg-light: #fafafa;
  --border: #e5e5e5;
  --border-light: #eeeeee;
  --success: #28a745;
  --error: #dc3545;
  --warning: #ffc107;
  --radius: 8px;
  --radius-sm: 4px;
  --shadow: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-lg: 0 4px 20px rgba(0,0,0,0.12);
  --transition: all 0.3s ease;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--text);
  line-height: 1.6;
  background: var(--bg);
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }

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

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.container-fluid { max-width: 1400px; margin: 0 auto; padding: 0 20px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 28px; font-size: 15px; font-weight: 500;
  border-radius: var(--radius); border: none; cursor: pointer;
  transition: var(--transition); text-decoration: none;
}
.btn-primary {
  background: var(--primary); color: #fff;
}
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-accent {
  background: var(--accent); color: #fff;
}
.btn-accent:hover { background: var(--accent-hover); color: #fff; }
.btn-outline {
  background: transparent; color: var(--primary);
  border: 2px solid var(--primary);
}
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-lg { padding: 16px 40px; font-size: 17px; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* Header */
.header {
  position: sticky; top: 0; z-index: 1000;
  background: var(--bg); border-bottom: 1px solid var(--border-light);
  box-shadow: var(--shadow);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 70px;
}
.logo {
  display: flex; flex-direction: column;
}
.logo a {
  font-size: 26px; font-weight: 700; color: var(--primary);
  letter-spacing: -0.5px;
}
.logo span {
  font-size: 11px; color: var(--text-muted); margin-top: -4px;
}
.nav-main {
  display: flex; gap: 32px;
}
.nav-main a {
  font-size: 15px; font-weight: 500; color: var(--text);
  padding: 8px 0; position: relative;
}
.nav-main a:hover { color: var(--primary); }
.nav-main a::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 0; height: 2px; background: var(--primary);
  transition: var(--transition);
}
.nav-main a:hover::after { width: 100%; }

.header-actions {
  display: flex; align-items: center; gap: 20px;
}
.cart-icon {
  position: relative; padding: 8px;
}
.cart-icon svg { width: 24px; height: 24px; color: var(--text); }
.cart-count {
  position: absolute; top: 0; right: 0;
  background: var(--accent); color: #fff;
  font-size: 11px; font-weight: 600;
  min-width: 18px; height: 18px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
}
.lang-switch {
  font-size: 13px; font-weight: 500; color: var(--text);
  padding: 6px 12px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); background: var(--bg);
  cursor: pointer; transition: var(--transition);
}
.lang-switch:hover { border-color: var(--primary); color: var(--primary); }

.mobile-menu-btn {
  display: none; flex-direction: column; gap: 5px;
  padding: 8px; cursor: pointer;
}
.mobile-menu-btn span {
  width: 24px; height: 2px; background: var(--text);
}

/* Hero */
.hero {
  position: relative; min-height: 600px;
  display: flex; align-items: center;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0.3;
}
.hero-content {
  position: relative; z-index: 1;
  max-width: 600px; padding: 80px 0;
  color: #fff;
}
.hero-content h1 {
  font-size: 52px; font-weight: 700; line-height: 1.2;
  margin-bottom: 20px;
}
.hero-content p {
  font-size: 20px; opacity: 0.9; margin-bottom: 32px;
}

/* Features bar */
.features-bar {
  background: var(--bg-warm); padding: 40px 0;
  border-bottom: 1px solid var(--border-light);
}
.features-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px;
}
.feature-item {
  display: flex; align-items: center; gap: 16px;
}
.feature-icon {
  width: 48px; height: 48px;
  background: var(--primary); border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 20px;
}
.feature-text h4 { font-size: 15px; font-weight: 600; }
.feature-text p { font-size: 13px; color: var(--text-light); }

/* Section */
.section { padding: 80px 0; }
.section-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 40px;
}
.section-title {
  font-size: 32px; font-weight: 700; color: var(--secondary);
}
.view-all {
  font-size: 14px; font-weight: 500; color: var(--primary);
  display: flex; align-items: center; gap: 4px;
}

/* Product cards */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.product-card {
  background: var(--bg); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow);
  transition: var(--transition);
}
.product-card:hover {
  transform: translateY(-4px); box-shadow: var(--shadow-lg);
}
.product-image {
  position: relative; aspect-ratio: 4/3;
  overflow: hidden; background: var(--bg-light);
}
.product-image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease;
}
.product-card:hover .product-image img { transform: scale(1.05); }
.product-badge {
  position: absolute; top: 12px; left: 12px;
  padding: 4px 12px; font-size: 12px; font-weight: 600;
  border-radius: var(--radius-sm);
}
.badge-sale { background: var(--error); color: #fff; }
.badge-new { background: var(--success); color: #fff; }
.product-info { padding: 20px; }
.product-category {
  font-size: 12px; color: var(--text-muted); text-transform: uppercase;
  letter-spacing: 0.5px; margin-bottom: 8px;
}
.product-name {
  font-size: 16px; font-weight: 600; color: var(--secondary);
  margin-bottom: 12px; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.product-price {
  display: flex; align-items: center; gap: 10px;
}
.price-current {
  font-size: 18px; font-weight: 700; color: var(--primary);
}
.price-original {
  font-size: 14px; color: var(--text-muted); text-decoration: line-through;
}

/* Categories */
.category-grid {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px;
}
.category-card {
  position: relative; border-radius: var(--radius);
  overflow: hidden; aspect-ratio: 1;
}
.category-card img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease;
}
.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%, transparent 60%);
  display: flex; align-items: flex-end; padding: 20px;
}
.category-name {
  color: #fff; font-size: 18px; font-weight: 600;
}

/* Newsletter */
.newsletter {
  background: var(--primary); padding: 80px 0;
  text-align: center; color: #fff;
}
.newsletter h2 { font-size: 36px; margin-bottom: 12px; }
.newsletter p { opacity: 0.9; margin-bottom: 32px; }
.newsletter-form {
  display: flex; max-width: 500px; margin: 0 auto;
  gap: 12px;
}
.newsletter-form input {
  flex: 1; padding: 16px 20px; font-size: 15px;
  border: none; border-radius: var(--radius);
}

/* Footer */
.footer {
  background: var(--secondary); color: #fff; padding: 60px 0 30px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px; margin-bottom: 40px;
}
.footer-brand .logo { margin-bottom: 20px; }
.footer-brand .logo a { color: #fff; }
.footer-brand p {
  font-size: 14px; color: rgba(255,255,255,0.7); line-height: 1.8;
}
.footer-title {
  font-size: 14px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 1px; margin-bottom: 20px;
}
.footer-links {
  list-style: none;
}
.footer-links li { margin-bottom: 12px; }
.footer-links a {
  font-size: 14px; color: rgba(255,255,255,0.7);
}
.footer-links a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 30px;
  display: flex; justify-content: space-between; align-items: center;
}
.footer-copyright {
  font-size: 13px; color: rgba(255,255,255,0.5);
}

/* Breadcrumb */
.breadcrumb {
  padding: 20px 0; background: var(--bg-warm);
}
.breadcrumb ol {
  display: flex; list-style: none; gap: 8px;
  font-size: 14px;
}
.breadcrumb li:not(:last-child)::after {
  content: '/'; margin-left: 8px; color: var(--text-muted);
}

/* Page header */
.page-header {
  background: var(--bg-warm); padding: 60px 0; text-align: center;
}
.page-header h1 { font-size: 42px; font-weight: 700; margin-bottom: 12px; }
.page-header p { color: var(--text-light); }

/* Shop page */
.shop-layout {
  display: grid; grid-template-columns: 260px 1fr; gap: 40px;
  padding: 40px 0;
}
.sidebar-title {
  font-size: 16px; font-weight: 600; margin-bottom: 20px;
}
.filter-group { margin-bottom: 30px; }
.filter-group ul { list-style: none; }
.filter-group li { margin-bottom: 12px; }
.filter-group a {
  font-size: 14px; color: var(--text);
  display: flex; justify-content: space-between;
}
.filter-group a:hover, .filter-group a.active { color: var(--primary); }
.filter-group .count {
  font-size: 12px; color: var(--text-muted); background: var(--bg-warm);
  padding: 2px 8px; border-radius: 12px;
}

.shop-toolbar {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 24px; padding-bottom: 20px; border-bottom: 1px solid var(--border-light);
}
.shop-toolbar select {
  padding: 10px 16px; font-size: 14px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--bg);
}

/* Product detail */
.product-detail {
  display: grid; grid-template-columns: 1fr 1fr; gap: 60px;
  padding: 40px 0;
}
.product-gallery {
  position: sticky; top: 100px;
}
.product-main-image {
  border-radius: var(--radius); overflow: hidden;
  background: var(--bg-light); margin-bottom: 16px;
}
.product-main-image img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.product-info-detail h1 { font-size: 32px; margin-bottom: 8px; }
.product-meta { color: var(--text-light); margin-bottom: 20px; }
.product-price-detail {
  display: flex; align-items: baseline; gap: 16px;
  margin-bottom: 24px;
}
.product-price-detail .current {
  font-size: 36px; font-weight: 700; color: var(--primary);
}
.product-price-detail .original {
  font-size: 20px; color: var(--text-muted); text-decoration: line-through;
}
.product-price-detail .discount {
  background: var(--error); color: #fff;
  padding: 4px 12px; font-size: 14px; font-weight: 600;
  border-radius: var(--radius-sm);
}
.product-description {
  font-size: 15px; line-height: 1.8; color: var(--text-light);
  margin-bottom: 30px;
}
.product-actions {
  display: flex; gap: 16px; margin-bottom: 30px;
}
.quantity-selector {
  display: flex; align-items: center;
  border: 1px solid var(--border); border-radius: var(--radius);
}
.quantity-selector button {
  width: 44px; height: 44px;
  background: none; border: none; font-size: 18px;
  cursor: pointer; color: var(--text);
}
.quantity-selector button:hover { background: var(--bg-warm); }
.quantity-selector input {
  width: 60px; text-align: center; border: none;
  font-size: 16px; font-weight: 600;
}

.product-tabs {
  border-top: 1px solid var(--border-light); padding-top: 40px;
}
.tab-nav {
  display: flex; gap: 40px; border-bottom: 2px solid var(--border-light);
  margin-bottom: 30px;
}
.tab-nav a {
  padding-bottom: 16px; font-size: 15px; font-weight: 500;
  color: var(--text-light); border-bottom: 2px solid transparent;
  margin-bottom: -2px;
}
.tab-nav a.active { color: var(--primary); border-color: var(--primary); }

/* Cart */
.cart-page { padding: 40px 0; }
.cart-layout {
  display: grid; grid-template-columns: 1fr 360px; gap: 40px;
}
.cart-table { width: 100%; }
.cart-table th {
  text-align: left; padding: 16px;
  font-size: 13px; font-weight: 600; text-transform: uppercase;
  color: var(--text-light); border-bottom: 2px solid var(--border);
}
.cart-table td { padding: 20px 16px; border-bottom: 1px solid var(--border-light); }
.cart-product {
  display: flex; align-items: center; gap: 16px;
}
.cart-product img {
  width: 80px; height: 80px; object-fit: cover;
  border-radius: var(--radius-sm);
}
.cart-product-info h4 { font-size: 15px; font-weight: 600; }
.cart-product-info p { font-size: 13px; color: var(--text-muted); }
.cart-summary {
  background: var(--bg-warm); padding: 24px;
  border-radius: var(--radius);
}
.cart-summary h3 { font-size: 18px; font-weight: 600; margin-bottom: 20px; }
.summary-row {
  display: flex; justify-content: space-between;
  padding: 12px 0; border-bottom: 1px solid var(--border);
  font-size: 15px;
}
.summary-row.total {
  font-size: 20px; font-weight: 700; border-bottom: none;
  padding-top: 20px;
}
.cart-summary .btn { width: 100%; margin-top: 20px; }

/* Checkout */
.checkout-page { padding: 40px 0; }
.checkout-layout {
  display: grid; grid-template-columns: 1fr 400px; gap: 40px;
}
.checkout-form h3 { font-size: 20px; margin-bottom: 24px; }
.form-group { margin-bottom: 20px; }
.form-group label {
  display: block; font-size: 14px; font-weight: 500;
  margin-bottom: 8px;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%; padding: 14px 16px; font-size: 15px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  transition: var(--transition);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none; border-color: var(--primary);
}
.form-group textarea { min-height: 100px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.payment-methods { margin: 24px 0; }
.payment-method {
  display: flex; align-items: center; gap: 12px;
  padding: 16px; border: 2px solid var(--border);
  border-radius: var(--radius); margin-bottom: 12px;
  cursor: pointer;
}
.payment-method.active { border-color: var(--primary); }
.payment-method input { width: 20px; height: 20px; }
.payment-method.disabled { opacity: 0.5; cursor: not-allowed; }

/* Admin */
.admin-layout {
  display: grid; grid-template-columns: 260px 1fr;
  min-height: 100vh;
}
.admin-sidebar {
  background: var(--primary-dark); color: #fff;
  padding: 30px 0;
}
.admin-sidebar .logo {
  padding: 0 30px 30px; border-bottom: 1px solid rgba(255,255,255,0.1);
}
.admin-sidebar .logo a { color: #fff; font-size: 22px; }
.admin-nav { list-style: none; padding: 20px 0; }
.admin-nav li a {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 30px; color: rgba(255,255,255,0.8);
  font-size: 15px;
}
.admin-nav li a:hover,
.admin-nav li a.active { color: #fff; background: rgba(255,255,255,0.1); }
.admin-main { background: var(--bg-warm); padding: 30px; }
.admin-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 30px;
}
.admin-header h1 { font-size: 24px; }

.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px;
  margin-bottom: 30px;
}
.stat-card {
  background: #fff; padding: 24px; border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.stat-card h3 {
  font-size: 14px; color: var(--text-light); text-transform: uppercase;
  margin-bottom: 8px;
}
.stat-card .value {
  font-size: 32px; font-weight: 700; color: var(--primary);
}

.admin-table {
  width: 100%; background: #fff; border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
}
.admin-table th,
.admin-table td { padding: 16px; text-align: left; }
.admin-table th {
  background: var(--bg-warm); font-size: 13px; font-weight: 600;
  text-transform: uppercase; color: var(--text-light);
}
.admin-table tr:not(:last-child) td { border-bottom: 1px solid var(--border-light); }
.status-badge {
  display: inline-block; padding: 4px 12px;
  font-size: 12px; font-weight: 600; border-radius: 20px;
}
.status-pending { background: #fff3cd; color: #856404; }
.status-processing { background: #cce5ff; color: #004085; }
.status-completed { background: #d4edda; color: #155724; }
.status-cancelled { background: #f8d7da; color: #721c24; }

/* Responsive */
@media (max-width: 1024px) {
  .product-grid { grid-template-columns: repeat(3, 1fr); }
  .category-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .shop-layout { grid-template-columns: 200px 1fr; }
}

@media (max-width: 768px) {
  .nav-main { display: none; }
  .mobile-menu-btn { display: flex; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .category-grid { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-content h1 { font-size: 36px; }
  .hero-content p { font-size: 16px; }
  .shop-layout { grid-template-columns: 1fr; }
  .product-detail { grid-template-columns: 1fr; }
  .cart-layout { grid-template-columns: 1fr; }
  .checkout-layout { grid-template-columns: 1fr; }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Utility */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
