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

/* Browser compatibility fixes */
html {
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f8f9fa;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.header {
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo h1 {
  color: #007bff;
  font-size: 2rem;
  font-weight: 700;
  margin: 0;
}

.tagline {
  color: #6c757d;
  font-size: 0.9rem;
  font-weight: 400;
}

.nav {
  display: flex;
  gap: 2rem;
}

.nav-link {
  text-decoration: none;
  color: #333; /* Dark text for white background */
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #ffffff; /* White text on hover */
  background-color: #007bff; /* Blue background for contrast */
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 4rem 0;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
  font-size: 1.25rem;
  margin-bottom: 3rem;
  opacity: 0.9;
}

/* Shortener Form */
.shortener-form {
  max-width: 600px;
  margin: 0 auto;
}

.input-group {
  display: flex;
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  margin-bottom: 1.5rem;
}

.url-input {
  flex: 1;
  padding: 1rem 1.5rem;
  border: none;
  font-size: 1rem;
  outline: none;
  color: #333;
}

.url-input::placeholder {
  color: #adb5bd;
}

.shorten-btn {
  background: #1e7e34; /* Darker green for better contrast */
  color: #ffffff; /* Ensure white text */
  border: none;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 140px;
}

.shorten-btn:hover {
  background: #155724; /* Even darker on hover */
  transform: translateY(-1px);
}

.shorten-btn:disabled {
  background: #495057; /* Darker disabled state for better contrast */
  cursor: not-allowed;
  transform: none;
}

.btn-loading {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top: 2px solid white;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Advanced Options */
.advanced-options {
  text-align: left;
  margin-top: 1rem;
}

.options-toggle {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 0.5rem 1rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.options-toggle:hover {
  background: rgba(255, 255, 255, 0.3);
}

.options-panel {
  background: rgba(255, 255, 255, 0.95);
  color: #333;
  padding: 1.5rem;
  border-radius: 8px;
  margin-top: 1rem;
  backdrop-filter: blur(10px);
}

.option-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #495057;
}

.expiry-input {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid #e9ecef;
  border-radius: 6px;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s ease;
}

.expiry-input:focus {
  border-color: #007bff;
}

.option-group small {
  color: #6c757d;
  font-size: 0.8rem;
  margin-top: 0.25rem;
  display: block;
}

/* Error Message */
.error-message {
  background: #f8d7da;
  color: #721c24;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  border: 1px solid #f5c6cb;
  margin-top: 1rem;
  font-size: 0.9rem;
}

/* Result Section */
.result-section {
  margin-top: 2rem;
  animation: slideUp 0.3s ease;
}

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

.result-card {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
  color: #333;
}

.result-header h3 {
  color: #28a745;
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
}

.url-display {
  display: flex;
  background: #f8f9fa;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  border: 2px solid #e9ecef;
}

.short-url-input {
  flex: 1;
  padding: 1rem;
  border: none;
  background: transparent;
  font-size: 1rem;
  color: #007bff;
  font-weight: 600;
  outline: none;
}

.copy-btn {
  background: #007bff;
  color: white;
  border: none;
  padding: 1rem 1.5rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

.copy-btn:hover {
  background: #0056b3;
}

.copy-btn.copied {
  background: #28a745;
}

.result-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.action-btn {
  background: #6c757d;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.action-btn:hover {
  background: #5a6268;
  transform: translateY(-1px);
}

.action-btn.secondary {
  background: #e9ecef;
  color: #495057;
}

.action-btn.secondary:hover {
  background: #dee2e6;
}

/* Features Section */
.features {
  padding: 4rem 0;
  background: white;
}

.features .section-title {
  color: #333; /* Dark text for white background */
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 3rem;
  color: #ffffff; /* High contrast white text for dark backgrounds */
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature-card {
  text-align: center;
  padding: 2rem;
  border-radius: 12px;
  background: #f8f9fa;
  transition: all 0.3s ease;
}

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

.feature-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.feature-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #333;
}

.feature-card p {
  color: #ffffff; /* High contrast white text */
  line-height: 1.6;
}

/* Analytics Section */
.analytics {
  padding: 4rem 0;
  background: #f8f9fa;
}

.analytics .section-title {
  color: #333; /* Dark text for light background */
}

.analytics-form {
  max-width: 600px;
  margin: 0 auto 3rem;
}

.analytics-btn {
  background: #0c5460; /* Darker teal for better contrast */
  color: #ffffff; /* Ensure white text */
  border: none;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.analytics-btn:hover {
  background: #084248; /* Even darker on hover */
}

.analytics-result {
  max-width: 800px;
  margin: 0 auto;
}

.analytics-card {
  background: white;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.analytics-card h3 {
  margin-bottom: 1.5rem;
  color: #333;
}

/* Footer */
.footer {
  background: #343a40;
  color: white;
  padding: 3rem 0 1rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  margin-bottom: 1rem;
  color: #007bff;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section ul li a {
  color: #adb5bd;
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-section ul li a:hover {
  color: white;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid #495057;
  color: #adb5bd;
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .input-group {
    flex-direction: column;
  }

  .shorten-btn {
    border-radius: 0 0 12px 12px;
  }

  .url-input {
    border-radius: 12px 12px 0 0;
  }

  .header-content {
    flex-direction: column;
    gap: 1rem;
  }

  .nav {
    gap: 1rem;
  }

  .result-actions {
    flex-direction: column;
  }

  .url-display {
    flex-direction: column;
  }

  .copy-btn {
    border-radius: 0 0 8px 8px;
  }
} /* How It 
Works Section */
.how-it-works {
  padding: 4rem 0;
  background: rgba(255, 255, 255, 0.05);
}

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

.step-card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  padding: 2rem;
  text-align: center;
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.step-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 123, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
}

.step-number {
  width: 60px;
  height: 60px;
  background: linear-gradient(45deg, #007bff, #0056b3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: bold;
  color: white;
  margin: 0 auto 1rem;
}

.step-card h4 {
  color: #fff;
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.step-card p {
  color: #ffffff; /* High contrast white text */
  line-height: 1.6;
}

/* SEO Improvements */
.hero-title {
  font-size: 3.5rem !important;
  color: #ffffff; /* Ensure high contrast */
  font-weight: 700;
}

/* Responsive improvements */
@media (max-width: 768px) {
  .steps-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .step-card {
    padding: 1.5rem;
  }

  .hero-title {
    font-size: 2.5rem !important;
  }
}
/* How It Works Section */
.how-it-works {
  padding: 80px 0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.how-it-works .section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 60px;
  color: white;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
  max-width: 1000px;
  margin: 0 auto;
}

.step-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 40px 30px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
  position: relative;
}

.step-card:hover {
  transform: translateY(-10px);
  background: rgba(255, 255, 255, 0.15);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.step-number {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #ff6b6b, #ee5a24);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 auto 20px;
  box-shadow: 0 10px 20px rgba(238, 90, 36, 0.3);
}

.step-card h4 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: white;
}

.step-card p {
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
}

/* Responsive adjustments for How It Works */
@media (max-width: 768px) {
  .how-it-works {
    padding: 60px 0;
  }

  .how-it-works .section-title {
    font-size: 2rem;
    margin-bottom: 40px;
  }

  .steps-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .step-card {
    padding: 30px 20px;
  }

  .step-number {
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
  }

  .step-card h4 {
    font-size: 1.3rem;
  }
}

.features {
  padding: 80px 0;
  background-color: #f8f9fa;
}

.features .section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 60px;
  color: #333;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
}

.feature-card {
  background: white;
  border-radius: 15px;
  padding: 40px 30px;
  text-align: center;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  border: 1px solid #e9ecef;
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 20px;
  display: block;
}

.feature-card h4 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: #333;
}

.feature-card p {
  font-size: 1rem;
  line-height: 1.6;
  color: #666;
  margin: 0;
}

/* Footer */
.footer {
  background: #2c3e50;
  color: white;
  padding: 60px 0 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-section h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: white;
}

.footer-section p {
  font-size: 1rem;
  line-height: 1.6;
  color: #bdc3c7;
  margin: 0;
}

.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-section ul li {
  margin-bottom: 10px;
}

.footer-section ul li a {
  color: #bdc3c7;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-section ul li a:hover {
  color: #3498db;
}

.footer-bottom {
  border-top: 1px solid #34495e;
  padding-top: 20px;
  text-align: center;
}

.footer-bottom p {
  color: #95a5a6;
  margin: 0;
  font-size: 0.9rem;
}

/* Responsive adjustments for Features */
@media (max-width: 768px) {
  .features {
    padding: 60px 0;
  }

  .features .section-title {
    font-size: 2rem;
    margin-bottom: 40px;
  }

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

  .feature-card {
    padding: 30px 20px;
  }

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

  .feature-card h4 {
    font-size: 1.3rem;
  }
}
/* Responsive adjustments for Features - Single Line Layout */
@media (max-width: 1024px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
  }
}

@media (max-width: 768px) {
  .features {
    padding: 60px 0;
  }

  .features .section-title {
    font-size: 2rem;
    margin-bottom: 40px;
  }

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

  .feature-card {
    padding: 30px 20px;
  }

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

  .feature-card h4 {
    font-size: 1.3rem;
  }
}
