* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f5f5f5;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Navigation */
nav {
  background-color: #2c3e50;
  color: white;
  padding: 1rem 0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

nav .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

nav h1 {
  font-size: 1.5rem;
}

nav ul {
  display: flex;
  list-style: none;
  gap: 2rem;
}

nav a {
  color: white;
  text-decoration: none;
  transition: opacity 0.3s;
}

nav a:hover {
  opacity: 0.8;
}

/* Main Content */
main {
  min-height: calc(100vh - 200px);
  padding: 2rem 0;
}

/* Hero Section */
.hero {
  text-align: center;
  padding: 3rem 0;
  background: white;
  border-radius: 8px;
  margin-bottom: 2rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.hero h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: #2c3e50;
}

.hero p {
  font-size: 1.2rem;
  color: #666;
  margin-bottom: 2rem;
}

.actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

/* Features */
.features {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.features h3 {
  text-align: center;
  margin-bottom: 2rem;
  color: #2c3e50;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature {
  text-align: center;
  padding: 1rem;
}

.feature h4 {
  margin-bottom: 0.5rem;
  color: #3498db;
}

/* Buttons */
.button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: #ecf0f1;
  color: #2c3e50;
  text-decoration: none;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.3s;
}

.button:hover {
  background-color: #bdc3c7;
}

.button.primary {
  background-color: #3498db;
  color: white;
}

.button.primary:hover {
  background-color: #2980b9;
}

.button.danger {
  background-color: #e74c3c;
  color: white;
}

.button.danger:hover {
  background-color: #c0392b;
}

.button.small {
  padding: 0.4rem 0.8rem;
  font-size: 0.875rem;
}

/* Forms */
.ticket-form, .login-form {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  max-width: 600px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #2c3e50;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 1rem;
  font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #3498db;
}

/* Alerts */
.alert {
  padding: 1rem;
  border-radius: 4px;
  margin-bottom: 1.5rem;
}

.alert.success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.alert.error {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Tickets */
.ticket-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.ticket-card {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.ticket-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.ticket-header h3 {
  color: #2c3e50;
  margin: 0;
}

.status {
  padding: 0.25rem 0.75rem;
  border-radius: 4px;
  font-size: 0.875rem;
  font-weight: 500;
}

.status.open {
  background-color: #3498db;
  color: white;
}

.status.in-progress {
  background-color: #f39c12;
  color: white;
}

.status.closed {
  background-color: #27ae60;
  color: white;
}

.ticket-body p {
  margin-bottom: 0.5rem;
}

.ticket-meta {
  color: #666;
  font-size: 0.875rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

/* Admin */
.login-container {
  max-width: 400px;
  margin: 3rem auto;
}

.admin-info {
  background: #e8f4f8;
  padding: 1rem;
  border-radius: 4px;
  margin-bottom: 1.5rem;
  border-left: 4px solid #3498db;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: bold;
  color: #3498db;
}

.stat-label {
  display: block;
  color: #666;
  font-size: 0.875rem;
  margin-top: 0.5rem;
}

.admin-table {
  width: 100%;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.admin-table thead {
  background-color: #2c3e50;
  color: white;
}

.admin-table th,
.admin-table td {
  padding: 1rem;
  text-align: left;
}

.admin-table tbody tr:hover {
  background-color: #f8f9fa;
}

.admin-table small {
  color: #666;
  font-size: 0.875rem;
}

.status-form {
  display: inline;
}

.status-select {
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  border: 1px solid #ddd;
  font-size: 0.875rem;
  cursor: pointer;
}

.status-select.open {
  background-color: #3498db;
  color: white;
  border-color: #3498db;
}

.status-select.in-progress {
  background-color: #f39c12;
  color: white;
  border-color: #f39c12;
}

.status-select.closed {
  background-color: #27ae60;
  color: white;
  border-color: #27ae60;
}

.description-row td {
  padding: 0 1rem 1rem 1rem;
  border-bottom: 1px solid #eee;
}

.description-row details {
  cursor: pointer;
}

.description-row summary {
  color: #3498db;
  user-select: none;
}

.description-row p {
  margin-top: 0.5rem;
  padding: 0.5rem;
  background-color: #f8f9fa;
  border-radius: 4px;
}

/* Misc */
.no-data {
  text-align: center;
  padding: 3rem;
  color: #666;
}

h2 {
  color: #2c3e50;
  margin-bottom: 1.5rem;
}

/* Footer */
footer {
  background-color: #2c3e50;
  color: white;
  text-align: center;
  padding: 2rem 0;
  margin-top: 3rem;
}

footer p {
  margin: 0;
}
