@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-magenta: hsl(288, 78%, 44%);
    --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 {
    position: relative;
    margin-top: 150px;
    min-height: calc(100svh - 148px);
    position: relative;
    padding-bottom: 4rem;
}

@media (min-width: 1100px) {
    main {
        display: grid;
        grid-template-columns: 5fr 4fr;
        gap: 40px;
        margin: 150px 10px 0px 10px;
    }
}
@media (min-width: 1600px) {
    main {
        max-width: 1600px;
        display: grid;
        grid-template-columns: 4fr 5fr;
        gap: 40px;
        margin: 150px auto 0px auto;
    }
}

.container {
    z-index: 3;
    position: relative;
    max-width: 1100px;
    margin: 0 1rem auto 1rem;
    background: #fff;
    border-radius: 5px;
    padding: 2rem 4rem 4rem 4rem;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    max-height: calc(100vh - 200px);
    overflow-y: auto;
}

@media (min-width: 1100px) {
    .container {
        padding: 40px;
        border-radius: 8px;
        position: sticky;
        top: 150px; /* #alternateHeader height (118px) + 32px gap */
        align-self: start;
        box-shadow: 
        inset 0px 0px 50px -10px hsl(4, 79%, 93%),
        -200px 0px 300px -100px hsl(286, 53%, 48%),
        0px 0px 80px -20px hsl(286, 53%, 48%),
        10px 10px 30px -10px hsl(283, 100%, 14%)
        ;
    }
}

#content {
    z-index: 1;
    width: 100%;
    max-width: 800px;
    margin: 0rem auto 2rem;
    padding: 10px;
}



@media (min-width: 1100px) {
    .container {
        padding: 60px 100px;
    }
    #content {
        margin-right: 2rem;
    }
}

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;
}

.radio-group {
    display: flex;
    gap: 20px;
    margin-top: 8px;
}

.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);
    z-index: 10000;
}

.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;
}

.product-owner-guidance {
    margin: 18px 0 20px;
    padding: 18px 20px;
    border: 1px solid #d7e5eb;
    border-left: 4px solid #24799c;
    border-radius: 8px;
    background: #f4f9fb;
    color: #334d58;
}

