add: new price card

Added new price card design, wip
This commit is contained in:
Fiona Lena Urban 2025-04-28 21:07:04 +02:00
parent 9d686e2af2
commit 7aa21c1c19
7 changed files with 194 additions and 139 deletions

View file

@ -13,9 +13,42 @@
transition: var(--transition-default);
outline: none;
border: none;
background: transparent;
background: var(--background);
color: var(--color);
&.raised {
box-shadow: var(--box-shadow-z2);
padding: .5em 1.5em;
border-radius: var(--radius-default);
}
&.text {
--background: transparent;
--color: var(--color-black);
padding: .5em 1.5em;
border-radius: var(--radius-default);
&:hover {
--background: rgba(0, 0, 0, 0.05);
}
&.danger {
--color: var(--color-red);
&:hover {
--background: rgba(255, 0, 0, 0.1);
}
}
}
&.round {
display: flex;
justify-content: center;
align-items: center;
border-radius: 100%;
padding: .5rem;
}
&.cta {
background: var(--background);
color: var(--color);

View file

@ -9,16 +9,15 @@
& label {
position: absolute;
font-size: .8em;
top: .3rem;
left: .5rem;
font-size: 1.5em;
top: .7rem;
transition: var(--transition-default);
}
& input {
all: unset;
width: calc(100% - 1rem);
font-size: 1.2em;
padding: 1.3rem .5rem .5rem .5rem;
background: var(--color-white);
@ -27,7 +26,7 @@
}
}
&:has(input:invalid) {
&.error {
border-color: var(--color-red);
outline-width: 2px;
}
@ -36,9 +35,6 @@
& input:not(:placeholder-shown) {
& + label {
color: var(--color-main);
font-size: 1em;
top: .3rem;
right: .5rem;
}
}
}

View file

@ -10,6 +10,7 @@
--color-blue: #2e86de;
--color-blue-dark: #1b4b7f;
--color-grey: #c7c7c7;
--color-black: #333;
--color-orange: #DE9C2F;
@ -127,4 +128,41 @@ body {
.gap-default {
gap: 1rem;
}
.bg-blue {
background: var(--color-blue);
}
.bg-white {
background: var(--color-white);
}
.padding {
gap: 1rem;
padding: var(--padding-default);
}
dialog {
top: 50%;
left: 50%;
width: 100vw;
transform: translate(-50%, -50%);
border: none;
border-radius: var(--radius-default);
font-size: 1rem;
& header {
justify-content: space-between;
align-items: center;
}
& footer {
justify-content: space-between;
}
&::backdrop {
background: rgba(0, 0, 0, 0.5);
}
}

View file

@ -11,83 +11,60 @@
opacity: 0;
}
&.folded {
grid-template-rows: auto 0fr auto;
}
& > header {
color: var(--color-white);
display: flex;
justify-content: space-between;
align-items: center;
font-size: 1.3em;
& > .name-price {
display: flex;
gap: .5rem;
& > span:nth-child(2)::before {
content: '•';
margin-right: .5rem;
opacity: .5;
}
}
& > .Button {
color: var(--color-white);
border: 2px solid var(--color-white);
}
}
& aside {
overflow: hidden;
}
& footer {
display: flex;
justify-content: space-between;
align-items: center;
& > .Button.delete {
scale: 0;
}
& > .Button.deletable {
scale: 1;
}
}
& .padding {
gap: 1rem;
padding: var(--padding-default);
}
& .bg-blue {
background: var(--color-blue);
}
& .bg-white {
background: var(--color-white);
}
& .wrapper {
display: flex;
flex-direction: row;
width: 100%;
gap: 1rem;
justify-content: space-between;
padding-top: 0;
& > * {
flex-basis: 25%;
flex-grow: 1;
flex-basis: 10%;
flex-grow: 0;
}
& > .info {
color: var(--color-white);
align-items: center;
gap: .25rem;
& > .icon {
color: var(--color-blue-light);
font-size: 2rem;
padding: .2rem;
}
& > .price {
font-size: 1.2rem;
display: flex;
align-items: center;
gap: .5rem;
}
& > .pro {
font-size: .8rem;
font-size: .6rem;
font-weight: bold;
color: var(--color-main-light);
}
}
}