پیشنمایش زنده
کد HTML
<div class="rounded-2xl shadow-lg p-3 bg-indigo-500 text-gray-600 max-w-xs">
<div
class="relative flex flex-col items-center p-5 pt-10 bg-blue-100 rounded-xl"
>
<span
class="mt-[-12px] absolute top-0 right-0 flex items-center bg-indigo-500 rounded-l-full py-2 px-3 text-xl font-semibold text-amber-100"
>
$49 <small class="text-xs ml-1 text-white">/ month</small>
</span>
<p
class="text-xl font-semibold text-blue-800 bg-indigo-200 px-2 py-1 rounded-lg"
>
Professional
</p>
<p class="text-center mt-3">
This plan is for those who have a team already and running a large
business.
</p>
<ul class="flex flex-col space-y-3 mt-4">
<li class="flex items-center space-x-2">
<span
class="flex items-center justify-center w-5 h-5 bg-teal-500 text-white rounded-full"
>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
width="14"
height="14"
>
<path fill="none" d="M0 0h24v24H0z"></path>
<path
d="M10 15.172l9.192-9.193 1.415 1.414L10 18l-6.364-6.364 1.414-1.414z"
fill="currentColor"
></path>
</svg>
</span>
<span
><strong class="font-semibold text-gray-800">20</strong> team
members</span
>
</li>
<li class="flex items-center space-x-2">
<span
class="flex items-center justify-center w-5 h-5 bg-teal-500 text-white rounded-full"
>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
width="14"
height="14"
>
<path fill="none" d="M0 0h24v24H0z"></path>
<path
d="M10 15.172l9.192-9.193 1.415 1.414L10 18l-6.364-6.364 1.414-1.414z"
fill="currentColor"
></path>
</svg>
</span>
<span
>Plan
<strong class="font-semibold text-gray-800"
>team meetings</strong
></span
>
</li>
<li class="flex items-center space-x-2">
<span
class="flex items-center justify-center w-5 h-5 bg-teal-500 text-white rounded-full"
>
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 24 24"
width="14"
height="14"
>
<path fill="none" d="M0 0h24v24H0z"></path>
<path
d="M10 15.172l9.192-9.193 1.415 1.414L10 18l-6.364-6.364 1.414-1.414z"
fill="currentColor"
></path>
</svg>
</span>
<span>File sharing</span>
</li>
</ul>
<div class="w-full flex justify-end mt-6">
<a
class="w-full py-3 text-center text-white bg-indigo-600 rounded-lg font-medium text-lg hover:bg-indigo-700 focus:outline-none"
href="#"
>
Choose plan
</a>
</div>
</div>
</div>
کد CSS
.absolute {
position: absolute;
}
.relative {
position: relative;
}
.right-0 {
right: 0px;
}
.top-0 {
top: 0px;
}
.ml-1 {
margin-left: 0.25rem;
}
.mt-3 {
margin-top: 0.75rem;
}
.mt-4 {
margin-top: 1rem;
}
.mt-6 {
margin-top: 1.5rem;
}
.mt-\[-12px\] {
margin-top: -12px;
}
.flex {
display: flex;
}
.h-5 {
height: 1.25rem;
}
.w-5 {
width: 1.25rem;
}
.w-full {
width: 100%;
}
.max-w-xs {
max-width: 20rem;
}
.flex-col {
flex-direction: column;
}
.items-center {
align-items: center;
}
.justify-end {
justify-content: flex-end;
}
.justify-center {
justify-content: center;
}
.space-x-2 > :not([hidden]) ~ :not([hidden]) {
--tw-space-x-reverse: 0;
margin-right: calc(0.5rem * var(--tw-space-x-reverse));
margin-left: calc(0.5rem * calc(1 - var(--tw-space-x-reverse)));
}
.space-y-3 > :not([hidden]) ~ :not([hidden]) {
--tw-space-y-reverse: 0;
margin-top: calc(0.75rem * calc(1 - var(--tw-space-y-reverse)));
margin-bottom: calc(0.75rem * var(--tw-space-y-reverse));
}
.rounded-2xl {
border-radius: 1rem;
}
.rounded-full {
border-radius: 9999px;
}
.rounded-lg {
border-radius: 0.5rem;
}
.rounded-xl {
border-radius: 0.75rem;
}
.rounded-l-full {
border-top-left-radius: 9999px;
border-bottom-left-radius: 9999px;
}
.bg-blue-100 {
--tw-bg-opacity: 1;
background-color: rgb(219 234 254 / var(--tw-bg-opacity));
}
.bg-indigo-200 {
--tw-bg-opacity: 1;
background-color: rgb(199 210 254 / var(--tw-bg-opacity));
}
.bg-indigo-500 {
--tw-bg-opacity: 1;
background-color: rgb(99 102 241 / var(--tw-bg-opacity));
}
.bg-indigo-600 {
--tw-bg-opacity: 1;
background-color: rgb(79 70 229 / var(--tw-bg-opacity));
}
.bg-teal-500 {
--tw-bg-opacity: 1;
background-color: rgb(20 184 166 / var(--tw-bg-opacity));
}
.p-3 {
padding: 0.75rem;
}
.p-5 {
padding: 1.25rem;
}
.px-2 {
padding-left: 0.5rem;
padding-right: 0.5rem;
}
.px-3 {
padding-left: 0.75rem;
padding-right: 0.75rem;
}
.py-1 {
padding-top: 0.25rem;
padding-bottom: 0.25rem;
}
.py-2 {
padding-top: 0.5rem;
padding-bottom: 0.5rem;
}
.py-3 {
padding-top: 0.75rem;
padding-bottom: 0.75rem;
}
.pt-10 {
padding-top: 2.5rem;
}
.text-center {
text-align: center;
}
.text-lg {
font-size: 1.125rem;
line-height: 1.75rem;
}
.text-xl {
font-size: 1.25rem;
line-height: 1.75rem;
}
.text-xs {
font-size: 0.75rem;
line-height: 1rem;
}
.font-medium {
font-weight: 500;
}
.font-semibold {
font-weight: 600;
}
.text-amber-100 {
--tw-text-opacity: 1;
color: rgb(254 243 199 / var(--tw-text-opacity));
}
.text-blue-800 {
--tw-text-opacity: 1;
color: rgb(30 64 175 / var(--tw-text-opacity));
}
.text-gray-600 {
--tw-text-opacity: 1;
color: rgb(75 85 99 / var(--tw-text-opacity));
}
.text-gray-800 {
--tw-text-opacity: 1;
color: rgb(31 41 55 / var(--tw-text-opacity));
}
.text-white {
--tw-text-opacity: 1;
color: rgb(255 255 255 / var(--tw-text-opacity));
}
.shadow-lg {
--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1),
0 4px 6px -4px rgb(0 0 0 / 0.1);
--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color),
0 4px 6px -4px var(--tw-shadow-color);
box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000),
var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
}
.hover\:bg-indigo-700:hover {
--tw-bg-opacity: 1;
background-color: rgb(67 56 202 / var(--tw-bg-opacity));
}
.focus\:outline-none:focus {
outline: 2px solid transparent;
outline-offset: 2px;
}