@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&family=Lato:wght@400;700&display=swap');

*, ::before, ::after {
  box-sizing: border-box;
  border-width: 0;
  border-style: solid;
}

html {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
}

body {
  margin: 0;
  line-height: inherit;
  background-color: #0A1A2A;
  color: #ffffff;
  font-family: 'Lato', sans-serif;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: inherit;
  margin: 0;
}

a {
  color: inherit;
  text-decoration: inherit;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: 100%;
  line-height: inherit;
  color: inherit;
  margin: 5px  10px 0px 0px;
  padding: 0;
}

button, select {
  text-transform: none;
}

button, [type='button'], [type='submit'] {
  -webkit-appearance: button;
  background-color: transparent;
  background-image: none;
}

img, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* Utility Classes */
.container { width: 100%; margin-left: auto; margin-right: auto; padding-left: 1rem; padding-right: 1rem; }
@media (min-width: 640px) { .container { max-width: 640px; } }
@media (min-width: 768px) { .container { max-width: 768px; } }
@media (min-width: 1024px) { .container { max-width: 1024px; } }
@media (min-width: 1280px) { .container { max-width: 1280px; } }

.mx-auto { margin-left: auto; margin-right: auto; }
.my-4 { margin-top: 1rem; margin-bottom: 1rem; }
.my-6 { margin-top: 1.5rem; margin-bottom: 1.5rem; }
.my-8 { margin-top: 2rem; margin-bottom: 2rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }
.ml-2 { margin-left: 0.5rem; }
.ml-3 { margin-left: 0.75rem; }
.mr-2 { margin-right: 0.5rem; }
.mr-3 { margin-right: 0.75rem; }

.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }

.flex { display: flex; }
.inline-flex { display: inline-flex; }
.grid { display: grid; }
.hidden { display: none; }
.block { display: block; }

