/* Modern styling based on Portal.VerifiableCredentials.React */
/* Import Roboto font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&display=swap');

:root {
  --primary-color: #3b82f6; /* blue-600 */
  --primary-hover-color: #2563eb; /* blue-700 */
  --secondary-bg: #f3f4f6; /* gray-100 */
  --secondary-text: #111827; /* gray-900 */
  --secondary-hover-bg: #e5e7eb; /* gray-200 */
  --dark-bg: #1f2937; /* gray-800 */
  --dark-secondary-bg: #374151; /* gray-700 */
  --dark-text: #ffffff;
  --dark-hover-bg: #4b5563; /* gray-600 */
}

body {
  font-family: 'Roboto', system-ui, -apple-system, sans-serif;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  background: linear-gradient(to bottom right, #f9fafb, #f3f4f6);
  padding-top: 64px; /* For fixed navbar - matches h-16 (4rem) */
  padding-bottom: 20px;
}

/* Layout */
.body-content {
  padding: 1rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* Modern Navigation - matching React */
.navbar {
  background-color: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #e5e7eb;
  color: #6b7280; /* text-gray-500 */
  box-shadow: none;
  min-height: 64px; /* h-16 = 4rem = 64px */
  padding: 0;
}

.navbar-inverse {
  background-color: rgba(255, 255, 255, 0.8);
  border-color: #e5e7eb;
}

.navbar > .container {
  max-width: 1280px; /* max-w-7xl */
  padding-left: 1rem;
  padding-right: 1rem;
}

.navbar-inverse .navbar-brand {
  color: #111827; /* text-gray-900 */
  font-weight: 700;
  font-size: 1.25rem;
  padding: 0;
  height: 64px;
  line-height: 64px;
}

.navbar-inverse .navbar-nav > li > a {
  color: #6b7280; /* text-gray-500 */
  transition: color 0.2s;
  font-weight: 500;
  padding: 0 0.75rem;
  height: 64px;
  line-height: 64px;
}

.navbar-inverse .navbar-nav > li > a:hover {
  color: #111827; /* text-gray-900 */
  background: transparent;
}

.navbar-inverse .navbar-toggle {
  border-color: transparent;
  margin-top: 15px;
}

.navbar-inverse .navbar-toggle .icon-bar {
  background-color: #6b7280;
}

.navbar-inverse .navbar-toggle:hover,
.navbar-inverse .navbar-toggle:focus {
  background-color: rgba(229, 231, 235, 0.5); /* gray-200 with opacity */
}

.navbar-inverse .navbar-collapse,
.navbar-inverse .navbar-form {
  border-color: #e5e7eb;
}

/* For dark mode */
@media (prefers-color-scheme: dark) {
  .navbar {
    background-color: rgba(31, 41, 55, 0.8); /* dark:bg-gray-800/80 */
    border-bottom: 1px solid #374151; /* dark:border-gray-700 */
  }
  
  .navbar-inverse {
    background-color: rgba(31, 41, 55, 0.8);
    border-color: #374151;
  }
  
  .navbar-inverse .navbar-brand {
    color: white;
  }
  
  .navbar-inverse .navbar-nav > li > a {
    color: #9ca3af; /* dark:text-gray-400 */
  }
  
  .navbar-inverse .navbar-nav > li > a:hover {
    color: #e5e7eb; /* dark:text-gray-200 */
  }
  
  .navbar-inverse .navbar-toggle .icon-bar {
    background-color: #9ca3af;
  }
  
  .navbar-inverse .navbar-toggle:hover,
  .navbar-inverse .navbar-toggle:focus {
    background-color: rgba(75, 85, 99, 0.5); /* dark:gray-600 with opacity */
  }
  
  .navbar-inverse .navbar-collapse,
  .navbar-inverse .navbar-form {
    border-color: #374151;
  }
}

/* Images */
img {
  max-width: 100%;
  height: auto;
}

/* Modern rounded image styles to match React */
.img-rounded,
.img-responsive,
.thumbnail img,
.thumbnail > img,
.card img,
.panel img {
  border-radius: 0.5rem; /* 8px - matches rounded-lg */
  transition: transform 0.2s ease-in-out;
}

.img-circle {
  border-radius: 9999px; /* Full rounded - matches rounded-full */
}

.img-thumbnail {
  padding: 0.25rem;
  background-color: white;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

/* Image hover effects */
.img-hover:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* Image within cards */
.card img,
.panel img {
  margin-bottom: 1rem;
}

/* Avatar-style images */
.img-avatar {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 9999px;
  object-fit: cover;
  box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.img-avatar-sm {
  width: 2rem;
  height: 2rem;
}

.img-avatar-lg {
  width: 3.5rem;
  height: 3.5rem;
}

/* Hero/banner images */
.img-hero {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 0.5rem;
  margin-bottom: 1.5rem;
}

/* Image overlay container */
.img-overlay-container {
  position: relative;
  border-radius: 0.5rem;
  overflow: hidden;
}

.img-overlay-container img {
  width: 100%;
  border-radius: 0;
}

.img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0));
  display: flex;
  align-items: flex-end;
  padding: 1.5rem;
  color: white;
}

/* Buttons */
.btn {
  font-family: 'Roboto', sans-serif;
  font-weight: 500;
  border-radius: 0.5rem;
  padding: 0.75rem 1.5rem;
  transition: all 0.2s;
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--primary-hover-color);
  color: white;
}

