/**
 * Peering Form Styles for AS6057 - ANTEL
 * Matches site look & feel:
 * - Primary color: #3498db (blue)
 * - Success color: #07bc0c (green)
 * - Error color: #e74c3c (red)
 * - Border radius: 6px
 * - Fonts: Futura Std, Roboto Condensed
 */

/* ============================================
   FLOATING BUTTON CONTAINER
   ============================================ */

#peering-button-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
}

.peering-floating-btn {
  background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
  color: #ffffff;
  border: none;
  border-radius: 50px;
  padding: 14px 28px;
  font-size: 14px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(52, 152, 219, 0.4);
  transition: all 0.3s ease;
  white-space: nowrap;
}

.peering-floating-btn:hover {
  background: linear-gradient(135deg, #2980b9 0%, #1a5276 100%);
  box-shadow: 0 6px 20px rgba(52, 152, 219, 0.5);
  transform: translateY(-2px);
}

.peering-floating-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

@media (max-width: 768px) {
  #peering-button-container {
    top: auto;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
  }

  .peering-floating-btn {
    padding: 12px 20px;
    font-size: 12px;
  }
}

/* ============================================
   PEERING REQUEST BUTTON (embedded)
   ============================================ */

.peering-request-btn {
  background-color: #3498db;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 12px 24px;
  font-size: 16px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
  display: inline-block;
  margin-top: 16px;
  text-align: center;
  text-decoration: none;
}

.peering-request-btn:hover {
  background-color: #2980b9;
  box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
  transform: translateY(-1px);
}

.peering-request-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(52, 152, 219, 0.3);
}

/* ============================================
   MODAL CONTAINER
   ============================================ */

.peering-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.peering-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
}

.peering-modal-container {
  position: relative;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
  max-height: calc(100vh - 40px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease-out;
}

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

/* ============================================
   MODAL HEADER
   ============================================ */

.peering-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #e8e8e8;
  background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
  color: #ffffff;
}

.peering-modal-header h2 {
  margin: 0;
  font-size: 20px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 600;
  color: #ffffff;
}

.peering-modal-close {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #ffffff;
  font-size: 28px;
  line-height: 1;
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.peering-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ============================================
   MODAL BODY
   ============================================ */

.peering-modal-body {
  padding: 24px;
  overflow-y: auto;
  max-height: calc(90vh - 80px);
}

/* ============================================
   FORM
   ============================================ */

.peering-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.peering-form-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.peering-form-section h3 {
  margin: 0;
  font-size: 16px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 600;
  color: #3498db;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding-bottom: 8px;
  border-bottom: 2px solid #e8e8e8;
}

.peering-form-section h4 {
  margin: 0 0 8px 0;
  font-size: 14px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 600;
  color: #555555;
}

.peering-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 600px) {
  .peering-form-row {
    grid-template-columns: 1fr;
  }
}

.peering-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.peering-form-group label {
  font-size: 13px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 500;
  color: #555555;
}

.peering-form-group input[type="text"],
.peering-form-group input[type="email"],
.peering-form-group input[type="tel"],
.peering-form-group textarea {
  padding: 10px 12px;
  border: 1px solid #d0d0d0;
  border-radius: 6px;
  font-size: 14px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  transition: all 0.2s ease;
  background-color: #fafafa;
}

.peering-form-group input:focus,
.peering-form-group textarea:focus {
  outline: none;
  border-color: #3498db;
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.peering-form-group input.error,
.peering-form-group textarea.error {
  border-color: #e74c3c;
  background-color: #fdf0f0;
}

.peering-form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.peering-error {
  font-size: 12px;
  color: #e74c3c;
  min-height: 16px;
}

/* ============================================
   NETWORK NAME DISPLAY
   ============================================ */

.network-name-display {
  padding: 10px 12px;
  background: linear-gradient(135deg, #07bc0c 0%, #05a50a 100%);
  color: #ffffff;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
}

.network-name-display::before {
  content: '✓';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  font-size: 12px;
}

/* ============================================
   ASN VALIDATION
   ============================================ */

.asn-validation {
  margin-top: 6px;
  font-size: 13px;
  min-height: 20px;
}

.asn-validation .success {
  color: #07bc0c;
  display: flex;
  align-items: center;
  gap: 6px;
}

.asn-validation .error {
  color: #e74c3c;
  display: flex;
  align-items: center;
  gap: 6px;
}

.asn-validation .validating {
  color: #3498db;
  display: flex;
  align-items: center;
  gap: 6px;
}

.asn-validation .validating::after {
  content: '';
  width: 14px;
  height: 14px;
  border: 2px solid #3498db;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ============================================
   CHECKBOX STYLES
   ============================================ */

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  padding: 10px 12px;
  background-color: #fafafa;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.checkbox-label:hover {
  background-color: #f0f7fc;
  border-color: #3498db;
}

.checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: #3498db;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.checkbox-label span {
  font-size: 14px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  color: #333333;
  line-height: 1.4;
}

/* ============================================
   PEERING TYPE OPTIONS
   ============================================ */

.peering-type-option {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
  background-color: #f8f9fa;
  border-radius: 8px;
}

.nested-section {
  padding-left: 28px;
  animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    max-height: 0;
  }
  to {
    opacity: 1;
    max-height: 1000px;
  }
}

