/* Base styles */
:root {
  /* Modern color scheme optimized for US audience and download pages */
  --primary-color: #1e88e5;    /* Modern blue - more vibrant than previous */
  --secondary-color: #00c853;  /* Fresh green - slightly brighter */
  --accent-color: #ff5722;     /* Modern orange - slightly less saturated */
  --accent-secondary: #42a5f5; /* Lighter blue - more modern shade */
  --success-color: #00c853;    /* Fresh green */
  --warning-color: #ff9800;    /* Softer orange for warnings */
  --danger-color: #f44336;     /* Modern red */
  --light-color: #f8f9fa;
  --dark-color: #263238;       /* Slightly softer dark */
  --gray-color: #78909c;       /* Bluish gray */
  --text-color: #37474f;       /* Softer than pure black */
  --border-radius: 8px;
  --box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  --header-height: 60px; /* Fixed header height */
  
  /* Typography scale - more refined and balanced */
  --base-font-size: 15px;
  --small-font-size: 0.85rem;  /* ~13px */
  --medium-font-size: 0.95rem; /* ~14px */
  --large-font-size: 1.05rem;  /* ~16px */
  --h1-size: 1.8rem;           /* ~27px */
  --h2-size: 1.5rem;           /* ~22px */
  --h3-size: 1.25rem;          /* ~19px */
  --h4-size: 1.1rem;           /* ~16px */
  --h5-size: 1rem;             /* ~15px */
  --line-height: 1.5;
}

html {
  font-size: var(--base-font-size);
  position: relative;
  min-height: 100%;
  scroll-padding-top: var(--header-height);
  /* Add scroll padding for fixed header */
}

@media (min-width: 768px) {
  html {
    font-size: var(--base-font-size);
  }
}

body {
  font-family: 'Poppins', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text-color);
  background-color: #f8fafc;
  line-height: var(--line-height);
  padding-top: var(--header-height);
  font-weight: 400;
  letter-spacing: 0.01em;
}

/* Typography refinements */
h1, .h1 { 
  font-size: var(--h1-size); 
  font-weight: 600;
  line-height: 1.3;
  color: var(--dark-color);
  margin-bottom: 1.25rem;
}

h2, .h2 { 
  font-size: var(--h2-size); 
  font-weight: 600;
  line-height: 1.35;
}

h3, .h3 { 
  font-size: var(--h3-size); 
  font-weight: 600;
  line-height: 1.4;
}

h4, .h4 { 
  font-size: var(--h4-size); 
  font-weight: 600;
}

h5, .h5 { 
  font-size: var(--h5-size); 
  font-weight: 600;
}

a {
  text-decoration: none;
}
p {
  margin-bottom: 1rem;
  font-size: var(--medium-font-size);
}

.lead {
  font-size: var(--large-font-size);
  font-weight: 400;
}

.small, small {
  font-size: var(--small-font-size);
}

/* Button focus styles */
.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem var(--primary-color);
}

/* ======= BEGIN: INTEGRATED LAYOUT-FIX.CSS ======= */
/* Fix for removing category navigation */
body {
  padding-top: 60px; /* Match header height exactly */
}

.main-content {
  animation: fadeIn 0.3s ease-in-out;
  margin-top: 2rem;
}

