/* Global Styles */
* {
  box-sizing: border-box;
}

#root {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
  line-height: 1.6;
}

.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header Styles */
.app-header {
  text-align: center;
  padding: 3rem 0;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  color: #1f2937;
  border-radius: 12px;
  margin-bottom: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  border: 1px solid #e5e7eb;
}

.app-header h1 {
  margin: 0 0 0.5rem 0;
  font-size: 2.5rem;
  font-weight: bold;
  color: #111827;
  text-shadow: none;
}

.app-header p {
  margin: 0 0 1.5rem 0;
  font-size: 1.2rem;
  color: #6b7280;
}

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

.links a {
  color: #374151;
  text-decoration: none;
  padding: 0.6rem 1.2rem;
  background: white;
  border: 2px solid #e5e7eb;
  border-radius: 20px;
  transition: all 0.3s ease;
  font-weight: 500;
}

.links a:hover {
  background: #f9fafb;
  border-color: #4da6ff;
  color: #4da6ff;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(77, 166, 255, 0.2);
}

/* Main Content */
.app-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* Demo Grid Layout */
.demo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

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

.demo-section {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}

.demo-section:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.demo-section h2 {
  color: #1f2937;
  margin: 0 0 0.5rem 0;
  font-size: 1.5rem;
  text-align: right;
  direction: rtl;
}

.demo-section p {
  color: #6b7280;
  margin: 0 0 1.5rem 0;
  text-align: right;
  direction: rtl;
}

.demo-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: stretch;
}

.result {
  padding: 1rem;
  background: #f8fafc;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  direction: rtl;
  text-align: right;
}

.result strong {
  color: #2563eb;
}

/* Form Styles */
.demo-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 500px;
  margin: 0 auto;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-weight: 600;
  color: #374151;
  text-align: right;
  direction: rtl;
}

.form-group input[type="text"],
.form-group input[type="date"] {
  padding: 0.75rem;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.3s ease;
  direction: rtl;
}

.form-group input[type="text"]:focus,
.form-group input[type="date"]:focus {
  outline: none;
  border-color: #4da6ff;
  box-shadow: 0 0 0 3px rgba(77, 166, 255, 0.1);
}

.submit-btn {
  background: white;
  color: #374151;
  border: 2px solid #4da6ff;
  padding: 1rem 2rem;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px rgba(77, 166, 255, 0.1);
}

.submit-btn:hover {
  background: #4da6ff;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(77, 166, 255, 0.3);
}

.submit-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(77, 166, 255, 0.2);
}

/* Features Grid */
.info-section {
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

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

.feature {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  text-align: right;
  direction: rtl;
  border: 1px solid #e5e7eb;
}

.feature h3 {
  margin: 0 0 0.5rem 0;
  color: #1f2937;
  font-size: 1.1rem;
}

.feature p {
  margin: 0;
  color: #6b7280;
  font-size: 0.9rem;
  line-height: 1.5;
}

/* Info Box */
.demo-info-box {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border: 2px solid #f59e0b;
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2rem;
  text-align: center;
  direction: rtl;
}

.demo-info-box h3 {
  margin: 0 0 1rem 0;
  color: #92400e;
  font-size: 1.2rem;
}

.demo-info-box p {
  margin: 0;
  color: #78350f;
  line-height: 1.6;
}

.demo-info-box strong {
  color: #92400e;
}

/* Footer */
.app-footer {
  text-align: center;
  padding: 2rem 0;
  margin-top: 2rem;
  border-top: 1px solid #e5e7eb;
  color: #6b7280;
}

.app-footer p {
  margin: 0.5rem 0;
}

/* Responsive Design */
@media (max-width: 768px) {
  #root {
    padding: 0.5rem;
  }

  .app-header h1 {
    font-size: 2rem;
  }

  .app-header p {
    font-size: 1rem;
  }

  .demo-section {
    padding: 1.5rem;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .links {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .app-header h1 {
    font-size: 1.5rem;
  }

  .demo-section {
    padding: 1rem;
  }
}