181 lines
4.2 KiB
CSS
181 lines
4.2 KiB
CSS
@import url("https://fonts.googleapis.com/css2?family=Red+Hat+Display:wght@500;700;900&display=swap");
|
|
|
|
/*
|
|
Mobile Screen Width: 375 x 709
|
|
Figma Box : 327 x 567
|
|
Ratio 0.872 x 0.7997179126
|
|
|
|
Desktop Width: 1440 x 900
|
|
Figma Box: 450 x 697
|
|
Ratio 0.3125 x 0.7744444444
|
|
*/
|
|
:root {
|
|
/* Colors */
|
|
--clr-pale-blue: hsl(225, 100%, 94%);
|
|
--clr-bright-blue: hsl(245, 75%, 52%);
|
|
|
|
--clr-very-pale-blue: hsl(225, 100%, 98%);
|
|
--clr-desaturated-blue: hsl(224, 23%, 55%);
|
|
--clr-dark-blue: hsl(223, 47%, 23%);
|
|
--clr-light-purple: hsla(245, 83%, 68%, 1);
|
|
|
|
/* Fonts */
|
|
--fs-p: 1rem;
|
|
--fw-500: 500;
|
|
--fw-700: 700;
|
|
--fw-900: 900;
|
|
|
|
/* Border Radii */
|
|
--br-11: 11px;
|
|
--br-20: 20px;
|
|
|
|
/* Scaling fonts between the left and right sizes */
|
|
--font-width-15px-16px: clamp(0.94rem, 0.92rem + 0.09vw, 1rem);
|
|
--font-width-14px-16px: clamp(0.88rem, 0.83rem + 0.19vw, 1rem);
|
|
|
|
/*
|
|
Used for the Price Plan box and the Proceed to Payment button
|
|
sensibly these should be two seperate variables in case the
|
|
components where used in different places */
|
|
--box-width: 85%;
|
|
|
|
--page-background-img: url("../images/pattern-background-mobile.svg");
|
|
}
|
|
|
|
*,
|
|
::before,
|
|
::after {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
/* because I want it to affect the link color */
|
|
color: var(--clr-desaturated-blue);
|
|
}
|
|
|
|
/* General Formatting */
|
|
|
|
html,
|
|
body {
|
|
min-height: 100vh;
|
|
width: 100%;
|
|
}
|
|
|
|
body {
|
|
font-family: "Red Hat Display", sans-serif;
|
|
background-color: var(--clr-pale-blue);
|
|
}
|
|
|
|
main {
|
|
background-image: var(--page-background-img);
|
|
background-repeat: no-repeat;
|
|
min-height: inherit;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
/* Order Summary Card formatting */
|
|
|
|
.card {
|
|
width: clamp(327px, 32%, 450px);
|
|
border-radius: var(--br-20);
|
|
background-color: white;
|
|
text-align: center;
|
|
|
|
box-shadow: 0px 40px 40px -20px rgba(13, 48, 189, 0.151826);
|
|
}
|
|
.card__hero-image {
|
|
width: 100%;
|
|
border-radius: var(--br-20) var(--br-20) 0 0;
|
|
margin-bottom: clamp(2rem, 8vw, 2.815rem);
|
|
}
|
|
|
|
.card__title {
|
|
font-weight: var(--fw-900);
|
|
font-size: clamp(1.375rem, 2.5vw, 1.815rem);
|
|
line-height: 1.3195;
|
|
margin-bottom: 1rem;
|
|
color: var(--clr-dark-blue);
|
|
}
|
|
|
|
.card__info {
|
|
font-weight: var(--fw-500);
|
|
margin: 0 clamp(2rem, 4vw, 3rem);
|
|
font-size: var(--font-width-15px-16px);
|
|
margin-bottom: 1.5rem;
|
|
line-height: 162%;
|
|
}
|
|
|
|
.card__price-plan {
|
|
display: flex;
|
|
justify-content: space-around;
|
|
align-items: center;
|
|
|
|
width: var(--box-width);
|
|
margin: 0 auto clamp(1.5rem, 2vw, 2rem) auto;
|
|
padding: clamp(1rem, 2vw, 1.5315rem) 0;
|
|
|
|
border-radius: var(--br-11);
|
|
background-color: var(--clr-very-pale-blue);
|
|
}
|
|
|
|
.card__plan-type-area {
|
|
line-height: 1.3125;
|
|
}
|
|
|
|
.card__plan-type {
|
|
color: var(--clr-dark-blue);
|
|
font-size: var(--font-width-14px-16px);
|
|
font-weight: var(--fw-900);
|
|
margin-bottom: clamp(0.1875rem, 0.8vw, 0.375rem);
|
|
}
|
|
.card__plan-price {
|
|
font-size: var(--font-width-14px-16px);
|
|
font-weight: 500;
|
|
}
|
|
.card__change-button {
|
|
font-size: clamp(0.813rem, 0.79rem + 0.09vw, 0.88rem);
|
|
font-weight: var(--fw-700);
|
|
color: var(--clr-bright-blue);
|
|
}
|
|
|
|
.card__button-area a {
|
|
display: block;
|
|
text-decoration: none;
|
|
font-weight: var(--fw-900);
|
|
font-size: 0.9375rem;
|
|
line-height: 20px;
|
|
}
|
|
.card__payment-button {
|
|
color: white;
|
|
background-color: var(--clr-bright-blue);
|
|
width: var(--box-width);
|
|
margin: 0 auto clamp(1.5rem, 4vw, 2rem) auto;
|
|
box-shadow: 0px 20px 20px rgba(56, 42, 225, 0.190291);
|
|
border-radius: var(--br-11);
|
|
padding: 15px 0;
|
|
}
|
|
.card__cancel-button {
|
|
margin-bottom: clamp(2rem, 8vw, 3rem);
|
|
}
|
|
|
|
.card__change-button:is(:hover, :focus) {
|
|
color: var(--clr-light-purple);
|
|
}
|
|
|
|
.card__payment-button:is(:hover, :focus) {
|
|
background-color: var(--clr-light-purple);
|
|
}
|
|
|
|
.card__cancel-button:is(:hover, :focus) {
|
|
color: var(--clr-dark-blue);
|
|
}
|
|
|
|
@media screen and (min-width: 376px) {
|
|
:root {
|
|
--box-width: 80%;
|
|
--page-background-img: url("../images/pattern-background-desktop.svg");
|
|
}
|
|
}
|