/* GFVR Flight Price Calculator - Updated Design Alignment */

:root {
  /* GFVR Brand Colors - Exact from Farbpalette */
  --gfvr-spanish-purple: #66033c; /* Spanish Purple - Main */
  --gfvr-burgundy: #a3002e; /* Burgund - Highlight */
  --gfvr-golden-grass: #d2ae23; /* Golden Grass - Akzent */
  --gfvr-revolver: #431f44; /* Revolver - Text */
  --gfvr-light: #feffff; /* Light - Background */
  --gfvr-silver: #c0c0c0; /* Silver - Background */

  /* Standard neutrals */
  --gfvr-white: #ffffff;
  --gfvr-black: #000000;
  --gfvr-dark-gray: #495057;
  --gfvr-medium-gray: #6c757d;
  --gfvr-light-gray: #e9ecef;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  margin: 0;
  padding: 0;
  background: var(--gfvr-light);
  color: var(--gfvr-revolver);
  min-height: 100vh;
}

/* Global Navigation */
.gfvr-nav {
  background: var(--gfvr-white);
  border-bottom: 1px solid var(--gfvr-light-gray);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.gfvr-nav-content {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 40px;
  height: 60px;
}

.gfvr-nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--gfvr-spanish-purple);
  font-weight: 600;
}

.gfvr-nav-icon {
  width: 32px;
  height: 32px;
}

.gfvr-nav-links {
  display: flex;
  gap: 20px;
}

.gfvr-nav-docs {
  margin-left: auto;
}

.gfvr-nav-link {
  text-decoration: none;
  color: var(--gfvr-medium-gray);
  padding: 8px 16px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.gfvr-nav-link:hover {
  color: var(--gfvr-spanish-purple);
  background: var(--gfvr-light-gray);
}

.gfvr-nav-link.active {
  color: var(--gfvr-spanish-purple);
  background: var(--gfvr-light-gray);
  font-weight: 500;
}

.main-header {
  max-width: 1400px;
  margin: 20px auto;
  background: var(--gfvr-white);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  padding: 30px 40px 20px;
  border-top: 4px solid var(--gfvr-spanish-purple);
}

.main-header .logo {
  font-size: 2rem;
  font-weight: 600;
  color: var(--gfvr-spanish-purple);
  margin-bottom: 8px;
  letter-spacing: 1px;
}

.main-header h1 {
  color: var(--gfvr-medium-gray);
  font-size: 1.1rem;
  font-weight: 400;
  margin: 0;
}

.container {
  max-width: 1400px;
  margin: 0 auto 20px auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--gfvr-white);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  min-height: 60vh;
}

.calculator {
  padding: 30px;
  border-right: 1px solid var(--gfvr-light-gray);
  display: flex;
  flex-direction: column;
  background: var(--gfvr-white);
}

.results-section {
  padding: 30px;
  display: flex;
  flex-direction: column;
  background: var(--gfvr-light);
}

.header {
  text-align: center;
  margin-bottom: 25px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--gfvr-light-gray);
}

/* Removed redundant .logo selector - styles handled by .main-header .logo */

.tagline {
  font-size: 0.9rem;
  color: var(--gfvr-medium-gray);
  font-weight: 400;
  font-style: italic;
  margin-bottom: 10px;
}

h1 {
  color: var(--gfvr-spanish-purple);
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
}

.input-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--gfvr-revolver);
  font-size: 0.95rem;
  line-height: 1.2;
}

input[type='number'],
select {
  width: 100%;
  padding: 16px;
  border: 2px solid var(--gfvr-light-gray);
  border-radius: 8px;
  font-size: 13px;
  transition: all 0.2s ease;
  box-sizing: border-box;
  background: var(--gfvr-white);
  color: var(--gfvr-revolver);
  line-height: 1.5;
}

input[type='number']:focus,
select:focus {
  outline: none;
  border-color: var(--gfvr-burgundy);
  box-shadow: 0 0 0 3px rgba(163, 0, 46, 0.1);
}

input[type='number']:hover,
select:hover {
  border-color: var(--gfvr-silver);
}

/* Validation styles */
.validation-error {
  border-color: var(--gfvr-burgundy) !important;
  box-shadow: 0 0 0 3px rgba(163, 0, 46, 0.1) !important;
}

.validation-success {
  border-color: #28a745 !important;
  box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.1) !important;
}

.validation-message {
  margin-top: 6px;
  font-size: 0.85rem;
  line-height: 1.3;
}

.validation-error-message {
  color: var(--gfvr-burgundy);
  background: rgba(163, 0, 46, 0.05);
  padding: 8px 12px;
  border-radius: 4px;
  border-left: 3px solid var(--gfvr-burgundy);
}

.rate-info {
  background: var(--gfvr-light);
  border-left: 4px solid var(--gfvr-golden-grass);
  padding: 16px;
  border-radius: 6px;
  margin-top: 8px;
}

.rate-info small {
  color: var(--gfvr-medium-gray);
  font-size: 0.9rem;
  line-height: 1.5;
}

.rate-info::before {
  content: '💡';
  margin-right: 8px;
}

.calculation-breakdown {
  background: var(--gfvr-white);
  border: 2px solid var(--gfvr-light-gray);
  padding: 20px;
  border-radius: 8px;
  margin-top: 20px;
}

.breakdown-title {
  color: var(--gfvr-spanish-purple);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}

.breakdown-step {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--gfvr-light-gray);
  font-size: 13px;
}