@keyframes fadeIn {
  from {
    opacity: 0.9;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Adding some visual improvement to header */
.navbar {
  box-shadow: 0 2px 15px rgba(0,0,0,0.15);
}

/* Improve space between sections */
.section {
  margin-bottom: 2rem;
}

.section-title {
  margin-bottom: 1.25rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  body {
    padding-top: 60px;
  }
  
  .main-content {
    margin-top: 1.5rem;
  }
}
/* ======= END: INTEGRATED LAYOUT-FIX.CSS ======= */

/* ======= BEGIN: INTEGRATED CATEGORY-NAVIGATION.CSS ======= */
.category-nav-scroll {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding: 12px 0;
    gap: 10px;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 10px;
}

.category-nav-scroll::-webkit-scrollbar {
    height: 5px;
}

.category-nav-scroll::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.category-nav-scroll::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.category-nav-scroll::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.category-pill {
    display: inline-block;
    padding: 8px 16px;
    background-color: #f8f9fa;
    color: #495057;
    border-radius: 50px;
    text-decoration: none;
    white-space: nowrap;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid #e9ecef;
}

.category-pill:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.category-pill:active {
    transform: translateY(0);
}

.text-muted {
    color: #6c757d;
    font-style: italic;
    padding: 8px 16px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .category-nav-scroll {
        padding: 8px 0;
    }
    
    .category-pill {
        padding: 6px 12px;
        font-size: 13px;
    }
}
/* ======= END: INTEGRATED CATEGORY-NAVIGATION.CSS ======= */

/* ======= BEGIN: INTEGRATED IMAGE-HANDLERS.CSS ======= */
/* Tạo hiệu ứng loading cho hình ảnh */
.card-img-top,
.software-detail-image,
.hero-image {
  background-color: #f0f2f5;
  min-height: 160px;
  position: relative;
}

.card-img-top::before,
.software-detail-image::before,
.hero-image::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 40px;
  height: 40px;
  margin-top: -20px;
  margin-left: -20px;
  border-radius: 50%;
  border: 3px solid #f3f3f3;
  border-top: 3px solid var(--primary-color);
  animation: spin 1s linear infinite;
  opacity: 0;
  transition: opacity 0.3s;
}

.card-img-top.loading::before,
.software-detail-image.loading::before,
.hero-image.loading::before {
  opacity: 1;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
/* ======= END: INTEGRATED IMAGE-HANDLERS.CSS ======= */

/* ======= BEGIN: INTEGRATED MEGA-MENU.CSS ======= */
/* Mega Menu Additional Styles */
.mega-menu {
    width: 100%;
    max-width: 100%;
    padding: 20px;
    left: 0;
    right: 0;
    margin-top: 0;
    position: absolute;
}

.dropdown-menu-dark.mega-menu.show {
    display: block;
    width: 100vw;
    position: absolute;
    left: 0; 
    right: 0;
    top: 100%;
    background-color: #2d3748;
    transform: none;
    border-radius: 0;
}

.mega-menu .container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.categories-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -10px;
}

/* Animation for dropdown */
.dropdown-menu-dark.mega-menu {
    transform: translateY(-10px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: block;
}

.dropdown-menu-dark.mega-menu.show {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.category-item {
    width: 25%;
    padding: 0 10px;
    margin-bottom: 20px;
}

.category-title {
    color: white;
    font-weight: 600;
    margin-bottom: 10px;
    font-size: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 8px;
}

.category-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-links li {
    margin-bottom: 8px;
}

.category-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    font-size: 0.9rem;
    display: block;
    padding: 4px 0;
    transition: all 0.2s ease;
}

.category-links a:hover {
    color: white;
    transform: translateX(5px);
}

.mega-menu-footer {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.all-categories-link {
    color: white;
    text-decoration: none;
    font-weight: 600;
    padding: 8px 16px;
    background: rgba(255,255,255,0.1);
    border-radius: 4px;
    transition: all 0.2s ease;
}

.all-categories-link:hover {
    background: rgba(255,255,255,0.2);
}

@media (max-width: 992px) {
    .category-item {
        width: 33.333%;
    }
}

@media (max-width: 768px) {
    .category-item {
        width: 50%;
    }
    
    .mega-menu {
        padding: 15px;
    }
}

@media (max-width: 576px) {
    .category-item {
        width: 100%;
    }
}
/* ======= END: INTEGRATED MEGA-MENU.CSS ======= */

/* ======= BEGIN: INTEGRATED SITE-MOBILE.CSS ======= */
/* site-mobile.css - Mobile optimization for SDP */

/* Optimized responsive settings for mobile devices */
@media (max-width: 767px) {
  /* Base styles adjustment */
  :root {
    --base-font-size: 14px;
    --h1-size: 1.6rem;
    --h2-size: 1.35rem;
    --h3-size: 1.15rem;
    --h4-size: 1rem;
    --header-height: 56px;
    --category-nav-height: 45px;
  }

  /* Adjust body padding for smaller header */
  body {
    padding-top: calc(var(--header-height) + var(--category-nav-height));
    overflow-x: hidden;
  }

  /* Header and navigation optimization */
  .navbar {
    height: var(--header-height);
    padding: 0.5rem 0;
  }

  .navbar-brand {
    font-size: 1.2rem;
    max-width: 130px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .navbar-toggler {
    padding: 0.25rem 0.5rem;
    font-size: 1rem;
  }

  .navbar-collapse {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-secondary) 100%);
    padding: 0.5rem;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: 0 5px 10px rgba(0,0,0,0.1);
  }

  .navbar-dark .navbar-nav .nav-link {
    padding: 0.7rem 1rem;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }

  .navbar-dark .navbar-nav .nav-item:last-child .nav-link {
    border-bottom: none;
  }

  /* Category navigation for mobile */
  .category-nav {
    height: var(--category-nav-height);
    padding: 0.5rem 0;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
  }

  .category-nav::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Edge */
  }

  .category-nav .container {
    padding-right: 0;
    padding-left: 0.5rem;
  }

  .category-nav-scroll {
    display: flex;
    flex-wrap: nowrap;
    padding-right: 1rem;
  }

  .category-pill {
    flex: 0 0 auto;
    margin-right: 0.5rem;
    margin-bottom: 0;
    white-space: nowrap;
  }

  /* Search container fixes */
  .center-search-container {
    padding: 1.5rem 1rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
  }

  .center-search-container h2 {
    font-size: 1.4rem;
    margin-bottom: 0.8rem;
  }

  .center-search-container p {
    margin-bottom: 1.2rem;
    font-size: var(--small-font-size);
  }

  .center-search-container .input-group {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  }

  .center-search-container input {
    height: 46px;
    padding: 0.6rem 0.8rem;
    font-size: var(--small-font-size);
  }

  .center-search-container .btn-search {
    height: 46px;
    padding: 0 1rem;
    min-width: 90px;
    font-size: var(--small-font-size);
  }

  .center-search-container .btn-search i {
    font-size: 1rem;
    margin-right: 0.3rem;
  }

  .center-search-container .popular-searches {
    margin-top: 1rem;
  }

  .center-search-container .popular-searches a {
    margin: 0.2rem;
    padding: 0.25rem 0.6rem;
  }

  /* Software cards for mobile */
  .software-card {
    margin-bottom: 1rem;
  }

  .software-card .card-img-top {
    height: 140px;
  }

  .software-card .card-body {
    padding: 1rem;
  }

  .software-card .card-title {
    font-size: 1.05rem;
    margin-bottom: 0.5rem;
  }

  .software-card .card-text {
    font-size: var(--small-font-size);
    margin-bottom: 0.7rem;
    -webkit-line-clamp: 2;
    height: 3em;
  }

  .software-card .meta {
    padding-top: 0.6rem;
    flex-wrap: wrap;
  }

  .software-card .meta .badge {
    margin-bottom: 0.3rem;
  }

  /* Software details page */
  .software-detail-header {
    margin-bottom: 1.5rem;
    text-align: center;
  }

  .software-detail-header h1 {
    font-size: var(--h1-size);
    margin-bottom: 0.5rem;
  }

  .software-detail-image {
    margin-bottom: 1rem;
    max-height: 200px;
  }

  .software-detail-meta {
    flex-direction: column;
    align-items: center;
  }

  .software-detail-meta > div {
    margin-bottom: 0.5rem;
  }

  /* Download button */
  .btn-download {
    width: 100%;
    padding: 0.8rem;
    font-size: 1rem;
    margin-bottom: 1rem;
  }

  /* Reviews section */
  .review-card {
    padding: 1rem;
  }

  /* Form controls for mobile */
  .form-control {
    padding: 0.5rem 0.7rem;
  }

  .btn {
    padding: 0.5rem 1rem;
  }

  /* Footer for mobile */
  footer {
    padding: 2rem 0 1rem;
    margin-top: 2rem;
    text-align: center;
  }

  footer .col-md-3 {
    margin-bottom: 1.5rem;
  }

  .footer-links {
    display: inline-block;
    text-align: left;
  }

  .social-icons {
    margin-top: 1rem;
  }

  .social-icons a {
    margin: 0 0.5rem;
  }

  /* Fix grid layout for mobile */
  .row {
    margin-left: -10px;
    margin-right: -10px;
  }

  .col-md-3, .col-md-4, .col-md-6, .col-md-8, .col-md-12 {
    padding-left: 10px;
    padding-right: 10px;
  }

  /* Improve responsive tables */
  .table-responsive {
    margin-bottom: 1rem;
    border-radius: var(--border-radius);
    overflow: hidden;
  }

  .table {
    margin-bottom: 0;
  }

  /* Fix page spacing */
  .section-header {
    margin: 1.2rem 0 1rem;
    font-size: 1.3rem;
  }

  .section-header::after {
    width: 50px;
  }

  /* Fix alerts and badges */
  .alert {
    padding: 0.8rem;
  }

  .badge {
    font-size: 0.7rem;
    padding: 0.25em 0.5em;
  }

  /* Software detail page refinements */
  .software-tabs .nav-link {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }

  .software-content-section {
    padding: 1rem;
  }

  .software-content-section h2 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
  }

  .screenshots-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  /* Responsive modal */
  .modal-dialog {
    margin: 0.5rem;
  }

  .modal-content {
    border-radius: var(--border-radius);
  }

  .modal-header {
    padding: 0.8rem 1rem;
  }

  .modal-body {
    padding: 1rem;
  }

  .modal-footer {
    padding: 0.75rem 1rem;
  }

  /* Login and registration forms */
  .auth-container {
    padding: 1.5rem 1rem;
  }

  .auth-container .card {
    padding: 1rem;
  }

  .auth-container .form-group {
    margin-bottom: 1rem;
  }

  .auth-container .btn {
    width: 100%;
  }

  /* Profile page */
  .profile-container {
    padding: 1rem;
  }

  .profile-header {
    padding: 1rem;
    flex-direction: column;
    text-align: center;
  }

  .profile-avatar {
    margin-bottom: 1rem;
    margin-right: 0;
  }

  .profile-info {
    width: 100%;
  }

  .profile-tabs .nav-link {
    padding: 0.5rem 0.75rem;
  }

  /* Admin dashboard panels */
  .admin-panel {
    padding: 1rem;
    margin-bottom: 1rem;
  }

  .admin-panel h2 {
    font-size: 1.25rem;
  }
}
/* ======= END: INTEGRATED SITE-MOBILE.CSS ======= */

