.ei-root {
    all: initial;
    display: block;
    font-family: inherit;
    margin: 0 auto;
    max-width: 90% !important;
}

.ei-container {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#ei-search {
  width: 320px;
  padding: 0.75rem 1rem 0.75rem 2.6rem;
  border: 2px solid #000;
  border-radius: 999px;
  outline: none;
  font-size: 1rem;
  margin: 0 auto 2rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 0.9rem center;
  background-size: 1.1rem 1.1rem;
}

#ei-search::placeholder {
  color: #666;
}

.ei-form-container {
    width: 100%;
    background: #272727;
    box-shadow: 0px 0px 26px 5px #272727;
    padding: 100px 0;
    margin-top: 70px;
}

.ei-form {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 900px;
    margin: auto;
    padding: 24px;
    text-align: center;
    color: #ffffff;
}

.ei-form h2 {
    font-size: 36px;
    line-height: 1.5;
    margin-top: 0;
    color: #ffffff;
}

.ei-form .ei-divider {
    width: 200px;
    height: 3px;
    background-color: #ffffff;
    margin: 0 auto 40px;
}

.ei-form h3 {
    font-size: 20px;
    line-height: 1.5;
}

#ei-add-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: left;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

#ei-add-form input {
    margin-bottom: 20px;
    box-sizing: border-box;
    -webkit-box-sizing:border-box;
    -moz-box-sizing: border-box;
}

#ei-add-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

#ei-add-form input, 
#ei-add-form select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
}

.ei-submit,
#ei-share-button,
#ei-copy-qr {
    display: block;
    width: 40%;
    padding: 15px;
    background-color: #b94013;
    color: white;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    margin: auto;
}

.ei-loading {
    text-align: center;
    padding: 40px 0;
}

.ei-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #ddd;
    border-top: 4px solid #333;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.ei-result {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#ei-qr {
    width: fit-content;
    margin: auto;
}

#ei-share-link {
    margin-top: 2rem;
    box-sizing: border-box;
    -webkit-box-sizing:border-box;
    -moz-box-sizing: border-box;
    width: 70%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
}

.ei-result-buttons {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    margin-top: 4rem;;
}

#ei-insamling-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(285px, 1fr));
    gap: 1.5rem;
}

.insamling-card {
    background: #fff;
    border: 4px solid #000;
    border-radius: 18px;
    padding: 1.5rem;
    text-align: center;
}

.insamling-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-break: anywhere;
}

.insamling-amount {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.progress-bar {
    background: #e0e0e0;
    border-radius: 999px;
    height: 12px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-fill {
    background: #a84f1d;
    height: 100%;
    width: 0;
    transition: width 0.4s ease;
}

.insamling-goal {
    font-size: 0.85rem;
    color: #444;
    margin-bottom: 1.25rem;
}

.donate-btn,
.share-btn {
    display: inline-block;
    background: #a84f1d;
    color: #fff;
    padding: 0.75rem 0;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 700;
    letter-spacing: 0.05em;
    cursor: pointer;
    width: 126px;
}

.donate-btn:hover,
.share-btn:hover {
    background: #8f4318;
}

#toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    color: #333;
    background-color: #fff;
    border: #333 1px solid;
    padding: 12px 16px;
    border-radius: 8px;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

#toast.show {
    opacity: 1;
}