.product-owner-guidance > strong { display: block; margin-bottom: 8px; color: #176d91; font-size: 1.05rem; }
.product-owner-guidance p { margin: 0 0 10px; line-height: 1.55; }
.product-owner-guidance small { display: block; padding-top: 10px; border-top: 1px solid #d7e5eb; line-height: 1.5; }
.companies-house-status { margin: 14px 0; }
.product-owner-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin: 16px 0 22px; }
.product-owner-card { display: flex; width: 100%; flex-direction: column; gap: 7px; padding: 16px; text-align: left; color: #334d58; background: #fff; border: 1px solid #8fb8c9; border-radius: 8px; cursor: pointer; font: inherit; line-height: 1.4; }
.product-owner-card:hover, .product-owner-card:focus-visible { background: #eef7fa; outline: 2px solid #24799c; }
.product-owner-card span { font-size: 0.9rem; }
.product-owner-card-action { color: #176d91; font-weight: 700; }
.product-owner-card-add { max-width: 320px; margin-top: 14px; border-style: dashed; background: #f4f9fb; }
.product-progress-saved, .product-resume-status { margin: 10px 0 0; text-align: center; font-size: 0.88rem; color: #49636e; }
.product-resume-status { padding: 9px 12px; border-radius: 6px; background: #f4f9fb; color: #176d91; }

.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;
    transition: opacity 0.3s ease;
}
/* 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%;
}



section.panel {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 0 auto 2rem;
    padding: 20px;
    border-radius: 40px;
    corner-shape: squircle;
}

section.panel.has-card {
    padding: 20px 20px 40px 20px;
    background-color: hsl(305, 57%, 99%);
}

section.panel h2 {
    color: white;
    font-size: 2.4rem;
    line-height: 1.2;
    margin-bottom: 3rem;
    text-shadow: 0 0 20px var(--flexipay-dark-purple);
}
section.panel h3 {
    font-size: 2.4rem;
    color: var(--flexipay-magenta);
    margin-bottom: 1.5rem;
    margin-right: auto;
    line-height: 1.2;
}
section.panel h3.magenta {
    color: var(--flexipay-magenta);
}

section.panel p {
    font-size: 1.1rem;
    color: #333;
    width: 100%;
}

section.panel p.strong,
section.panel p strong {
    color: var(--flexipay-purple);
    font-weight: 500;
}

section.panel ul {
    margin: 2rem 0 2rem 2rem;
    width: calc(100% - 2rem);
}


section.panel li {
    margin-bottom: 0.75rem;
    display: flex;
    gap: 10px;
    align-items: flex-start;
}


section.panel li:has(.icon-check) {
    padding-left: 0;
    margin-bottom: 2rem;
    font-size: 1.2rem;
}
section.panel li:has(.icon-check):last-child {
    margin-bottom: 0;
}

section.panel li .icon-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}
section.panel li .icon-check path {
    fill: var(--flexipay-magenta);
}


section.panel hr {
    outline: none;
    border: 0;
    border-top: 1px solid var(--flexipay-light-purple);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
}

@media (min-width: 800px) {
    section.panel {
        padding: 40px;
    }
}

@media (min-width: 1100px) {
    section.panel {
        padding: 60px 100px;
    }
}

.has-credit-card-background {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    position: relative;
    place-items: center;
}
.has-credit-card-background h2 {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
    z-index: 5;
}
.has-credit-card-background img {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
    z-index: 1;
    opacity: 0.25;
    object-fit: contain;
    object-position: center;
    height: 480px;
    width: 100%;
    transform-origin: center;
    rotate: -30deg;
}

.card-content {
    border-radius: 40px;
    corner-shape: squircle;
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.card-footer {
    background-color: var(--flexipay-magenta);
    margin: 0 -52px -72px -52px;
    padding: 20px 32px;
    border-radius: 0 0 40px 40px;
    corner-shape: squircle;
    color: white;
    font-size: 1.1rem;
}

.card-content h4 {
    color: var(--flexipay-dark-purple);
    font-size: 1.5rem;
    margin: 0 auto 0 0;
    text-align: left;
}

section.panel .card-footer p {
    color: white;
    text-align: center;
    text-wrap: balance;
    font-weight: 500;
    font-size: 1.2rem;
}

.breakout {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 0rem auto 2rem;
    padding: 20px 40px;
    background-color: var(--flexipay-lavender);
    border-radius: 24px;
    corner-shape: squircle;
    display: flex;
    gap: 20px;
    align-items: center;
}


.breakout .floating-image {
    position: absolute;
    top: 50%;
    left: 80%;
    transform: translate(-50%, -50%);
    z-index: 2;
}
.breakout .floating-image img {
    width: 250px;
    height: 250px;
    object-fit: contain;
}


.breakout:has(.floating-image) {
    display: flex;
    justify-content: center;
    text-align: center;
    margin: 4rem auto;
    border-radius: 200px;
    corner-shape: round;
}
.breakout:has(.floating-image) p {
    font-size: 1.5rem;
    font-weight: 500;
    text-align: center;
    margin-right: 150px;
    color: var(--flexipay-dark-purple);
}

.breakout .icon {
    width: 100px;
    height: 100px;
    flex-shrink: 0;
}

.breakout p {
    margin: 0;
    font-size: 1.1rem;
    color: #333;
    text-wrap: balance;
    text-align: center;
}

section.panel:has(.sidebar) .card-content {
}

section.panel .sidebar {
    background-color: var(--flexipay-magenta);
    padding: 2rem;
    margin: 0rem -52px -72px -52px;
    border-radius: 0 0 40px 40px;
    corner-shape: squircle;
}
section.panel .sidebar p {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 500;
    text-align: center;
    color: white;
    text-wrap: balance;
}


.card-side {
    background-color: var(--flexipay-magenta);
    color: white;
    border-radius: 36px;
    corner-shape: squircle;
    padding: 0px;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 20px;
    max-width: 400px;
    margin: 0 auto;
}

@media (min-width: 1600px) {
    .card-side {
        position: absolute;
        top: 50%;
        right: -50px;
        transform: translateY(-50%);
        width: 300px;
    }

    .panel:has(.card-side) .card-content {
        width: 66%;
    }
}


.card-side .part p { color: white;}

.card-side .part:nth-child(1)  p {
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: 0.03em;
    margin: 0;
}
.card-side .part:nth-child(2) {
    background: var(--flexipay-very-dark-purple);
    border-radius: 48px 48px 100% 100%;
    corner-shape: squircle;
    width: 100%;
    padding: 20px 20px;
    margin-bottom: 20px;
}

.card-side .part:nth-child(2) p,
.card-side .part:nth-child(3) p {
    text-align: center;
}

.card-side .part:nth-child(2) p:nth-of-type(1),
.card-side .part:nth-child(3) p:nth-of-type(1) {
    display: block;
    font-weight: 700;
    font-size: 3.5rem;
    margin: 0;
    line-height: 1;
}

.card-side .part:nth-child(2) p:nth-of-type(1) span,
.card-side .part:nth-child(3) p:nth-of-type(1) span {
    font-size: 2.25rem;
    display: inline-block;
    transform: translateY(-1rem);
    margin: 0;
}


.card-side .part:nth-child(2) p:nth-of-type(2),
.card-side .part:nth-child(3) p:nth-of-type(2) {
    font-weight: 700;
    font-size: 1.6rem;
    margin: 0;
    line-height: 1;
}
.card-side .part:nth-child(2) p:nth-of-type(3) {}
.card-side .part:nth-child(2) p:nth-of-type(4),
.card-side .part:nth-child(3) p:nth-of-type(4) {
    font-size: 0.9rem;
}

section.panel.panel-transparent h3,
section.panel.panel-transparent p {
    color: white;
}
section.panel.panel-transparent p {
    margin-bottom: 1rem;
    line-height: 1.5;
}


.accumulate p:nth-of-type(2) {
    color: var(--flexipay-magenta);
    font-weight: 500; 
}


.two-column-table {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-radius: 32px 32px 32px 32px;
    border: 2px solid var(--flexipay-magenta)

}

.table-header {
    display: grid;
    grid-template-columns: subgrid;
    grid-column: 1 / 3;
    font-weight: 700;
    background: var(--flexipay-very-dark-purple);
    color: white;
    border-radius: 30px 30px 0px 0px;
    border-bottom: 2px solid var(--flexipay-magenta);
}

.table-body {
    display: grid;
    grid-template-columns: subgrid;
    grid-column: 1 / 3;
    color: var(--flexipay-magenta);
    border-radius: 0 0 24px 24px;
}
.table-header .cell,
.table-body .cell {
    display: grid;
    grid-template-columns: subgrid;
    padding: 10px;
}

.cell p {
    display: block;
    margin: 0;
    padding: 10px 20px;
    text-wrap: balance;
}

.cell:nth-child(2) {
    grid-column: 2 / 3;
    border-left: 2px solid var(--flexipay-magenta);
}

.two-column-table .table-header .cell p {
    font-size: 1.1rem;
    color: white;
} 

/* Content Footer */
.content-footer {
    width: 100%;
    max-width: 800px;
    margin: 0rem auto 2rem;
    padding: 20px;
    border-radius: 40px;
    corner-shape: squircle;
    background-color: var(--flexipay-lavender);
    text-align: center;
}

.content-footer h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.content-footer h4 {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    color: var(--flexipay-magenta);
    font-weight: 300;
    font-size: 1.8rem;
}


.content-footer .bulleted-list {
    list-style: none;
    padding: 0;
    margin: 0 0 0 2rem;
    display: inline-flex;
    flex-direction: column;
    gap: 20px;
}


.content-footer .bullet-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.content-footer .bullet-item p {
    margin: 0 auto 0 0;
    font-size: 1.1rem;
    color: #333;
    text-wrap: balance;
    text-align: left;
}

.content-footer .bullet-item .icon-check {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    margin-right: 1rem;
}
.content-footer .bullet-item .icon-check path {
    fill: var(--flexipay-magenta);
}
