/* WidgetBin Core Stylesheet — Dark Theme & Vibrant Ice Cyan */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background-color: #0b0f17;
  color: #e2e8f0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: #22d3ee; text-decoration: none; transition: 0.2s ease; }
a:hover { color: #67e8f9; }

.container {
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header & Navigation */
.site-header {
  background-color: #101622;
  border-bottom: 1px solid #1e293b;
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.brand-logo {
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-logo span { color: #22d3ee; }

.brand-tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  background: rgba(34, 211, 238, 0.12);
  color: #22d3ee;
  border: 1px solid rgba(34, 211, 238, 0.3);
  padding: 2px 8px;
  border-radius: 4px;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
}

.top-nav a { color: #cbd5e1; }
.top-nav a:hover, .top-nav a.active { color: #22d3ee; }

/* Symmetric Cross-Promo Banner Enclosure */
.promo-banner-wrap {
  margin: 24px auto 0;
}

.promo-enclosure {
  background: linear-gradient(90deg, #131a26 0%, #162234 50%, #131a26 100%);
  border: 1px solid #1e293b;
  border-left: 3px solid #22d3ee;
  border-right: 3px solid #22d3ee;
  border-radius: 8px;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.promo-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #22d3ee;
  background: rgba(34, 211, 238, 0.1);
  padding: 3px 8px;
  border-radius: 4px;
  margin-right: 10px;
}

.promo-text { font-size: 14px; color: #e2e8f0; }

.btn-promo {
  background-color: #22d3ee;
  color: #0b0f17;
  font-weight: 700;
  font-size: 13px;
  padding: 8px 16px;
  border-radius: 5px;
  white-space: nowrap;
}

.btn-promo:hover { background-color: #67e8f9; color: #0b0f17; }

/* Hero & Search Bar */
.hero-bar {
  text-align: center;
  padding: 36px 0 24px;
}

.hero-bar h1 {
  font-size: 32px;
  color: #ffffff;
  margin-bottom: 8px;
}

.hero-bar h1 span { color: #22d3ee; }

.hero-bar p {
  color: #94a3b8;
  max-width: 640px;
  margin: 0 auto 22px;
  font-size: 15px;
}

.filter-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: #131a26;
  border: 1px solid #1e293b;
  padding: 14px 18px;
  border-radius: 8px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.cat-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.cat-pill {
  background: #0b0f17;
  color: #cbd5e1;
  border: 1px solid #1e293b;
  padding: 7px 14px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s;
}

.cat-pill:hover, .cat-pill.active {
  background: rgba(34, 211, 238, 0.14);
  color: #22d3ee;
  border-color: #22d3ee;
}

.search-input {
  background: #0b0f17;
  border: 1px solid #1e293b;
  color: #ffffff;
  padding: 8px 14px;
  border-radius: 5px;
  font-size: 14px;
  min-width: 250px;
  outline: none;
}

.search-input:focus { border-color: #22d3ee; }

/* 3-Column Symmetric Widget Grid */
.widget-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-bottom: 44px;
}

.widget-card {
  background-color: #131a26;
  border: 1px solid #1e293b;
  border-top: 2px solid #1e293b;
  border-radius: 8px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.widget-card:hover {
  transform: translateY(-3px);
  border-color: #334155;
  border-top-color: #22d3ee;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 12px;
}

.card-cat {
  color: #94a3b8;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-free {
  background: rgba(34, 211, 238, 0.12);
  color: #22d3ee;
  border: 1px solid rgba(34, 211, 238, 0.3);
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 700;
}

.badge-pro {
  background: rgba(213, 74, 250, 0.14);
  color: #e879f9;
  border: 1px solid rgba(213, 74, 250, 0.35);
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 700;
}

.widget-card h3 {
  font-size: 18px;
  color: #ffffff;
  margin-bottom: 8px;
}

.widget-card p {
  font-size: 14px;
  color: #94a3b8;
  margin-bottom: 20px;
  flex-grow: 1;
}

.card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.btn-outline {
  text-align: center;
  background: #0b0f17;
  color: #e2e8f0;
  border: 1px solid #334155;
  padding: 8px 12px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
}

.btn-outline:hover {
  border-color: #22d3ee;
  color: #22d3ee;
}

.btn-primary {
  text-align: center;
  background: #22d3ee;
  color: #0b0f17;
  border: 1px solid #22d3ee;
  padding: 8px 12px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 700;
}

.btn-primary:hover {
  background: #67e8f9;
  color: #0b0f17;
}

/* Single Widget Sandbox Page */
.sandbox-enclosure {
  background: #131a26;
  border: 1px solid #1e293b;
  border-top: 3px solid #22d3ee;
  border-radius: 8px;
  padding: 26px;
  margin: 24px 0 36px;
}

.demo-frame-box {
  background: #0b0f17;
  border: 1px solid #1e293b;
  border-radius: 6px;
  padding: 24px;
  margin: 18px 0 26px;
  min-height: 220px;
}

.code-box-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.code-area {
  width: 100%;
  min-height: 220px;
  background: #070a10;
  color: #67e8f9;
  border: 1px solid #1e293b;
  border-radius: 6px;
  padding: 16px;
  font-family: Consolas, Monaco, "Courier New", monospace;
  font-size: 13px;
  line-height: 1.5;
  resize: vertical;
}

/* Footer */
.site-footer {
  margin-top: auto;
  background: #101622;
  border-top: 1px solid #1e293b;
  padding: 28px 0;
  font-size: 13px;
  color: #64748b;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a { color: #94a3b8; }
.footer-links a:hover { color: #22d3ee; }

@media (max-width: 900px) {
  .widget-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
  .widget-grid { grid-template-columns: 1fr; }
  .search-input { width: 100%; }
}
