/* Reset and Base Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: #f5f5f5;
  color: #333;
  line-height: 1.6;
}

/* App Container */
.app {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* Header */
header {
  text-align: center;
  margin-bottom: 40px;
  padding: 30px;
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

header h1 {
  color: #2c3e50;
  margin-bottom: 10px;
}

header p {
  color: #7f8c8d;
}

.server-status {
  margin-top: 20px;
  padding: 10px;
  background: #f8f9fa;
  border-radius: 5px;
  font-size: 14px;
}

/* Sections */
section {
  margin-bottom: 40px;
  padding: 30px;
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

section h2 {
  color: #2c3e50;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #ecf0f1;
}

/* Wallet Connect */
.wallet-section {
  text-align: center;
}

.wallet-connect {
  display: inline-block;
}

.connect-btn {
  background: #3498db;
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
}

.connect-btn:hover {
  background: #2980b9;
}

.connect-btn:disabled {
  background: #95a5a6;
  cursor: not-allowed;
}

.wallet-connected {
  display: inline-block;
}

.wallet-info {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  background: #e8f5e9;
  border-radius: 5px;
  border: 1px solid #4caf50;
}

.status-indicator {
  color: #4caf50;
  font-size: 20px;
}

.address {
  font-family: monospace;
  color: #2e7d32;
}

.disconnect-btn {
  background: none;
  border: none;
  color: #e74c3c;
  cursor: pointer;
  text-decoration: underline;
}

/* Pricing Grid */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.pricing-card {
  padding: 20px;
  border: 2px solid #ecf0f1;
  border-radius: 8px;
  text-align: center;
  transition: transform 0.3s, box-shadow 0.3s;
}

.pricing-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.pricing-card h3 {
  color: #2c3e50;
  margin-bottom: 10px;
}

.price {
  font-size: 28px;
  font-weight: bold;
  color: #3498db;
  margin: 10px 0;
}

.description {
  color: #7f8c8d;
  margin-bottom: 20px;
}

.action-btn {
  background: #27ae60;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
  width: 100%;
}

.action-btn:hover {
  background: #229954;
}

.action-btn:disabled {
  background: #95a5a6;
  cursor: not-allowed;
}

/* Results */
.result-card {
  margin-bottom: 20px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #3498db;
}

.result-card h3 {
  color: #2c3e50;
  margin-bottom: 10px;
}

.result-card pre {
  background: #2c3e50;
  color: #ecf0f1;
  padding: 15px;
  border-radius: 5px;
  overflow-x: auto;
  margin-top: 10px;
}

/* Sessions */
.sessions-section ul {
  list-style: none;
}

.sessions-section li {
  padding: 10px;
  background: #f8f9fa;
  margin-bottom: 10px;
  border-radius: 5px;
  font-family: monospace;
}

/* Error Messages */
.error-message,
.error {
  color: #e74c3c;
  margin-top: 10px;
  padding: 10px;
  background: #ffebee;
  border-radius: 5px;
  font-size: 14px;
}

/* Footer */
footer {
  text-align: center;
  margin-top: 40px;
  padding: 20px;
  color: #7f8c8d;
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Builder Resources */
.builder-resources {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid #e9ecef;
}

.builder-resources h3 {
  color: #2c3e50;
  margin-bottom: 0.5rem;
}

.builder-resources p {
  color: #718096;
  margin-bottom: 1rem;
}

.resource-links {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
}

.resource-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  color: #3182ce;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.2s;
}

.resource-links a:hover {
  background: #e9ecef;
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Payment section styling */
.payment-section,
.validation-section {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.payment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.payment-card {
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
}

.payment-card h3 {
  color: #2d3748;
  margin-bottom: 0.5rem;
}

.payment-card .price {
  font-size: 2rem;
  font-weight: bold;
  color: #3182ce;
  margin: 0.5rem 0;
}

.payment-card .description {
  color: #718096;
  margin-bottom: 1rem;
}

/* Session validation section */
.validation-section {
  margin-top: 2rem;
}

.session-validator {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.session-input {
  flex: 1;
  padding: 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 1rem;
  font-family: monospace;
}

.session-input:focus {
  outline: none;
  border-color: #3182ce;
  box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.1);
}

.validate-btn {
  padding: 0.75rem 1.5rem;
  background: #3182ce;
  color: white;
  border: none;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.validate-btn:hover {
  background: #2c5282;
}

.validation-result {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 6px;
  border: 1px solid;
}

.validation-result.success {
  background: #f0fdf4;
  border-color: #22c55e;
  color: #166534;
}

.validation-result.error {
  background: #fef2f2;
  border-color: #ef4444;
  color: #991b1b;
}

.session-details,
.access-details {
  margin-top: 0.5rem;
  padding: 0.5rem;
  background: rgba(0, 0, 0, 0.05);
  border-radius: 4px;
  font-size: 0.9rem;
}

/* Active sessions styling */
.sessions-section {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  margin-top: 2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.sessions-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.session-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 6px;
}

.session-item code {
  font-family: monospace;
  font-size: 0.85rem;
  color: #4a5568;
  flex: 1;
}

.session-type {
  padding: 0.25rem 0.75rem;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 500;
}

.session-type.24hour {
  background: #dbeafe;
  color: #1e40af;
}

.session-type.onetime {
  background: #fef3c7;
  color: #92400e;
}

.session-expires {
  font-size: 0.85rem;
  color: #718096;
}