/* Icon Pack Utilities - Security Theme */
/* Font Awesome 6 Pro with Feather Icons fallback */

:root {
  --icon-primary: #239af4;
  --icon-secondary: #1a7bc4;
  --icon-success: #10b981;
  --icon-warning: #f59e0b;
  --icon-danger: #ef4444;
  --icon-light: #f3f4f6;
  --icon-dark: #1a1a1a;
}

/* Icon Base Styles */
i[class*="fas"],
i[class*="fab"],
i[class*="far"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Icon Sizing Utilities */
.icon-xs { font-size: 0.75rem; }
.icon-sm { font-size: 1rem; }
.icon-md { font-size: 1.5rem; }
.icon-lg { font-size: 2rem; }
.icon-xl { font-size: 2.5rem; }
.icon-2xl { font-size: 3rem; }
.icon-3xl { font-size: 3.5rem; }

/* Icon Color Utilities */
.icon-primary { color: var(--icon-primary); }
.icon-secondary { color: var(--icon-secondary); }
.icon-success { color: var(--icon-success); }
.icon-warning { color: var(--icon-warning); }
.icon-danger { color: var(--icon-danger); }
.icon-light { color: var(--icon-light); }
.icon-dark { color: var(--icon-dark); }
.icon-white { color: white; }

/* Icon Animation Utilities */
.icon-spin {
  animation: spin 2s linear infinite;
}

.icon-pulse {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.icon-bounce {
  animation: bounce 1s infinite;
}

.icon-flip {
  animation: flip 0.6s ease-in-out;
}

.icon-shake {
  animation: shake 0.5s ease-in-out;
}

.icon-swing {
  animation: swing 1s ease-in-out infinite;
  transform-origin: top center;
}

.icon-tada {
  animation: tada 0.6s ease-in-out;
}

.icon-heartbeat {
  animation: heartbeat 1.3s ease-in-out infinite;
}

/* Icon Hover Effects */
.icon-hover-lift:hover {
  transform: translateY(-3px);
}

.icon-hover-scale:hover {
  transform: scale(1.2);
}

.icon-hover-rotate:hover {
  transform: rotate(15deg);
}

.icon-hover-color:hover {
  color: var(--icon-primary);
}

.icon-hover-glow:hover {
  filter: drop-shadow(0 0 8px var(--icon-primary));
}

/* Icon Badge */
.icon-badge {
  position: relative;
  display: inline-block;
}

.icon-badge::after {
  content: attr(data-badge);
  position: absolute;
  top: -8px;
  right: -8px;
  background: var(--icon-danger);
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
}

/* Icon Wrapper */
.icon-wrapper {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--icon-light);
  transition: all 0.3s ease;
}

.icon-wrapper.sm { width: 32px; height: 32px; }
.icon-wrapper.md { width: 48px; height: 48px; }
.icon-wrapper.lg { width: 64px; height: 64px; }
.icon-wrapper.xl { width: 80px; height: 80px; }

.icon-wrapper.primary {
  background: linear-gradient(135deg, var(--icon-primary), var(--icon-secondary));
  color: white;
}

.icon-wrapper.success {
  background: var(--icon-success);
  color: white;
}

.icon-wrapper.warning {
  background: var(--icon-warning);
  color: white;
}

.icon-wrapper.danger {
  background: var(--icon-danger);
  color: white;
}

.icon-wrapper:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(35, 154, 244, 0.3);
}

/* Icon with Text */
.icon-text {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.icon-text.gap-sm { gap: 4px; }
.icon-text.gap-md { gap: 12px; }
.icon-text.gap-lg { gap: 16px; }

/* Icon List */
.icon-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.icon-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.icon-list li i {
  color: var(--icon-primary);
  flex-shrink: 0;
  width: 20px;
  text-align: center;
}

/* Icon Grid */
.icon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
  gap: 16px;
  padding: 20px;
}

.icon-grid-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  border-radius: 8px;
  background: #f8f9fa;
  transition: all 0.3s ease;
  cursor: pointer;
}

.icon-grid-item:hover {
  background: var(--icon-light);
  transform: translateY(-4px);
}

.icon-grid-item i {
  font-size: 1.5rem;
  color: var(--icon-primary);
}

.icon-grid-item span {
  font-size: 0.7rem;
  text-align: center;
  color: #666;
}

/* Animations */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes flip {
  0% { transform: perspective(400px) rotateY(0); }
  100% { transform: perspective(400px) rotateY(360deg); }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

@keyframes swing {
  20% { transform: rotate(15deg); }
  40% { transform: rotate(-10deg); }
  60% { transform: rotate(5deg); }
  80% { transform: rotate(-5deg); }
  100% { transform: rotate(0deg); }
}

@keyframes tada {
  0% { transform: scale(1) rotate(0deg); }
  10%, 20% { transform: scale(0.9) rotate(-3deg); }
  30%, 50%, 70%, 90% { transform: scale(1.1) rotate(3deg); }
  40%, 60%, 80% { transform: scale(1.1) rotate(-3deg); }
  100% { transform: scale(1) rotate(0deg); }
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  14% { transform: scale(1.3); }
  28% { transform: scale(1); }
  42% { transform: scale(1.3); }
  70% { transform: scale(1); }
}

/* Security-Specific Icons */
.icon-security { color: var(--icon-danger); }
.icon-verified { color: var(--icon-success); }
.icon-warning-icon { color: var(--icon-warning); }
.icon-info { color: var(--icon-primary); }

/* Responsive Icon Sizing */
@media (max-width: 768px) {
  .icon-lg { font-size: 1.5rem; }
  .icon-xl { font-size: 2rem; }
  .icon-2xl { font-size: 2.5rem; }
  .icon-3xl { font-size: 3rem; }
  
  .icon-wrapper.lg { width: 56px; height: 56px; }
  .icon-wrapper.xl { width: 64px; height: 64px; }
}

/* Icon Loading State */
.icon-loading {
  animation: spin 1s linear infinite;
  opacity: 0.6;
}

/* Icon Disabled State */
.icon-disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Icon Tooltip */
.icon-tooltip {
  position: relative;
}

.icon-tooltip::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #1a1a1a;
  color: white;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  margin-bottom: 8px;
}

.icon-tooltip:hover::after {
  opacity: 1;
}

/* Icon Gradient */
.icon-gradient {
  background: linear-gradient(135deg, var(--icon-primary), var(--icon-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Icon Shadow */
.icon-shadow {
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.icon-shadow-lg {
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.15));
}

/* Icon Stacked */
.icon-stack {
  position: relative;
  display: inline-block;
  width: 2em;
  height: 2em;
  line-height: 2em;
  vertical-align: -0.125em;
}

.icon-stack-1x,
.icon-stack-2x {
  position: absolute;
  left: 0;
  width: 100%;
  text-align: center;
}

.icon-stack-1x { line-height: inherit; }
.icon-stack-2x { font-size: 2em; }

.icon-stack-1x.icon-inverse { color: white; }
