@font-face {
    font-family: 'Helvetica Neue';
    src: url('../fonts/HelveticaNeue-Bold.ttf');
    font-weight: 700;
    font-style: bold;
}
@font-face {
    font-family: 'Helvetica';
    src: url('../fonts/Helvetica/Helvetica.ttf');
    font-weight: 400;
    font-style: normal;
}
@font-face {
    font-family: 'Helvetica';
    src: url('../fonts/Helvetica/Helvetica-Bold.ttf');
    font-weight: 700;
    font-style: bold;
}
@font-face {
    font-family: 'Helvetica';
    src: url('../fonts/Helvetica/Helvetica-Oblique.ttf');
    font-weight: 400;
    font-style: italic;
}
@font-face {
    font-family: 'Helvetica';
    src: url('../fonts/Helvetica/Helvetica-BoldOblique.ttf');
    font-weight: 700;
    font-style: italic;
}

:root {
    --flexipay-very-dark-purple: hsl(283, 100%, 14%);
    --flexipay-dark-purple: hsl(284, 100%, 29%);
    --flexipay-purple: hsl(273, 58%, 46%);
    --flexipay-light-purple: hsl(288, 87%, 78%);
    --flexipay-lavender: hsl(287, 80%, 92%);
    --flexipay-peach: hsl(9, 80%, 92%);
    --flexipay-success: hsl(111, 58%, 65%);
}

body {
    font-family: 'Helvetica', sans-serif;
    background-color: var(--flexipay-dark-purple);
    background-image: linear-gradient(90deg, var(--flexipay-dark-purple) 0, var(--flexipay-purple) 50%, var(--flexipay-dark-purple) 100%);
    /* background-image: linear-gradient(90deg, red 0, blue 100%); */
    color: #333;
    margin: 0;
    padding: 120px 0px 0px 0px;
    line-height: 1.6;
    min-height: 400px;
}

main {
    margin-top: 150px;
    min-height: calc(100svh - 148px);
}
.container {
    max-width: 800px;
    margin: 0 auto 20px auto;
    background: #fff;
    padding: 2rem 4rem 4rem 4rem;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

@media (max-width: 800px) {
    .container {
        padding: 20px;
        margin: 0 auto 20px auto;
        border-radius: 5px;
    }
}

h1, h2, h3, h4 {
    font-family: 'Helvetica Neue', sans-serif;
    color: var(--flexipay-dark-purple);
}

h2 {
    margin-top: 0;
    margin-bottom: 20px;
}

h2 + p {
    margin-top: -10px;
    margin-bottom: 20px;
    color: #555;
}

.hidden {
    display: none !important;
}

.form-group {
    padding-top: 15px;
    border-top: 1px solid #e9e9e9 ;
    margin-bottom: 15px;
}

.form-group:first-of-type {
    border-top: none;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-family: 'Helvetica', sans-serif;
    font-weight: 500;
    color: #414141
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
    border: 1px solid #e3e3e3;
    border-radius: 4px;
    font-size: 1rem;
    margin-bottom: 8px;
}

input[type="text"] + select {
    margin-top: 4px;
}

.form-group input:focus-visible {
    outline: 1px solid var(--flexipay-purple);
    border-color: var(--flexipay-purple);
}
.form-group input:focus {
    background: color-mix(in oklab, var(--flexipay-peach) 20%, white);
}

input#postcode, input#prev_postcode {
    text-transform: uppercase;
}

.btn-primary {
    background-color: var(--flexipay-purple);
    color: white;
    padding: 16px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1.0rem;
    margin-right: 10px;
}

.btn-primary:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.btn-primary:hover {
    background-color: var(--flexipay-dark-purple);
}

.btn-secondary {
    background-color: #7d868e;
    color: white;
    padding: 16px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    margin-right: 10px;
    font-size: 1.0rem;
}

.form-group button.btn-secondary {
    padding: 9px 14px;
    font-size: 0.9rem;
    margin-right: 0px;
}

