/* CondoSavy AI Document Uploader Styles */
:root {
  --primary-color: #4ecdc4;
  --primary-dark: #3ba99f;
  --primary-light: #7dd3d8;
  --secondary-color: #2c3e50;
  --accent-color: #e74c3c;
  --success-color: #27ae60;
  --warning-color: #f39c12;
  --error-color: #e74c3c;
  --text-primary: #2c3e50;
  --text-secondary: #7f8c8d;
  --background-light: #f8fffe;
  --background-white: #ffffff;
  --border-color: #e8f4f8;
  --shadow-light: 0 2px 10px rgba(78, 205, 196, 0.1);
  --shadow-medium: 0 4px 20px rgba(78, 205, 196, 0.15);
  --border-radius: 12px;
  --border-radius-small: 8px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  margin: 0;
  background: linear-gradient(135deg, var(--background-light) 0%, #e8f8f5 100%);
  color: var(--text-primary);
  min-height: 100vh;
}

#mainContainer {
  max-width: 1200px;
  margin: 0 auto;
  background: var(--background-white);
  box-shadow: var(--shadow-medium);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header Styles */
.app-header {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 2rem 2rem 3rem;
  position: relative;
  overflow: hidden;
}

.app-header::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 200px;
  height: 200px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  transform: translate(50%, -50%);
}

.header-content {
  display: flex;
  align-items: center;
  gap: 2rem;
  position: relative;
  z-index: 1;
}

.company-logo {
  height: 80px;
  width: auto;
  filter: brightness(0) invert(1);
  transition: var(--transition);
}

.header-text h1 {
  margin: 0 0 0.5rem 0;
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.subtitle {
  margin: 0;
  font-size: 1.1rem;
  opacity: 0.9;
  font-weight: 400;
}

/* Progress Indicator */
.progress-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: var(--background-white);
  margin: -1rem 2rem 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  position: relative;
  z-index: 2;
}

.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  transition: var(--transition);
}

.step.active {
  color: var(--primary-color);
}

.step-number {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  transition: var(--transition);
}

.step.active .step-number {
  background: var(--primary-color);
  color: white;
}

.step-connector {
  width: 80px;
  height: 2px;
  background: var(--border-color);
  margin: 0 1rem;
}

/* Main Content */
.main-content {
  flex: 1;
  padding: 0 2rem 2rem;
}

.form-section {
  margin-bottom: 3rem;
  background: var(--background-white);
  border-radius: var(--border-radius);
  padding: 2rem;
  box-shadow: var(--shadow-light);
  border: 1px solid var(--border-color);
  transition: var(--transition);
}

.form-section:hover {
  box-shadow: var(--shadow-medium);
}

.section-header {
  margin-bottom: 2rem;
  text-align: center;
}

.section-header h2 {
  color: var(--text-primary);
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 0.5rem 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.section-header h2 i {
  color: var(--primary-color);
}

.section-header p {
  color: var(--text-secondary);
  margin: 0;
  font-size: 1rem;
}

/* Form Styles */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

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

.input-group label {
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
}

.input-group label i {
  color: var(--primary-color);
  width: 16px;
}

.input-group input[type="text"] {
  padding: 1rem;
  border: 2px solid var(--border-color);
  border-radius: var(--border-radius-small);
  font-size: 1rem;
  transition: var(--transition);
  background: var(--background-white);
}

.input-group input[type="text"]:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.1);
}

.input-group input[type="text"]:disabled {
  background: #f8f9fa;
  color: var(--text-secondary);
  cursor: not-allowed;
}

.input-help {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-top: 0.25rem;
}

/* Drop Zone */
.drop-zone {
  border: 3px dashed var(--primary-color);
  border-radius: var(--border-radius);
  padding: 3rem 2rem;
  text-align: center;
  background: linear-gradient(135deg, rgba(78, 205, 196, 0.05) 0%, rgba(78, 205, 196, 0.02) 100%);
  transition: var(--transition);
  cursor: pointer;
  position: relative;
}