.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }
.items-start { align-items: flex-start; }
.items-center { align-items: center; }
.items-end { align-items: flex-end; }
.justify-start { justify-content: flex-start; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.justify-between { justify-content: space-between; }

.gap-2 { gap: 0.5rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.gap-10 { gap: 2.5rem; }

.w-full { width: 100%; }
.w-auto { width: auto; }
.max-w-md { max-width: 28rem; }
.max-w-lg { max-width: 32rem; }
.max-w-xl { max-width: 36rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.min-h-screen { min-height: 100vh; }

.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }

.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.uppercase { text-transform: uppercase; }
.tracking-wide { letter-spacing: 0.025em; }
.leading-relaxed { line-height: 1.625; }

.rounded { border-radius: 0.25rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-full { border-radius: 9999px; }

.border { border-width: 1px; }
.border-2 { border-width: 2px; }

.shadow { box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1); }
.shadow-lg { box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1); }

.cursor-pointer { cursor: pointer; }
.outline-none { outline: 2px solid transparent; outline-offset: 2px; }

.transition { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-colors { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.duration-200 { transition-duration: 200ms; }

.space-y-4 > * + * { margin-top: 1rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }
.space-y-8 > * + * { margin-top: 2rem; }
.space-y-10 > * + * { margin-top: 2.5rem; }

/* Colors */
.bg-imc-bg { background-color: #0A1A2A; }
.bg-imc-card { background-color: #07131F; }
.bg-imc-input { background-color: #0F1F33; }
.bg-imc-cta {
    background-color: #00C853;
    height: 5rem;
    width: 20rem;
}
.bg-imc-cta:hover, .hover\:bg-imc-cta-hover:hover { background-color: #00A844; }

.text-white { color: #ffffff; }
.text-imc-title { color: #FFBA00; }
.text-imc-text-muted { color: rgba(255, 255, 255, 0.6); }
.text-red-400 { color: #f87171; }
.text-green-400 { color: #4ade80; }

.border-imc-border { border-color: #17314E; }
.border-imc-title { border-color: #FFBA00; }

/* Gauge Colors */
.bg-gauge-critical {
    background-color: #FF3B30;
    padding: 5px 10px 5px 10px;
    height: 3rem;
    margin: 10px;
}
.bg-gauge-unstable {
    background-color: #FF9500;
    padding: 5px 10px 5px 10px;
    height: 3rem;
    margin: 10px;
}
.bg-gauge-transition {
    background-color: #FFCC00;
    padding: 5px 10px 5px 10px;
    height: 3rem;
    margin: 10px;
}
.bg-gauge-stable {
    background-color: #34C759;
    padding: 5px 10px 5px 10px;
    height: 3rem;
    margin: 10px;
}
.bg-gauge-scalable {
    background-color: #0F9D58;
    padding: 5px 10px 5px 10px;
    height: 3rem;
    margin: 10px;
}

/* Component Classes */
.imc-card {
  background-color: #07131F;
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}
@media (min-width: 768px) {
  .imc-card { padding: 2rem; }
}

.imc-input {
  width: 100%;
  background-color: #0F1F33;
  border: 1px solid #17314E;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  color: #ffffff;
  transition: border-color 150ms, box-shadow 150ms;
}
.imc-input::placeholder { color: rgba(255, 255, 255, 0.6); }
.imc-input:focus {
  outline: none;
  border-color: #FFBA00;
  box-shadow: 0 0 0 1px #FFBA00;
}

.imc-select {
  width: 100%;
  background-color: #0F1F33;
  border: 1px solid #17314E;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  padding-right: 2.5rem;
  color: #ffffff;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23FFBA00' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  transition: border-color 150ms, box-shadow 150ms;
}
.imc-select:focus {
  outline: none;
  border-color: #FFBA00;
  box-shadow: 0 0 0 1px #FFBA00;
}
.imc-select option {
  background-color: #07131F;
  color: #ffffff;
  padding: 0.5rem;
}

.imc-btn-primary {
  width: 100%;
  background-color: #00C853;
  color: #ffffff;
  font-weight: 700;
  padding: 1rem 1.5rem;
  border-radius: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  cursor: pointer;
  transition: background-color 200ms;
  border: none;
}
.imc-btn-primary:hover { background-color: #00A844; }
.imc-btn-primary:disabled {
  background-color: #4a5568;
  cursor: not-allowed;
}

.imc-label {
  display: block;
  color: #FFBA00;
  font-weight: 600;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.imc-subtitle {
  color: rgba(255, 255, 255, 0.6);
  font-size: 1rem;
  line-height: 1.625;
}
@media (min-width: 768px) {
  .imc-subtitle { font-size: 1.125rem; }
}

.imc-pillar-title {
  color: #FFBA00;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
}

.imc-question {
  color: #ffffff;
  font-size: 1rem;
  margin-bottom: 1rem;
  line-height: 1.625;
}
@media (min-width: 768px) {
  .imc-question { font-size: 1.125rem; }
}

.imc-error {
  color: #f87171;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* Responsive */
@media (min-width: 768px) {
  .md\:flex { display: flex; }
  .md\:hidden { display: none; }
  .md\:flex-row { flex-direction: row; }
  .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:p-8 { padding: 2rem; }
  .md\:text-lg { font-size: 1.125rem; line-height: 1.75rem; }
  .md\:text-xl { font-size: 1.25rem; line-height: 1.75rem; }
  .md\:text-2xl { font-size: 1.5rem; line-height: 2rem; }
  .md\:text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
  .md\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
  .md\:gap-8 { gap: 2rem; }
}

@media (min-width: 1024px) {
  .lg\:flex { display: flex; }
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lg\:gap-12 { gap: 3rem; }
}

/* Focus ring for accessibility */
.focus\:ring-1:focus { box-shadow: 0 0 0 1px #FFBA00; }
.focus\:ring-imc-title:focus { --tw-ring-color: #FFBA00; }
.focus\:border-imc-title:focus { border-color: #FFBA00; }
.focus\:outline-none:focus { outline: 2px solid transparent; outline-offset: 2px; }

/* Validation styles */
.field-validation-error { color: #f87171; font-size: 0.875rem; margin-top: 0.25rem; display: block; }
.input-validation-error { border-color: #f87171 !important; }
.validation-summary-errors { color: #f87171; margin-bottom: 1rem; }
.validation-summary-errors ul { list-style: disc; padding-left: 1.25rem; }