.form-group > div:has( .btn-secondary) {
    display: flex;
    gap: 10px;
    align-items: center;
}

.form-group > div:has( .btn-secondary) input {
    margin: 0;
    flex: 1;
}

.btn-secondary:hover {
    background-color: #60686f;
}


.btn-success {
    background-color: #28a745;
    color: white;
    padding: 16px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    margin-right: 10px;
    font-size: 1.0rem;
}

.btn-small {
    padding: 5px 10px;
    font-size: 0.8rem;
    margin-bottom: 10px;
}

button.btn-success:has( .icon-check-square ) {
    display: flex;
    align-items: center;
}
button.btn-primary:has( .icon-check-square ) span{
    display: none;
    align-items: center;
}

.icon-check-square {
    margin-right: 10px;
}
.icon-check-square svg {
    width: 20px;
    height: 20px;
    fill: #FFFFFF;
}

.button-group:has(#btn-goto-stage-3) {
    display: flex;
    gap: 10px;
}

#btn-finish-directors {
    margin-top: 20px;
}

.radio-columns {
    display: flex;
    gap: 20px;
}

.radio-columns .column {
    flex: 1;
}

.radio-columns label {
    display: block;
    font-weight: normal;
}

/* Modal */
.modal {
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    border-radius: 5px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

#share-warning {
    margin-top: 10px;
}

.director-card {
    border: 1px solid #ddd;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.director-info {
    flex-grow: 1;
}

.director-actions button {
    margin-left: 5px;
    padding: 5px 10px;
    font-size: 0.9em;
}

.text-warning {
    color: #856404;
    background-color: #fff3cd;
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #ffeeba;
}

.text-small {
    font-size: 0.9em;
    color: #666;
}

.mt-4 {
    margin-top: 20px;
}
/* Progress Bar */
#progress-bar {
    width: 100%;
    background-color: #e0e0e0;
    border-radius: 8px;
    margin: 20px 0;
    height: 16px;
    overflow: hidden;
}

#progress-fill {
    height: 100%;
    background-color: #28a745; /* Green */
    background-image: linear-gradient(90deg, var(--flexipay-light-purple) 0%, var(--flexipay-purple) 100%);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 7px;
}

/* Loading Spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
    display: inline-block;
    vertical-align: middle;
    margin-left: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.7);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
}
/* Toast Notification */
.toast {
    visibility: hidden;
    min-width: 250px;
    margin-left: -125px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 2px;
    padding: 16px;
    position: fixed;
    z-index: 1001;
    left: 50%;
    bottom: 30px;
    font-size: 17px;
    opacity: 0;
    transition: opacity 0.5s, bottom 0.5s;
    z-index: 9999;
}

.toast.show {
    visibility: visible;
    opacity: 1;
    bottom: 50px;
}

.toast.error {
    background-color: #d9534f;
}

.toast.success {
    background-color: #28a745;
}

#cashback-card-banner {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    margin-top: -2px;
    margin-bottom: -100px;
    display: grid;
    place-items: start;
}
#cashback-card-background {
    background-image: linear-gradient(90deg, var(--flexipay-lavender) 0px, var(--flexipay-peach) 50%, var(--flexipay-lavender) 100%);
    height: 150px;
    width: 100%;
    z-index: 2;
    grid-column: 1 / 2;
    grid-row: 1 / 2;
}
#cashback-card-banner-image {
    height: 150px;
    width: 100%;
    z-index: 3;
    grid-column: 1 / 2;
    grid-row: 1 / 2;
    display: flex;
    align-items: center;
    justify-content: center;
}

#cashback-card-banner-image img {
    object-fit: contain;
    height: 100%;
    margin: 0 auto;
}
#cashback-card-oblique {
    height: 220px;
    width: 100%;
    position: absolute;
    top: -10px;
    bottom: 0px;
    left: 90px;
    z-index: 4;
    grid-column: 1 / 2;
    grid-row: 1 / 2;
}

#cashback-card-oblique img {
    object-fit: contain;
    height: 100%;
    width: 100%;
}