.drop-zone:hover,
.drop-zone.highlight {
  border-color: var(--primary-dark);
  background: linear-gradient(135deg, rgba(78, 205, 196, 0.1) 0%, rgba(78, 205, 196, 0.05) 100%);
  transform: translateY(-2px);
}

.drop-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.drop-icon {
  font-size: 3rem;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.drop-content h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
}

.drop-content p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 1rem;
}

.file-requirements {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.file-requirements small {
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Buttons */
.btn {
  padding: 1rem 2rem;
  border: none;
  border-radius: var(--border-radius-small);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  justify-content: center;
  min-width: 160px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(78, 205, 196, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(78, 205, 196, 0.4);
}

.btn-primary:disabled {
  background: #bdc3c7;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-secondary {
  background: var(--secondary-color);
  color: white;
}

.btn-secondary:hover {
  background: #34495e;
  transform: translateY(-1px);
}

/* Action Section */
.action-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.progress-feedback {
  font-style: italic;
  color: var(--text-secondary);
  text-align: center;
  min-height: 1.5rem;
}

/* Results Section */
.results-section {
  margin-top: 2rem;
}

.status-summary {
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, rgba(78, 205, 196, 0.05) 0%, rgba(78, 205, 196, 0.02) 100%);
  border-radius: var(--border-radius-small);
  border-left: 4px solid var(--primary-color);
}

.table-container {
  overflow-x: auto;
  border-radius: var(--border-radius-small);
  border: 1px solid var(--border-color);
}

.results-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--background-white);
}

.results-table th {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.9rem;
  border: none;
}

.results-table th i {
  margin-right: 0.5rem;
  opacity: 0.8;
}

.results-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.results-table tbody tr:hover {
  background: rgba(78, 205, 196, 0.05);
}

.results-table tbody tr:last-child td {
  border-bottom: none;
}

/* Status Styles */
.status-success {
  color: var(--success-color);
  font-weight: 600;
}

.status-error {
  color: var(--error-color);
  font-weight: 600;
}

.status-processing {
  color: var(--primary-color);
  font-weight: 600;
}

/* Footer */
.app-footer {
  background: var(--secondary-color);
  color: white;
  padding: 1.5rem 2rem;
  text-align: center;
  margin-top: auto;
}

.footer-content p {
  margin: 0;
  opacity: 0.8;
  font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    text-align: center;
    gap: 1.5rem;
  }

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

  .company-logo {
    height: 60px;
  }

  .progress-indicator {
    margin: -1rem 1rem 1rem;
    padding: 1.5rem 1rem;
  }

  .step span {
    font-size: 0.85rem;
  }

  .step-connector {
    width: 40px;
    margin: 0 0.5rem;
  }

  .main-content {
    padding: 0 1rem 1rem;
  }

  .form-section {
    padding: 1.5rem;
    margin-bottom: 2rem;
  }

  .form-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .drop-zone {
    padding: 2rem 1rem;
  }

  .drop-icon {
    font-size: 2.5rem;
  }

  .btn {
    padding: 0.875rem 1.5rem;
    font-size: 0.95rem;
    min-width: 140px;
  }

  .results-table {
    font-size: 0.85rem;
  }

  .results-table th,
  .results-table td {
    padding: 0.75rem 0.5rem;
  }

  .app-footer {
    padding: 1rem;
  }
}

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

  .subtitle {
    font-size: 1rem;
  }

  .progress-indicator {
    flex-direction: column;
    gap: 1rem;
  }

  .step-connector {
    width: 2px;
    height: 20px;
    margin: 0;
  }

  .drop-content h3 {
    font-size: 1.1rem;
  }

  .drop-content p {
    font-size: 0.9rem;
  }
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus styles for accessibility */
.btn:focus,
input:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  :root {
    --border-color: #000000;
    --text-secondary: #000000;
  }
}