/* CAPTCHA styles */
.captcha-container {
  margin-bottom: 15px;
}

.captcha-box {
  display: inline-block;
  background-color: #f0f0f0;
  background-image: linear-gradient(45deg, rgba(0,0,0,0.05) 25%, transparent 25%, transparent 50%, rgba(0,0,0,0.05) 50%, rgba(0,0,0,0.05) 75%, transparent 75%, transparent);
  background-size: 4px 4px;
  padding: 15px 20px;
  border-radius: 5px;
  margin-bottom: 10px;
  border: 1px solid #ddd;
  position: relative;
  min-width: 200px;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.captcha-text {
  font-family: 'Courier New', monospace;
  font-size: 28px;
  font-weight: bold;
  letter-spacing: 8px;
  color: #333;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.2);
  user-select: none;
  position: relative;
  transform: skew(-5deg, 0);
}

.captcha-text::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 100%;
  height: 2px;
  background-color: rgba(0,0,0,0.2);
  transform: translateY(-50%) rotate(-2deg);
}

/* Container and layout styles */
.container {
  padding: 0 1.5rem;
}

@media (min-width: 992px) {
  .container {
    padding: 0 2rem;
  }
}

.main-content {
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0.9;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Fixed header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1030;
  width: 100%;
}

/* Navbar & header styles */
.navbar {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-secondary) 100%);
  padding: 0.7rem 0;
  box-shadow: 0 2px 10px rgba(0,0,0,0.15);
  height: var(--header-height);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar-brand {
  font-size: 1.4rem;
  font-weight: 600;
  padding: 0.25rem 0;
}

