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

:root {
  --primary-color: #4a90e2;
  --secondary-color: #50c878;
  --dark-bg: #1a1a2e;
  --card-bg: #16213e;
  --text-primary: #e8e8e8;
  --text-secondary: #a0a0a0;
  --border-color: #2d3748;
  --success-color: #48bb78;
  --warning-color: #f6ad55;
  --danger-color: #fc8181;
  --code-bg: #0f1419;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #1a1a2e 0%, #0f1419 100%);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

/* Header */
.header {
  background: linear-gradient(135deg, var(--card-bg) 0%, #0f1419 100%);
  border-bottom: 2px solid var(--border-color);
  padding: 2rem 0;
  box-shadow: var(--shadow);
}

.header-content {
  text-align: center;
  margin-bottom: 1rem;
}

.logo {
  font-size: 2.5rem;
  font-weight: bold;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
}

.tagline {
  color: var(--text-secondary);
  font-size: 1.1rem;
  font-style: italic;
}

.header-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.link-btn {
  padding: 0.5rem 1.5rem;
  background: var(--primary-color);
  color: white;
  text-decoration: none;
  border-radius: 5px;
  transition: all 0.3s ease;
  font-weight: 500;
}

.link-btn:hover {
  background: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(74, 144, 226, 0.4);
}

/* Main Content */
.main-content {
  flex: 1;
  padding: 3rem 0;
}

.intro-section {
  text-align: center;
  margin-bottom: 3rem;
}

.intro-section h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.intro-section p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 700px;
  margin: 0 auto;
}

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

.loading {
  grid-column: 1 / -1;
  text-align: center;
  font-size: 1.2rem;
  color: var(--text-secondary);
  padding: 3rem;
}

/* Script Card */
.script-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.script-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5);
  border-color: var(--primary-color);
}

.script-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.script-title {
  font-size: 1.5rem;
  color: var(--text-primary);
  font-weight: 600;
}

.platform-badge {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  background: var(--primary-color);
  color: white;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 500;
}

.platform-badge.windows {
  background: #0078d4;
}

.platform-badge.unix {
  background: var(--secondary-color);
}

.script-description {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.features-list {
  margin-bottom: 1.5rem;
}

.features-list h4 {
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.features-list ul {
  list-style: none;
  padding-left: 0;
}

.features-list li {
  padding: 0.3rem 0;
  color: var(--text-secondary);
  position: relative;
  padding-left: 1.5rem;
}

.features-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--success-color);
  font-weight: bold;
}

/* Usage Section */
.usage-section {
  background: var(--code-bg);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.usage-section h4 {
  color: var(--text-primary);
  margin-bottom: 1rem;
  font-size: 1rem;
}

.command-block {
  position: relative;
  margin-bottom: 1rem;
}

.command-block:last-child {
  margin-bottom: 0;
}

.command-label {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
  display: block;
}

.command-wrapper {
  position: relative;
  background: #0a0e14;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 1rem;
  padding-right: 100px;
}

.command-text {
  font-family: 'Courier New', monospace;
  color: var(--success-color);
  font-size: 0.9rem;
  word-break: break-all;
  white-space: pre-wrap;
}

.copy-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  padding: 0.5rem 1rem;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.copy-btn:hover {
  background: var(--secondary-color);
  transform: translateY(-50%) scale(1.05);
}

.copy-btn:active {
  transform: translateY(-50%) scale(0.95);
}

/* Requirements & Notes */
.info-section {
  margin-top: 1.5rem;
  padding: 1rem;
  background: rgba(74, 144, 226, 0.1);
  border-left: 3px solid var(--primary-color);
  border-radius: 5px;
}

.info-section h4 {
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.info-section ul {
  list-style: none;
  padding-left: 0;
}

.info-section li {
  color: var(--text-secondary);
  padding: 0.3rem 0;
  font-size: 0.9rem;
  position: relative;
  padding-left: 1.5rem;
}

.info-section li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
}

/* Footer */
.footer {
  background: var(--card-bg);
  border-top: 1px solid var(--border-color);
  padding: 2rem 0;
  text-align: center;
  margin-top: auto;
}

.footer p {
  color: var(--text-secondary);
  margin: 0.3rem 0;
}

/* Toast Notification */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--success-color);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
  z-index: 1000;
  font-weight: 500;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast.error {
  background: var(--danger-color);
}

/* Responsive Design */
@media (max-width: 768px) {
  .scripts-grid {
    grid-template-columns: 1fr;
  }

  .logo {
    font-size: 2rem;
  }

  .script-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .command-wrapper {
    padding-right: 10px;
  }

  .copy-btn {
    position: static;
    transform: none;
    width: 100%;
    margin-top: 0.5rem;
  }

  .copy-btn:hover {
    transform: scale(1.02);
  }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-color);
}
