

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }
  
  body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #e0f2fe 0%, #b3e5fc 100%);
    min-height: 100vh;
    padding: 20px;
  }
  
  .container {
    max-width: 1200px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
  }
  
  .header {
    text-align: center;
    margin-bottom: 30px;
  }
  
  .title {
    font-size: 2.5em;
    font-weight: bold;
    background: linear-gradient(45deg, #0288d1, #00acc1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
  }
  
  .subtitle {
    color: #666;
    font-size: 1.1em;
  }
  
  .controls {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    align-items: end;
  }
  input.error {
    border-color: red;
    box-shadow: 0 0 5px rgba(255, 0, 0, 0.5);
  }
  
  .input-group {
    flex: 1;
    min-width: 300px;
  }
  
  .input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
  }
  
  .input-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e8ed;
    border-radius: 10px;
    font-size: 16px;
    font-family: 'Courier New', monospace;
    transition: all 0.3s ease;
  }
  
  .input-group input:focus {
    outline: none;
    border-color: #0288d1;
    box-shadow: 0 0 0 3px rgba(2, 136, 209, 0.1);
  }
  
  .button-group {
    display: flex;
    gap: 10px;
  }
  
  .btn {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
  }
  
  .btn-primary {
    background: linear-gradient(45deg, #0288d1, #00acc1);
    color: white;
  }
  
  .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(2, 136, 209, 0.3);
  }
  
  .btn-secondary {
    background: #f5f5f5;
    color: #666;
    border: 2px solid #e1e8ed;
  }
  
  .btn-secondary:hover {
    background: #e1e8ed;
  }
  
  .result-card {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    border: 1px solid rgba(2, 136, 209, 0.2);
  }
  
  .result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
  }
  
  .result-title {
    font-size: 1.4em;
    font-weight: 600;
    color: #333;
  }
  
  .water-counter {
    background: linear-gradient(45deg, #00acc1, #0288d1);
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 1.1em;
    display: flex;
    align-items: center;
    gap: 8px;
  }
  
  .visualization-area {
    background: linear-gradient(180deg, #e3f2fd 0%, #f3e5f5 100%);
    border-radius: 15px;
    padding: 30px;
    overflow-x: auto;
    position: relative;
  }
  
  .svg-container {
    display: flex;
    justify-content: center;
  }
  
  /* Blocks */
  .building {
    fill: #8d6e63;
    stroke: #5d4037;
    stroke-width: 2;
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.3));
  }
  
  .water {
    fill: url(#waterGradient);
    opacity: 0.8;
    transform-origin: bottom;
    animation:
      waterFill 1s ease-out forwards,
      waterFlow 2s ease-in-out infinite alternate;
  }
  
  
  /* Animations */
  @keyframes waterFill {
    0% {
      opacity: 0;
      transform: scaleY(0);
      transform-origin: bottom;
    }
    100% {
      opacity: 0.8;
      transform: scaleY(1);
      transform-origin: bottom;
    }
  }
  
  @keyframes waterFlow {
    0% {
      transform: translateY(1px);
      filter: brightness(1);
    }
    50% {
      transform: translateY(-0.5px);
      filter: brightness(1.1);
    }
    100% {
      transform: translateY(1px);
      filter: brightness(1);
    }
  }
  
  .legend {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 20px;
    flex-wrap: wrap;
  }
  
  .legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 15px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 20px;
    border: 1px solid rgba(2, 136, 209, 0.2);
  }
  
  .legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    border: 1px solid rgba(0,0,0,0.2);
  }
  
  .legend-building {
    background: linear-gradient(45deg, #8d6e63, #5d4037);
  }
  
  .legend-water {
    background: linear-gradient(45deg, #4fc3f7, #29b6f6);
    animation: waterFlow 2s ease-in-out infinite alternate;
  }
  
  /* Responsive */
  @media (max-width: 768px) {
    .controls {
      flex-direction: column;
    }
  
    .input-group {
      min-width: auto;
    }
  
    .result-header {
      flex-direction: column;
      text-align: center;
    }
  
    .legend {
      flex-direction: column;
      align-items: center;
    }
  }
  /* .highlighted {
    animation: glow 1s ease-in-out infinite alternate;
    stroke: #00e5ff;
    stroke-width: 2;
  } */
  input.error {
    border-color: red;
    box-shadow: 0 0 5px rgba(255, 0, 0, 0.5);
  }
  
  .highlighted {
    animation: glow 1s ease-in-out infinite alternate;
    stroke: #00e5ff;
    stroke-width: 2;
  }
  
  @keyframes glow {
    from {
      filter: drop-shadow(0 0 5px #00e5ff);
    }
    to {
      filter: drop-shadow(0 0 15px #00e5ff);
    }
  }
  
  
  @keyframes glow {
    from {
      filter: drop-shadow(0 0 5px #00e5ff);
    }
    to {
      filter: drop-shadow(0 0 15px #00e5ff);
    }
  }
  .water-counter.highlighted {
    animation: waterCounterGlow 1.2s ease-in-out 2;
    box-shadow: 0 0 15px #00bcd4;
    border: 2px solid #00e5ff;
  }
  
  @keyframes waterCounterGlow {
    0% {
      transform: scale(1);
      background-color: #00acc1;
    }
    50% {
      transform: scale(1.1);
      background-color: #4fc3f7;
    }
    100% {
      transform: scale(1);
      background-color: #00acc1;
    }
  }
  
  
  