.section-description {
  margin: 0 0 10px 0;
  font-size: 13px;
  color: #666666;
  font-style: italic;
}

/* ============================================
   IXP LIST
   ============================================ */

.ixp-list,
.locations-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 200px;
  overflow-y: auto;
  padding-right: 8px;
}

.ixp-list::-webkit-scrollbar,
.locations-list::-webkit-scrollbar {
  width: 6px;
}

.ixp-list::-webkit-scrollbar-track,
.locations-list::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 3px;
}

.ixp-list::-webkit-scrollbar-thumb,
.locations-list::-webkit-scrollbar-thumb {
  background: #cccccc;
  border-radius: 3px;
}

.ixp-list::-webkit-scrollbar-thumb:hover,
.locations-list::-webkit-scrollbar-thumb:hover {
  background: #999999;
}

.ixp-item,
.location-item {
  padding: 8px 10px;
}

.ixp-info,
.location-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ixp-name,
.location-name {
  font-size: 13px;
  font-weight: 500;
  color: #333333;
}

.ixp-location,
.location-address {
  font-size: 11px;
  color: #888888;
}

/* ============================================
   LOADING & INFO MESSAGES
   ============================================ */

.loading {
  text-align: center;
  padding: 20px;
  color: #3498db;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.loading::after {
  content: '';
  width: 18px;
  height: 18px;
  border: 2px solid #3498db;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.info-message {
  text-align: center;
  padding: 12px;
  background-color: #fff3cd;
  border-left: 3px solid #ffc107;
  border-radius: 4px;
  font-size: 13px;
  color: #856404;
}

/* ============================================
   FORM ACTIONS
   ============================================ */

.peering-form-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  padding-top: 12px;
  border-top: 1px solid #e8e8e8;
}

.peering-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.peering-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.peering-btn-primary {
  background-color: #3498db;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.peering-btn-primary:hover:not(:disabled) {
  background-color: #2980b9;
  box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
  transform: translateY(-1px);
}

.peering-btn-secondary {
  background-color: #e8e8e8;
  color: #555555;
}

.peering-btn-secondary:hover {
  background-color: #d0d0d0;
}

/* ============================================
   ALERTS
   ============================================ */

.peering-alert {
  padding: 12px 16px;
  border-radius: 6px;
  font-size: 13px;
  font-family: 'Roboto Condensed Variable', 'Roboto Condensed', sans-serif;
  display: flex;
  align-items: center;
  gap: 10px;
}

.peering-alert-success {
  background-color: #d4edda;
  border-left: 4px solid #07bc0c;
  color: #155724;
}

.peering-alert-success::before {
  content: '✓';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: #07bc0c;
  color: #ffffff;
  border-radius: 50%;
  font-size: 12px;
  flex-shrink: 0;
}

.peering-alert-error {
  background-color: #f8d7da;
  border-left: 4px solid #e74c3c;
  color: #721c24;
}

.peering-alert-error::before {
  content: '!';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: #e74c3c;
  color: #ffffff;
  border-radius: 50%;
  font-size: 12px;
  flex-shrink: 0;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 700px) {
  .peering-modal-container {
    width: 95%;
    max-height: 95vh;
  }

  .peering-modal-header {
    padding: 16px;
  }

  .peering-modal-header h2 {
    font-size: 18px;
  }

  .peering-modal-body {
    padding: 16px;
  }

  .peering-form-row {
    grid-template-columns: 1fr;
  }

  .peering-form-actions {
    flex-direction: column-reverse;
  }

  .peering-btn {
    width: 100%;
  }

  .nested-section {
    padding-left: 0;
  }

  .ixp-list,
  .locations-list {
    max-height: 150px;
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

.peering-modal-container:focus-within {
  outline: 2px solid #3498db;
  outline-offset: -2px;
}

.peering-form-group input:focus-visible,
.peering-form-group textarea:focus-visible,
.peering-btn:focus-visible {
  outline: 2px solid #3498db;
  outline-offset: 2px;
}

/* Skip to main content link for screen readers */
.peering-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Reduced motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  .peering-modal,
  .peering-modal-container,
  .peering-btn,
  .peering-request-btn,
  .checkbox-label,
  .nested-section,
  .asn-validation .validating::after,
  .loading::after {
    animation: none;
    transition: none;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .peering-modal-container {
    border: 2px solid #000000;
  }

  .peering-btn-primary,
  .peering-request-btn {
    border: 2px solid #000000;
  }

  .checkbox-label {
    border-width: 2px;
  }
}
/* Test comment Tue Mar 24 14:55:20 -03 2026 */