.breakdown-step:last-child {
  border-bottom: none;
  font-weight: 600;
  font-size: 15px;
  color: var(--gfvr-spanish-purple);
  background: var(--gfvr-light);
  padding: 16px;
  margin: 12px -16px -16px -16px;
  border-radius: 6px;
}

.step-label {
  font-weight: 500;
  color: var(--gfvr-revolver);
}

.step-value {
  font-weight: 600;
  color: var(--gfvr-spanish-purple);
}

.final-price {
  text-align: center;
  font-size: 2rem;
  font-weight: 600;
  color: var(--gfvr-white);
  margin: 20px 0;
  padding: 30px;
  background: var(--gfvr-burgundy);
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(163, 0, 46, 0.2);
}

.error-message {
  font-size: 1.2rem;
  color: var(--gfvr-light);
  font-weight: 500;
  line-height: 1.4;
}

.success-amount {
  color: var(--gfvr-light);
}

.profit-highlight {
  background: var(--gfvr-light);
  border-left: 4px solid var(--gfvr-golden-grass);
  padding: 16px;
  border-radius: 6px;
  margin-top: 16px;
  color: var(--gfvr-revolver);
}

.warning {
  background: var(--gfvr-light);
  border-left: 4px solid var(--gfvr-golden-grass);
  padding: 16px;
  border-radius: 6px;
  margin-top: 16px;
  font-size: 0.9rem;
  color: var(--gfvr-medium-gray);
  line-height: 1.5;
}

.refresh-button {
  padding: 12px 24px;
  border: none;
  background: var(--gfvr-burgundy);
  color: var(--gfvr-white);
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: all 0.2s ease;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.refresh-button:hover {
  background: var(--gfvr-spanish-purple);
  transform: translateY(-1px);
}

.refresh-button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.flex-container {
  display: flex;
  gap: 12px;
  align-items: center;
}

.flex-container > div:first-child {
  flex: 1;
}

.rate-display {
  font-size: 13px;
  color: var(--gfvr-medium-gray);
  margin-top: 4px;
  font-weight: 500;
  line-height: 1.4;
}

.currency-selector {
  display: flex;
  gap: 8px;
  align-items: center;
}

.currency-selector input {
  flex: 1;
}

.currency-selector select {
  flex: 0 0 auto;
  width: auto;
  min-width: 70px;
}

.profit-selector {
  display: flex;
  gap: 8px;
  align-items: center;
}

.profit-selector input {
  flex: 1;
}

.profit-selector select {
  flex: 0 0 auto;
  width: auto;
  min-width: 60px;
}

.profit-selector select:first-of-type {
  min-width: 70px;
}

.profit-selector select:last-of-type {
  min-width: 70px;
}

.accent-text {
  color: var(--gfvr-burgundy);
  font-weight: 600;
}

/* Add bottom accent bar like itinerator */
.container::after {
  content: '';
  display: block;
  height: 4px;
  background: var(--gfvr-spanish-purple);
  grid-column: 1 / -1;
}

/* Mobile Responsive Design */
@media (max-width: 1024px) {
  .container {
    grid-template-columns: 1fr;
  }

  .calculator {
    border-right: none;
    border-bottom: 1px solid var(--gfvr-light-gray);
    padding: 20px 30px;
  }

  .results-section {
    padding: 20px 30px;
  }
}

@media (max-width: 768px) {
  body {
    padding: 10px;
  }

  .main-header {
    padding: 20px 20px 15px;
    margin-bottom: 15px;
  }

  .main-header .logo {
    font-size: 1.6rem;
  }

  .main-header h1 {
    font-size: 1rem;
  }

  .calculator,
  .results-section {
    padding: 15px 20px;
  }

  .header {
    margin-bottom: 20px;
    padding-bottom: 15px;
  }

  .logo {
    font-size: 1.3rem;
  }

  h1 {
    font-size: 1rem;
  }

  .input-group {
    margin-bottom: 15px;
  }

  .final-price {
    font-size: 1.5rem;
    padding: 20px;
    margin: 15px 0;
  }

  .flex-container {
    flex-direction: column;
    gap: 8px;
    align-items: stretch;
  }

  .refresh-button {
    width: 100%;
  }

  .breakdown-step {
    font-size: 12px;
  }

  .breakdown-step:last-child {
    font-size: 14px;
  }

  .calculation-breakdown {
    padding: 15px;
  }

  .profit-selector {
    flex-wrap: wrap;
    gap: 6px;
  }

  .profit-selector input {
    flex: 1 1 100%;
    min-width: 0;
  }

  .profit-selector select {
    flex: 1 1 auto;
    min-width: 60px;
  }
}

@media (max-width: 480px) {
  .main-header {
    margin-bottom: 10px;
    padding: 12px;
    border-radius: 8px;
  }

  .main-header .logo {
    font-size: 1.4rem;
  }

  .main-header h1 {
    font-size: 0.95rem;
  }

  .calculator,
  .results-section {
    padding: 15px;
  }

  .container {
    border-radius: 8px;
  }

  .final-price {
    font-size: 1.3rem;
    padding: 15px;
  }

  .currency-selector {
    flex-direction: column;
    gap: 5px;
  }

  .currency-selector select {
    width: 100%;
  }

  .profit-selector {
    flex-direction: column;
    gap: 5px;
  }

  .profit-selector input,
  .profit-selector select {
    width: 100%;
    flex: none;
  }

  .header {
    margin-bottom: 15px;
    padding-bottom: 12px;
  }

  .logo {
    font-size: 1.2rem;
  }

  h1 {
    font-size: 0.9rem;
  }

  input[type='number'],
  select {
    padding: 12px;
    font-size: 13px;
  }

  label {
    font-size: 0.9rem;
  }
}
