:root {
  --primary: #d73502;
  --primary-hover: #b82d00;
  --bg-color: #fafafa;
  --card-bg: #ffffff;
  --text-color: #333;
  --text-muted: #666;
  --border-color: #e0e0e0;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.15);
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
  font-family: var(--font-family);
  max-width: 800px;
  margin: 2em auto;
  padding: 0 1em;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--bg-color);
}

header {
  text-align: center;
  margin-bottom: 3em;
  padding: 1.5em 0;
  border-bottom: 1px solid var(--border-color);
  background: var(--card-bg);
  position: relative;
  border-radius: var(--radius-md);
  margin: 0 -1em 3em -1em;
  box-shadow: var(--shadow-md);
}

.header-logo {
  max-width: 400px;
  width: 80%;
  height: auto;
  margin: 0 auto;
  display: block;
}

h1 {
  display: none;
}

.tagline {
  font-size: 1.2em;
  color: var(--text-muted);
  margin-top: 0.5em;
  font-weight: 500;
}

/* Navigation */
.nav {
  display: flex;
  gap: 1em;
  justify-content: center;
  margin: 2em 0;
  flex-wrap: wrap;
}

.nav a {
  padding: 0.8em 2em;
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
  text-decoration: none;
  border-radius: var(--radius-full);
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: none;
}

.nav a:hover,
.nav a.active {
  background: var(--primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(215, 53, 2, 0.3);
}

/* Buttons */
button,
.home-nav-btn {
  background: var(--primary);
  color: white;
  border: none;
  padding: 0.8em 2em;
  font-size: 1em;
  font-weight: 600;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
}

button:hover,
.home-nav-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(215, 53, 2, 0.25);
}

button:disabled {
  background: #ccc;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Cards & Containers */
/* Cards & Containers */
.feature,
.rant-preview,
.filter-container,
.form-container,
.description,
.creator-credit,
.no-results {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  padding: 1.5em;
  /* Added padding */
}

/* Rants */
.rant-preview {

  margin: 1.5em 0;
  border-left: 4px solid var(--primary);
}

.rant-preview:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* Features Grid */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2em;
  margin: 3em 0;
}

.feature {

  background: var(--card-bg);
  /* Explicit back for consisteny */
}

.feature h3 {
  color: var(--primary);
  margin-top: 0;
}

/* Forms */
input[type="text"],
input[type="password"],
textarea,
select {
  width: 100%;
  padding: 1em;
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  font-size: 1em;
  font-family: inherit;
  transition: all 0.3s ease;
  box-sizing: border-box;
  background: var(--bg-color);
}

input[type="text"]:focus,
input[type="password"]:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--card-bg);
  box-shadow: 0 0 0 4px rgba(215, 53, 2, 0.1);
}

textarea {
  height: 150px;
  resize: vertical;
}

.form-container {
  padding: 2.5em;
}

label {
  display: block;
  margin-bottom: 0.5em;
  font-weight: 600;
  color: var(--text-color);
  margin-top: 1.5em;
}

label:first-child {
  margin-top: 0;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5em;
  margin-bottom: 1em;
}

.form-row label {
  margin-top: 0;
}

select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1em center;
  background-size: 1.2em;
  padding-right: 2.5em;
  cursor: pointer;
}

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

/* Filters & Tags */
.filter-btn,
.sort-btn {
  padding: 0.6em 1.2em;
  border: 2px solid var(--border-color);
  background: var(--card-bg);
  color: var(--text-muted);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.3s;
  font-weight: 500;
  box-shadow: none;
  /* Reset distinct style */
}

.filter-btn:hover,
.sort-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

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

.category-tag {
  background: var(--bg-color);
  color: var(--text-muted);
  padding: 0.4em 1em;
  border-radius: var(--radius-full);
  font-size: 0.85em;
  font-weight: 500;
  text-transform: capitalize;
  border: 1px solid var(--border-color);
}

/* Like Button */
.like-btn {
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 0.5em 1em;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-weight: 600;
  color: var(--text-muted);
}

.like-btn:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

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

.like-count {
  color: inherit;
}

/* Misc Components */
.admin-overlay-btn {
  position: fixed;
  bottom: 2em;
  right: 8em;
  background: transparent;
  color: #ccc;
  font-size: 1.2em;
  opacity: 0.2;
  padding: 0.8em;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  z-index: 999;
  transition: all 0.3s ease;
}

.admin-overlay-btn:hover {
  opacity: 0.8;
  background: rgba(215, 53, 2, 0.1);
  transform: scale(1.1);
  color: var(--primary);
}