.navbar-dark .navbar-nav .nav-link {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  padding: 0.5rem 1rem;
  transition: all 0.2s;
  margin: 0 0.1rem;
  font-size: var(--medium-font-size);
}

.navbar-dark .navbar-nav .nav-link:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: var(--border-radius);
}

.btn-search {
  background-color: var(--accent-color);
  color: #fff;
  border: none;
  font-weight: 500;
}

.btn-search:hover {
  background-color: #ff7d26;
  color: #fff;
  transform: translateY(-2px);
}

/* Adding center search container for the homepage */
.center-search-container {
  background: linear-gradient(135deg, var(--primary-color) 0%, #3949ab 100%);
  padding: 4rem 0;
  margin: 0 auto 2.5rem;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  max-width: 96%;
}

.center-search-container h1 {
  color: white;
  font-size: 2.25rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  text-align: center;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  line-height: 1.3;
}

.center-search-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('/images/pattern-overlay.png');
  opacity: 0.1;
  z-index: 1;
}

.center-search-container::after {
  content: '';
  position: absolute;
  bottom: -10px;
  right: -10px;
  width: 150px;
  height: 150px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  z-index: 1;
}

.center-search-container .container {
  position: relative;
  z-index: 2;
}

.center-search-container h2 {
  color: white;
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  text-align: center;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.center-search-container p {
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
  max-width: 700px;
  margin: 0 auto 2rem;
  font-size: var(--medium-font-size);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.center-search-container .search-form {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
}

.center-search-container .input-group {
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.center-search-container .input-group:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.center-search-container input {
  padding: 1.1rem 1.5rem;
  border: none;
  font-size: var(--medium-font-size);
  height: 60px;
  background-color: white;
}

.center-search-container input:focus {
  outline: none;
}

.center-search-container .btn-search {
  padding: 0 2rem;
  font-size: var(--medium-font-size);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--accent-color) 0%, #ff7043 100%);
  transition: all 0.3s ease;
  height: 60px;
  min-width: 140px;
}

.center-search-container .btn-search:hover {
  background: linear-gradient(135deg, #ff7043 0%, var(--accent-color) 100%);
  transform: translateX(0);
}

.center-search-container .btn-search i {
  font-size: 1.3rem;
  margin-right: 0.6rem;
}

.center-search-container .popular-searches {
  margin-top: 1.5rem;
  text-align: center;
}

.center-search-container .popular-searches span {
  color: rgba(255, 255, 255, 0.7);
  font-size: var(--small-font-size);
  margin-right: 0.5rem;
}

.center-search-container .popular-searches a {
  display: inline-block;
  color: white;
  margin: 0.3rem 0.5rem;
  text-decoration: none;
  font-size: var(--small-font-size);
  background: rgba(255, 255, 255, 0.2);
  padding: 0.3rem 0.8rem;
  border-radius: 50px;
  transition: all 0.2s;
}

.center-search-container .popular-searches a:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

@media (max-width: 768px) {
  .center-search-container {
    padding: 2.5rem 0;
  }
  
  .center-search-container h2 {
    font-size: 1.7rem;
    margin-bottom: 1rem;
  }
  
  .center-search-container p {
    font-size: var(--medium-font-size);
    margin-bottom: 1.5rem;
  }
  
  .center-search-container input {
    height: 52px;
    padding: 0.8rem;
  }
  
  .center-search-container .btn-search {
    height: 52px;
    padding: 0 1.5rem;
    min-width: 110px;
  }
  
  .center-search-container .popular-searches {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .center-search-container .popular-searches span {
    width: 100%;
    margin-bottom: 0.5rem;
  }
}

.category-nav {
  background-color: #f7f9fc;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  padding: 0.7rem 0;
  height: var(--category-nav-height);
}

/* Category pills */
.category-pill {
  display: inline-block;
  padding: 0.35rem 0.75rem;
  border-radius: 50px;
  background-color: rgba(30, 136, 229, 0.1);
  color: var(--primary-color);
  font-size: var(--small-font-size);
  font-weight: 500;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  text-decoration: none;
  transition: all 0.2s;
}

.category-pill:hover {
  background-color: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

/* Improved spacing for main content */
main {
  margin: 1.5rem 0 3rem;
}

.section-header {
  border-bottom: 2px solid #e9ecef;
  padding-bottom: 0.7rem;
  margin: 2rem 0 1.5rem;
  font-weight: 600;
  color: var(--dark-color);
  position: relative;
  font-size: var(--h2-size);
}

.section-header::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60px;
  height: 2px;
  background: linear-gradient(to right, var(--primary-color), #3949ab);
}

/* Card styles for software listings */
.software-card {
  transition: transform 0.3s, box-shadow 0.3s;
  margin-bottom: 1.5rem;
  height: 100%;
  border-radius: var(--border-radius);
  overflow: hidden;
  border: none;
  background: white;
  box-shadow: var(--box-shadow);
}

.software-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.12);
}

.software-card .card-img-top {
  height: 180px;
  object-fit: contain;
  background-color: #f0f2f5;
}

.software-card .card-body {
  padding: 1.5rem;
}

.software-card .card-title {
  font-size: var(--h4-size);
  font-weight: 600;
  margin-bottom: 0.7rem;
  color: var(--primary-color);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.software-card .card-text {
  font-size: var(--medium-font-size);
  color: #666;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.5;
  height: 4.5em; /* Fix height for 3 lines of text */
}

.software-card .meta {
  font-size: var(--small-font-size);
  color: var(--gray-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 0.8rem;
  border-top: 1px solid #f0f2f5;
}

/* Download button */
.btn-download {
  background: linear-gradient(135deg, var(--success-color) 0%, #00b248 100%);
  color: white;
  font-weight: 500;
  border-radius: 4px;
  padding: 0.7rem 1.6rem;
  transition: all 0.2s;
  border: none;
  letter-spacing: 0.5px;
  white-space: nowrap;
  font-size: var(--medium-font-size);
}

.btn-download:hover {
  background: linear-gradient(135deg, #00b248 0%, var(--success-color) 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,166,81,0.3);
  color: white;
}

/* Software details page */
.software-detail-image {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  object-fit: contain;
  max-height: 300px;
}

.software-detail-header {
  margin-bottom: 2rem;
}

.software-detail-header h1 {
  font-size: var(--h1-size);
  font-weight: 600;
  margin-bottom: 0.8rem;
  color: var(--primary-color);
  word-wrap: break-word;
}

.rating-stars {
  color: #ffc107;
  font-size: 1.1rem;
}

/* Reviews section */
.review-card {
  border-radius: var(--border-radius);
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  margin-bottom: 1.2rem;
  padding: 1.5rem;
  background: white;
}

.review-author {
  font-weight: 600;
  color: var(--dark-color);
}

.review-date {
  font-size: 0.8rem;
  color: var(--gray-color);
}

/* Footer styles */
footer {
  background: linear-gradient(135deg, var(--dark-color) 0%, #1a237e 100%);
  color: #fff;
  padding: 3rem 0 2rem;
  margin-top: 4rem;
}

footer div.container {
  padding: 20px !important;
}

footer h5 {
  font-size: var(--h5-size);
  font-weight: 600;
  margin-bottom: 1.2rem;
  color: white;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  display: block;
  padding: 0.4rem 0;
  transition: all 0.2s;
  font-size: var(--small-font-size);
}

.footer-links a:hover {
  color: var(--accent-color);
  transform: translateX(3px);
}

.social-icons a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.4rem;
  transition: all 0.2s;
  margin-right: 1rem;
}

.social-icons a:hover {
  color: var(--accent-color);
}

/* Form controls */
.form-control {
  border-radius: var(--border-radius);
  padding: 0.6rem 0.9rem;
  border: 1px solid #dee2e6;
  font-size: var(--medium-font-size);
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(0, 85, 150, 0.15);
}

.btn {
  border-radius: var(--border-radius);
  padding: 0.6rem 1.2rem;
  font-weight: 500;
  transition: all 0.2s;
  font-size: var(--medium-font-size);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-secondary) 100%);
  border: none;
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--accent-secondary) 0%, var(--primary-color) 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(30,136,229,0.3);
}

/* Custom classes */
.badge {
  font-weight: 500;
  padding: 0.35em 0.65em;
  font-size: 0.75em;
}

.badge.bg-primary {
  background: var(--primary-color) !important;
}

.badge.bg-success {
  background: var(--success-color) !important;
}

.badge.bg-warning {
  background: var(--warning-color) !important;
  color: #fff;
}

/* Improved alerts */
.alert {
  border-radius: var(--border-radius);
  padding: 1.2rem;
  margin-bottom: 1.5rem;
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.alert-info {
  background-color: rgba(0, 134, 205, 0.1);
  color: var(--primary-color);
}

/* Dropdown menu styling */
.dropdown-menu-dark {
  background-color: #2d3748;
  border: none;
  border-radius: var(--border-radius);
  box-shadow: 0 5px 15px rgba(0,0,0,0.2);
  padding: 0.7rem 0.5rem;
}

/* Mega Menu Styling */
.mega-menu {
  width: 100%;
  max-width: 100%;
  padding: 20px;
  left: 0;
  right: 0;
}

.mega-menu .container {
  max-width: 1200px;
  margin: 0 auto;
}

.categories-grid {
  display: flex;
  flex-wrap: wrap;
}

.category-item {
  padding: 5px 10px;
  margin-bottom: 10px;
}

.dropdown-item {
  padding: 0.6rem 1rem;
  font-weight: 500;
  border-radius: 4px;
  margin-bottom: 0.2rem;
  white-space: normal;
}

.dropdown-menu-dark .dropdown-item:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

/* Card category styles */
.category-card {
  border: none;
  border-radius: var(--border-radius);
  transition: all 0.3s;
  box-shadow: var(--box-shadow);
  overflow: hidden;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.12);
}

.category-card .card-title {
  font-weight: 600;
  color: var(--dark-color);
}

.category-card .card-body {
  padding: 1.8rem;
}

.category-card .card-footer {
  padding: 1.2rem 1.8rem;
  border-top: 1px solid rgba(0,0,0,0.05);
  background-color: white;
}

/* Latest software card styles */
.latest-software-card {
  border-radius: var(--border-radius);
  transition: transform 0.2s, box-shadow 0.2s;
  border: none;
}

.latest-software-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.latest-software-card .card-title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.latest-software-card .card-text {
  font-size: var(--small-font-size);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.4;
  height: 2.8em;
}

.software-thumbnail img {
  transition: transform 0.3s;
  background-color: #f0f2f5;
}

.latest-software-card:hover .software-thumbnail img {
  transform: scale(1.05);
}

/* Latest software list styles - new UI */
.latest-software-list {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  margin-bottom: 2rem;
}

.latest-software-item {
  display: flex;
  align-items: center;
  padding: 1rem 1.5rem;
  transition: all 0.2s ease;
}

.latest-software-item.even {
  background-color: #f7f9fc;
}

.latest-software-item.odd {
  background-color: #eff3f9;
}

.latest-software-item:hover {
  background-color: #e9effa;
}

.software-icon {
  flex: 0 0 52px;
  height: 52px;
  margin-right: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.software-icon img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 8px;
  object-fit: contain;
}

.software-details {
  flex: 1 1 auto;
  padding-right: 1rem;
}

.software-name {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
  color: #04367c;
  margin-bottom: 0.3rem;
  text-decoration: none;
}

.software-name:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

.software-description {
  color: #64748b;
  font-size: var(--small-font-size);
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.software-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.software-date {
  color: #94a3b8;
  font-size: 0.75rem;
}

.software-rating {
  color: #ffc107;
  font-size: 0.8rem;
}

.software-info {
  flex: 0 0 170px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.os-badge {
  color: #04367c;
  font-weight: 600;
  font-size: 0.75rem;
  margin-bottom: 0.5rem;
}

.download-count {
  color: #64748b;
  font-size: 0.8rem;
}

/* Responsive adaptations for the latest software list */
@media (max-width: 768px) {
  .latest-software-item {
    padding: 0.8rem;
    flex-wrap: wrap;
  }
  
  .software-icon {
    flex: 0 0 40px;
    height: 40px;
    margin-right: 0.8rem;
  }
  
  .software-details {
    flex: 1 1 calc(100% - 130px);
    padding-right: 0.5rem;
  }
  
  .software-info {
    flex: 0 0 80px;
  }
  
  .software-name {
    font-size: 0.95rem;
  }
  
  .software-description {
    -webkit-line-clamp: 1;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0.3rem;
  }
}

@media (max-width: 576px) {
  .latest-software-item {
    padding: 0.8rem;
  }
  
  .software-info {
    flex: 1 0 100%;
    align-items: flex-start;
    margin-top: 0.5rem;
    margin-left: calc(40px + 0.8rem);
  }
  
  .software-details {
    flex: 1 1 calc(100% - 50px);
  }
  
  .software-meta {
    flex-wrap: wrap;
  }
}

/* Mobile optimizations for latest software cards */
@media (max-width: 767px) {
  .latest-software-card .card-body {
    padding: 0.75rem;
  }
  
  .latest-software-card .software-thumbnail img {
    width: 50px !important;
    height: 50px !important;
  }
  
  .latest-software-card .card-title {
    font-size: 0.95rem;
  }
  
  .latest-software-card .card-text {
    height: 2.5em;
    -webkit-line-clamp: 1;
    margin-bottom: 0.5rem !important;
  }
  
  .latest-software-card .btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
  }
}

/* Responsive fixes for mobile */
@media (max-width: 768px) {
  :root {
    --base-font-size: 14px;
    --h1-size: 1.7rem;
    --h2-size: 1.4rem;
    --h3-size: 1.2rem;
  }
  
  .center-search-container {
    padding: 2.5rem 0;
  }
  
  .center-search-container h2 {
    font-size: 1.7rem;
    margin-bottom: 1rem;
  }
  
  .center-search-container p {
    font-size: var(--medium-font-size);
    margin-bottom: 1.5rem;
  }
  
  .center-search-container input {
    height: 52px;
    padding: 0.8rem;
  }
  
  .center-search-container .btn-search {
    height: 52px;
    padding: 0 1.5rem;
    min-width: 110px;
  }
  
  .software-card .card-img-top {
    height: 150px;
  }
  
  .software-detail-header h1 {
    font-size: var(--h1-size);
  }
  
  footer {
    padding: 2rem 0 1.5rem;
  }
  
  .section-header {
    margin: 1.5rem 0 1.2rem;
  }
  
  .btn-download, .btn-primary {
    padding: 0.5rem 1rem;
    font-size: var(--medium-font-size);
  }
  
  .software-card .meta .badge {
    display: inline-block;
    margin-bottom: 0.3rem;
  }
  
  .software-card .card-title {
    font-size: var(--h5-size);
  }
  
  /* Improve category layout on mobile */
  .category-pill {
    padding: 0.25rem 0.5rem;
    margin-right: 0.3rem;
    margin-bottom: 0.3rem;
    font-size: var(--small-font-size);
  }
  
  /* Fix software details layout */
  .col-md-4, .col-md-8 {
    padding-left: 12px;
    padding-right: 12px;
  }
}

/* Software details page - Softpedia style */
.software-details-container {
    padding-top: 1.5rem;
    padding-bottom: 3rem;
    background-color: #f8f9fa;
}

/* Top header section */
.software-details-header {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.software-icon {
    width: 80px;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.software-details-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #1a4977;
}

.software-meta {
    margin-bottom: 0.75rem;
    gap: 1.25rem;
}

.software-category, .software-date, .software-rating {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    color: #5a6a7e;
}

.software-category a {
    color: #1a4977;
    text-decoration: none;
    margin-left: 0.25rem;
}

.software-category a:hover {
    text-decoration: underline;
}

.software-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.rating-stars {
    color: #ffb400;
    font-size: 0.85rem;
}

.rating-count {
    color: #5a6a7e;
    font-size: 0.8rem;
}

.software-short-desc {
    color: #505a64;
    font-size: 0.95rem;
    margin-bottom: 0;
    line-height: 1.5;
}

.software-info-box {
    background-color: #f5f7fa;
    border-radius: 6px;
    padding: 1rem;
    border: 1px solid #e2e8f0;
}

.info-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.info-item:last-child {
    margin-bottom: 0;
}

.info-item .label {
    color: #5a6a7e;
    font-weight: 500;
}

.info-item .value {
    color: #1a4977;
    font-weight: 600;
}

/* Tabs styling */
.software-tabs {
    border-bottom: 1px solid #dee2e6;
    margin-bottom: 1.5rem;
}

.software-tabs .nav-link {
    border: none;
    font-weight: 600;
    color: #5a6a7e;
    padding: 0.75rem 1.25rem;
    position: relative;
    background-color: transparent;
}

.software-tabs .nav-link:hover {
    color: #1a4977;
}

.software-tabs .nav-link.active {
    color: #1a4977;
    background-color: transparent;
    border: none;
}

.software-tabs .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #1a4977;
    border-radius: 3px 3px 0 0;
}

.software-tabs .review-count {
    font-size: 0.75rem;
    background-color: #e2e8f0;
    color: #5a6a7e;
    padding: 0.15rem 0.5rem;
    border-radius: 12px;
    margin-left: 0.5rem;
}

.software-tabs-content {
    padding: 1rem 0;
}

/* Content sections */
.software-content-section {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.software-content-section h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a4977;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e2e8f0;
}

.software-content-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1rem;
}

.software-full-content {
    color: #505a64;
    font-size: 0.95rem;
    line-height: 1.6;
}

.software-full-content p {
    margin-bottom: 1rem;
}

/* Screenshots section */
.screenshots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.screenshot-placeholder {
    background-color: #f5f7fa;
    border: 1px dashed #cbd5e0;
    border-radius: 8px;
    padding: 2rem;
    min-height: 180px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.placeholder-content {
    text-align: center;
    color: #a0aec0;
}

.placeholder-content i {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.placeholder-content p {
    margin-bottom: 0;
    font-size: 0.9rem;
}

/* Technical details */
.technical-table {
    margin-bottom: 2rem;
}

.technical-table th {
    width: 30%;
    font-weight: 600;
    color: #2d3748;
    background-color: #f8fafc;
}

.technical-table td {
    color: #505a64;
}

/* Versions table */
.versions-list table th {
    font-weight: 600;
    color: #2d3748;
    background-color: #f8fafc;
}

/* Reviews tab */
.reviews-summary {
    display: flex;
    background-color: #f8fafc;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid #e2e8f0;
}

.average-rating {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-right: 2rem;
    margin-right: 2rem;
    border-right: 1px solid #e2e8f0;
}

.rating-number {
    font-size: 3rem;
    font-weight: 700;
    color: #1a4977;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.average-rating .rating-stars {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.average-rating .rating-count {
    font-size: 0.85rem;
    color: #5a6a7e;
}

.rating-breakdown {
    flex-grow: 1;
}

.rating-row {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.stars-label {
    width: 100px;
    font-size: 0.8rem;
    color: #ffb400;
}

.rating-row .progress {
    flex-grow: 1;
    height: 8px;
    margin-right: 1rem;
    background-color: #e2e8f0;
}

.rating-row .progress-bar {
    background-color: #1a4977;
}

.rating-row .count {
    width: 30px;
    font-size: 0.85rem;
    color: #5a6a7e;
    text-align: right;
}

.reviews-list {
    margin-bottom: 2rem;
}

.review-item {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    background-color: white;
}

.review-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.review-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.review-user i {
    font-size: 1.25rem;
    color: #a0aec0;
}

.review-author {
    font-weight: 600;
    color: #2d3748;
}

.review-rating {
    color: #ffb400;
}

.review-date {
    font-size: 0.8rem;
    color: #a0aec0;
    margin-bottom: 0.75rem;
}

.review-content {
    color: #505a64;
    font-size: 0.95rem;
    line-height: 1.5;
}

.no-reviews-message {
    text-align: center;
    padding: 3rem 1.5rem;
    background-color: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    color: #a0aec0;
}

.no-reviews-message i {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Review form */
.review-form-section {
    background-color: #f8fafc;
    border-radius: 8px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
}

.review-form-section h3 {
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
    font-weight: 600;
    color: #2d3748;
}

.rating-selection {
    display: flex;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.rating-selection .form-check {
    margin-right: 0;
}

.rating-selection .form-check-input {
    display: none;
}

.rating-selection .form-check-label {
    cursor: pointer;
    color: #a0aec0;
    transition: color 0.2s;
}

.rating-selection .form-check-input:checked + .form-check-label {
    color: #ffb400;
}

.rating-selection .form-check-label:hover {
    color: #ffb400;
}

/* Right sidebar */
.download-section {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.download-header {
    background-color: #1a4977;
    color: white;
    padding: 1rem 1.5rem;
}

.download-header h2 {
    margin-bottom: 0;
    font-size: 1.2rem;
    font-weight: 600;
}

.download-body {
    padding: 1.5rem;
}

.download-info {
    margin-bottom: 1.25rem;
}

.download-info-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.download-info-item:last-child {
    margin-bottom: 0;
}

.download-info-item .label {
    color: #5a6a7e;
    font-weight: 500;
}

.download-info-item .value {
    color: #1a4977;
    font-weight: 600;
}

.btn-download {
    background-color: #09ad19;
    border-color: #09ad19;
    color: white;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    width: 100%;
    font-size: 1.05rem;
    margin-bottom: 1rem;
    transition: all 0.2s;
}

.btn-download:hover {
    background-color: #07971a;
    border-color: #07971a;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(9, 173, 25, 0.25);
}

.download-security {
    text-align: center;
    color: #5a6a7e;
    font-size: 0.85rem;
}

.details-box, .tags-box, .related-box {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.details-header, .tags-header, .related-header {
    background-color: #f5f7fa;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 1.25rem;
}

.details-header h3, .tags-header h3, .related-header h3 {
    margin-bottom: 0;
    font-size: 1.05rem;
    font-weight: 600;
    color: #2d3748;
}

.details-body, .tags-body, .related-body {
    padding: 1.25rem;
}

.details-table {
    width: 100%;
}

.details-table td {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f4f8;
    font-size: 0.9rem;
}

.details-table tr:last-child td {
    border-bottom: none;
}

.details-label {
    color: #5a6a7e;
    font-weight: 500;
    width: 35%;
}

.details-value {
    color: #2d3748;
}

.details-value a {
    color: #1a4977;
    text-decoration: none;
}

.details-value a:hover {
    text-decoration: underline;
}

.tags-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-item {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background-color: #f0f4f8;
    border-radius: 20px;
    color: #1a4977;
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.2s;
}

.tag-item:hover {
    background-color: #e2e8f0;
    color: #0d2b4e;
    text-decoration: none;
}

.related-placeholder {
    text-align: center;
    padding: 2rem 1rem;
    color: #a0aec0;
}

.related-placeholder i {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.related-placeholder p {
    margin-bottom: 0;
    font-size: 0.9rem;
}

/* Related Software styles */
.related-items {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.related-item {
    display: flex;
    padding: 0.75rem;
    border-radius: 6px;
    background-color: #f8fafc;
    transition: all 0.2s;
}

.related-item:hover {
    background-color: #edf2f7;
    transform: translateY(-2px);
}

.related-item-image {
    width: 48px;
    height: 48px;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

.related-item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 6px;
}

.related-item-info {
    flex-grow: 1;
}

.related-item-info h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
    line-height: 1.3;
}

.related-item-info h4 a {
    color: #1a4977;
    text-decoration: none;
}

.related-item-info h4 a:hover {
    text-decoration: underline;
}

.related-item-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: #5a6a7e;
}

.related-item-meta .version {
    background-color: #e2e8f0;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
}

/* Responsive adjustments */
@media (max-width: 767.98px) {
    .software-details-header {
        padding: 1rem;
    }
    
    .software-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 1rem;
    }
    
    .software-details-header h1 {
        font-size: 1.4rem;
    }
    
    .software-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .reviews-summary {
        flex-direction: column;
    }
    
    .average-rating {
        padding-right: 0;
        margin-right: 0;
        border-right: none;
        padding-bottom: 1.5rem;
        margin-bottom: 1.5rem;
        border-bottom: 1px solid #e2e8f0;
    }
    
    .rating-selection {
        flex-wrap: wrap;
    }
}