I have a text and it looks like in pic. I want to make like that. I tired textshadow and box shadow. but i can’t achieve that design. Can someone help me with this.
It seems as if there are multiple text elements rendered on top of each other, not just a single element (look at the upper left corner of the character "v" for example to see what I mean).
In regards to the outline, it might be easier to achieve the desired effect by using SVG instead of HTML, because SVG allows to define the position/alignment of the stroke (inner/center/outer) via paint-order.
Below is a quick and dirty version to get you started.
body {
font-family: sans-serif;
background: hsl(120deg, 40%, 50%);
}
3
Answers
It seems as if there are multiple text elements rendered on top of each other, not just a single element (look at the upper left corner of the character "v" for example to see what I mean).
In regards to the outline, it might be easier to achieve the desired effect by using SVG instead of HTML, because SVG allows to define the position/alignment of the stroke (inner/center/outer) via
paint-order
.Below is a quick and dirty version to get you started.
If we look carefully at the characters, for example the a, we can see that there seem to be two things going on.
The first is a text stroke, which gives a narrow black border around the top.
The second looks like another copy of the character, offset slightly downwards, in black.
This snippet gives the characters a text-stroke and also a text-shadow. The shadow is offset in the y direction and has no blur so it is solid black.
You will need to play around with the sizes to get exactly the effect you want with whatever font and font size you are needing.