.ai-info-trigger {
  position: fixed;
  bottom: 2em;
  right: 2em;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  font-size: 1.5em;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(215, 53, 2, 0.4);
  transition: all 0.3s ease;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ai-info-trigger:hover {
  transform: scale(1.1);
  background: var(--primary-hover);
}

.creator-credit {
  margin-top: 1.5em;
  padding: 0;
  background: transparent;
  border: none;
}

.creator-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

.creator-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  object-fit: cover;
}

.creator-text {
  text-align: left;
}

.creator-text p {
  margin: 0;
}

footer {
  text-align: center;
  margin-top: 4em;
  padding: 3em 0;
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.9em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
}

footer p {
  margin: 0;
}

/* Utility */
.error {
  color: #d73502;
  background: #ffeaea;
  padding: 1em;
  border-radius: var(--radius-sm);
  border-left: 4px solid #d73502;
  margin-top: 1em;
}

.success {
  color: #2d5016;
  background: #eafaea;
  padding: 1em;
  border-radius: var(--radius-sm);
  border-left: 4px solid #4caf50;
  margin-top: 1em;
}

.description {
  background: var(--card-bg);
  padding: 2em;
  margin-bottom: 2em;
  border-left: 4px solid var(--primary);
}

/* Search */
.search-box {
  margin-bottom: 1.5em;
}

.search-box input {
  border-radius: var(--radius-full);
  padding-left: 1.5em;
}

.category-filters,
.sort-controls {
  display: flex;
  gap: 0.5em;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 1.5em;
}


/* AI Card */
.ai-info-card {
  position: fixed;
  bottom: 5em;
  right: 2em;
  width: 400px;
  max-width: 90vw;
  /* Mobile responsive */
  max-height: 600px;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  z-index: 999;
  overflow-y: auto;
  display: none;
  animation: slideUp 0.3s ease;
}

.ai-info-card.show {
  display: block;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}


.ai-info-header {
  background: var(--primary);
  color: white;
  padding: 1.5em;
}

.ai-close {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  color: white;
  cursor: pointer;
  transition: background 0.2s;
}

.ai-close:hover {
  background: rgba(255, 255, 255, 0.4);
}

.ai-style {
  background: var(--bg-color);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--primary);
  padding: 1em;
}

/* Admin Styles */
.login-container {
  background: var(--card-bg);
  padding: 2.5em;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  margin-bottom: 2em;
  border: 1px solid var(--border-color);
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.controls {
  background: var(--card-bg);
  padding: 1.5em;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  margin-bottom: 2em;
  border: 1px solid var(--border-color);
  display: flex;
  gap: 1em;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}

.rant-admin-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  padding: 1.5em;
  margin-bottom: 1.5em;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--primary);
  transition: all 0.3s ease;
}

.rant-admin-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

.rant-meta {
  display: flex;
  gap: 1em;
  align-items: center;
  flex-wrap: wrap;
}

.author {
  font-weight: 700;
  color: var(--primary);
}

.category {
  font-style: italic;
  color: var(--text-muted);
  background: var(--bg-color);
  padding: 0.3em 0.8em;
  border-radius: var(--radius-full);
  font-size: 0.85em;
  border: 1px solid var(--border-color);
}

.rant-content {
  margin: 1em 0;
  line-height: 1.6;
  color: var(--text-color);
  font-size: 1.1em;
}

.actions {
  margin-top: 1.5em;
  display: flex;
  gap: 0.8em;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* Admin Buttons */
button.primary {
  background: var(--primary);
  color: white;
}

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

button.secondary {
  background: white;
  color: var(--text-muted);
  border: 2px solid var(--border-color);
  box-shadow: none;
}

button.secondary:hover {
  border-color: var(--text-muted);
  color: var(--text-color);
  background: var(--bg-color);
}

button.approve {
  background: #2d5016;
  color: white;
}

button.approve:hover {
  background: #1e360f;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(45, 80, 22, 0.2);
}

button.reject {
  background: white;
  color: #d32f2f;
  border: 2px solid #ffcdd2;
  box-shadow: none;
}

button.reject:hover {
  background: #ffebee;
  border-color: #d32f2f;
  transform: translateY(-2px);
}

.status {
  padding: 1em;
  border-radius: var(--radius-md);
  margin-bottom: 1em;
  font-weight: 500;
  text-align: center;
}

.status.error {
  background: #ffeaea;
  color: #d73502;
  border: 1px solid #ffcdd2;
}

.status.success {
  background: #eafaea;
  color: #2d5016;
  border: 1px solid #c8e6c9;
}

.empty-state {
  text-align: center;
  padding: 4em 2em;
  color: var(--text-muted);
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  border: 2px dashed var(--border-color);
}