.btn-secondary {
  background-color: var(--secondary-bg);
  color: var(--secondary-text);
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-secondary:hover,
.btn-secondary:focus,
.btn-secondary:active {
  background-color: var(--secondary-hover-bg);
  color: var(--secondary-text);
}

/* Cards */
.card {
  background-color: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
  padding: 1.5rem;
  margin-bottom: 1rem;
}

/* Panel styling to match cards */
.panel {
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
  border: none;
  overflow: hidden;
}

.panel-heading {
  border-top-left-radius: 0.5rem;
  border-top-right-radius: 0.5rem;
  padding: 1rem 1.5rem;
  font-weight: 500;
}

.panel-body {
  padding: 1.5rem;
}

/* Form controls */
.form-control {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  font-family: 'Roboto', sans-serif;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  background-color: white;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Roboto', sans-serif;
  font-weight: 500;
  margin-bottom: 1rem;
  color: var(--secondary-text);
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--primary-hover-color);
  text-decoration: none;
}

/* Tables */
.table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  margin-bottom: 1rem;
}

.table th,
.table td {
  padding: 0.75rem 1rem;
  vertical-align: top;
  border-top: 1px solid #e5e7eb;
}

.table thead th {
  vertical-align: bottom;
  border-bottom: 2px solid #e5e7eb;
  font-weight: 500;
}

.table-striped tbody tr:nth-of-type(odd) {
  background-color: rgba(0, 0, 0, 0.02);
}

.table-hover tbody tr:hover {
  background-color: rgba(0, 0, 0, 0.04);
}

/* Carousel */
.carousel-caption p {
  font-family: 'Roboto', sans-serif;
  font-size: 1.25rem;
  line-height: 1.5;
}

.carousel-inner .item img[src$=".svg"] {
  width: 100%;
}

/* QR code */
#qrCode {
  margin: 1rem 0;
  border-radius: 0.5rem;
  overflow: hidden;
}

/* Media queries */
@media screen and (max-width: 767px) {
  .carousel-caption {
    display: none;
  }
  
  .btn {
    width: 100%;
    margin-bottom: 0.5rem;
  }
  
  .navbar-brand {
    font-size: 1.25rem;
  }
  
  .navbar-inverse .navbar-nav > li > a {
    height: auto;
    line-height: 2.5;
  }
}

/* Supporting dark mode */
@media (prefers-color-scheme: dark) {
  body {
    background: linear-gradient(to bottom right, #111827, #1f2937);
    color: white;
  }
  
  h1, h2, h3, h4, h5, h6 {
    color: white;
  }
  
  .card, .panel {
    background-color: var(--dark-bg);
    color: var(--dark-text);
  }
  
  .panel-heading {
    background-color: var(--dark-secondary-bg);
    color: var(--dark-text);
    border-bottom: 1px solid var(--dark-hover-bg);
  }
  
  .btn-secondary {
    background-color: var(--dark-secondary-bg);
    color: var(--dark-text);
  }
  
  .btn-secondary:hover,
  .btn-secondary:focus,
  .btn-secondary:active {
    background-color: var(--dark-hover-bg);
    color: var(--dark-text);
  }
  
  .form-control {
    background-color: var(--dark-bg);
    border-color: var(--dark-secondary-bg);
    color: var(--dark-text);
  }
  
  .form-control:focus {
    border-color: var(--primary-color);
  }
  
  .img-thumbnail {
    background-color: var(--dark-bg);
    border-color: var(--dark-secondary-bg);
  }
  
  .table th,
  .table td {
    border-top: 1px solid var(--dark-secondary-bg);
  }
  
  .table thead th {
    border-bottom: 2px solid var(--dark-secondary-bg);
  }
  
  .table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(255, 255, 255, 0.05);
  }
  
  .table-hover tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.1);
  }
}
